]> git.karo-electronics.de Git - karo-tx-linux.git/commit
drm/mipi_dsi: refactor device creation
authorArchit Taneja <architt@codeaurora.org>
Wed, 19 Aug 2015 10:44:09 +0000 (16:14 +0530)
committerSrinivas Kandagatla <srinivas.kandagatla@linaro.org>
Mon, 11 Jan 2016 09:54:41 +0000 (09:54 +0000)
commitc5cabe2bcdf2d461724c95c9a65e97d1a131bc33
tree90ddb6a4304e0e1f80b2aa2ad8d344632431c53a
parentafd2ff9b7e1b367172f18ba7f693dfb62bdcb2dc
drm/mipi_dsi: refactor device creation

Create a helper function mipi_dsi_device_new which takes in struct
mipi_dsi_device_info and the mipi_dsi_host. This will be called by
of_mipi_dsi_device_add.

Instead of calling device_initialize and device_add separately, merge
it into a single device_register call. This will remove the need of
having two separate funcs mipi_dsi_device_alloc and mipi_dsi_device_add.

The reason for creating mipi_dsi_device_new is that it can also be used
as a standalone way for creating a dsi device that isn't available via
DT.

Signed-off-by: Archit Taneja <architt@codeaurora.org>
drivers/gpu/drm/drm_mipi_dsi.c
include/drm/drm_mipi_dsi.h