summaryrefslogtreecommitdiffstats
path: root/src/southbridge/intel/bd82x6x/usb_ehci.c
diff options
context:
space:
mode:
authorElyes Haouas <ehaouas@noos.fr>2022-12-04 09:09:49 +0100
committerFelix Held <felix-coreboot@felixheld.de>2022-12-06 19:51:17 +0000
commitaf776d8b660d6fbffd3bda1178e5f43457a4b5b0 (patch)
tree01002038174af337e6a4d95709550e2e1aa4cf79 /src/southbridge/intel/bd82x6x/usb_ehci.c
parent067642d939bd083dd1aa314dd3c4982530e290c5 (diff)
downloadcoreboot-af776d8b660d6fbffd3bda1178e5f43457a4b5b0.tar.gz
coreboot-af776d8b660d6fbffd3bda1178e5f43457a4b5b0.tar.bz2
coreboot-af776d8b660d6fbffd3bda1178e5f43457a4b5b0.zip
sb/intel/bd82x6x: Use {read,write}32p
While on it, sort includes. Change-Id: Iacc858fbad89b54b1f5891c18cd3043b3963d53f Signed-off-by: Elyes Haouas <ehaouas@noos.fr> Reviewed-on: https://review.coreboot.org/c/coreboot/+/70292 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Diffstat (limited to 'src/southbridge/intel/bd82x6x/usb_ehci.c')
-rw-r--r--src/southbridge/intel/bd82x6x/usb_ehci.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/src/southbridge/intel/bd82x6x/usb_ehci.c b/src/southbridge/intel/bd82x6x/usb_ehci.c
index 3661aba4f2c5..1cb260ae7398 100644
--- a/src/southbridge/intel/bd82x6x/usb_ehci.c
+++ b/src/southbridge/intel/bd82x6x/usb_ehci.c
@@ -2,12 +2,13 @@
#include <console/console.h>
#include <device/device.h>
-#include <device/pci.h>
-#include <device/pci_ids.h>
-#include "pch.h"
-#include <device/pci_ehci.h>
#include <device/mmio.h>
+#include <device/pci_ehci.h>
+#include <device/pci_ids.h>
#include <device/pci_ops.h>
+#include <device/pci.h>
+
+#include "pch.h"
static void usb_ehci_init(struct device *dev)
{
@@ -46,8 +47,8 @@ static void usb_ehci_init(struct device *dev)
res = probe_resource(dev, PCI_BASE_ADDRESS_0);
if (res) {
/* Number of ports and companion controllers. */
- reg32 = read32((void *)(uintptr_t)(res->base + 4));
- write32((void *)(uintptr_t)(res->base + 4),
+ reg32 = read32p((uintptr_t)(res->base + 4));
+ write32p((uintptr_t)(res->base + 4),
(reg32 & 0xfff00000) | 3);
}