summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/stackcollapse.py
diff options
context:
space:
mode:
authorWill Deacon <will@kernel.org>2021-06-15 19:35:46 +0100
committerWill Deacon <will@kernel.org>2021-06-15 19:35:46 +0100
commitb472191f0a0ce6d98d61e939118cfd6ad0ff91e7 (patch)
treeabc8e385b1ad2add51396f9699f6a9610e5669fd /tools/perf/scripts/python/stackcollapse.py
parent0d97174aeadfc49ad8d281bbcd69fdfeb5fd2fcb (diff)
iommu/arm-smmu: Check smmu->impl pointer before dereferencing
Commit 0d97174aeadf ("iommu/arm-smmu: Implement ->probe_finalize()") added a new optional ->probe_finalize callback to 'struct arm_smmu_impl' but neglected to check that 'smmu->impl' is present prior to checking if the new callback is present. Add the missing check, which avoids dereferencing NULL when probing an SMMU which doesn't require any implementation-specific callbacks: | Unable to handle kernel NULL pointer dereference at virtual address | 0000000000000070 | | Call trace: | arm_smmu_probe_finalize+0x14/0x48 | of_iommu_configure+0xe4/0x1b8 | of_dma_configure_id+0xf8/0x2d8 | pci_dma_configure+0x44/0x88 | really_probe+0xc0/0x3c0 Fixes: 0d97174aeadf ("iommu/arm-smmu: Implement ->probe_finalize()") Reported-by: Marek Szyprowski <m.szyprowski@samsung.com> Signed-off-by: Will Deacon <will@kernel.org>
Diffstat (limited to 'tools/perf/scripts/python/stackcollapse.py')
0 files changed, 0 insertions, 0 deletions