From: Chris Zhong <zyw@rock-chips.com>
To: heiko@sntech.de, linux-rockchip@lists.infradead.org,
mark.yao@rock-chips.com, treding@nvidia.com
Cc: Chris Zhong <zyw@rock-chips.com>,
linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org
Subject: [PATCH v5 05/11] drm: bridge: allow some funcs to be optional
Date: Thu, 26 Nov 2015 15:50:19 +0800 [thread overview]
Message-ID: <1448524225-5489-6-git-send-email-zyw@rock-chips.com> (raw)
In-Reply-To: <1448524225-5489-1-git-send-email-zyw@rock-chips.com>
Check the validity of post_disable/pre_enable in bridge->funcs before
call them.
Signed-off-by: Chris Zhong <zyw@rock-chips.com>
---
Changes in v5: None
Changes in v4: None
Changes in v3: None
Changes in v2: None
drivers/gpu/drm/drm_bridge.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/gpu/drm/drm_bridge.c b/drivers/gpu/drm/drm_bridge.c
index 6b8f721..8f29330 100644
--- a/drivers/gpu/drm/drm_bridge.c
+++ b/drivers/gpu/drm/drm_bridge.c
@@ -223,7 +223,8 @@ void drm_bridge_post_disable(struct drm_bridge *bridge)
if (!bridge)
return;
- bridge->funcs->post_disable(bridge);
+ if (bridge->funcs->post_disable)
+ bridge->funcs->post_disable(bridge);
drm_bridge_post_disable(bridge->next);
}
@@ -273,7 +274,8 @@ void drm_bridge_pre_enable(struct drm_bridge *bridge)
drm_bridge_pre_enable(bridge->next);
- bridge->funcs->pre_enable(bridge);
+ if (bridge->funcs->pre_enable)
+ bridge->funcs->pre_enable(bridge);
}
EXPORT_SYMBOL(drm_bridge_pre_enable);
--
2.6.3
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2015-11-26 7:50 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-26 7:50 [PATCH v5 0/11] Add mipi dsi support for rk3288 Chris Zhong
[not found] ` <1448524225-5489-1-git-send-email-zyw-TNX95d0MmH7DzftRWevZcw@public.gmane.org>
2015-11-26 7:50 ` [PATCH v5 01/11] clk: rockchip: add id for mipidsi sclk on rk3288 Chris Zhong
[not found] ` <1448524225-5489-2-git-send-email-zyw-TNX95d0MmH7DzftRWevZcw@public.gmane.org>
2015-11-26 13:57 ` Heiko Stübner
2015-11-26 7:50 ` [PATCH v5 06/11] Documentation: dt-bindings: Add bindings for DW MIPI DSI Chris Zhong
2015-11-26 7:50 ` [PATCH v5 10/11] ARM: dts: rockchip: add rk3288 mipi_dsi nodes Chris Zhong
2015-11-26 7:50 ` [PATCH v5 02/11] clk: rockchip: add mipidsi clocks on rk3288 Chris Zhong
2015-11-26 13:58 ` Heiko Stübner
2015-11-26 7:50 ` [PATCH v5 03/11] drm/rockchip: return a true clock rate to adjusted_mode Chris Zhong
2015-11-26 7:50 ` [PATCH v5 04/11] drm/dsi: Add a helper to get bits per pixel of MIPI DSI pixel format Chris Zhong
2015-11-26 7:50 ` Chris Zhong [this message]
2015-11-26 7:50 ` [PATCH v5 07/11] drm/bridge: Add Synopsys DesignWare MIPI DSI host controller driver Chris Zhong
2015-11-26 7:50 ` [PATCH v5 08/11] drm: rockchip: Support Synopsys DesignWare MIPI DSI host controller Chris Zhong
2015-11-26 7:50 ` [PATCH v5 09/11] Documentation: dt-bindings: Add bindings for rk3288 DW MIPI DSI driver Chris Zhong
2015-11-26 7:50 ` [PATCH v5 11/11] ARM: dts: rockchip: add support mipi panel tv080wum-nl0 for rk3288-evb Chris Zhong
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=1448524225-5489-6-git-send-email-zyw@rock-chips.com \
--to=zyw@rock-chips.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=heiko@sntech.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rockchip@lists.infradead.org \
--cc=mark.yao@rock-chips.com \
--cc=treding@nvidia.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox