summaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/spi/spi.c')
-rw-r--r--drivers/spi/spi.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c
index f460a7a690..eebf64c980 100644
--- a/drivers/spi/spi.c
+++ b/drivers/spi/spi.c
@@ -112,17 +112,17 @@ void spi_of_register_slaves(struct spi_master *master, struct device_node *node)
chip.name = xstrdup(n->name);
chip.bus_num = master->bus_num;
/* Mode (clock phase/polarity/etc.) */
- if (of_find_property(n, "spi-cpha"))
+ if (of_find_property(n, "spi-cpha", NULL))
chip.mode |= SPI_CPHA;
- if (of_find_property(n, "spi-cpol"))
+ if (of_find_property(n, "spi-cpol", NULL))
chip.mode |= SPI_CPOL;
- if (of_find_property(n, "spi-cs-high"))
+ if (of_find_property(n, "spi-cs-high", NULL))
chip.mode |= SPI_CS_HIGH;
- if (of_find_property(n, "spi-3wire"))
+ if (of_find_property(n, "spi-3wire", NULL))
chip.mode |= SPI_3WIRE;
of_property_read_u32(n, "spi-max-frequency",
&chip.max_speed_hz);
- reg = of_find_property(n, "reg");
+ reg = of_find_property(n, "reg", NULL);
if (!reg)
continue;
chip.chip_select = of_read_number(reg->value, 1);