On 15.09.23 12:45, Herbert Xu wrote: > On Wed, Sep 06, 2023 at 01:27:57AM +0200, Stefan Wahren wrote: >> The last RCU stall fix caused a massive throughput regression of the >> hwrng on Raspberry Pi 0 - 3. hwrng_msleep doesn't sleep precisely enough >> and usleep_range doesn't allow scheduling. So try to restore the >> best possible throughput by introducing hwrng_yield which interruptable >> sleeps for one jiffy. >> >> Some performance measurements on Raspberry Pi 3B+ (arm64/defconfig): >> >> sudo dd if=/dev/hwrng of=/dev/null count=1 bs=10000 >> >> cpu_relax ~138025 Bytes / sec >> hwrng_msleep(1000) ~13 Bytes / sec >> hwrng_yield ~2510 Bytes / sec >> >> Fixes: 96cb9d055445 ("hwrng: bcm2835 - use hwrng_msleep() instead of cpu_relax()") >> Link: https://lore.kernel.org/linux-arm-kernel/bc97ece5-44a3-4c4e-77da-2db3eb66b128@xxxxxxx/ >> Signed-off-by: Stefan Wahren <wahrenst@xxxxxxx> >> --- >> >> Changes in V2: >> - introduce hwrng_yield and use it >> >> drivers/char/hw_random/bcm2835-rng.c | 2 +- >> drivers/char/hw_random/core.c | 6 ++++++ >> include/linux/hw_random.h | 1 + >> 3 files changed, 8 insertions(+), 1 deletion(-) > > Patch applied. Thanks. Hi Herbert, I there a strong reason why you merged this to what from here looks like the branch that targets the next merge window? The patch fixes a regression introduced during the last 12 months and thus normally should not wait for the next merge window. For details see "Expectations and best practices for fixing regressions" in Documentation/process/handling-regressions.rst; or if you want to hear it from Linus directly, check these out: https://lore.kernel.org/all/CAHk-=wis_qQy4oDNynNKi5b7Qhosmxtoj1jxo5wmB6SRUwQUBQ@xxxxxxxxxxxxxx/ https://lore.kernel.org/all/CAHk-=wgD98pmSK3ZyHk_d9kZ2bhgN6DuNZMAJaV0WTtbkf=RDw@xxxxxxxxxxxxxx/ Ciao, Thorsten (wearing his 'the Linux kernel's regression tracker' hat) -- Everything you wanna know about Linux kernel regression tracking: https://linux-regtracking.leemhuis.info/about/#tldr If I did something stupid, please tell me, as explained on that page.