From cef1f0c7a41226cdefec41b01868f2b4702d487c Mon Sep 17 00:00:00 2001 From: Philippe Reynes Date: Fri, 22 Jun 2018 18:52:05 +0200 Subject: cpu: bmips: fix probe to get the address In the device tree, the address for cpu is located in the node "cpus", not in the cpu node (for exemple cpu@0). So when probing cpu, the cpu address must be read in the cpu parent. The commit "cpu: bmips: convert to use live dt" (sha1: c444afbbefa103d567f197393d39ec0fcca21a0c) change this behaviour and read the address in the cpu node when probing cpu. We fix this by reading the address in the cpu parent. Signed-off-by: Philippe Reynes --- drivers/cpu/bmips_cpu.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers') diff --git a/drivers/cpu/bmips_cpu.c b/drivers/cpu/bmips_cpu.c index f5bacd2b18..78560b0fb4 100644 --- a/drivers/cpu/bmips_cpu.c +++ b/drivers/cpu/bmips_cpu.c @@ -407,7 +407,7 @@ int bmips_cpu_probe(struct udevice *dev) const struct bmips_cpu_hw *hw = (const struct bmips_cpu_hw *)dev_get_driver_data(dev); - priv->regs = dev_remap_addr(dev); + priv->regs = dev_remap_addr(dev_get_parent(dev)); if (!priv->regs) return -EINVAL; -- cgit From c38abed5093a486d6349fc0d9d7a663f24965d78 Mon Sep 17 00:00:00 2001 From: Philippe Reynes Date: Thu, 28 Jun 2018 15:26:16 +0200 Subject: led: bcm6328: read base address in the parent node In the device tree, the address for the led is located in the parent node (for exemple leds), not in the led node (for exemple led@0). The commit "led: bcm6328: convert to use live dt" (sha1: 899455176058d673887a762aa38853188a030af4) change this behaviour and read the address in the led node. We fix this by reading the base address for led in the parent node. Signed-off-by: Philippe Reynes --- drivers/led/led_bcm6328.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers') diff --git a/drivers/led/led_bcm6328.c b/drivers/led/led_bcm6328.c index a29e5a02c0..7be4badbac 100644 --- a/drivers/led/led_bcm6328.c +++ b/drivers/led/led_bcm6328.c @@ -173,7 +173,7 @@ static int bcm6328_led_probe(struct udevice *dev) struct bcm6328_led_priv *priv = dev_get_priv(dev); unsigned int pin; - priv->regs = dev_remap_addr(dev); + priv->regs = dev_remap_addr(dev_get_parent(dev)); if (!priv->regs) return -EINVAL; -- cgit