diff options
| author | Maxime Ripard <mripard@kernel.org> | 2025-06-26 12:04:59 +0200 |
|---|---|---|
| committer | Maxime Ripard <mripard@kernel.org> | 2025-06-27 11:22:39 +0200 |
| commit | 2d22b63f3a5aae2088708941d08cf0f01f430a58 (patch) | |
| tree | 6cba712bef5e21fc61ed4b626094d492c3e9c2b1 /include | |
| parent | 55e8ff842051b1150461d7595d8f1d033c69d66b (diff) | |
drm/mipi-dsi: Add dev_is_mipi_dsi function
This will be especially useful for generic panels (like panel-simple)
which can take different code path depending on if they are MIPI-DSI
devices or platform devices.
Reviewed-by: Javier Martinez Canillas <javierm@redhat.com>
Tested-by: Francesco Dolcini <francesco.dolcini@toradex.com> # Toradex Colibri iMX6
Link: https://lore.kernel.org/r/20250626-drm-panel-simple-fixes-v2-1-5afcaa608bdc@kernel.org
Signed-off-by: Maxime Ripard <mripard@kernel.org>
Diffstat (limited to 'include')
| -rw-r--r-- | include/drm/drm_mipi_dsi.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/drm/drm_mipi_dsi.h b/include/drm/drm_mipi_dsi.h index b37860f4a895..6d2c08e81101 100644 --- a/include/drm/drm_mipi_dsi.h +++ b/include/drm/drm_mipi_dsi.h @@ -223,6 +223,9 @@ struct mipi_dsi_multi_context { #define to_mipi_dsi_device(__dev) container_of_const(__dev, struct mipi_dsi_device, dev) +extern const struct bus_type mipi_dsi_bus_type; +#define dev_is_mipi_dsi(dev) ((dev)->bus == &mipi_dsi_bus_type) + /** * mipi_dsi_pixel_format_to_bpp - obtain the number of bits per pixel for any * given pixel format defined by the MIPI DSI |
