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: <CA+-6iNyvkvwPvr-_R8zivnKLtkwmYG34vephdYUJ7ywCqNmjMg@mail.gmail.com>
Date:   Mon, 14 Sep 2020 13:02:32 -0400
From:   Jim Quinlan <james.quinlan@...adcom.com>
To:     Thomas Bogendoerfer <tsbogend@...ha.franken.de>
Cc:     linux-mips@...r.kernel.org,
        "maintainer:BROADCOM BCM7XXX ARM ARCHITECTURE" 
        <bcm-kernel-feedback-list@...adcom.com>,
        open list <linux-kernel@...r.kernel.org>
Subject: Re: [RESEND PATCH v1] MIPS: uasm: false warning on use of uasm_i_lui()

On Thu, Sep 10, 2020 at 5:37 AM Thomas Bogendoerfer
<tsbogend@...ha.franken.de> wrote:
>
> On Tue, Sep 08, 2020 at 12:45:06PM -0400, Jim Quinlan wrote:
> > Currently, the example uasm code
> >
> >       uasm_i_lui(p, tmp, 0xa000);
> >
> > issues a warning at Linux boot when the code is "assembled".  This is
> > because the "lui" instruction is defined by the macro "Ip_u1s2(_lui)" -- I
> > believe it should be Ip_u1u2(_lui) -- and its definition is associated with
> > the SIMM macro -- I believe it should be the UIMM macro.  The current code
> > takes a 32bit number and checks that it can be converted to a 16bit signed
> > immediate.  This check fails of course for an immediate such as 0x0000a000.
>
> IMHO SIMM is correct as the upper 16bits will be sign extended on 64bit
> CPUs.
>
Hi Thomas,

Got it.

Thanks,
Jim

> Your example looks like to try to load a KSEG1 address, so just use
>
> uasm_i_lui(p, tmp, uasm_rel_hi(0xa0000000));
>
> which even makes it clearer, what this is about.
>
> Thomas.
>
> --
> Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
> good idea.                                                [ RFC1925, 2.3 ]

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ