Re: [PATCH 0/2] nfsd: improvements for wake_up_bit/var

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, 31 Aug 2024, Chuck Lever wrote:
> On Fri, 30 Aug 2024 17:03:15 +1000, NeilBrown wrote:
> > I've been digging into wake_up_bit and wake_up_var recently.  There are
> > a lot of places where the required barriers aren't quite right.
> > 
> > This patch fixes them up for nfsd.  The bugs are mostly minor, though
> > the rp_locked on might be a credible problem on weakly ordered hosts
> > (e.g.  power64).
> > 
> > [...]
> 
> Applied to nfsd-next for v6.12, thanks!
> 
> [1/2] nfsd: use clear_and_wake_up_bit()
>       commit: 2b9a19d16beda1b2ca5edab47d74b73d4d958b12
> [2/2] nfsd: avoid races with wake_up_var()
>       commit: a2bf7d13821603fb90c3f6e695bd5fb4ee19de71
> 
> Both of these patches threw compilation errors. I corrected those
> issues before applying. Please check my work.

Thanks for that ...  I really shouldn't post patches in the afternoon -
I'm not thinking as clearly :-(

> 
> checkpatch.pl complained about the lack of comment on the added
> barriers. I felt the code was self-explanatory so made no change.
> 

I'd really like a wake_up_var_after_atomic() but Linus wasn't keen on
going in that direction.

if/when my improvements land
  https://lore.kernel.org/all/20240826063659.15327-1-neilb@xxxxxxx/
we could change rp_locked to an "int" and use
   store_release_wake_up()
which includes that required barrier.

NeilBrown




[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux