# CVE-2022-50171: crypto: hisilicon/sec - don't sleep when in softirq

> Archived entry. Full-text search covers entries since 2026-11-10; exact IDs work for all years.

- **Severity:** HIGH 7.5
- **CVSS:** 7.5 (v3.1, CNA) `CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H`
- **CVSS metrics:** Attack vector: Network; Attack complexity: Low; Privileges required: None; User interaction: None; Scope: Unchanged; Confidentiality impact: None; Integrity impact: None; Availability impact: High
- **Exploited in the wild:** Not in CISA KEV
- **Public exploit / PoC:** None known
- **Remote exploitation:** Remote, no login needed
- **EPSS:** 0.41% (percentile 27, 2026-11-26)
- **Published:** 2025-06-18T11:03:23.710Z
- **Modified:** 2026-08-05T08:57:38.553Z

## Who should check

- Anyone running Linux \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< 16e18a8ac7c9748cf35a8d2f0ba2c6e8850e7568; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< aa495dfe71229b9034b59d8072ff0b2325ddd5ee; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< 4a461ba5b9753352f438824fdd915cba675b1733; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< c9be45e4c69fde36522274f04d1aa0d097ae3958; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< 02884a4f12de11f54d4ca67a07dd1f111d96fdbd
- Anyone running Linux 5.5

## Description

In the Linux kernel, the following vulnerability has been resolved:

crypto: hisilicon/sec - don't sleep when in softirq

When kunpeng920 encryption driver is used to deencrypt and decrypt
packets during the softirq, it is not allowed to use mutex lock. The
kernel will report the following error:

BUG: scheduling while atomic: swapper/57/0/0x00000300
Call trace:
dump\_backtrace+0x0/0x1e4
show\_stack+0x20/0x2c
dump\_stack+0xd8/0x140
\_\_schedule\_bug+0x68/0x80
\_\_schedule+0x728/0x840
schedule+0x50/0xe0
schedule\_preempt\_disabled+0x18/0x24
\_\_mutex\_lock.constprop.0+0x594/0x5dc
\_\_mutex\_lock\_slowpath+0x1c/0x30
mutex\_lock+0x50/0x60
sec\_request\_init+0x8c/0x1a0 \[hisi\_sec2\]
sec\_process+0x28/0x1ac \[hisi\_sec2\]
sec\_skcipher\_crypto+0xf4/0x1d4 \[hisi\_sec2\]
sec\_skcipher\_encrypt+0x1c/0x30 \[hisi\_sec2\]
crypto\_skcipher\_encrypt+0x2c/0x40
crypto\_authenc\_encrypt+0xc8/0xfc \[authenc\]
crypto\_aead\_encrypt+0x2c/0x40
echainiv\_encrypt+0x144/0x1a0 \[echainiv\]
crypto\_aead\_encrypt+0x2c/0x40
esp\_output\_tail+0x348/0x5c0 \[esp4\]
esp\_output+0x120/0x19c \[esp4\]
xfrm\_output\_one+0x25c/0x4d4
xfrm\_output\_resume+0x6c/0x1fc
xfrm\_output+0xac/0x3c0
xfrm4\_output+0x64/0x130
ip\_build\_and\_send\_pkt+0x158/0x20c
tcp\_v4\_send\_synack+0xdc/0x1f0
tcp\_conn\_request+0x7d0/0x994
tcp\_v4\_conn\_request+0x58/0x6c
tcp\_v6\_conn\_request+0xf0/0x100
tcp\_rcv\_state\_process+0x1cc/0xd60
tcp\_v4\_do\_rcv+0x10c/0x250
tcp\_v4\_rcv+0xfc4/0x10a4
ip\_protocol\_deliver\_rcu+0xf4/0x200
ip\_local\_deliver\_finish+0x58/0x70
ip\_local\_deliver+0x68/0x120
ip\_sublist\_rcv\_finish+0x70/0x94
ip\_list\_rcv\_finish.constprop.0+0x17c/0x1d0
ip\_sublist\_rcv+0x40/0xb0
ip\_list\_rcv+0x140/0x1dc
\_\_netif\_receive\_skb\_list\_core+0x154/0x28c
\_\_netif\_receive\_skb\_list+0x120/0x1a0
netif\_receive\_skb\_list\_internal+0xe4/0x1f0
napi\_complete\_done+0x70/0x1f0
gro\_cell\_poll+0x9c/0xb0
napi\_poll+0xcc/0x264
net\_rx\_action+0xd4/0x21c
\_\_do\_softirq+0x130/0x358
irq\_exit+0x11c/0x13c
\_\_handle\_domain\_irq+0x88/0xf0
gic\_handle\_irq+0x78/0x2c0
el1\_irq+0xb8/0x140
arch\_cpu\_idle+0x18/0x40
default\_idle\_call+0x5c/0x1c0
cpuidle\_idle\_call+0x174/0x1b0
do\_idle+0xc8/0x160
cpu\_startup\_entry+0x30/0x11c
secondary\_start\_kernel+0x158/0x1e4
softirq: huh, entered softirq 3 NET\_RX 0000000093774ee4 with
preempt\_count 00000100, exited with fffffe00?

## Affected and fixed versions

- Linux: \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< 16e18a8ac7c9748cf35a8d2f0ba2c6e8850e7568; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< aa495dfe71229b9034b59d8072ff0b2325ddd5ee; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< 4a461ba5b9753352f438824fdd915cba675b1733; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< c9be45e4c69fde36522274f04d1aa0d097ae3958; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< 02884a4f12de11f54d4ca67a07dd1f111d96fdbd (cvelist)
- Linux: 5.5 (cvelist)

## Mitigation

- Upgrade Linux to 02884a4f12de11f54d4ca67a07dd1f111d96fdbd or later.

## Check your systems with an agent

Paste this into a coding agent:

```text
Check whether anything I run is affected by CVE-2022-50171. Work read-only: do not install, upgrade, delete or change anything.

Details: https://flawdb.com/CVE-2022-50171.md
Affected: Linux >= 416d82204df44ef727de6eafafeaa4d12fdc78dc, < 16e18a8ac7c9748cf35a8d2f0ba2c6e8850e7568; >= 416d82204df44ef727de6eafafeaa4d12fdc78dc, < aa495dfe71229b9034b59d8072ff0b2325ddd5ee; >= 416d82204df44ef727de6eafafeaa4d12fdc78dc, < 4a461ba5b9753352f438824fdd915cba675b1733; >= 416d82204df44ef727de6ea…
Fixed in: Linux 16e18a8ac7c9748cf35a8d2f0ba2c6e8850e7568, Linux 4a461ba5b9753352f438824fdd915cba675b1733, Linux 02884a4f12de11f54d4ca67a07dd1f111d96fdbd

Steps:
1. Search this machine and project for Linux: dependency manifests and lockfiles, installed packages, container images and running services.
2. For each match, note the installed version and whether it is inside the affected range.
3. Report a table: location, installed version, affected (yes / no / unsure), evidence. If affected, say which fixed version or mitigation from the details link applies, but don't apply it.
```

## FAQ

### Is CVE-2022-50171 being exploited?

There is no confirmed exploitation: CVE-2022-50171 is not in the CISA Known Exploited Vulnerabilities catalog. No public exploit code is known. EPSS estimates a 0.41% chance of exploitation in the next 30 days (as of 2026-11-26).

### How serious is CVE-2022-50171?

High: CVSS 7.5 (v3.1, scored by CNA). Remote, no login needed.

### Which versions are affected by CVE-2022-50171?

Linux \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< 16e18a8ac7c9748cf35a8d2f0ba2c6e8850e7568; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< aa495dfe71229b9034b59d8072ff0b2325ddd5ee; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< 4a461ba5b9753352f438824fdd915cba675b1733; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< c9be45e4c69fde36522274f04d1aa0d097ae3958; \>= 416d82204df44ef727de6eafafeaa4d12fdc78dc, \< 02884a4f12de11f54d4ca67a07dd1f111d96fdbd; Linux 5.5.

### Is there a fix for CVE-2022-50171?

Yes. Fixed in Linux 16e18a8ac7c9748cf35a8d2f0ba2c6e8850e7568, Linux 4a461ba5b9753352f438824fdd915cba675b1733, Linux 02884a4f12de11f54d4ca67a07dd1f111d96fdbd. Upgrade Linux to 02884a4f12de11f54d4ca67a07dd1f111d96fdbd or later.

### How do I check if I'm affected by CVE-2022-50171?

Find where you use the affected software (dependency lockfiles, installed packages, container images, servers) and compare the installed version with the affected range above. The agent prompt on this page does this read-only.

## References

- patch: <https://git.kernel.org/stable/c/16e18a8ac7c9748cf35a8d2f0ba2c6e8850e7568>
- patch: <https://git.kernel.org/stable/c/aa495dfe71229b9034b59d8072ff0b2325ddd5ee>
- patch: <https://git.kernel.org/stable/c/4a461ba5b9753352f438824fdd915cba675b1733>
- patch: <https://git.kernel.org/stable/c/c9be45e4c69fde36522274f04d1aa0d097ae3958>
- patch: <https://git.kernel.org/stable/c/02884a4f12de11f54d4ca67a07dd1f111d96fdbd>

## Attribution

- CVE Program: CVE® is a registered trademark of The MITRE Corporation. CVE records © 1999–2026 The MITRE Corporation. <https://www.cve.org/Legal/TermsOfUse>
- NVD: This product uses data from the NVD API but is not endorsed or certified by the NVD. <https://nvd.nist.gov/vuln/detail/CVE-2022-50171>

HTML: <https://flawdb.com/CVE-2022-50171> · JSON: <https://flawdb.com/api/v1/entries/CVE-2022-50171>
