About  04/17/2019 08:55AM in some timezone, Cédric Le Goater wrote:


>Here is a little series providing cleanups on the Aspeed SMC
>Controller
>driver and adding support for the 4B opcodes which were recently
>added
>to the Linux kernels 5.0.x.
>
>The use of the 4B opcodes was breaking the read of the golden buffer
>done at slow speed in the optimization read sequence. The code
>assumed
>that the chip was in 4B address mode, as if a EN4B opcode had been
>sent, but this is not the case anymore with 4B opcodes. The golden
>buffer is now read with a SPINOR_OP_READ_4B (0x13) when the chip
>supports 4B opcodes.
>
>It should fix accesses to the palmetto PNOR and the Witherspoon BMC
>flash modules.
>
>
>*Please test !*


Cedric,

did you notice that spi_nor_read_sfdp is now calling the nor->read method?

Since the read method is hard-coding the opcode, this means that we are
returning random flash contents instead of the flash parameter block, which
probably confuses the kernel.

milton