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

drm/edid/firmware: drop drm_kms_helper.edid_firmware backward compat

Since the edid_firmware module parameter was moved from
drm_kms_helper.ko to drm.ko in v4.15, we've had a backwards
compatibility helper in place, with a DRM_NOTE() suggesting to migrate
to drm.edid_firmware. This was added in commit ac6c35a4d8c7 ("drm: add
backwards compatibility support for drm_kms_helper.edid_firmware").

More than five years and 30+ kernel releases later, drop the backward
compatibility.

v2: Drop the warnings too

Acked-by: Daniel Vetter <daniel@ffwll.ch>
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20231114151406.61230-1-jani.nikula@intel.com

-53
-16
drivers/gpu/drm/drm_edid_load.c
··· 23 23 MODULE_PARM_DESC(edid_firmware, "Do not probe monitor, use specified EDID blob " 24 24 "from built-in data or /lib/firmware instead. "); 25 25 26 - /* Use only for backward compatibility with drm_kms_helper.edid_firmware */ 27 - int __drm_set_edid_firmware_path(const char *path) 28 - { 29 - scnprintf(edid_firmware, sizeof(edid_firmware), "%s", path); 30 - 31 - return 0; 32 - } 33 - EXPORT_SYMBOL(__drm_set_edid_firmware_path); 34 - 35 - /* Use only for backward compatibility with drm_kms_helper.edid_firmware */ 36 - int __drm_get_edid_firmware_path(char *buf, size_t bufsize) 37 - { 38 - return scnprintf(buf, bufsize, "%s", edid_firmware); 39 - } 40 - EXPORT_SYMBOL(__drm_get_edid_firmware_path); 41 - 42 26 #define GENERIC_EDIDS 6 43 27 static const char * const generic_edid_name[GENERIC_EDIDS] = { 44 28 "edid/800x600.bin",
-32
drivers/gpu/drm/drm_kms_helper_common.c
··· 27 27 28 28 #include <linux/module.h> 29 29 30 - #include <drm/drm_edid.h> 31 - #include <drm/drm_print.h> 32 - 33 - #include "drm_crtc_helper_internal.h" 34 - 35 30 MODULE_AUTHOR("David Airlie, Jesse Barnes"); 36 31 MODULE_DESCRIPTION("DRM KMS helper"); 37 32 MODULE_LICENSE("GPL and additional rights"); 38 - 39 - #if IS_ENABLED(CONFIG_DRM_LOAD_EDID_FIRMWARE) 40 - 41 - /* Backward compatibility for drm_kms_helper.edid_firmware */ 42 - static int edid_firmware_set(const char *val, const struct kernel_param *kp) 43 - { 44 - DRM_NOTE("drm_kms_helper.edid_firmware is deprecated, please use drm.edid_firmware instead.\n"); 45 - 46 - return __drm_set_edid_firmware_path(val); 47 - } 48 - 49 - static int edid_firmware_get(char *buffer, const struct kernel_param *kp) 50 - { 51 - return __drm_get_edid_firmware_path(buffer, PAGE_SIZE); 52 - } 53 - 54 - static const struct kernel_param_ops edid_firmware_ops = { 55 - .set = edid_firmware_set, 56 - .get = edid_firmware_get, 57 - }; 58 - 59 - module_param_cb(edid_firmware, &edid_firmware_ops, NULL, 0644); 60 - __MODULE_PARM_TYPE(edid_firmware, "charp"); 61 - MODULE_PARM_DESC(edid_firmware, 62 - "DEPRECATED. Use drm.edid_firmware module parameter instead."); 63 - 64 - #endif
-5
include/drm/drm_edid.h
··· 329 329 int drm_av_sync_delay(struct drm_connector *connector, 330 330 const struct drm_display_mode *mode); 331 331 332 - #ifdef CONFIG_DRM_LOAD_EDID_FIRMWARE 333 - int __drm_set_edid_firmware_path(const char *path); 334 - int __drm_get_edid_firmware_path(char *buf, size_t bufsize); 335 - #endif 336 - 337 332 bool drm_edid_are_equal(const struct edid *edid1, const struct edid *edid2); 338 333 339 334 int