blob: 59e7234dde9fde98d5ff1229d2edbd2dc12df7c3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
|
From 78704bc154d695ee16fdf8396f4d60b740190014 Mon Sep 17 00:00:00 2001
Message-Id: <78704bc154d695ee16fdf8396f4d60b740190014.1650924333.git.stefan@agner.ch>
From: Stefan Agner <stefan@agner.ch>
Date: Thu, 14 Apr 2022 12:15:26 +0200
Subject: [PATCH 1/5] drivers: bcm283x: don't explicitly disable init
It seems that the reason why init doesn't succeed is the lack of clock
support in U-Boot. Setting the default clock of 48MHz for the PL011
UARTs makes reinitialization work consistently.
Note that for the first UART the "skip-init" is anyways set in the
device tree. This will only affect probing of UARTs not enabled by
firmware.
Signed-off-by: Stefan Agner <stefan@agner.ch>
---
drivers/serial/serial_bcm283x_pl011.c | 6 ------
include/configs/rpi.h | 3 +++
2 files changed, 3 insertions(+), 6 deletions(-)
diff --git a/drivers/serial/serial_bcm283x_pl011.c b/drivers/serial/serial_bcm283x_pl011.c
index 2d2e970316..182274036c 100644
--- a/drivers/serial/serial_bcm283x_pl011.c
+++ b/drivers/serial/serial_bcm283x_pl011.c
@@ -51,12 +51,6 @@ static int bcm283x_pl011_serial_probe(struct udevice *dev)
if (ret)
return ret;
- /*
- * TODO: Reinitialization doesn't always work for now, just skip
- * init always - we know we're already initialized
- */
- plat->skip_init = true;
-
return pl01x_serial_probe(dev);
}
diff --git a/include/configs/rpi.h b/include/configs/rpi.h
index e24c94c7d2..98ba4dc052 100644
--- a/include/configs/rpi.h
+++ b/include/configs/rpi.h
@@ -40,6 +40,9 @@
#define CONFIG_SYS_BOOTM_LEN SZ_64M
#endif
+/* Define PL011 default clock */
+#define CONFIG_PL011_CLOCK 48000000
+
/* Devices */
/* GPIO */
#define CONFIG_BCM2835_GPIO
--
2.36.0
|