summaryrefslogtreecommitdiffstats
path: root/Documentation/features/debug/stackprotector
diff options
context:
space:
mode:
authorNiklas Schnelle <schnelle@linux.ibm.com>2026-01-08 16:45:53 +0100
committerHeiko Carstens <hca@linux.ibm.com>2026-01-17 15:55:22 +0100
commit84d875e69818bed600edccb09be4a64b84a34a54 (patch)
treee19f10af76fe152e1eec2accd5b4f8af9b8afaa8 /Documentation/features/debug/stackprotector
parent86302ddf20e6b27ef463006c8bde6fd753056101 (diff)
downloadlinux-84d875e69818bed600edccb09be4a64b84a34a54.tar.gz
linux-84d875e69818bed600edccb09be4a64b84a34a54.zip
s390/pci: Handle futile config accesses of disabled devices directly
On s390 PCI busses and slots with multiple functions may have holes because PCI functions are passed-through by the hypervisor on a per function basis and some functions may be in standby or reserved. This fact is indicated by returning true from the hypervisor_isolated_pci_functions() helper and triggers common code to scan all possible devfn values. Via pci_scan_single_device() this in turn causes config reads for the device and vendor IDs, even for PCI functions which are in standby and thereofore disabled. So far these futile config reads, as well as potentially writes, which can never succeed were handled by the PCI load/store instructions themselves. This works as the platform just returns an error for a disabled and thus not usable function handle. It does cause spamming of error logs and additional overhead though. Instead check if the used function handle is enabled in zpci_cfg_load() and zpci_cfg_write() and if not enable directly return -ENODEV. Also refactor zpci_cfg_load() and zpci_cfg_store() slightly to accommodate the new logic while meeting modern kernel style guidelines. Cc: stable@vger.kernel.org Fixes: a50297cf8235 ("s390/pci: separate zbus creation from scanning") Signed-off-by: Niklas Schnelle <schnelle@linux.ibm.com> Reviewed-by: Benjamin Block <bblock@linux.ibm.com> Reviewed-by: Farhan Ali <alifm@linux.ibm.com> Signed-off-by: Heiko Carstens <hca@linux.ibm.com>
Diffstat (limited to 'Documentation/features/debug/stackprotector')
0 files changed, 0 insertions, 0 deletions