aboutsummaryrefslogtreecommitdiffstats
path: root/scripts/generate_rust_target.rs
diff options
context:
space:
mode:
authorClaudiu Beznea <[email protected]>2025-08-10 12:33:28 +0000
committerJonathan Cameron <[email protected]>2025-08-16 13:52:43 +0000
commitc69e13965f26b8058f538ea8bdbd2d7718cf1fbe (patch)
treeb94f3adff2ef8373285caf5b0955a60a3cc97f2c /scripts/generate_rust_target.rs
parentiio: adc: rzg2l: Cleanup suspend/resume path (diff)
downloadkernel-c69e13965f26b8058f538ea8bdbd2d7718cf1fbe.tar.gz
kernel-c69e13965f26b8058f538ea8bdbd2d7718cf1fbe.zip
iio: adc: rzg2l_adc: Set driver data before enabling runtime PM
When stress-testing the system by repeatedly unbinding and binding the ADC device in a loop, and the ADC is a supplier for another device (e.g., a thermal hardware block that reads temperature through the ADC), it may happen that the ADC device is runtime-resumed immediately after runtime PM is enabled, triggered by its consumer. At this point, since drvdata is not yet set and the driver's runtime PM callbacks rely on it, a crash can occur. To avoid this, set drvdata just after it was allocated. Fixes: 89ee8174e8c8 ("iio: adc: rzg2l_adc: Simplify the runtime PM code") Signed-off-by: Claudiu Beznea <[email protected]> Link: https://patch.msgid.link/[email protected] Cc: <[email protected]> Signed-off-by: Jonathan Cameron <[email protected]>
Diffstat (limited to 'scripts/generate_rust_target.rs')
0 files changed, 0 insertions, 0 deletions