[PATCH 31/48] drm: omapdrm: hdmi4: Allocate the omap_hdmi data structure dynamically

Sebastian Reichel sre at kernel.org
Mon Oct 16 10:27:57 UTC 2017


Hi,

On Fri, Oct 13, 2017 at 05:59:27PM +0300, Laurent Pinchart wrote:
> The omap_hdmi private data structure is currently stored as a global
> variable. While no platform with multiple HDMI4 encoders currently
> exists nor is planned, this doesn't comply with the kernel device model
> and should thus be fixed.
> 
> Signed-off-by: Laurent Pinchart <laurent.pinchart at ideasonboard.com>
> ---

[...]

> -static void hdmi_init_output(struct platform_device *pdev)
> +static void hdmi_init_output(struct omap_hdmi *hdmi)
>  {
> -	struct omap_dss_device *out = &hdmi.output;
> +	struct omap_dss_device *out = &hdmi->output;
>  
> -	out->dev = &pdev->dev;
> +	out->dev = &hdmi->pdev->dev;
>  	out->id = OMAP_DSS_OUTPUT_HDMI;
>  	out->output_type = OMAP_DISPLAY_TYPE_HDMI;
> -	out->name = "hdmi.0";
> +	out->name = "hdmi->0";

I guess this was an unintended side-effect of "s/hdmi./hdmi->/g"?

-- Sebastian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/dri-devel/attachments/20171016/13a607c6/attachment.sig>


More information about the dri-devel mailing list