drivers: flash: spi_nor: fix 4byte opcodes

the check for both bit should be in the first DWORD.

Signed-off-by: Fin Maaß <f.maass@vogl-electronic.com>
This commit is contained in:
Fin Maaß 2024-11-26 16:47:19 +01:00 committed by Benjamin Cabé
parent a7756f20d1
commit ba18d41804

View file

@ -1330,7 +1330,7 @@ static int spi_nor_process_sfdp(const struct device *dev)
}
if (!((sys_le32_to_cpu(u2.dw[0]) & BIT(0)) &&
(sys_le32_to_cpu(u2.dw[1]) & BIT(6)))) {
(sys_le32_to_cpu(u2.dw[0]) & BIT(6)))) {
LOG_ERR("4-byte addressing not supported");
return -ENOTSUP;
}