]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Fix a couple of issues in the interrupt code:
authordes <des@FreeBSD.org>
Wed, 10 Dec 2003 22:11:51 +0000 (22:11 +0000)
committerdes <des@FreeBSD.org>
Wed, 10 Dec 2003 22:11:51 +0000 (22:11 +0000)
commitdcadbab0fa618972ac3aecd091e1026da968ce05
tree90524ace83ffa3f11de5c48ce2b76a2debdf0fc9
parent4c2b7999cfefb9ac291078e4e31d80190ec2f860
Fix a couple of issues in the interrupt code:

 - Replace overly-complicated (and buggy) -a logic with a much simpler
   version: -a causes all interrupts to be displayed, otherwise only
   those that have occurred are displayed.  This removes the need for
   any MD code.

 - Instead of just making sure intrcnt is large enough, figure out the
   exact size it needs to be.  We derive nintr from this number, and we
   don't want to risk printing garbage.  Note that on sparc64, we end up
   printing garbage anyway because the names of non-existent interrupts
   are left uninitialized by the kernel.

Tested on: alpha, i386, sparc64
usr.bin/vmstat/vmstat.c