scsi: pmcraid: Make pmcraid_class constant
authorRicardo B. Marliere <ricardo@marliere.net>
Sat, 2 Mar 2024 16:47:23 +0000 (13:47 -0300)
committerMartin K. Petersen <martin.petersen@oracle.com>
Sun, 10 Mar 2024 22:15:48 +0000 (18:15 -0400)
commitee8dda6a7e9d28260e30ecaf8b5f27d176c8ade0
tree00a2b78de5b663b0b4995508427230f65c2252ae
parentf1fb41765d0bff77514ffeaef37bbb45608f6c62
scsi: pmcraid: Make pmcraid_class constant

Since commit 43a7206b0963 ("driver core: class: make class_register() take
a const *"), the driver core allows for struct class to be in read-only
memory, so move the pmcraid_class structure to be declared at build time
placing it into read-only memory, instead of having to be dynamically
allocated at boot time.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Suggested-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Ricardo B. Marliere <ricardo@marliere.net>
Link: https://lore.kernel.org/r/20240302-class_cleanup-scsi-v1-2-b9096b990e27@marliere.net
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
drivers/scsi/pmcraid.c