peci: constify the struct device_type usage
authorRicardo B. Marliere <ricardo@marliere.net>
Mon, 19 Feb 2024 12:36:35 +0000 (09:36 -0300)
committerIwona Winiarska <iwona.winiarska@intel.com>
Mon, 15 Apr 2024 22:14:43 +0000 (00:14 +0200)
commite6faf2b750ebf3837a63ebe465e7b7933502bdc4
tree22dedecca37b35c9320a2f3d80dea056c535ff38
parented8c2dad25eb2fbaa61f2e32385ecc1aa34c2355
peci: constify the struct device_type usage

Since commit aed65af1cc2f ("drivers: make device_type const"), the driver
core can properly handle constant struct device_type. Move the
peci_controller_type and peci_device_type variables to be constant
structures as well, placing it into read-only memory which can not be
modified at runtime.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: "Ricardo B. Marliere" <ricardo@marliere.net>
Reviewed-by: Iwona Winiarska <iwona.winiarska@intel.com>
Link: https://lore.kernel.org/r/20240219-device_cleanup-peci-v1-1-0727662616f7@marliere.net
Signed-off-by: Iwona Winiarska <iwona.winiarska@intel.com>
drivers/peci/core.c
drivers/peci/device.c
drivers/peci/internal.h