diff options
| author | Deepanshu Kartikey <kartikey406@gmail.com> | 2026-01-24 18:52:14 +0530 |
|---|---|---|
| committer | Jason Gunthorpe <jgg@nvidia.com> | 2026-01-28 12:49:17 -0400 |
| commit | 2724138b2f7f6299812b3404e23b124304834759 (patch) | |
| tree | 77a57b04060021eb320fd70ed6d8708bb6585119 /tools/perf/python | |
| parent | 63804fed149a6750ffd28610c5c1c98cce6bd377 (diff) | |
iommufd: Initialize batch->kind in batch_clear()
KMSAN reported an uninitialized value when batch_add_pfn_num() reads
batch->kind. This occurs because batch_clear() does not initialize the
kind field.
When batch_add_pfn_num() checks "if (batch->kind != kind)", it reads this
uninitialized value, triggering KMSAN warnings. However the algorithm is
fine with any value in kind at this point as the batch is always empty and
it always corrects kind if wrong.
Initialize batch->kind to zero in batch_clear() to silence the KMSAN
warning.
Link: https://patch.msgid.link/r/20260124132214.624041-1-kartikey406@gmail.com
Reported-by: syzbot+df28076a30d726933015@syzkaller.appspotmail.com
Closes: https://syzkaller.appspot.com/bug?extid=df28076a30d726933015
Fixes: f394576eb11db ("iommufd: PFN handling for iopt_pages")
Tested-by: syzbot+df28076a30d726933015@syzkaller.appspotmail.com
Signed-off-by: Deepanshu Kartikey <kartikey406@gmail.com>
Reviewed-by: Kevin Tian <kevin.tian@intel.com>
Tested-by: syzbot+a0c841e02f328005bbcc@syzkaller.appspotmail.com
Reported-by: syzbot+a0c841e02f328005bbcc@syzkaller.appspotmail.com
Signed-off-by: Jason Gunthorpe <jgg@nvidia.com>
Diffstat (limited to 'tools/perf/python')
0 files changed, 0 insertions, 0 deletions
