In the Linux kernel, the following vulnerability has been resolved:
IB/mad: Don't call to function that might sleep while in atomic context
Tracepoints are not allowed to sleep, as such the following splat is generated due to call to ibquerypkey() in atomic context.
WARNING: CPU: 0 PID: 1888000 at kernel/trace/ringbuffer.c:2492 rbcommit+0xc1/0x220 CPU: 0 PID: 1888000 Comm: kworker/u9:0 Kdump: loaded Tainted: G OE --------- - - 4.18.0-305.3.1.el8.x8664 #1 Hardware name: Red Hat KVM, BIOS 1.13.0-2.moduleel8.3.0+555+a55c8938 04/01/2014 Workqueue: ib-comp-unb-wq ibcqpollwork [ibcore] RIP: 0010:rbcommit+0xc1/0x220 RSP: 0000:ffffa8ac80f9bca0 EFLAGS: 00010202 RAX: ffff8951c7c01300 RBX: ffff8951c7c14a00 RCX: 0000000000000246 RDX: ffff8951c707c000 RSI: ffff8951c707c57c RDI: ffff8951c7c14a00 RBP: 0000000000000000 R08: 0000000000000000 R09: 0000000000000000 R10: ffff8951c7c01300 R11: 0000000000000001 R12: 0000000000000246 R13: 0000000000000000 R14: ffffffff964c70c0 R15: 0000000000000000 FS: 0000000000000000(0000) GS:ffff8951fbc00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 00007f20e8f39010 CR3: 000000002ca10005 CR4: 0000000000170ef0 Call Trace: ringbufferunlockcommit+0x1d/0xa0 tracebufferunlockcommitregs+0x3b/0x1b0 traceeventbuffercommit+0x67/0x1d0 traceeventraweventibmadrecvdonehandler+0x11c/0x160 [ibcore] ibmadrecvdone+0x48b/0xc10 [ibcore] ? traceeventraweventcqpoll+0x6f/0xb0 [ibcore] _ibprocesscq+0x91/0x1c0 [ibcore] ibcqpollwork+0x26/0x80 [ibcore] processonework+0x1a7/0x360 ? createworker+0x1a0/0x1a0 workerthread+0x30/0x390 ? createworker+0x1a0/0x1a0 kthread+0x116/0x130 ? kthreadflushworkfn+0x10/0x10 retfromfork+0x35/0x40 ---[ end trace 78ba8509d3830a16 ]---
[
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@fa8a2f3be78e4585996bcf4c15e4504441a4c7a0",
"id": "CVE-2022-50472-388f04fe",
"deprecated": false,
"signature_version": "v1",
"target": {
"file": "include/trace/events/ib_mad.h"
},
"digest": {
"threshold": 0.9,
"line_hashes": [
"33417336541822365447140914937779144094",
"213343068402975373285023594765915620058",
"75664643606947822742609151324209527914",
"68994991383835144344481942109800947541",
"307546598908664644611090453447274536259",
"325736060842266469623221181923007671519",
"304789852902752619531550774533799620538",
"299606786862425974957555675385056791065",
"325452752587825456563466459942365557541",
"20267311018132707422978890720724487669",
"183980838709301142245854557828968727195",
"14149281303790056377193591343155226884",
"158730341145724470777763003148314271440",
"226429397230672364370397927272138349643",
"52980616136895996873128016302217344040",
"114375615911837709773678174591898491818",
"320011774882513696061322827600350675304",
"28394479437003899477477409204022257515",
"267572283345567069028588907695338914981",
"297599047636129083620598603330247799441",
"297683114943579767069553146865151244345",
"239669972746022019837934416540010725080",
"219249684743437817862155788217206361131",
"134606385581796790921688890418381557344",
"313079012326669335935804732550166684113",
"102517116803908790175912265141844036192",
"323601015482057377710905855296908450495",
"213320468738124532770373037878550671026",
"253679766257021106804976921545344421000",
"52434138269981054460410038550515782841"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@cea70a572c0cb9728d728cfebe7d5bd485e97513",
"id": "CVE-2022-50472-42930522",
"deprecated": false,
"signature_version": "v1",
"target": {
"function": "create_mad_addr_info",
"file": "drivers/infiniband/core/mad.c"
},
"digest": {
"length": 491.0,
"function_hash": "103001209441130543651219387476408247774"
},
"signature_type": "Function"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@5c20311d76cbaeb7ed2ecf9c8b8322f8fc4a7ae3",
"id": "CVE-2022-50472-6d373229",
"deprecated": false,
"signature_version": "v1",
"target": {
"function": "create_mad_addr_info",
"file": "drivers/infiniband/core/mad.c"
},
"digest": {
"length": 491.0,
"function_hash": "103001209441130543651219387476408247774"
},
"signature_type": "Function"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@5c20311d76cbaeb7ed2ecf9c8b8322f8fc4a7ae3",
"id": "CVE-2022-50472-75ad3085",
"deprecated": false,
"signature_version": "v1",
"target": {
"file": "drivers/infiniband/core/mad.c"
},
"digest": {
"threshold": 0.9,
"line_hashes": [
"24436973351975454930611767995932095651",
"148796771312133975232898654879121687078",
"155760578808006679661674199984153511783",
"81494013501615336485872028304066170422",
"85777353653237924796100104152391625495",
"315053753988208595438766633595886374261",
"109268884287746834570654938628734406131",
"90226870573178778236715490798470898559",
"170481118965551588826554105504061265042",
"203453774930747435870117466376841123262",
"226172586509796020770618263761602567442"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@cea70a572c0cb9728d728cfebe7d5bd485e97513",
"id": "CVE-2022-50472-8c234d99",
"deprecated": false,
"signature_version": "v1",
"target": {
"file": "include/trace/events/ib_mad.h"
},
"digest": {
"threshold": 0.9,
"line_hashes": [
"33417336541822365447140914937779144094",
"213343068402975373285023594765915620058",
"75664643606947822742609151324209527914",
"68994991383835144344481942109800947541",
"307546598908664644611090453447274536259",
"325736060842266469623221181923007671519",
"304789852902752619531550774533799620538",
"299606786862425974957555675385056791065",
"325452752587825456563466459942365557541",
"20267311018132707422978890720724487669",
"183980838709301142245854557828968727195",
"14149281303790056377193591343155226884",
"158730341145724470777763003148314271440",
"226429397230672364370397927272138349643",
"52980616136895996873128016302217344040",
"114375615911837709773678174591898491818",
"320011774882513696061322827600350675304",
"28394479437003899477477409204022257515",
"267572283345567069028588907695338914981",
"297599047636129083620598603330247799441",
"297683114943579767069553146865151244345",
"239669972746022019837934416540010725080",
"219249684743437817862155788217206361131",
"134606385581796790921688890418381557344",
"313079012326669335935804732550166684113",
"102517116803908790175912265141844036192",
"323601015482057377710905855296908450495",
"213320468738124532770373037878550671026",
"253679766257021106804976921545344421000",
"52434138269981054460410038550515782841"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@5c20311d76cbaeb7ed2ecf9c8b8322f8fc4a7ae3",
"id": "CVE-2022-50472-ae05f884",
"deprecated": false,
"signature_version": "v1",
"target": {
"file": "include/trace/events/ib_mad.h"
},
"digest": {
"threshold": 0.9,
"line_hashes": [
"33417336541822365447140914937779144094",
"213343068402975373285023594765915620058",
"75664643606947822742609151324209527914",
"68994991383835144344481942109800947541",
"307546598908664644611090453447274536259",
"325736060842266469623221181923007671519",
"304789852902752619531550774533799620538",
"299606786862425974957555675385056791065",
"325452752587825456563466459942365557541",
"20267311018132707422978890720724487669",
"183980838709301142245854557828968727195",
"14149281303790056377193591343155226884",
"158730341145724470777763003148314271440",
"226429397230672364370397927272138349643",
"52980616136895996873128016302217344040",
"114375615911837709773678174591898491818",
"320011774882513696061322827600350675304",
"28394479437003899477477409204022257515",
"267572283345567069028588907695338914981",
"297599047636129083620598603330247799441",
"297683114943579767069553146865151244345",
"239669972746022019837934416540010725080",
"219249684743437817862155788217206361131",
"134606385581796790921688890418381557344",
"313079012326669335935804732550166684113",
"102517116803908790175912265141844036192",
"323601015482057377710905855296908450495",
"213320468738124532770373037878550671026",
"253679766257021106804976921545344421000",
"52434138269981054460410038550515782841"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@fa8a2f3be78e4585996bcf4c15e4504441a4c7a0",
"id": "CVE-2022-50472-b4dcc5ad",
"deprecated": false,
"signature_version": "v1",
"target": {
"function": "create_mad_addr_info",
"file": "drivers/infiniband/core/mad.c"
},
"digest": {
"length": 491.0,
"function_hash": "103001209441130543651219387476408247774"
},
"signature_type": "Function"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@fa8a2f3be78e4585996bcf4c15e4504441a4c7a0",
"id": "CVE-2022-50472-c9fe800e",
"deprecated": false,
"signature_version": "v1",
"target": {
"file": "drivers/infiniband/core/mad.c"
},
"digest": {
"threshold": 0.9,
"line_hashes": [
"24436973351975454930611767995932095651",
"148796771312133975232898654879121687078",
"155760578808006679661674199984153511783",
"81494013501615336485872028304066170422",
"85777353653237924796100104152391625495",
"315053753988208595438766633595886374261",
"109268884287746834570654938628734406131",
"90226870573178778236715490798470898559",
"170481118965551588826554105504061265042",
"203453774930747435870117466376841123262",
"226172586509796020770618263761602567442"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@47e31b86edff36f2d26cbc88ce695d98ff804178",
"id": "CVE-2022-50472-d53bdcd7",
"deprecated": false,
"signature_version": "v1",
"target": {
"file": "drivers/infiniband/core/mad.c"
},
"digest": {
"threshold": 0.9,
"line_hashes": [
"24436973351975454930611767995932095651",
"148796771312133975232898654879121687078",
"155760578808006679661674199984153511783",
"81494013501615336485872028304066170422",
"85777353653237924796100104152391625495",
"315053753988208595438766633595886374261",
"109268884287746834570654938628734406131",
"90226870573178778236715490798470898559",
"170481118965551588826554105504061265042",
"203453774930747435870117466376841123262",
"226172586509796020770618263761602567442"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@cea70a572c0cb9728d728cfebe7d5bd485e97513",
"id": "CVE-2022-50472-e9ee4eb5",
"deprecated": false,
"signature_version": "v1",
"target": {
"file": "drivers/infiniband/core/mad.c"
},
"digest": {
"threshold": 0.9,
"line_hashes": [
"24436973351975454930611767995932095651",
"148796771312133975232898654879121687078",
"155760578808006679661674199984153511783",
"81494013501615336485872028304066170422",
"85777353653237924796100104152391625495",
"315053753988208595438766633595886374261",
"109268884287746834570654938628734406131",
"90226870573178778236715490798470898559",
"170481118965551588826554105504061265042",
"203453774930747435870117466376841123262",
"226172586509796020770618263761602567442"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@47e31b86edff36f2d26cbc88ce695d98ff804178",
"id": "CVE-2022-50472-f899cac3",
"deprecated": false,
"signature_version": "v1",
"target": {
"file": "include/trace/events/ib_mad.h"
},
"digest": {
"threshold": 0.9,
"line_hashes": [
"33417336541822365447140914937779144094",
"213343068402975373285023594765915620058",
"75664643606947822742609151324209527914",
"68994991383835144344481942109800947541",
"307546598908664644611090453447274536259",
"325736060842266469623221181923007671519",
"304789852902752619531550774533799620538",
"299606786862425974957555675385056791065",
"325452752587825456563466459942365557541",
"20267311018132707422978890720724487669",
"183980838709301142245854557828968727195",
"14149281303790056377193591343155226884",
"158730341145724470777763003148314271440",
"226429397230672364370397927272138349643",
"52980616136895996873128016302217344040",
"114375615911837709773678174591898491818",
"320011774882513696061322827600350675304",
"28394479437003899477477409204022257515",
"267572283345567069028588907695338914981",
"297599047636129083620598603330247799441",
"297683114943579767069553146865151244345",
"239669972746022019837934416540010725080",
"219249684743437817862155788217206361131",
"134606385581796790921688890418381557344",
"313079012326669335935804732550166684113",
"102517116803908790175912265141844036192",
"323601015482057377710905855296908450495",
"213320468738124532770373037878550671026",
"253679766257021106804976921545344421000",
"52434138269981054460410038550515782841"
]
},
"signature_type": "Line"
},
{
"source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@47e31b86edff36f2d26cbc88ce695d98ff804178",
"id": "CVE-2022-50472-ff033a65",
"deprecated": false,
"signature_version": "v1",
"target": {
"function": "create_mad_addr_info",
"file": "drivers/infiniband/core/mad.c"
},
"digest": {
"length": 491.0,
"function_hash": "103001209441130543651219387476408247774"
},
"signature_type": "Function"
}
]