opnsense-src/sys/dev/xen
Colin Percival 93954c2da3 Check that blkfront devices have a non-zero number of sectors and a
non-zero sector size.  Such a device would be a virtual disk of zero
bytes; clearly not useful, and not something we should try to attach.

As a fortuitous side effect, checking that these values are non-zero
here results in them not *becoming* zero later on the function.  This
odd behaviour began with r309124 (clang 3.9.0) but is challenging to
debug; making any changes to this function whatsoever seems to affect
the llvm optimizer behaviour enough to make the unexpected zeroing of
the sector_size variable cease.

PR:		215209
Security:	The potential for variables to unexpectedly become zero
		has worrying consequences for security in general, but
		not so much in this particular context.
2016-12-13 06:54:13 +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 Check that blkfront devices have a non-zero number of sectors and a 2016-12-13 06:54:13 +00:00
console xen/console: Introduce a new console driver for Xen guest 2015-10-08 16:39:43 +00:00
control Add an EARLY_AP_STARTUP option to start APs earlier during boot. 2016-05-14 18:22:52 +00:00
debug xen: add a handler for the debug interrupt 2015-03-30 07:09:07 +00:00
evtchn Remove misc NULL checks after M_WAITOK allocations. 2016-05-10 10:26:07 +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 Add domain support to PCI bus allocation 2015-09-16 23:34:51 +00:00
privcmd xen/privcmd: fix integer truncation in IOCTL_PRIVCMD_MMAPBATCH 2016-05-06 16:44:46 +00:00
pvcpu xen: add missing files 2014-06-16 08:54:04 +00:00
timer xen/timer: re-introduce the inittodr call in the resume path 2016-06-09 16:15:01 +00:00
xenpci xen: Code cleanup and small bug fixes 2015-10-21 10:44:07 +00:00
xenstore sys/dev: minor spelling fixes. 2016-05-03 03:41:25 +00:00