[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200519103247.GA4611@sirena.org.uk>
Date: Tue, 19 May 2020 11:32:47 +0100
From: Mark Brown <broonie@...nel.org>
To: Serge Semin <Sergey.Semin@...kalelectronics.ru>
Cc: Serge Semin <fancer.lancer@...il.com>,
Ramil Zaripov <Ramil.Zaripov@...kalelectronics.ru>,
Alexey Malahov <Alexey.Malahov@...kalelectronics.ru>,
Thomas Bogendoerfer <tsbogend@...ha.franken.de>,
Paul Burton <paulburton@...nel.org>,
Ralf Baechle <ralf@...ux-mips.org>,
Lee Jones <lee.jones@...aro.org>,
Miquel Raynal <miquel.raynal@...tlin.com>,
Arnd Bergmann <arnd@...db.de>,
Rob Herring <robh+dt@...nel.org>, linux-mips@...r.kernel.org,
devicetree@...r.kernel.org, John Garry <john.garry@...wei.com>,
Chuanhong Guo <gch981213@...il.com>,
Andy Shevchenko <andy.shevchenko@...il.com>,
Eddie James <eajames@...ux.ibm.com>,
Geert Uytterhoeven <geert@...ux-m68k.org>,
Chris Packham <chris.packham@...iedtelesis.co.nz>,
Tomer Maimon <tmaimon77@...il.com>,
Masahisa Kojima <masahisa.kojima@...aro.org>,
Krzysztof Kozlowski <krzk@...nel.org>,
Florian Fainelli <f.fainelli@...il.com>,
Jassi Brar <jaswinder.singh@...aro.org>,
linux-kernel@...r.kernel.org, linux-spi@...r.kernel.org
Subject: Re: [PATCH 2/2] spi: Add Baikal-T1 System Boot SPI Controller driver
On Tue, May 19, 2020 at 12:17:27AM +0300, Serge Semin wrote:
> Here is what we need to do to perform the EEPROM-read operation:
> 1) Enable EEPROM-read mode.
> 2) Initialize a corresponding registers with a number of SPI transfer words
> (with bits-per-word taken into account) to read.
> 3) Push opcode + address + dummy bytes into the Tx FIFO. When it's done and
> the Tx FIFO is empty, the controller will proceed with read operations by
> pushing zeros (or ones, don't remember what level it's by default) to MOSI
> and pulling data from MISO into the RX FIFO.
> 4) Keep up with getting data from the Rx FIFO so one wouldn't get overflown.
> Regarding programming write each time. Well, it's up to the driver implementation.
> If opcode, address, dummy bytes and number of words to read are the same as before,
> then re-programming isn't required.
Ah, nice. This should be useful for far more than just flash - most
register reads will also be able to take advantage of this, they follow
a similar write then read pattern.
Download attachment "signature.asc" of type "application/pgp-signature" (489 bytes)
Powered by blists - more mailing lists