aboutsummaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/bin
diff options
context:
space:
mode:
authorNicolin Chen <[email protected]>2023-10-15 00:46:48 -0700
committerJason Gunthorpe <[email protected]>2023-10-16 11:05:51 -0300
commit266dcae34d8f44c3bbab00e227f8b14517682bb7 (patch)
treec33b5681650efe7cbfd37def5b79aeaebb26132a /tools/perf/scripts/python/bin
parentc97d1b20d3835178bcd0e3a86c20ce4e36b6d80c (diff)
iommufd/selftest: Rework TEST_LENGTH to test min_size explicitly
TEST_LENGTH passing ".size = sizeof(struct _struct) - 1" expects -EINVAL from "if (ucmd.user_size < op->min_size)" check in iommufd_fops_ioctl(). This has been working when min_size is exactly the size of the structure. However, if the size of the structure becomes larger than min_size, i.e. the passing size above is larger than min_size, that min_size sanity no longer works. Since the first test in TEST_LENGTH() was to test that min_size sanity routine, rework it to support a min_size calculation, rather than using the full size of the structure. Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Nicolin Chen <[email protected]> Reviewed-by: Kevin Tian <[email protected]> Signed-off-by: Jason Gunthorpe <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/bin')
0 files changed, 0 insertions, 0 deletions