Displaying 6 results from an estimated 6 matches for "__drm_encoder_init".
Did you mean:
dw_drm_encoder_init
2020 Feb 07
3
[PATCH 2/6] drm: Add drm_simple_encoder_{init,create}()
...char *name, ...)
> +{
> + char *namestr = NULL;
> + int ret;
> +
> + if (name) {
> + va_list ap;
> +
> + va_start(ap, name);
> + namestr = kvasprintf(GFP_KERNEL, name, ap);
> + va_end(ap);
> + if (!namestr)
> + return -ENOMEM;
> + }
> +
> + ret = __drm_encoder_init(dev, encoder,
> + &drm_simple_encoder_funcs_cleanup,
> + encoder_type, namestr);
> + if (ret)
> + goto err_kfree;
> +
> + return 0;
> +
> +err_kfree:
> + if (name)
> + kfree(namestr);
> + return ret;
> +}
> +EXPORT_SYMBOL(drm_simple_encoder_init)...
2020 Feb 07
3
[PATCH 2/6] drm: Add drm_simple_encoder_{init,create}()
...char *name, ...)
> +{
> + char *namestr = NULL;
> + int ret;
> +
> + if (name) {
> + va_list ap;
> +
> + va_start(ap, name);
> + namestr = kvasprintf(GFP_KERNEL, name, ap);
> + va_end(ap);
> + if (!namestr)
> + return -ENOMEM;
> + }
> +
> + ret = __drm_encoder_init(dev, encoder,
> + &drm_simple_encoder_funcs_cleanup,
> + encoder_type, namestr);
> + if (ret)
> + goto err_kfree;
> +
> + return 0;
> +
> +err_kfree:
> + if (name)
> + kfree(namestr);
> + return ret;
> +}
> +EXPORT_SYMBOL(drm_simple_encoder_init)...
2020 Feb 07
0
[PATCH 2/6] drm: Add drm_simple_encoder_{init,create}()
...*dev,
+ struct drm_encoder *encoder,
+ int encoder_type, const char *name, ...)
+{
+ char *namestr = NULL;
+ int ret;
+
+ if (name) {
+ va_list ap;
+
+ va_start(ap, name);
+ namestr = kvasprintf(GFP_KERNEL, name, ap);
+ va_end(ap);
+ if (!namestr)
+ return -ENOMEM;
+ }
+
+ ret = __drm_encoder_init(dev, encoder,
+ &drm_simple_encoder_funcs_cleanup,
+ encoder_type, namestr);
+ if (ret)
+ goto err_kfree;
+
+ return 0;
+
+err_kfree:
+ if (name)
+ kfree(namestr);
+ return ret;
+}
+EXPORT_SYMBOL(drm_simple_encoder_init);
+
+static void drm_encoder_destroy(struct drm_encoder *encoder)...
2020 Feb 07
1
[PATCH 2/6] drm: Add drm_simple_encoder_{init,create}()
...; + return ERR_PTR(-ENOMEM);
> +
> + if (name) {
> + va_list ap;
> +
> + va_start(ap, name);
> + namestr = kvasprintf(GFP_KERNEL, name, ap);
> + va_end(ap);
> + if (!namestr) {
> + ret = -ENOMEM;
> + goto err_devm_kfree;
> + }
> + }
> +
> + ret = __drm_encoder_init(dev, encoder,
> + &drm_simple_encoder_funcs_destroy,
> + encoder_type, namestr);
> + if (ret)
> + goto err_kfree;
> +
> + return encoder;
> +
> +err_kfree:
> + if (name)
> + kfree(namestr);
> +err_devm_kfree:
> + devm_kfree(dev->dev, encoder);
&g...
2020 Feb 07
0
[PATCH 2/6] drm: Add drm_simple_encoder_{init,create}()
...L;
>> + int ret;
>> +
>> + if (name) {
>> + va_list ap;
>> +
>> + va_start(ap, name);
>> + namestr = kvasprintf(GFP_KERNEL, name, ap);
>> + va_end(ap);
>> + if (!namestr)
>> + return -ENOMEM;
>> + }
>> +
>> + ret = __drm_encoder_init(dev, encoder,
>> + &drm_simple_encoder_funcs_cleanup,
>> + encoder_type, namestr);
>> + if (ret)
>> + goto err_kfree;
>> +
>> + return 0;
>> +
>> +err_kfree:
>> + if (name)
>> + kfree(namestr);
>> + return ret;
>>...
2020 Feb 07
11
[PATCH 0/6] drm: Provide a simple encoder
Many DRM drivers implement an encoder with an empty implementation. This
patchset adds drm_simple_encoder_init() and drm_simple_encoder_create(),
which can be used by drivers instead. Except for the destroy callback, the
simple encoder's implementation is empty.
The patchset also converts 4 encoder instances to use the simple-encoder
helpers. But there are at least 11 other drivers which can