CVE-2024-50196 pinctrl: ocelot: fix system hang on level based interrupts

Medium 5.5 Published Updated

A logic error in the Ocelot pinctrl driver causes a system hang when handling specific level-based GPIO interrupts, requiring a kernel patch.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Local or same network only
Victim action needed
Not needed
Fix
Available

What is CVE-2024-50196?

CVE-2024-50196 is a medium-severity denial of service vulnerability in Linux kernel, published on 8 Nov 2024. It can only be exploited from the same machine or local network, with no action from the victim.

Official description

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

pinctrl: ocelot: fix system hang on level based interrupts

The current implementation only calls chained_irq_enter() and chained_irq_exit() if it detects pending interrupts.

``` for (i = 0; i < info->stride; i++) { uregmap_read(info->map, id_reg + 4 * i, &reg); if (!reg) continue;

chained_irq_enter(parent_chip, desc); ```

However, in case of GPIO pin configured in level mode and the parent controller configured in edge mode, GPIO interrupt might be lowered by the hardware. In the result, if the interrupt is short enough, the parent interrupt is still pending while the GPIO interrupt is cleared; chained_irq_enter() never gets called and the system hangs trying to service the parent interrupt.

Moving chained_irq_enter() and chained_irq_exit() outside the for loop ensures that they are called even when GPIO interrupt is lowered by the hardware.

The similar code with chained_irq_enter() / chained_irq_exit() functions wrapping interrupt checking loop may be found in many other drivers: ``` grep -r -A 10 chained_irq_enter drivers/pinctrl ```

Weakness: CWE-754

Which versions are affected by CVE-2024-50196?

It affects 1 product.

Products include Linux kernel.

How do I fix CVE-2024-50196?

Apply the vendor's patch.

Upgrade, then put limits on request size, rate and nesting depth so one client cannot exhaust the service. More about Denial of service.

Is CVE-2024-50196 being exploited?

There is no known exploitation of CVE-2024-50196 in the wild and no public exploit code.

All Linux kernel vulnerabilities

Sources

Also known as AZL-53552, AZL-53660, BELL-CVE-2024-50196, DEBIAN-CVE-2024-50196, GHSA-3vv9-rrp8-6jqf, ROOT-OS-DEBIAN-11-CVE-2024-50196 and 1 more.

Is CVE-2024-50196 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free