diff options
author | Michal Simek <michal.simek@xilinx.com> | 2018-05-16 10:56:43 +0200 |
---|---|---|
committer | Michal Simek <michal.simek@xilinx.com> | 2018-05-31 13:50:39 +0200 |
commit | ce69030eb9d600173d6ce801c3158f685721fe79 (patch) | |
tree | 02ba3e8d63434a68fd4ce39596713bd117bb7b73 /drivers/serial/serial_zynq.c | |
parent | 2882b39d564bfa531d86aa22900658285483107d (diff) | |
download | u-boot-ce69030eb9d600173d6ce801c3158f685721fe79.zip u-boot-ce69030eb9d600173d6ce801c3158f685721fe79.tar.gz u-boot-ce69030eb9d600173d6ce801c3158f685721fe79.tar.bz2 |
serial: zynq: Use live-tree functions
Use live-tree functions.
Signed-off-by: Michal Simek <michal.simek@xilinx.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers/serial/serial_zynq.c')
-rw-r--r-- | drivers/serial/serial_zynq.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/serial/serial_zynq.c b/drivers/serial/serial_zynq.c index 06f0a48..3650af2 100644 --- a/drivers/serial/serial_zynq.c +++ b/drivers/serial/serial_zynq.c @@ -175,7 +175,9 @@ static int zynq_serial_ofdata_to_platdata(struct udevice *dev) { struct zynq_uart_priv *priv = dev_get_priv(dev); - priv->regs = (struct uart_zynq *)devfdt_get_addr(dev); + priv->regs = (struct uart_zynq *)dev_read_addr(dev); + if (IS_ERR(priv->regs)) + return PTR_ERR(priv->regs); return 0; } |