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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <1521754493.7999.49.camel@perches.com>
Date:   Thu, 22 Mar 2018 14:34:53 -0700
From:   Joe Perches <joe@...ches.com>
To:     Alan Tull <atull@...nel.org>
Cc:     Paolo Pisati <p.pisati@...il.com>, Moritz Fischer <mdf@...nel.org>,
        Rob Herring <robh+dt@...nel.org>,
        Mark Rutland <mark.rutland@....com>,
        linux-fpga@...r.kernel.org,
        "open list:OPEN FIRMWARE AND FLATTENED DEVICE TREE BINDINGS" 
        <devicetree@...r.kernel.org>,
        linux-kernel <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 2/2] fpga: lattice machxo2: Add Lattice MachXO2 support

On Thu, 2018-03-22 at 16:32 -0500, Alan Tull wrote:
> On Wed, Mar 21, 2018 at 1:04 PM, Joe Perches <joe@...ches.com> wrote:
> > On Wed, 2018-03-21 at 18:35 +0100, Paolo Pisati wrote:
> > > This patch adds support to the FPGA manager for programming
> > > MachXO2 device’s internal flash memory, via slave SPI.
> > 
> > style trivia:
> > 
> > > diff --git a/drivers/fpga/machxo2-spi.c b/drivers/fpga/machxo2-spi.c
> > 
> > []
> > > +static int get_status(struct spi_device *spi, unsigned long *status)
> > > +{
> > > +     struct spi_message msg;
> > > +     struct spi_transfer rx, tx;
> > > +     u8 cmd[] = LSC_READ_STATUS;
> > 
> > static const u8 cmd[]
> > here and everywhere else as all the tx_buf assignments
> > of cmd are to const void *
> 
> Why *static* const u8 cmd[]?

So various compilers don't reload it on each call.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ