[PATCH v3 28/32] drm/exynos: Implement drm_connector in hdmi directly

Tomasz Figa tomasz.figa at gmail.com
Mon Dec 2 01:54:32 PST 2013


On Monday 02 of December 2013 10:46:37 Thierry Reding wrote:
> On Fri, Nov 29, 2013 at 04:58:46PM +0100, Tomasz Figa wrote:
> > On Tuesday 29 of October 2013 12:13:14 Sean Paul wrote:
> [...]
> > > diff --git a/drivers/gpu/drm/exynos/exynos_hdmi.c b/drivers/gpu/drm/exynos/exynos_hdmi.c
> [...]
> > > @@ -811,11 +816,60 @@ static int hdmi_check_mode(struct exynos_drm_display *display,
> > >  
> > >  	ret = mixer_check_mode(mode);
> > >  	if (ret)
> > > -		return ret;
> > > +		return MODE_BAD;
> > 
> > Is there a need to define custom return values, instead of returning 0 or
> > a standard error code depending on whether the mode is correct?
> 
> That's not a custom return value. It's one of the values in the
> drm_mode_status enumeration (include/drm/drm_crtc.h). They are used to
> transport more meaning than one of the standard error codes.

OK. Strange thing is that LXR doesn't index them.

> In this
> case one could argue that MODE_BAD doesn't transport very much meaning,
> though, and I think it would be more useful to modify mixer_check_mode()
> to return a specific MODE_* value rather than one of the standard error
> codes.

Right.

Best regards,
Tomasz



More information about the dri-devel mailing list