[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Yrpe/D+PU078OoIn@gondor.apana.org.au>
Date: Tue, 28 Jun 2022 09:53:00 +0800
From: Herbert Xu <herbert@...dor.apana.org.au>
To: "Jason A. Donenfeld" <Jason@...c4.com>
Cc: linux-wireless@...r.kernel.org, linux-kernel@...r.kernel.org,
Toke Høiland-Jørgensen <toke@...hat.com>,
Gregory Erwin <gregerwin256@...il.com>,
Kalle Valo <kvalo@...nel.org>,
Rui Salvaterra <rsalvaterra@...il.com>, stable@...r.kernel.org
Subject: Re: [PATCH v6] ath9k: sleep for less time when unregistering hwrng
On Mon, Jun 27, 2022 at 02:07:35PM +0200, Jason A. Donenfeld wrote:
> Even though hwrng provides a `wait` parameter, it doesn't work very well
> when waiting for a long time. There are numerous deadlocks that emerge
> related to shutdown. Work around this API limitation by waiting for a
> shorter amount of time and erroring more frequently. This commit also
> prevents hwrng from splatting messages to dmesg when there's a timeout
> and switches to using schedule_timeout_interruptible(), so that the
> kthread can be stopped.
>
> Reported-by: Gregory Erwin <gregerwin256@...il.com>
> Tested-by: Gregory Erwin <gregerwin256@...il.com>
> Cc: Toke Høiland-Jørgensen <toke@...hat.com>
> Cc: Kalle Valo <kvalo@...nel.org>
> Cc: Rui Salvaterra <rsalvaterra@...il.com>
> Cc: Herbert Xu <herbert@...dor.apana.org.au>
> Cc: stable@...r.kernel.org
> Fixes: fcd09c90c3c5 ("ath9k: use hw_random API instead of directly dumping into random.c")
> Link: https://lore.kernel.org/all/CAO+Okf6ZJC5-nTE_EJUGQtd8JiCkiEHytGgDsFGTEjs0c00giw@mail.gmail.com/
> Link: https://lore.kernel.org/lkml/CAO+Okf5k+C+SE6pMVfPf-d8MfVPVq4PO7EY8Hys_DVXtent3HA@mail.gmail.com/
> Link: https://bugs.archlinux.org/task/75138
> Signed-off-by: Jason A. Donenfeld <Jason@...c4.com>
> ---
> drivers/char/hw_random/core.c | 5 +++--
> drivers/net/wireless/ath/ath9k/rng.c | 20 +++-----------------
> 2 files changed, 6 insertions(+), 19 deletions(-)
Acked-by: Herbert Xu <herbert@...dor.apana.org.au>
Thanks,
--
Email: Herbert Xu <herbert@...dor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
Powered by blists - more mailing lists