Blob Blame History Raw
From 50bf73bdce8efc57f563297a6c2fedaedefa849e Mon Sep 17 00:00:00 2001
From: Rikard Falkeborn <rikard.falkeborn@gmail.com>
Date: Thu, 11 Jun 2020 00:47:03 +0200
Subject: [PATCH] mei: hdcp: Constify struct mei_cl_device_id
Git-commit: 50bf73bdce8efc57f563297a6c2fedaedefa849e
Patch-mainline: v5.9-rc1
References: jsc#SLE-13387

mei_hdcp_tbl[] is never modified and can be made const to allow the
compiler to put it in read-only memory.

Before: text    data     bss     dec     hex filename  15844    5416       0   21260    530c drivers/misc/mei/hdcp/mei_hdcp.o

After: text    data     bss     dec     hex filename  16004    5256       0   21260    530c drivers/misc/mei/hdcp/mei_hdcp.o

Signed-off-by: Rikard Falkeborn <rikard.falkeborn@gmail.com>
Link: https://lore.kernel.org/r/20200610224704.27082-4-rikard.falkeborn@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Acked-by: Takashi Iwai <tiwai@suse.de>

---
 drivers/misc/mei/hdcp/mei_hdcp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/misc/mei/hdcp/mei_hdcp.c b/drivers/misc/mei/hdcp/mei_hdcp.c
index 4c596c646ac0..e6c3dc595617 100644
--- a/drivers/misc/mei/hdcp/mei_hdcp.c
+++ b/drivers/misc/mei/hdcp/mei_hdcp.c
@@ -852,7 +852,7 @@ static int mei_hdcp_remove(struct mei_cl_device *cldev)
 #define MEI_UUID_HDCP GUID_INIT(0xB638AB7E, 0x94E2, 0x4EA2, 0xA5, \
 				0x52, 0xD1, 0xC5, 0x4B, 0x62, 0x7F, 0x04)
 
-static struct mei_cl_device_id mei_hdcp_tbl[] = {
+static const struct mei_cl_device_id mei_hdcp_tbl[] = {
 	{ .uuid = MEI_UUID_HDCP, .version = MEI_CL_VERSION_ANY },
 	{ }
 };
-- 
2.16.4