diff options
author | aiju <devnull@localhost> | 2011-04-24 17:23:17 +0200 |
---|---|---|
committer | aiju <devnull@localhost> | 2011-04-24 17:23:17 +0200 |
commit | b267359b69cb5b04f500a145e3c9c2bab813274e (patch) | |
tree | 0e578b9284e61cd50726de67144b1daba5d6164c /sys | |
parent | abf197c3237a1274018fdb26baa3f11c303bc258 (diff) |
fixed interrupt problem with BCM driver on multicore machines
Diffstat (limited to 'sys')
-rw-r--r-- | sys/src/9/pc/etherbcm.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/src/9/pc/etherbcm.c b/sys/src/9/pc/etherbcm.c index 67d7c2a4a..48963c247 100644 --- a/sys/src/9/pc/etherbcm.c +++ b/sys/src/9/pc/etherbcm.c @@ -22,7 +22,7 @@ typedef struct Ctlr Ctlr; struct Ctlr { - Lock txlock; + Lock txlock, imlock; Ctlr *link; Pcidev *pdev; ulong *nic, *status; @@ -404,6 +404,7 @@ bcminterrupt(Ureg*, void *arg) edev = arg; ctlr = edev->ctlr; + ilock(&ctlr->imlock); dummyread(csr32(ctlr, InterruptMailbox)); csr32(ctlr, InterruptMailbox) = 1; status = ctlr->status[0]; @@ -416,6 +417,7 @@ bcminterrupt(Ureg*, void *arg) bcmtransclean(edev); bcmtransmit(edev); csr32(ctlr, InterruptMailbox) = tag << 24; + iunlock(&ctlr->imlock); } static void @@ -664,5 +666,5 @@ bcmpnp(Ether* edev) void etherbcmlink(void) { - addethercard("BCM57xx", bcmpnp); + addethercard("BCM5755", bcmpnp); } |