spi: cadence_qspi: Add support for Versal NET platform
[platform/kernel/u-boot.git] / drivers / spi / mscc_bb_spi.c
index c3c7b80..2a01ea0 100644 (file)
@@ -8,11 +8,12 @@
 #include <common.h>
 #include <dm.h>
 #include <errno.h>
+#include <log.h>
 #include <malloc.h>
 #include <spi.h>
-#include <dm.h>
 #include <asm/gpio.h>
 #include <asm/io.h>
+#include <linux/bitops.h>
 #include <linux/delay.h>
 
 struct mscc_bb_priv {
@@ -116,7 +117,7 @@ int mscc_bb_spi_xfer(struct udevice *dev, unsigned int bitlen,
                     const void *dout, void *din, unsigned long flags)
 {
        struct udevice *bus = dev_get_parent(dev);
-       struct dm_spi_slave_platdata *plat = dev_get_parent_platdata(dev);
+       struct dm_spi_slave_plat *plat = dev_get_parent_plat(dev);
        struct mscc_bb_priv *priv = dev_get_priv(bus);
        u32             i, count;
        const u8        *txd = dout;
@@ -231,6 +232,6 @@ U_BOOT_DRIVER(mscc_bb) = {
        .id     = UCLASS_SPI,
        .of_match = mscc_bb_ids,
        .ops    = &mscc_bb_ops,
-       .priv_auto_alloc_size = sizeof(struct mscc_bb_priv),
+       .priv_auto      = sizeof(struct mscc_bb_priv),
        .probe  = mscc_bb_spi_probe,
 };