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] [day] [month] [year] [list]
Message-ID: <CAFAt38GhDX0OMEz-3AcQRJy6q-cpO-GW_eDFGHmHYw5tZw6EXw@mail.gmail.com>
Date:   Mon, 6 Jan 2020 13:38:50 +0800
From:   Yingjie Bai <byj.tea@...il.com>
To:     Scott Wood <oss@...error.net>
Cc:     Michael Ellerman <mpe@...erman.id.au>, yingjie_bai@....com,
        Kumar Gala <galak@...nel.crashing.org>,
        Benjamin Herrenschmidt <benh@...nel.crashing.org>,
        Paul Mackerras <paulus@...ba.org>,
        linuxppc-dev@...ts.ozlabs.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] powerpc/mpc85xx: also write addr_h to spin table for
 64bit boot entry

Hi Scott,

Sorry for the late reply, I have checked the compilation error from
kbuild system, and found when CONFIG_PHYS_64BIT is not set,
phys_addr_t is 32bit, there is still "right shift count >= width of
type" error.
So I update the patches accordingly.

https://lore.kernel.org/patchwork/patch/1175560/
https://lore.kernel.org/patchwork/patch/1175559/


On Mon, Dec 30, 2019 at 3:41 PM Yingjie Bai <byj.tea@...il.com> wrote:
>
> Hi Scott,
>
> Thanks for your time to review this patch
>
> Based on your suggestion, I have verified below new patches that pass
> compilation with and without CONFIG_RELOCATABLE
>
> https://lore.kernel.org/patchwork/patch/1173548
> https://lore.kernel.org/patchwork/patch/1173547
>
> On Wed, Dec 25, 2019 at 3:19 PM Yingjie Bai <byj.tea@...il.com> wrote:
> >
> > Thanks Scott, I will test to see if returning phys_addr_t in __pa()
> > works for my setup.
> >
> > And another thin I will test is to compile without CONFIG_RELOCATABLE
> > before resubmitting the patch.
> >
> > On Wed, Dec 25, 2019 at 2:53 PM Scott Wood <oss@...error.net> wrote:
> > >
> > > On Wed, 2019-12-25 at 11:24 +0800, Yingjie Bai wrote:
> > > > Hi Scott,
> > > >
> > > > __pa() returns 64bit in my setup.
> > > >
> > > > in arch/powerpc/include/asm/page.h
> > > >
> > > > #if defined(CONFIG_PPC32) && defined(CONFIG_BOOKE)
> > > > #define __va(x) ((void *)(unsigned long)((phys_addr_t)(x) +
> > > > VIRT_PHYS_OFFSET))
> > > > #define __pa(x) ((unsigned long)(x) - VIRT_PHYS_OFFSET)
> > > > #else
> > > > #ifdef CONFIG_PPC64
> > > > ...
> > > >
> > > >
> > > >
> > > > /* See Description below for VIRT_PHYS_OFFSET */
> > > > #if defined(CONFIG_PPC32) && defined(CONFIG_BOOKE)
> > > > #ifdef CONFIG_RELOCATABLE
> > > > #define VIRT_PHYS_OFFSET virt_phys_offset
> > > > #else
> > > > #define VIRT_PHYS_OFFSET (KERNELBASE - PHYSICAL_START)
> > > > #endif
> > > > #endif
> > >
> > > OK, so it's the lack of CONFIG_RELOCATABLE causing the build to fail.  Ideally
> > > we'd make __pa() consistently return phys_addr_t, even if the upper bits are
> > > known to always be zero in a particular config.
> > >
> > > -Scott
> > >
> > >

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ