linux-mainline/drivers/scsi
Greg Kroah-Hartman d69d804845 driver core: have match() callback in struct bus_type take a const *
In the match() callback, the struct device_driver * should not be
changed, so change the function callback to be a const *.  This is one
step of many towards making the driver core safe to have struct
device_driver in read-only memory.

Because the match() callback is in all busses, all busses are modified
to handle this properly.  This does entail switching some container_of()
calls to container_of_const() to properly handle the constant *.

For some busses, like PCI and USB and HV, the const * is cast away in
the match callback as those busses do want to modify those structures at
this point in time (they have a local lock in the driver structure.)
That will have to be changed in the future if they wish to have their
struct device * in read-only-memory.

Cc: Rafael J. Wysocki <rafael@kernel.org>
Reviewed-by: Alex Elder <elder@kernel.org>
Acked-by: Sumit Garg <sumit.garg@linaro.org>
Link: https://lore.kernel.org/r/2024070136-wrongdoer-busily-01e8@gregkh
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2024-07-03 15:16:54 +02:00
..
aacraid
aic7xxx Kbuild updates for v6.10 2024-05-18 12:39:20 -07:00
aic94xx
arcmsr scsi: arcmsr: Use PCI_IRQ_INTX instead of PCI_IRQ_LEGACY 2024-05-16 14:35:08 -05:00
arm
be2iscsi
bfa Driver core changes for 6.10-rc1 2024-05-22 12:13:40 -07:00
bnx2fc SCSI misc on 20240514 2024-05-14 18:25:53 -07:00
bnx2i
csiostor
cxgbi
cxlflash
device_handler scsi: core: alua: I/O errors for ALUA state transitions 2024-05-15 09:46:13 -04:00
elx
esas2r
fcoe driver core: have match() callback in struct bus_type take a const * 2024-07-03 15:16:54 +02:00
fnic
hisi_sas SCSI misc on 20240514 2024-05-14 18:25:53 -07:00
ibmvscsi
ibmvscsi_tgt
isci
libfc
libsas SCSI misc on 20240514 2024-05-14 18:25:53 -07:00
lpfc
megaraid pci-v6.10-changes 2024-05-21 10:09:28 -07:00
mpi3mr scsi: mpi3mr: Fix ATA NCQ priority support 2024-06-11 21:40:23 -04:00
mpt3sas SCSI fixes on 20240614 2024-06-14 10:25:29 -07:00
mvsas Driver core changes for 6.10-rc1 2024-05-22 12:13:40 -07:00
pcmcia
pm8001
qedf scsi: qedf: Set qed_slowpath_params to zero before use 2024-05-15 10:26:53 -04:00
qedi
qla2xxx Driver core changes for 6.10-rc1 2024-05-22 12:13:40 -07:00
qla4xxx
smartpqi Driver core changes for 6.10-rc1 2024-05-22 12:13:40 -07:00
snic
sym53c8xx_2
.gitignore
3w-9xxx.c
3w-9xxx.h
3w-sas.c
3w-sas.h
3w-xxxx.c
3w-xxxx.h
53c700_d.h_shipped
53c700.c
53c700.h
53c700.scr
a100u2w.c
a100u2w.h
a2091.c
a2091.h
a3000.c
a3000.h
a4000t.c
advansys.c
aha152x.c
aha152x.h
aha1542.c
aha1542.h
aha1740.c
aha1740.h
am53c974.c
atari_scsi.c
atp870u.c
atp870u.h
BusLogic.c
BusLogic.h
bvme6000_scsi.c
ch.c
constants.c
dc395x.c
dc395x.h
dmx3191d.c
esp_scsi.c
esp_scsi.h
fdomain_isa.c
fdomain_pci.c
fdomain.c
fdomain.h
FlashPoint.c
g_NCR5380.c
gvp11.c
gvp11.h
hosts.c SCSI misc on 20240514 2024-05-14 18:25:53 -07:00
hpsa_cmd.h
hpsa.c pci-v6.10-changes 2024-05-21 10:09:28 -07:00
hpsa.h
hptiop.c
hptiop.h
imm.c
imm.h
initio.c
initio.h
ipr.c pci-v6.10-changes 2024-05-21 10:09:28 -07:00
ipr.h
ips.c
ips.h
iscsi_boot_sysfs.c
iscsi_tcp.c
iscsi_tcp.h
jazz_esp.c
Kconfig
lasi700.c
libiscsi_tcp.c
libiscsi.c
mac53c94.c
mac53c94.h
mac_esp.c
mac_scsi.c
Makefile
megaraid.c
megaraid.h
mesh.c
mesh.h
mvme16x_scsi.c
mvme147.c
mvme147.h
mvumi.c
mvumi.h
myrb.c
myrb.h
myrs.c
myrs.h
ncr53c8xx.c
ncr53c8xx.h
NCR5380.c
NCR5380.h
nsp32_debug.c
nsp32_io.h
nsp32.c
nsp32.h
pmcraid.c pci-v6.10-changes 2024-05-21 10:09:28 -07:00
pmcraid.h
ppa.c
ppa.h
ps3rom.c
qla1280.c
qla1280.h
qlogicfas408.c
qlogicfas408.h
qlogicfas.c
qlogicpti.c
qlogicpti.h
raid_class.c
script_asm.pl
scsi_bsg.c
scsi_common.c
scsi_debug.c
scsi_debugfs.c
scsi_debugfs.h
scsi_devinfo.c
scsi_dh.c
scsi_error.c
scsi_ioctl.c
scsi_lib_dma.c
scsi_lib_test.c
scsi_lib.c SCSI misc on 20240514 2024-05-14 18:25:53 -07:00
scsi_logging.c
scsi_logging.h
scsi_netlink.c
scsi_pm.c
scsi_priv.h
scsi_proc.c
scsi_proto_test.c
scsi_sas_internal.h
scsi_scan.c SCSI misc on 20240514 2024-05-14 18:25:53 -07:00
scsi_sysctl.c
scsi_sysfs.c driver core: have match() callback in struct bus_type take a const * 2024-07-03 15:16:54 +02:00
scsi_trace.c
scsi_transport_api.h
scsi_transport_fc.c
scsi_transport_iscsi.c driver core: have match() callback in struct bus_type take a const * 2024-07-03 15:16:54 +02:00
scsi_transport_sas.c scsi: mpi3mr: Fix ATA NCQ priority support 2024-06-11 21:40:23 -04:00
scsi_transport_spi.c
scsi_transport_srp.c
scsi.c scsi: core: Disable CDL by default 2024-06-11 21:14:54 -04:00
scsicam.c
sd_dif.c
sd_trace.h
sd_zbc.c
sd.c SCSI fixes on 20240614 2024-06-14 10:25:29 -07:00
sd.h
sense_codes.h
ses.c
sg.c
sgiwd93.c
sim710.c
sni_53c710.c
sr_ioctl.c scsi: sr: Fix unintentional arithmetic wraparound 2024-05-15 10:05:24 -04:00
sr_vendor.c
sr.c
sr.h scsi: sr: Fix unintentional arithmetic wraparound 2024-05-15 10:05:24 -04:00
st_options.h
st.c
st.h
stex.c
storvsc_drv.c
sun3_scsi_vme.c
sun3_scsi.c
sun3x_esp.c
sun_esp.c
virtio_scsi.c scsi: virtio: drop owner assignment 2024-05-22 08:31:18 -04:00
vmw_pvscsi.c scsi: vmw_pvscsi: Do not use PCI_IRQ_LEGACY instead of PCI_IRQ_LEGACY 2024-05-16 14:35:08 -05:00
vmw_pvscsi.h
wd33c93.c
wd33c93.h
wd719x.c
wd719x.h
xen-scsifront.c
zalon.c
zorro7xx.c
zorro_esp.c