aboutsummaryrefslogtreecommitdiff
path: root/tools/testing/selftests/bpf/prog_tests
diff options
context:
space:
mode:
authorSai Praneeth Prakhya <[email protected]>2020-11-24 21:06:03 +0800
committerWill Deacon <[email protected]>2020-11-25 12:14:33 +0000
commit0b8a96a3120ffe4d3571d93902693c59f90c3d0c (patch)
tree8d7845d5f7b08be39b68df3023ef435c3ef16707 /tools/testing/selftests/bpf/prog_tests
parent08a27c1c3ecf5e1da193ce5f8fc97c3be16e75f0 (diff)
iommu: Take lock before reading iommu group default domain type
"/sys/kernel/iommu_groups/<grp_id>/type" file could be read to find out the default domain type of an iommu group. The default domain of an iommu group doesn't change after booting and hence could be read directly. But, after addding support to dynamically change iommu group default domain, the above assumption no longer stays valid. iommu group default domain type could be changed at any time by writing to "/sys/kernel/iommu_groups/<grp_id>/type". So, take group mutex before reading iommu group default domain type so that the user wouldn't see stale values or iommu_group_show_type() doesn't try to derefernce stale pointers. Signed-off-by: Sai Praneeth Prakhya <[email protected]> Signed-off-by: Lu Baolu <[email protected]> Cc: Christoph Hellwig <[email protected]> Cc: Joerg Roedel <[email protected]> Cc: Ashok Raj <[email protected]> Cc: Will Deacon <[email protected]> Cc: Sohil Mehta <[email protected]> Cc: Robin Murphy <[email protected]> Cc: Jacob Pan <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Will Deacon <[email protected]>
Diffstat (limited to 'tools/testing/selftests/bpf/prog_tests')
0 files changed, 0 insertions, 0 deletions