drm: bridge: dw-hdmi: Move IRQ and IO resource allocation to common code
authorLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tue, 17 Jan 2017 08:28:57 +0000 (10:28 +0200)
committerArchit Taneja <architt@codeaurora.org>
Wed, 18 Jan 2017 03:59:32 +0000 (09:29 +0530)
commitc608119dfdde9710e4bd068d632beb68bb3517db
tree766785412556c76904149eec5fa51e6a0509cdd3
parentba5d7e6160b7aed4df92d1764aa90790db0e7996
drm: bridge: dw-hdmi: Move IRQ and IO resource allocation to common code

There's no need to duplicate identical code in multiple drivers (two at
the moment, one more to come soon). Move it to the dw-hdmi core where it
can be shared. If resource allocation ever becomes device-specific later
we'll always have the option of splitting it out again.

While it at pass the platform device to the bind function to avoid
having to cast struct device to struct platform_device.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Reviewed-by: Jose Abreu <joabreu@synopsys.com>
Signed-off-by: Archit Taneja <architt@codeaurora.org>
Link: http://patchwork.freedesktop.org/patch/msgid/20170117082910.27023-8-laurent.pinchart+renesas@ideasonboard.com
drivers/gpu/drm/bridge/dw-hdmi.c
drivers/gpu/drm/imx/dw_hdmi-imx.c
drivers/gpu/drm/rockchip/dw_hdmi-rockchip.c
include/drm/bridge/dw_hdmi.h