Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

drm: Remove unnecessary include statements for drm_crtc_helper.h

Several DRM core and helper source files include drm_crtc_helper.h
without needing it or only to get its transitive include statements;
leading to unnecessary compile-time dependencies.

Directly include required headers and drop drm_crtc_helper.h where
possible. The header file, drm_fixed.h, includes <linux/kernel.h>
for lower_32_bits().

v2:
* include drm_crtc_helper.h in drm_crtc_helper.c (Sam)

Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Sam Ravnborg <sam@ravnborg.org>
Acked-by: Jani Nikula <jani.nikula@intel.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20230116131235.18917-3-tzimmermann@suse.de

+2 -2
+1 -1
drivers/gpu/drm/drm_lease.c
··· 6 6 #include <linux/uaccess.h> 7 7 8 8 #include <drm/drm_auth.h> 9 - #include <drm/drm_crtc_helper.h> 9 + #include <drm/drm_crtc.h> 10 10 #include <drm/drm_drv.h> 11 11 #include <drm/drm_file.h> 12 12 #include <drm/drm_lease.h>
-1
drivers/gpu/drm/drm_plane_helper.c
··· 28 28 #include <drm/drm_atomic.h> 29 29 #include <drm/drm_atomic_helper.h> 30 30 #include <drm/drm_atomic_uapi.h> 31 - #include <drm/drm_crtc_helper.h> 32 31 #include <drm/drm_device.h> 33 32 #include <drm/drm_drv.h> 34 33 #include <drm/drm_encoder.h>
+1
include/drm/drm_fixed.h
··· 25 25 #ifndef DRM_FIXED_H 26 26 #define DRM_FIXED_H 27 27 28 + #include <linux/kernel.h> 28 29 #include <linux/math64.h> 29 30 30 31 typedef union dfixed {