From: Carlos Palminha <CARLOS.PALMINHA@synopsys.com>
To: Daniel Vetter <daniel@ffwll.ch>,
Carlos Palminha <CARLOS.PALMINHA@synopsys.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>,
Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
dri-devel@lists.freedesktop.org
Subject: Re: [PATCH v2] drm: fixes when bridge mode_fixup is null.
Date: Wed, 10 Feb 2016 12:26:13 +0000 [thread overview]
Message-ID: <56BB2C65.1080304@synopsys.com> (raw)
In-Reply-To: <20160210122234.GT11240@phenom.ffwll.local>
I'll send a v3 patch with the removal for dw-hdmi
On 10-02-2016 12:22, Daniel Vetter wrote:
> On Wed, Feb 10, 2016 at 11:21:16AM +0000, Carlos Palminha wrote:
>> Avoid drivers to copy/past code to implement functions that will only return
>> true.
>>
>> Changes v1->v2:
>> * Added Signed off by
>>
>> Signed-off-by: Carlos Palminha <palminha@synopsys.com>
>> ---
>> drivers/gpu/drm/drm_bridge.c | 2 ++
>> 1 file changed, 2 insertions(+)
>>
>> diff --git a/drivers/gpu/drm/drm_bridge.c b/drivers/gpu/drm/drm_bridge.c
>> index bd93453..4133e51 100644
>> --- a/drivers/gpu/drm/drm_bridge.c
>> +++ b/drivers/gpu/drm/drm_bridge.c
>> @@ -161,6 +161,8 @@ bool drm_bridge_mode_fixup(struct drm_bridge *bridge,
>>
>> if (bridge->funcs->mode_fixup)
>> ret = bridge->funcs->mode_fixup(bridge, mode, adjusted_mode);
>> + else
>> + return true;
>
> Ok, this doesn't make sense - if there's no fixup function for this bridge
> we should still call any fixup functions of bridges further down the
> chain. And ret is initialized already to true, so this should work.
>
> Where/how exactly do you see this blow up?
>
> Aside: dw-hdmi has a dummy mode_fixup function in it's bridge vtable, can
> you pls create a patch to remove that one? All other bridge drivers don't
> have a mode_fixup function at all.
> -Daniel
>
>>
>> ret = ret && drm_bridge_mode_fixup(bridge->next, mode, adjusted_mode);
>>
>> --
>> 2.5.0
>>
>
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
prev parent reply other threads:[~2016-02-10 12:26 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-10 11:03 [PATCH] drm: fixes when bridge mode_fixup is null Carlos Palminha
2016-02-10 11:11 ` Fabio Estevam
2016-02-10 11:21 ` [PATCH v2] " Carlos Palminha
2016-02-10 12:22 ` Daniel Vetter
2016-02-10 12:26 ` Carlos Palminha [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=56BB2C65.1080304@synopsys.com \
--to=carlos.palminha@synopsys.com \
--cc=daniel.vetter@ffwll.ch \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=laurent.pinchart@ideasonboard.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.