From 7385e486874e307f4e08ae0fcbc04b0bedf78852 Mon Sep 17 00:00:00 2001 From: kettenis Date: Fri, 18 Jun 2021 12:12:22 +0000 Subject: [PATCH] Enable 32-bit I/O addressing. This gets rid of the io address conflict messages on the HiFive Unmatched. ok patrick@ --- sys/dev/fdt/dwpcie.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sys/dev/fdt/dwpcie.c b/sys/dev/fdt/dwpcie.c index 75daa9866c7..55647d2ca7b 100644 --- a/sys/dev/fdt/dwpcie.c +++ b/sys/dev/fdt/dwpcie.c @@ -1,4 +1,4 @@ -/* $OpenBSD: dwpcie.c,v 1.31 2021/06/14 20:54:04 kettenis Exp $ */ +/* $OpenBSD: dwpcie.c,v 1.32 2021/06/18 12:12:22 kettenis Exp $ */ /* * Copyright (c) 2018 Mark Kettenis * @@ -478,6 +478,10 @@ dwpcie_attach_deferred(struct device *self) HWRITE4(sc, PCI_MAPREG_START, PCI_MAPREG_MEM_TYPE_64BIT); HWRITE4(sc, PCI_MAPREG_START + 4, 0); + /* Enable 32-bit I/O addressing. */ + HSET4(sc, PPB_REG_IOSTATUS, + PPB_IO_32BIT | (PPB_IO_32BIT << PPB_IOLIMIT_SHIFT)); + /* Make sure read-only bits are write-protected. */ HCLR4(sc, MISC_CONTROL_1, MISC_CONTROL_1_DBI_RO_WR_EN); -- 2.20.1