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: <CAK8P3a2SP0eX50NoFKaM2N85mgSejToQkD9ZOE_7V_RT__BCvg@mail.gmail.com>
Date:   Tue, 4 Dec 2018 22:17:18 +0100
From:   Arnd Bergmann <arnd@...db.de>
To:     Firoz Khan <firoz.khan@...aro.org>
Cc:     linuxppc-dev <linuxppc-dev@...ts.ozlabs.org>,
        Benjamin Herrenschmidt <benh@...nel.crashing.org>,
        Paul Mackerras <paulus@...ba.org>,
        Michael Ellerman <mpe@...erman.id.au>,
        Geert Uytterhoeven <geert@...ux-m68k.org>, linuxram@...ibm.com,
        Mathieu Desnoyers <mathieu.desnoyers@...icios.com>,
        leitao@...ian.org, Boqun Feng <boqun.feng@...il.com>,
        gregkh <gregkh@...uxfoundation.org>,
        Philippe Ombredanne <pombredanne@...b.com>,
        Thomas Gleixner <tglx@...utronix.de>,
        Kate Stewart <kstewart@...uxfoundation.org>,
        y2038 Mailman List <y2038@...ts.linaro.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        linux-arch <linux-arch@...r.kernel.org>,
        Deepa Dinamani <deepa.kernel@...il.com>,
        Marcin Juszkiewicz <marcin.juszkiewicz@...aro.org>
Subject: Re: [PATCH v3 4/4] powerpc: generate uapi header and system call
 table files

> diff --git a/arch/powerpc/kernel/systbl.S b/arch/powerpc/kernel/systbl.S
> index 9ff1913..d756348 100644
> --- a/arch/powerpc/kernel/systbl.S
> +++ b/arch/powerpc/kernel/systbl.S

>  #ifdef CONFIG_PPC64
> @@ -47,5 +25,17 @@
>  .globl sys_call_table
>  sys_call_table:
>
> +#if defined CONFIG_PPC64 && defined(CONFIG_COMPAT)
> +#define __SYSCALL(nr, entry, nargs) .8byte entry
>  #define compat_sys_sigsuspend  sys_sigsuspend
> -#include <asm/systbl.h>
> +#include <asm/syscall_table_c32.h>
> +#undef __SYSCALL
> +#elif defined CONFIG_PPC64 && !defined(CONFIG_COMPAT)
> +#define __SYSCALL(nr, entry, nargs) .8byte entry
> +#include <asm/syscall_table_64.h>
> +#undef __SYSCALL

This part looks wrong: where the old sys_call_table contained
both the native and compat calls side by side, the new table
contains only the compat versions (note that CONFIG_COMPAT is
always set on PPC64). I think you copy-pasted this incorrectly from
one of the other architectures that uses a different layout for the
compat calls.

The way I think this could work best is if you add a preparation
patch that splits out the 64-bit table into two separate ones
(and make sure that works). After that, you can add your
existing patch, rebased to use the two generated tables
instead of the old-style tables. I'll follow up with an untested
patch for illustration.

       Arnd

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ