From e704d0ebe7071478db75fd9ad787ba6fe93056c6 Mon Sep 17 00:00:00 2001 From: Peter Wemm Date: Thu, 7 Jun 2007 06:28:48 +0000 Subject: [PATCH] Calculate the correct PCI BAR for the Timedia based serial cards. The Linux equivalent gives BAR offsets relative to the implied base of 0x10. Our PUC_CFG_GET_RID functions have to add the base offset themselves. --- sys/dev/puc/pucdata.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/dev/puc/pucdata.c b/sys/dev/puc/pucdata.c index 17cdf80dd840..10cd6883ebfa 100644 --- a/sys/dev/puc/pucdata.c +++ b/sys/dev/puc/pucdata.c @@ -1110,7 +1110,7 @@ puc_config_timedia(struct puc_softc *sc, enum puc_cfg_cmd cmd, int port, *res = (port == 1 || port == 3) ? 8 : 0; return (0); case PUC_CFG_GET_RID: - *res = (port > 3) ? port - 2 : port >> 1; + *res = 0x10 + ((port > 3) ? port - 2 : port >> 1); return (0); case PUC_CFG_GET_TYPE: *res = PUC_TYPE_SERIAL;