Re: [PATCH 1/1] futex: futex_wake_op, fix sign_extend32 sign bits

2017-12-11 Thread Darren Hart
On Mon, Dec 11, 2017 at 08:37:11AM +0100, Jiri Slaby wrote: > On 12/10/2017, 09:50 PM, Linus Torvalds wrote: > > On Thu, Nov 30, 2017 at 6:35 AM, Jiri Slaby wrote: > >> sign_extend32 counts the sign bit parameter from 0, not from 1. So we > >> have to use "11" for 12th bit, not "12". > > > > This

Re: [PATCH 1/1] futex: futex_wake_op, fix sign_extend32 sign bits

2017-12-10 Thread Jiri Slaby
On 12/10/2017, 09:50 PM, Linus Torvalds wrote: > On Thu, Nov 30, 2017 at 6:35 AM, Jiri Slaby wrote: >> sign_extend32 counts the sign bit parameter from 0, not from 1. So we >> have to use "11" for 12th bit, not "12". > > This interface is crap. It really doesn't make much sense. I wonder > how ma

Re: [PATCH 1/1] futex: futex_wake_op, fix sign_extend32 sign bits

2017-12-10 Thread Linus Torvalds
On Thu, Nov 30, 2017 at 6:35 AM, Jiri Slaby wrote: > sign_extend32 counts the sign bit parameter from 0, not from 1. So we > have to use "11" for 12th bit, not "12". This interface is crap. It really doesn't make much sense. I wonder how many people have gotten this wrong, but it's hard to tell.