aboutsummaryrefslogtreecommitdiff
path: root/scripts/objdiff
diff options
context:
space:
mode:
authorClemens Ladisch <[email protected]>2010-10-26 14:22:13 -0700
committerLinus Torvalds <[email protected]>2010-10-26 16:52:11 -0700
commit96e9694df446d1154ec2f4fdba8908588b9cba38 (patch)
tree09f667548a5e6bb465bdaac45d35d69b2cff9a39 /scripts/objdiff
parenta56d5318716d120e040294bb258901ba89fb9c90 (diff)
hpet: fix unwanted interrupt due to stale irq status bit
Jaswinder Singh Rajput wrote: > By executing Documentation/timers/hpet_example.c > > for polling, I requested for 3 iterations but it seems iteration work > for only 2 as first expired time is always very small. > > # ./hpet_example poll /dev/hpet 10 3 > -hpet: executing poll > hpet_poll: info.hi_flags 0x0 > hpet_poll: expired time = 0x13 > hpet_poll: revents = 0x1 > hpet_poll: data 0x1 > hpet_poll: expired time = 0x1868c > hpet_poll: revents = 0x1 > hpet_poll: data 0x1 > hpet_poll: expired time = 0x18645 > hpet_poll: revents = 0x1 > hpet_poll: data 0x1 Clearing the HPET interrupt enable bit disables interrupt generation but does not disable the timer, so the interrupt status bit will still be set when the timer elapses. If another interrupt arrives before the timer has been correctly programmed (due to some other device on the same interrupt line, or CONFIG_DEBUG_SHIRQ), this results in an extra unwanted interrupt event because the status bit is likely to be set from comparator matches that happened before the device was opened. Therefore, we have to ensure that the interrupt status bit is and stays cleared until we actually program the timer. Signed-off-by: Clemens Ladisch <[email protected]> Reported-by: Jaswinder Singh Rajput <[email protected]> Cc: Ingo Molnar <[email protected]> Cc: Thomas Gleixner <[email protected]> Cc: john stultz <[email protected]> Cc: Bob Picco <[email protected]> Cc: <[email protected]> Signed-off-by: Andrew Morton <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
Diffstat (limited to 'scripts/objdiff')
0 files changed, 0 insertions, 0 deletions