Re: [PATCH 10/11] x86, rwsem: provide __down_write_killable

From: H. Peter Anvin
Date: Wed Apr 20 2016 - 17:09:16 EST


On 04/20/2016 01:45 PM, Borislav Petkov wrote:
> On Wed, Apr 20, 2016 at 11:04:05AM -0700, H. Peter Anvin wrote:
>> The reason it breaks is because the same register can't be an
>> input-output register and a separate input. However, the input side of
>> the input-output is probably undefined, and so gcc may not notice.
>
> So Michal and I talked about this a while ago. Why do we need the '"a"
> (sem)' input dependency if '"+a" (ret)' already supplies the same thing?
>

Setting ret to sem doesn't make any sense. Just use "=a" and "a".

-hpa