#include <linux/pm_runtime.h>
#include "internals.h"
#else
+#include <dm/device_compat.h>
#include <spi.h>
#include <spi-mem.h>
#endif
spi_check_buswidth_req(slave, op->dummy.buswidth, true))
return false;
- if (op->data.nbytes &&
+ if (op->data.dir != SPI_MEM_NO_DATA &&
spi_check_buswidth_req(slave, op->data.buswidth,
op->data.dir == SPI_MEM_DATA_OUT))
return false;