Commit 6e9d9fcb4cfc869dfad9d9207f44595e7ce17a95

Authored by Vipul Kumar
Committed by Jagan Teki
1 parent 83ce646943

spi: xilinx_spi: convert to livetree

Update the xilinx spi driver to support a live tree.

Signed-off-by: Vipul Kumar <vipul.kumar@xilinx.com>
Reviewed-by: Jagan Teki <jagan@openedev.com>

Showing 1 changed file with 2 additions and 3 deletions Side-by-side Diff

drivers/spi/xilinx_spi.c
... ... @@ -113,10 +113,9 @@
113 113 struct xilinx_spi_priv *priv = dev_get_priv(bus);
114 114 struct xilinx_spi_regs *regs = priv->regs;
115 115  
116   - priv->regs = (struct xilinx_spi_regs *)devfdt_get_addr(bus);
  116 + priv->regs = (struct xilinx_spi_regs *)dev_read_addr(bus);
117 117  
118   - priv->fifo_depth = fdtdec_get_int(gd->fdt_blob, dev_of_offset(bus),
119   - "fifo-size", 0);
  118 + priv->fifo_depth = dev_read_u32_default(bus, "fifo-size", 0);
120 119  
121 120 writel(SPISSR_RESET_VALUE, &regs->srr);
122 121