freebsd-nq/sys/dev/xen
Roger Pau Monné ca7af67ac9 xen: fix IPI setup with EARLY_AP_STARTUP
Current Xen IPI setup functions require that the caller provide a device in
order to obtain the name of the interrupt from it. With early AP startup this
device is no longer available at the point where IPIs are bound, and a KASSERT
would trigger:

panic: NULL pcpu device_t
cpuid = 0
KDB: stack backtrace:
db_trace_self_wrapper() at db_trace_self_wrapper+0x2b/frame 0xffffffff82233a20
vpanic() at vpanic+0x186/frame 0xffffffff82233aa0
kassert_panic() at kassert_panic+0x126/frame 0xffffffff82233b10
xen_setup_cpus() at xen_setup_cpus+0x5b/frame 0xffffffff82233b50
mi_startup() at mi_startup+0x118/frame 0xffffffff82233b70
btext() at btext+0x2c

Fix this by no longer requiring the presence of a device in order to bind IPIs,
and simply use the "cpuX" format where X is the CPU identifier in order to
describe the interrupt.

Reported by:            sbruno, cperciva
Tested by:              sbruno
X-MFC-With:             r310177
Sponsored by:           Citrix Systems R&D
2016-12-22 16:09:44 +00:00
..
balloon sys/dev: minor spelling fixes. 2016-05-03 03:41:25 +00:00
blkback xen-blkback: fix error path on failed attach 2016-06-03 11:39:35 +00:00
blkfront In xbd_connect(), use correct scanf conversion specifiers for the 2016-12-14 19:28:19 +00:00
console
control Add an EARLY_AP_STARTUP option to start APs earlier during boot. 2016-05-14 18:22:52 +00:00
debug
evtchn xen: fix IPI setup with EARLY_AP_STARTUP 2016-12-22 16:09:44 +00:00
gntdev xen: add a grant-table user-space device 2016-10-31 13:12:58 +00:00
grant_table sys/dev: extend use of the howmany() macro when available. 2016-04-26 15:03:15 +00:00
netback sys/dev: minor spelling fixes. 2016-05-03 03:41:25 +00:00
netfront xen/netfront: fix statistics 2016-10-31 11:31:11 +00:00
pci Associate device_t objects with ACPI handles via PCI_CHILD_ADDED(). 2016-04-07 17:15:16 +00:00
pcifront
privcmd xen/privcmd: fix integer truncation in IOCTL_PRIVCMD_MMAPBATCH 2016-05-06 16:44:46 +00:00
pvcpu
timer xen/timer: re-introduce the inittodr call in the resume path 2016-06-09 16:15:01 +00:00
xenpci
xenstore sys/dev: minor spelling fixes. 2016-05-03 03:41:25 +00:00