diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2009-09-23 09:43:22 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-09-23 09:43:22 -0700 |
commit | ff830b8e5f999d1ccbd0282a666520f0b557daa4 (patch) | |
tree | 5979aba5ed48c93d658a208f3a1f714e9e1e8b67 /drivers/firewire/ohci.c | |
parent | 746942d06acdb4dd78d16baa5f3728a48a033bdd (diff) | |
parent | 625f0850a8e27b6a8d6fdb95056f35bc22d92b55 (diff) | |
download | linux-ff830b8e5f999d1ccbd0282a666520f0b557daa4.tar.gz linux-ff830b8e5f999d1ccbd0282a666520f0b557daa4.tar.bz2 linux-ff830b8e5f999d1ccbd0282a666520f0b557daa4.zip |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/ieee1394/linux1394-2.6:
ieee1394: sbp2: remove a workaround for Momobay FX-3A
firewire: sbp2: remove a workaround for Momobay FX-3A
firewire: sbp2: fix status reception
firewire: core: fix topology map response handler
firewire: core: fix race with parallel PCI device probe
firewire: core: header file cleanup
firewire: ohci: fix Self ID Count register mask (safeguard against buffer overflow)
ieee1394: raw1394: Do not leak memory on failed trylock.
Diffstat (limited to 'drivers/firewire/ohci.c')
-rw-r--r-- | drivers/firewire/ohci.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/firewire/ohci.c b/drivers/firewire/ohci.c index 76b321bb73f9..5d524254499e 100644 --- a/drivers/firewire/ohci.c +++ b/drivers/firewire/ohci.c @@ -1279,8 +1279,8 @@ static void bus_reset_tasklet(unsigned long data) * the inverted quadlets and a header quadlet, we shift one * bit extra to get the actual number of self IDs. */ - self_id_count = (reg >> 3) & 0x3ff; - if (self_id_count == 0) { + self_id_count = (reg >> 3) & 0xff; + if (self_id_count == 0 || self_id_count > 252) { fw_notify("inconsistent self IDs\n"); return; } |