[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20160813145403.GB24335@yury-N73SV>
Date: Sat, 13 Aug 2016 17:54:03 +0300
From: Yury Norov <ynorov@...iumnetworks.com>
To: Andreas Schwab <schwab@...e.de>
CC: <arnd@...db.de>, <catalin.marinas@....com>,
<linux-arm-kernel@...ts.infradead.org>,
<linux-kernel@...r.kernel.org>, <linux-doc@...r.kernel.org>,
<linux-arch@...r.kernel.org>, <libc-alpha@...rceware.org>,
<schwidefsky@...ibm.com>, <heiko.carstens@...ibm.com>,
<pinskia@...il.com>, <broonie@...nel.org>,
<joseph@...esourcery.com>,
<christoph.muellner@...obroma-systems.com>,
<bamvor.zhangjian@...wei.com>, <szabolcs.nagy@....com>,
<klimov.linux@...il.com>, <Nathan_Lynch@...tor.com>,
<agraf@...e.de>, <Prasun.Kapoor@...iumnetworks.com>,
<kilobyte@...band.pl>, <geert@...ux-m68k.org>,
<philipp.tomsich@...obroma-systems.com>,
<manuel.montezelo@...il.com>, <linyongting@...wei.com>,
<maxim.kuvyrkov@...aro.org>, <davem@...emloft.net>
Subject: Re: [PATCH 18/19] arm64:ilp32: add vdso-ilp32 and use for signal
return
On Mon, Jun 20, 2016 at 04:54:17PM +0200, Andreas Schwab wrote:
> Yury Norov <ynorov@...iumnetworks.com> writes:
>
> > diff --git a/arch/arm64/kernel/vdso.c b/arch/arm64/kernel/vdso.c
> > index 2a0de6f..e48ea34 100644
> > --- a/arch/arm64/kernel/vdso.c
> > +++ b/arch/arm64/kernel/vdso.c
> > @@ -40,6 +40,12 @@ extern char vdso_start, vdso_end;
> > static unsigned long vdso_pages;
> > static struct page **vdso_pagelist;
> >
> > +#ifdef CONFIG_ARM64_ILP32
> > +extern char vdso_ilp32_start, vdso_ilp32_end;
> > +static unsigned long vdso_ilp32_pages;
> > +static struct page **vdso_ilp32_pagelist;
> > +#endif
> > +
> > /*
> > * The vDSO data page.
> > */
> > @@ -110,24 +116,29 @@ int aarch32_setup_vectors_page(struct linux_binprm *bprm, int uses_interp)
> > }
> > #endif /* CONFIG_AARCH32_EL0 */
> >
> > -static struct vm_special_mapping vdso_spec[2];
> > -
> > -static int __init vdso_init(void)
> > +static int __init vdso_init_common(char *vdso_start, char *vdso_end,
>
> Using the same name for the parameter as for the global variable is
> dangerous ....
>
> > + unsigned long *vdso_pagesp,
> > + struct page ***vdso_pagelistp,
> > + struct vm_special_mapping* vdso_spec)
> > {
> > int i;
> > + unsigned long vdso_pages;
> > + struct page **vdso_pagelist;
> >
> > - if (memcmp(&vdso_start, "\177ELF", 4)) {
> > + if (memcmp(vdso_start, "\177ELF", 4)) {
>
> ... because forgetting to remove & can be fatal, and your compiler may
> not even warn you.
>
> Andreas.
Fixed. See here: https://github.com/norov/linux/tree/ilp32-4.8
Thanks.
Yury.
Powered by blists - more mailing lists