[PATCH 2/4] HID: intel-ish-hid: hid-client: constify devicetable initializer

From: Thomas Weißschuh
Date: Wed Nov 10 2021 - 18:00:56 EST


Previously the compilation broke on clang and gcc < 8.1.0 with errors like
"error: initializer element is not constant".

Fixes: 0d0cccc0fd83 ("HID: intel-ish-hid: hid-client: only load for matching devices")
Reported-by: Nathan Chancellor <nathan@xxxxxxxxxx>
Signed-off-by: Thomas Weißschuh <linux@xxxxxxxxxxxxxx>
---
drivers/hid/intel-ish-hid/ishtp-hid-client.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/hid/intel-ish-hid/ishtp-hid-client.c b/drivers/hid/intel-ish-hid/ishtp-hid-client.c
index fb47d38d1e87..cff7da0578b6 100644
--- a/drivers/hid/intel-ish-hid/ishtp-hid-client.c
+++ b/drivers/hid/intel-ish-hid/ishtp-hid-client.c
@@ -12,9 +12,9 @@
#include "ishtp-hid.h"

/* ISH Transport protocol (ISHTP in short) GUID */
-static const guid_t hid_ishtp_guid =
- GUID_INIT(0x33AECD58, 0xB679, 0x4E54,
- 0x9B, 0xD9, 0xA0, 0x4D, 0x34, 0xF0, 0xC2, 0x26);
+#define HID_ISHTP_GUID GUID_INIT(0x33AECD58, 0xB679, 0x4E54, \
+ 0x9B, 0xD9, 0xA0, 0x4D, 0x34, 0xF0, 0xC2, 0x26)
+static const guid_t hid_ishtp_guid = HID_ISHTP_GUID;

/* Rx ring buffer pool size */
#define HID_CL_RX_RING_SIZE 32
@@ -953,7 +953,7 @@ static struct ishtp_cl_driver hid_ishtp_cl_driver = {
};

static const struct ishtp_device_id hid_ishtp_id_table[] = {
- { hid_ishtp_guid },
+ { HID_ISHTP_GUID },
{ }
};
MODULE_DEVICE_TABLE(ishtp, hid_ishtp_id_table);
--
2.33.1