brcm2708: update linux 4.4 patches to latest version
[openwrt/openwrt.git] / target / linux / brcm2708 / patches-4.4 / 0438-drm-mipi-dsi-Unregister-bus-at-exit.patch
1 From 229ed4a50a90820a5288c7f839db1f089bed71c4 Mon Sep 17 00:00:00 2001
2 From: Takashi Iwai <tiwai@suse.de>
3 Date: Tue, 2 Aug 2016 14:16:42 +0200
4 Subject: [PATCH] drm/mipi-dsi: Unregister bus at exit
5
6 This is a preliminary patch for building drm-mipi-dsi as a module.
7 Add the module exit callback to unregister the bus properly.
8
9 Suggested-by: Thierry Reding <treding@nvidia.com>
10 Signed-off-by: Takashi Iwai <tiwai@suse.de>
11 Signed-off-by: Eric Anholt <eric@anholt.net>
12 ---
13 drivers/gpu/drm/drm_mipi_dsi.c | 6 ++++++
14 1 file changed, 6 insertions(+)
15
16 --- a/drivers/gpu/drm/drm_mipi_dsi.c
17 +++ b/drivers/gpu/drm/drm_mipi_dsi.c
18 @@ -928,6 +928,12 @@ static int __init mipi_dsi_bus_init(void
19 }
20 postcore_initcall(mipi_dsi_bus_init);
21
22 +static void __exit mipi_dsi_bus_exit(void)
23 +{
24 + bus_unregister(&mipi_dsi_bus_type);
25 +}
26 +module_exit(mipi_dsi_bus_exit);
27 +
28 MODULE_AUTHOR("Andrzej Hajda <a.hajda@samsung.com>");
29 MODULE_DESCRIPTION("MIPI DSI Bus");
30 MODULE_LICENSE("GPL and additional rights");