freebsd-dev/sys/dev/advansys
Steven Hartland 85c9dd9d89 Prevent overflow issues in timeout processing
Previously, any timeout value for which (timeout * hz) will overflow the
signed integer, will give weird results, since callout(9) routines will
convert negative values of ticks to '1'. For unsigned integer overflow we
will get sufficiently smaller timeout values than expected.

Switch from callout_reset, which requires conversion to int based ticks
to callout_reset_sbt to avoid this.

Also correct isci to correctly resolve ccb timeout.

This was based on the original work done by Eygene Ryabinkin
<rea@freebsd.org> back in 5 Aug 2011 which used a macro to help avoid
the overlow.

Differential Revision:	https://reviews.freebsd.org/D1157
Reviewed by:	mav, davide
MFC after:	1 month
Sponsored by:	Multiplay
2014-11-21 21:01:24 +00:00
..
adv_eisa.c Add locking to adv(4) driver and mark it MPSAFE. 2012-10-12 21:31:44 +00:00
adv_isa.c Add locking to adv(4) driver and mark it MPSAFE. 2012-10-12 21:31:44 +00:00
adv_pci.c Add locking to adv(4) driver and mark it MPSAFE. 2012-10-12 21:31:44 +00:00
advansys.c Prevent overflow issues in timeout processing 2014-11-21 21:01:24 +00:00
advansys.h Add locking to adv(4) driver and mark it MPSAFE. 2012-10-12 21:31:44 +00:00
advlib.c Remove instances of variables that were set, but never used. gcc 4.9 2014-03-30 23:43:36 +00:00
advlib.h Add locking to adv(4) driver and mark it MPSAFE. 2012-10-12 21:31:44 +00:00
advmcode.c
advmcode.h
adw_pci.c Update PCI drivers to no longer look at the MEMIO-enabled bit in the PCI 2013-08-12 23:30:01 +00:00
adwcam.c Prevent overflow issues in timeout processing 2014-11-21 21:01:24 +00:00
adwlib.c Add locking to the adw(4) driver and mark it MPSAFE. 2012-10-15 15:26:00 +00:00
adwlib.h Add locking to the adw(4) driver and mark it MPSAFE. 2012-10-15 15:26:00 +00:00
adwmcode.c
adwmcode.h
adwvar.h Add locking to the adw(4) driver and mark it MPSAFE. 2012-10-15 15:26:00 +00:00