diff options
author | 2024-08-12 13:26:59 -0700 | |
---|---|---|
committer | 2024-08-21 15:28:08 -0500 | |
commit | dbc3171194403d0d40e4bdeae666f6e76e428b53 (patch) | |
tree | 8dae8ed665e16931acb906d28566700e527a0a57 /scripts/lib/kdoc/kdoc_files.py | |
parent | Linux 6.11-rc1 (diff) | |
download | linux-rng-dbc3171194403d0d40e4bdeae666f6e76e428b53.tar.xz linux-rng-dbc3171194403d0d40e4bdeae666f6e76e428b53.zip |
x86/PCI: Check pcie_find_root_port() return for NULL
If pcie_find_root_port() is unable to locate a Root Port, it will return
NULL. Check the pointer for NULL before dereferencing it.
This particular case is in a quirk for devices that are always below a Root
Port, so this won't avoid a problem and doesn't need to be backported, but
check as a matter of style and to prevent copy/paste mistakes.
Link: https://lore.kernel.org/r/20240812202659.1649121-1-samasth.norway.ananda@oracle.com
Signed-off-by: Samasth Norway Ananda <samasth.norway.ananda@oracle.com>
[bhelgaas: drop Fixes: and explain why there's no problem in this case]
Signed-off-by: Bjorn Helgaas <bhelgaas@google.com>
Reviewed-by: Mario Limonciello <mario.limonciello@amd.com>
Diffstat (limited to 'scripts/lib/kdoc/kdoc_files.py')
0 files changed, 0 insertions, 0 deletions