phy: renesas: phy-rcar-gen3-usb2: Fix devm action registration for disabled VBUS regulator
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
| No fix yet |
| Linux Linux |
|
|
6.18.527.2.67.3In the Linux kernel, the following vulnerability has been resolved:
phy: renesas: phy-rcar-gen3-usb2: Fix devm action registration for disabled VBUS regulator
devm_regulator_get_exclusive() initialises the regulator with enable_count = 1, requiring the consumer to disable it before release.
The devm disable action was previously only registered when the caller explicitly requested enable, so when the regulator was left in its initial enabled state without an explicit enable call, the cleanup path skipped decrementing enable_count, triggering a WARN_ON during regulator release on device removal.
Fix this by always registering the devm disable action based on the actual enabled state via regulator_is_enabled(), regardless of whether the caller requested an explicit enable. This covers both the explicitly enabled case and the initial state set by devm_regulator_get_exclusive().
From the CVE record · Linux
The Renesas USB2 PHY driver can skip disabling a VBUS regulator during cleanup when the regulator was initially enabled but no explicit enable was requested. This triggers a kernel warning when the device is removed; the input does not describe an attacker path, authentication requirement, or user interaction.
Engineers running Linux kernels with the Renesas R-Car Gen3 USB2 PHY driver should check whether their kernel includes the fix; affected versions are not specified.