Commit ee8dda6
scsi: pmcraid: Make pmcraid_class constant
Since commit 43a7206 ("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>1 parent f1fb417 commit ee8dda6
1 file changed
Lines changed: 11 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
65 | 67 | | |
66 | 68 | | |
67 | 69 | | |
| |||
4723 | 4725 | | |
4724 | 4726 | | |
4725 | 4727 | | |
4726 | | - | |
| 4728 | + | |
4727 | 4729 | | |
4728 | 4730 | | |
4729 | 4731 | | |
| |||
4739 | 4741 | | |
4740 | 4742 | | |
4741 | 4743 | | |
4742 | | - | |
| 4744 | + | |
4743 | 4745 | | |
4744 | 4746 | | |
4745 | 4747 | | |
| |||
5390 | 5392 | | |
5391 | 5393 | | |
5392 | 5394 | | |
5393 | | - | |
5394 | 5395 | | |
5395 | | - | |
5396 | | - | |
| 5396 | + | |
| 5397 | + | |
| 5398 | + | |
5397 | 5399 | | |
5398 | 5400 | | |
5399 | 5401 | | |
| |||
5402 | 5404 | | |
5403 | 5405 | | |
5404 | 5406 | | |
5405 | | - | |
| 5407 | + | |
5406 | 5408 | | |
5407 | 5409 | | |
5408 | 5410 | | |
| |||
5413 | 5415 | | |
5414 | 5416 | | |
5415 | 5417 | | |
5416 | | - | |
| 5418 | + | |
5417 | 5419 | | |
5418 | 5420 | | |
5419 | 5421 | | |
| |||
5432 | 5434 | | |
5433 | 5435 | | |
5434 | 5436 | | |
5435 | | - | |
| 5437 | + | |
5436 | 5438 | | |
5437 | 5439 | | |
5438 | 5440 | | |
| |||
0 commit comments