In the Linux kernel, the following vulnerability has been resolved:
crypto: qat - ADFSTATUSPFRUNNING should be set after adfdev_init
ADFSTATUSPFRUNNING is (only) used and checked by adfvf2pfshutdown() before calling adfiovputmsg()->mutexlock(vf2pflock), however the vf2pflock is initialized in adfdevinit(), which can fail and when it fail, the vf2pflock is either not initialized or destroyed, a subsequent use of vf2pflock will cause issue. To fix this issue, only set this flag if adfdevinit() returns 0.
[ 7.178404] BUG: KASAN: user-memory-access in _mutexlock.isra.0+0x1ac/0x7c0 [ 7.180345] Call Trace: [ 7.182576] mutexlock+0xc9/0xd0 [ 7.183257] adfiovputmsg+0x118/0x1a0 [intelqat] [ 7.183541] adfvf2pfshutdown+0x4d/0x7b [intelqat] [ 7.183834] adfdevshutdown+0x172/0x2b0 [intelqat] [ 7.184127] adfprobe+0x5e9/0x600 [qatdh895xccvf]
"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2021-47056.json"
[
{
"events": [
{
"introduced": "4.7"
},
{
"fixed": "4.9.269"
}
]
},
{
"events": [
{
"introduced": "4.10"
},
{
"fixed": "4.14.233"
}
]
},
{
"events": [
{
"introduced": "4.15"
},
{
"fixed": "4.19.191"
}
]
},
{
"events": [
{
"introduced": "4.20"
},
{
"fixed": "5.4.119"
}
]
},
{
"events": [
{
"introduced": "5.5"
},
{
"fixed": "5.10.37"
}
]
},
{
"events": [
{
"introduced": "5.11"
},
{
"fixed": "5.11.21"
}
]
},
{
"events": [
{
"introduced": "5.12"
},
{
"fixed": "5.12.4"
}
]
}
]