From: Miklos Szeredi <miklos@szeredi.hu>
To: Russell King - ARM Linux <linux@arm.linux.org.uk>
Cc: linux-arch <linux-arch@vger.kernel.org>,
Kernel Mailing List <linux-kernel@vger.kernel.org>,
Miklos Szeredi <mszeredi@suse.cz>
Subject: Re: [PATCH 02/15] arm: __NR_syscalls fix
Date: Fri, 11 Apr 2014 14:02:32 +0200 [thread overview]
Message-ID: <CAJfpegtenNUCEAJ3SZpQ8NYcdbCeS8pVxaT767szkR1PF8YPNA@mail.gmail.com> (raw)
In-Reply-To: <20140411115421.GL16119@n2100.arm.linux.org.uk>
On Fri, Apr 11, 2014 at 1:54 PM, Russell King - ARM Linux
<linux@arm.linux.org.uk> wrote:
> On Fri, Apr 11, 2014 at 01:50:50PM +0200, Miklos Szeredi wrote:
>> On Fri, Apr 11, 2014 at 12:33 PM, Russell King - ARM Linux
>> <linux@arm.linux.org.uk> wrote:
>> > On Fri, Apr 11, 2014 at 12:25:38PM +0200, Miklos Szeredi wrote:
>> >> From: Miklos Szeredi <mszeredi@suse.cz>
>> >>
>> >> Signed-off-by: Miklos Szeredi <mszeredi@suse.cz>
>> >> Cc: Russell King <linux@arm.linux.org.uk>
>> >> ---
>> >
>> > This has me wondering...
>> >
>> > (a) what you think it fixes
>> > (b) whether you tried to build-test this
>> >
>> > The ARM instruction set supports 8-bit immediate constants with an even
>> > power of two shift. 384 fits that (0x180), 382 does not (0x17e), and
>> > in your following patch, 383 definitely doesn't (0x17f).
>> >
>> > Having this constant larger than necessary does not cause any problem
>> > for the syscall table: we explicitly pad it with calls to sys_ni_syscall
>> > to make up the difference.
>>
>> Yes, and the padding will be of wrong length if NR_syscalls is
>> incorrect (which may be Oopsable?). At least that is my impression
>> from a casual glance.
>
> Please explain.
Look at ending lines of arch/arm/kernel/calls.S: if NR_syscalls is a
multiple of 4, then syscalls_padding will be zero. I.e. no padding
despite the fact that there is in fact only 382 system calls in table
and there should be 2 sys_ni_syscall pads.
So there's some crap in there, for sure. If it causes actual
problems, I don't know.
Thanks,
Miklos
next prev parent reply other threads:[~2014-04-11 12:02 UTC|newest]
Thread overview: 60+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-11 10:25 [PATCH 00/15] wire up renameat2 syscall for various archs Miklos Szeredi
2014-04-11 10:25 ` [PATCH 01/15] i386: add renameat2 syscall Miklos Szeredi
2014-04-11 10:25 ` Miklos Szeredi
2014-04-11 10:25 ` [PATCH 02/15] arm: __NR_syscalls fix Miklos Szeredi
2014-04-11 10:25 ` Miklos Szeredi
2014-04-11 10:33 ` Russell King - ARM Linux
2014-04-11 10:33 ` Russell King - ARM Linux
2014-04-11 11:50 ` Miklos Szeredi
2014-04-11 11:54 ` Russell King - ARM Linux
2014-04-11 12:02 ` Miklos Szeredi [this message]
2014-04-11 12:45 ` Russell King - ARM Linux
2014-04-23 10:27 ` Russell King - ARM Linux
2014-04-23 12:00 ` Miklos Szeredi
2014-04-11 10:25 ` [PATCH 03/15] arm: add renameat2 syscall Miklos Szeredi
2014-04-11 10:25 ` Miklos Szeredi
2014-04-11 10:35 ` Russell King - ARM Linux
2014-04-11 11:48 ` Miklos Szeredi
2014-04-11 17:39 ` David Miller
2014-04-11 10:25 ` [PATCH 04/15] arm64: __NR_compat_syscalls fix Miklos Szeredi
2014-04-22 16:58 ` Catalin Marinas
2014-04-22 16:58 ` Catalin Marinas
2014-04-23 8:46 ` Miklos Szeredi
2014-04-23 9:40 ` Catalin Marinas
2014-04-11 10:25 ` [PATCH 05/15] arm64: add renameat2 syscall Miklos Szeredi
2014-04-11 10:25 ` Miklos Szeredi
2014-04-22 17:01 ` Catalin Marinas
2014-04-11 10:25 ` [PATCH 06/15] m68k: " Miklos Szeredi
2014-04-11 10:25 ` Miklos Szeredi
2014-04-14 16:29 ` Geert Uytterhoeven
2014-04-14 16:29 ` Geert Uytterhoeven
2014-04-21 8:10 ` Geert Uytterhoeven
2014-04-22 15:32 ` Miklos Szeredi
2014-04-22 15:32 ` Miklos Szeredi
2014-04-11 10:25 ` [PATCH 07/15] mips: " Miklos Szeredi
2014-04-23 11:40 ` James Hogan
2014-04-23 11:40 ` James Hogan
2014-05-15 12:04 ` Miklos Szeredi
2014-04-11 10:25 ` [PATCH 08/15] ia64: " Miklos Szeredi
2014-04-11 10:25 ` [PATCH 09/15] parisc: " Miklos Szeredi
2014-04-11 10:25 ` Miklos Szeredi
2014-04-19 18:54 ` Helge Deller
2014-04-19 18:54 ` Helge Deller
2014-04-22 15:33 ` Miklos Szeredi
2014-04-22 15:33 ` Miklos Szeredi
2014-04-11 10:25 ` [PATCH 10/15] powerpc: " Miklos Szeredi
2014-04-11 10:25 ` Miklos Szeredi
2014-04-11 10:25 ` [PATCH 11/15] s390: NR_syscalls fix Miklos Szeredi
2014-04-11 11:24 ` Martin Schwidefsky
2014-04-11 11:24 ` Martin Schwidefsky
2014-04-11 11:52 ` Miklos Szeredi
2014-04-11 10:25 ` [PATCH 12/15] s390: add renameat2 syscall Miklos Szeredi
2014-04-11 10:25 ` [PATCH 13/15] sparc: " Miklos Szeredi
2014-04-11 10:25 ` Miklos Szeredi
2014-04-11 10:25 ` [PATCH 14/15] xtensa: " Miklos Szeredi
2014-04-11 10:25 ` [PATCH 15/15] asm-generic: " Miklos Szeredi
2014-04-23 11:46 ` James Hogan
2014-04-14 16:32 ` [PATCH 00/15] wire up renameat2 syscall for various archs Geert Uytterhoeven
2014-04-14 20:11 ` Miklos Szeredi
2014-04-15 7:45 ` Geert Uytterhoeven
2014-04-15 7:45 ` Geert Uytterhoeven
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAJfpegtenNUCEAJ3SZpQ8NYcdbCeS8pVxaT767szkR1PF8YPNA@mail.gmail.com \
--to=miklos@szeredi.hu \
--cc=linux-arch@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
--cc=mszeredi@suse.cz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).