diff options
author | Felix Held <felix.held@amd.corp-partner.google.com> | 2021-10-12 23:35:48 +0200 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2021-10-15 14:46:58 +0000 |
commit | ad6f87d61202984e7604a35b6ce5babee614e676 (patch) | |
tree | a6ef329a6993c254c902bd8d76a46104365287a9 /src/soc/amd/cezanne | |
parent | cb70d836ed048b81ad8047e97c9758680cc2da2d (diff) |
soc/amd/cezanne,picasso/uart: implement read_resource
Implement the read_resources function for the UART devices so that the
resource allocator knows about their fixed MMIO resources when enabled.
TEST=UART still works on Mandolin.
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I4ffddee3f5f4281aca98ddfcefa639dfb7a38dae
Reviewed-on: https://review.coreboot.org/c/coreboot/+/58306
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Diffstat (limited to 'src/soc/amd/cezanne')
-rw-r--r-- | src/soc/amd/cezanne/uart.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/soc/amd/cezanne/uart.c b/src/soc/amd/cezanne/uart.c index e5f2e4edbb..cf535d7aec 100644 --- a/src/soc/amd/cezanne/uart.c +++ b/src/soc/amd/cezanne/uart.c @@ -85,8 +85,13 @@ static void uart_enable(struct device *dev) } } +static void uart_read_resources(struct device *dev) +{ + mmio_resource(dev, 0, dev->path.mmio.addr / KiB, 4); +} + struct device_operations cezanne_uart_mmio_ops = { - .read_resources = noop_read_resources, + .read_resources = uart_read_resources, .set_resources = noop_set_resources, .scan_bus = scan_static_bus, .enable = uart_enable, |