diff options
author | mav <mav@FreeBSD.org> | 2017-07-24 06:49:57 +0000 |
---|---|---|
committer | mav <mav@FreeBSD.org> | 2017-07-24 06:49:57 +0000 |
commit | 98c1dd5ea292a2bd9dc96748a191f96a42d2be2a (patch) | |
tree | 578f1f432a1ed19b186e769165d9d905353fccd0 /sys/amd64 | |
parent | eaaa8cd970f11a0785780896a3e106958bd87fe7 (diff) | |
download | FreeBSD-src-98c1dd5ea292a2bd9dc96748a191f96a42d2be2a.zip FreeBSD-src-98c1dd5ea292a2bd9dc96748a191f96a42d2be2a.tar.gz |
MFC r302843:
Increase number of I/O APIC pins from 24 to 32 to give PCI up to 16 IRQs.
Move HPET to the top of the supported 0-31 range.
Diffstat (limited to 'sys/amd64')
-rw-r--r-- | sys/amd64/vmm/io/vhpet.c | 6 | ||||
-rw-r--r-- | sys/amd64/vmm/io/vioapic.c | 2 |
2 files changed, 5 insertions, 3 deletions
diff --git a/sys/amd64/vmm/io/vhpet.c b/sys/amd64/vmm/io/vhpet.c index f57f407..6d9b0fe 100644 --- a/sys/amd64/vmm/io/vhpet.c +++ b/sys/amd64/vmm/io/vhpet.c @@ -715,8 +715,10 @@ vhpet_init(struct vm *vm) vhpet->freq_sbt = bttosbt(bt); pincount = vioapic_pincount(vm); - if (pincount >= 24) - allowed_irqs = 0x00f00000; /* irqs 20, 21, 22 and 23 */ + if (pincount >= 32) + allowed_irqs = 0xff000000; /* irqs 24-31 */ + else if (pincount >= 20) + allowed_irqs = 0xf << (pincount - 4); /* 4 upper irqs */ else allowed_irqs = 0; diff --git a/sys/amd64/vmm/io/vioapic.c b/sys/amd64/vmm/io/vioapic.c index e6b8b5a..d112bbb 100644 --- a/sys/amd64/vmm/io/vioapic.c +++ b/sys/amd64/vmm/io/vioapic.c @@ -49,7 +49,7 @@ __FBSDID("$FreeBSD$"); #define IOREGSEL 0x00 #define IOWIN 0x10 -#define REDIR_ENTRIES 24 +#define REDIR_ENTRIES 32 #define RTBL_RO_BITS ((uint64_t)(IOART_REM_IRR | IOART_DELIVS)) struct vioapic { |