From: arnd@arndb.de (Arnd Bergmann)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] arm64: compat: fix compat types affecting struct compat_elf_prpsinfo
Date: Tue, 14 Oct 2014 12:08:19 +0200 [thread overview]
Message-ID: <5165393.b3bTx8bIzn@wuerfel> (raw)
In-Reply-To: <20141014095353.GD26987@e104818-lin.cambridge.arm.com>
On Tuesday 14 October 2014 10:53:53 Catalin Marinas wrote:
> > > The problem is that elf_prpsinfo uses __kernel_uid_t which arm32 defines
> > > as (unsigned short) while compat_elf_prspinfo uses __compat_uid_t which
> > > is 32-bit. In reality compat_uid_t is different from the arm32
> > > kernel_uid_t (other 32-bit architectures may use a 32-bit kernel_uid_t).
> >
> > compat_uid_t should match the __kernel_uid_t for all 32-bit architectures
> > that are emulated on a 64-bit architecture, that is the definition.
>
> I guess you meant __compat_uid_t here. The compat_uid_t type is u32
> already.
Ah, that's weird: compat_uid_t is not used anywhere in the kernel,
and the definition is odd. Apparently it was intentional back in 2005
when Stephen Rothwell introduced it as part of 202e5979af4d9
("compat: be more consistent about [ug]id_t"), but I have trouble
understanding the intention.
> So that patch is fine, I'll take it for 3.17 (and cc stable all the way
> back to 3.7).
Ok. It might be worth checking if there are any uses of __compat_uid_t
in arm64 that should have been __compat_uid32_t. Currently they are
the same, but after Victor's patch, they would be different, which could
cause regressions.
Arnd
next prev parent reply other threads:[~2014-10-14 10:08 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-14 5:55 [PATCH] compat: fix compat types affecting struct compat_elf_prpsinfo Victor Kamensky
2014-10-14 5:55 ` [PATCH] arm64: " Victor Kamensky
2014-10-14 8:51 ` Catalin Marinas
2014-10-14 8:53 ` Catalin Marinas
2014-10-14 9:29 ` Arnd Bergmann
2014-10-14 9:53 ` Catalin Marinas
2014-10-14 10:08 ` Arnd Bergmann [this message]
2014-10-14 10:28 ` Catalin Marinas
2014-10-14 16:38 ` Victor Kamensky
2014-10-14 17:54 ` Arnd Bergmann
-- strict thread matches above, loose matches on Subject: below --
2014-10-14 6:00 Victor Kamensky
2014-10-15 6:11 Victor Kamensky
2014-10-15 14:50 ` Catalin Marinas
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=5165393.b3bTx8bIzn@wuerfel \
--to=arnd@arndb.de \
--cc=linux-arm-kernel@lists.infradead.org \
/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