On 01/26/2023 07:15 AM, Jonas Gorski wrote: >> >> +static bool bcm63xx_hsspi_mem_supports_op(struct spi_mem *mem, >> + const struct spi_mem_op *op) >> +{ >> + if (!spi_mem_default_supports_op(mem, op)) >> + return false; >> + >> + /* Controller doesn't support spi mem dual/quad read cmd in prepend mode */ >> + if ((op->cmd.opcode == 0xbb) || (op->cmd.opcode == 0xeb)) > > There are defines in linux/mtd/spi-nor.h you can use: > > if ((op->cmd.opcode == SPINOR_OP_READ_1_2_2) || (op->cmd.opcode == > SPINOR_OP_READ_1_4_4)) > > Though SPINOR_OP_READ_1_4_4 seems to be redundant, since the > controller does not support quad mode, and does not advertise it, so > it should never even be an option. > > Looking at that file, instead what is missing is > SPINOR_OP_READ_1_2_2_4B (0xbc) which shouldn't be usable either. > You are right. I was only looking at the spi nand header which does not have this clear definition. Will use them and drop the quad IO opcode for the reason you mentioned.