lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <9d09639f-6821-8d21-d3cb-ec980338c4e8@collabora.com>
Date:   Thu, 9 Jul 2020 21:19:47 -0300
From:   André Almeida <andrealmeid@...labora.com>
To:     Randy Dunlap <rdunlap@...radead.org>, linux-kernel@...r.kernel.org,
        tglx@...utronix.de, peterz@...radead.org
Cc:     krisman@...labora.com, kernel@...labora.com, dvhart@...radead.org,
        mingo@...hat.com, pgriffais@...vesoftware.com, fweimer@...hat.com,
        libc-alpha@...rceware.org, malteskarupke@....de,
        linux-api@...r.kernel.org, arnd@...db.de
Subject: Re: [RFC v2 1/4] futex2: Add new futex interface

Hello,

On 7/9/20 9:09 PM, Randy Dunlap wrote:
> Hi,
> 
> On 7/9/20 10:59 AM, André Almeida wrote:
>>
>>
>> diff --git a/kernel/futex2.c b/kernel/futex2.c
>> new file mode 100644
>> index 000000000000..b87a10ba7c01
>> --- /dev/null
>> +++ b/kernel/futex2.c
>> @@ -0,0 +1,73 @@
>> +// SPDX-License-Identifier: GPL-2.0-or-later
>> +/*
>> + * futex2 system call interface by André Almeida <andrealmeid@...labora.com>
>> + *
>> + * Copyright 2020 Collabora Ltd.
>> + */
>> +
>> +#include <linux/syscalls.h>
>> +
>> +#include <asm/futex.h>
>> +
>> +/*
>> + * Set of flags that futex2 operates. If we got something that is not in this
>> + * set, it can be a unsupported futex1 operation like BITSET or PI, so we
>> + * refuse to accept
>> + */
>> +#define FUTEX2_MASK (FUTEX_SIZE_MASK | FUTEX_PRIVATE_FLAG | FUTEX_CLOCK_REALTIME)
>> +
>> +/**
>> + * sys_futex_wait: Wait on a futex address if (*uaddr) == val
> 
> Function name line should use - as separator, not :, so
>  * sys_futex_wait - Wait on a futex address if (*uaddr) == val
> 
>> + * @uaddr: User address of futex
>> + * @val:   Expected value of futex
>> + * @flags: Checks if futex is private, the size of futex and the clockid
>> + * @timo:  Optional absolute timeout. Supports only 64bit time.
>> + */
>> +SYSCALL_DEFINE4(futex_wait, void __user *, uaddr, unsigned long, val,
>> +		unsigned long, flags, struct __kernel_timespec __user *, timo)
>> +{
>   ...
>> +}
>> +
>> +/**
>> + * sys_futex_wake: Wake a number of futexes waiting in an address
> 
> Same here:
>  * sys_futex_wake - Wake a number of futexes waiting in an address
> 
> or could it be "on an address":
>  * sys_futex_wake - Wake a number of futexes waiting on an address
> 
>> + * @uaddr:   Address of futex to be woken up
>> + * @nr_wake: Number of futexes to be woken up
>> + * @flags:   Checks if futex is private and the size of futex
>> + */
>> +SYSCALL_DEFINE3(futex_wake, void __user *, uaddr, unsigned int, nr_wake,
>> +		unsigned long, flags)
>> +{
> 

Both changes applied for v3, thanks for the feedback.

> 
> thanks.
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ