Blob Blame History Raw
From: Takashi Iwai <tiwai@suse.de>
Subject: Fix kABI breakage due to additional fields in drm structs
Patch-mainline: Never, kABI fix
References: FATE#325208

The commit c3ff0cdb354f89a5b877eee61af70e6ae51de50b
  drm: Expose modes with aspect ratio, only if requested
and the commit 7595bda2fb4378ccbb8db1d0e8de56d15ea7f7fa
  drm: Add DRM client cap for aspect-ratio
add new fields that break kABI.

Add typical workarounds.
  
Signed-off-by: Takashi Iwai <tiwai@suse.de>

---
 include/drm/drm_file.h  |   18 ++++++++++--------
 include/drm/drm_modes.h |    2 ++
 2 files changed, 12 insertions(+), 8 deletions(-)

--- a/include/drm/drm_file.h
+++ b/include/drm/drm_file.h
@@ -182,14 +182,6 @@ struct drm_file {
 	unsigned atomic:1;
 
 	/**
-	 * @aspect_ratio_allowed:
-	 *
-	 * True, if client can handle picture aspect ratios, and has requested
-	 * to pass this information along with the mode.
-	 */
-	unsigned aspect_ratio_allowed:1;
-
-	/**
 	 * @is_master:
 	 *
 	 * This client is the creator of @master. Protected by struct
@@ -200,6 +192,16 @@ struct drm_file {
 	 */
 	unsigned is_master:1;
 
+#ifndef __GENKSYMS__
+	/**
+	 * @aspect_ratio_allowed:
+	 *
+	 * True, if client can handle picture aspect ratios, and has requested
+	 * to pass this information along with the mode.
+	 */
+	unsigned aspect_ratio_allowed:1;
+#endif
+
 	/**
 	 * @master:
 	 *
--- a/include/drm/drm_modes.h
+++ b/include/drm/drm_modes.h
@@ -416,6 +416,7 @@ struct drm_display_mode {
 	 */
 	enum hdmi_picture_aspect picture_aspect_ratio;
 
+#ifndef __GENKSYMS__
 	/**
 	 * @export_head:
 	 *
@@ -428,6 +429,7 @@ struct drm_display_mode {
 	 * avoid overhead of protecting it by mode_config.mutex.
 	 */
 	struct list_head export_head;
+#endif
 };
 
 /**