[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <f03c76b1d0cb49848371915f53f9784d@asem.it>
Date: Thu, 7 Mar 2019 17:50:19 +0000
From: Flavio Suligoi <f.suligoi@...m.it>
To: David Woodhouse <dwmw2@...radead.org>,
Brian Norris <computersforpeace@...il.com>,
Boris Brezillon <bbrezillon@...nel.org>,
"Marek Vasut" <marek.vasut@...il.com>,
Richard Weinberger <richard@....at>,
"Mark Brown" <broonie@...nel.org>,
Frieder Schrempf <frieder.schrempf@...eet.de>,
Yogesh Gaur <yogeshnarayan.gaur@....com>,
"linux-mtd@...ts.infradead.org" <linux-mtd@...ts.infradead.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH v1 1/1] mtd: devices: add ACPI support for non-jedec
m25p80
> -----Original Message-----
> From: David Woodhouse <dwmw2@...radead.org>
> Sent: giovedì 7 marzo 2019 18:40
> To: Flavio Suligoi <f.suligoi@...m.it>; Brian Norris
> <computersforpeace@...il.com>; Boris Brezillon <bbrezillon@...nel.org>;
> Marek Vasut <marek.vasut@...il.com>; Richard Weinberger <richard@....at>;
> Mark Brown <broonie@...nel.org>; Frieder Schrempf
> <frieder.schrempf@...eet.de>; Yogesh Gaur <yogeshnarayan.gaur@....com>;
> linux-mtd@...ts.infradead.org; linux-kernel@...r.kernel.org
> Subject: Re: [PATCH v1 1/1] mtd: devices: add ACPI support for non-jedec
> m25p80
>
> On Tue, 2019-02-26 at 11:48 +0100, Flavio Suligoi wrote:
> > For the x86 machines a m25p80-compatible device have to be declared
> using
> > an ACPI table (which can be directly a part of the BIOS ACPI tables).
> >
> > In this case it is necessary to add the device in the "of_device_id"
> structure
> > list, to permit the device name matching by the ACPI kernel functions.
> >
> > This is an example of a SSDT table for the Everspin mr25h40:
> >
> > DefinitionBlock ("mr25h40.aml", "SSDT", 5, "ASEMsp", "MR25H40", 1)
> > {
> > External (_SB.SPI1, DeviceObj)
> >
> > Scope (\_SB.SPI1)
> > {
> > Device (NVR0)
> > {
> > Name (_HID, "PRP0001")
> > Name (_DDN, "Everspin MR25H40 MRAM")
> > Name (_CRS, ResourceTemplate () {
> > SpiSerialBus (
> > 1, // Chip select
> > PolarityLow, // Chip select is active
> low
> > FourWireMode, // Full duplex
> > 8, // Bits per word is 8
> (byte)
> > ControllerInitiated, // Don't care
> > 10000000, // 10 MHz
> > ClockPolarityLow, // SPI mode 0
> ClockPolarityLow
> > ClockPhaseFirst, // SPI mode 0
> ClockPhaseFirst
> > "\\_SB.SPI1", // SPI host controller
> > 0, // Must be 0
> > ResourceConsumer,
> > ,
> > )
> > })
> >
> > Name (_DSD, Package () {
> > ToUUID("daffd814-6eba-4d8c-8a91-bc9bbf4aa301"),
> > Package () {
> > Package () {"compatible", "mr25h40"},
> > }
> > })
> > }
> > }
> > }
> >
> > Signed-off-by: Flavio Suligoi <f.suligoi@...m.it>
>
> Why use the specific chip name in the "compatible" property? Why isn't
> it using "jedec,spi-nor"?
>
> Does this still actually get passed through to spi_nor_scan()... and is
> it *necessary*? Can't the chips be probed?
>
Hi David,
exactly, the mr25h40 is not Jedec compatible, so it can't be probed,
so it is necessary to identify it explicitly.
Flavio
Powered by blists - more mailing lists