[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-changelog] [xen-unstable] x86/HPET: fix oversight in 23033:84bacd800bf8
# HG changeset patch # User Jan Beulich <jbeulich@xxxxxxxxxx> # Date 1300183356 0 # Node ID 599ceb5b0a9b014cf609e4c9e54c54c51b3217e5 # Parent 9f6dec0d25cdef647b60286b99e8beb39b4d91cd x86/HPET: fix oversight in 23033:84bacd800bf8 Clearly for the adjusted BUG_ON()s to not yield false positives num_chs_used must be incremented before setting up an IRQ (and decremented back when the setup failed). Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx> --- diff -r 9f6dec0d25cd -r 599ceb5b0a9b xen/arch/x86/hpet.c --- a/xen/arch/x86/hpet.c Mon Mar 14 17:20:11 2011 +0000 +++ b/xen/arch/x86/hpet.c Tue Mar 15 10:02:36 2011 +0000 @@ -428,10 +428,8 @@ ch->flags = 0; ch->idx = i; - if ( (ch->irq = hpet_assign_irq(num_chs_used)) < 0 ) - continue; - - num_chs_used++; + if ( (ch->irq = hpet_assign_irq(num_chs_used++)) < 0 ) + num_chs_used--; } printk(XENLOG_INFO "HPET: %u timers (%u will be used for broadcast)\n", _______________________________________________ Xen-changelog mailing list Xen-changelog@xxxxxxxxxxxxxxxxxxx http://lists.xensource.com/xen-changelog
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |