[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y2EVx95XUEVOn7p3@arm.com>
Date: Tue, 1 Nov 2022 12:49:11 +0000
From: 'Szabolcs Nagy' <szabolcs.nagy@....com>
To: David Laight <David.Laight@...LAB.COM>
Cc: Theodore Ts'o <tytso@....edu>,
"linux-api@...r.kernel.org" <linux-api@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>
Subject: Re: linux interprets an fcntl int arg as long
The 11/01/2022 12:19, David Laight wrote:
> From: 'Szabolcs Nagy' <szabolcs.nagy@....com>
> > SYSCALL_DEFINE3(fcntl, unsigned int, fd, unsigned int, cmd, unsigned long, arg)
> > {
>
> That is just a wrapper and calls do_fcntl().
> which needs changing to be add:
> arg &= ~0U;
> before the switch(cmd) {
this makes sense.
i thought previously you meant masking in userspace.
although if you mask there then many linux internal
apis could use int instead of long arg.
do you want me to post a patch? (i'm not a kernel
developer)
Powered by blists - more mailing lists