| To: | Mitchell Blank Jr <mitch@xxxxxxxxxx> |
|---|---|
| Subject: | Re: [RFC] add rtnl semaphore to linux-atm |
| From: | "David S. Miller" <davem@xxxxxxxxxx> |
| Date: | Fri, 3 Oct 2003 22:16:40 -0700 |
| Cc: | chas3@xxxxxxxxxxxxxxxxxxxxx, chas@xxxxxxxxxxxxxxxx, netdev@xxxxxxxxxxx |
| In-reply-to: | <20031003214541.GA73152@xxxxxxxxxxxxxx> |
| References: | <200310011134.h91BYPkT003172@xxxxxxxxxxxxxxxxxxxxxxx> <20031001054226.126cea7b.davem@xxxxxxxxxx> <20031003022615.GA42593@xxxxxxxxxxxxxx> <20031003065824.713627c6.davem@xxxxxxxxxx> <20031003214541.GA73152@xxxxxxxxxxxxxx> |
| Sender: | netdev-bounce@xxxxxxxxxxx |
On Fri, 3 Oct 2003 14:45:41 -0700 Mitchell Blank Jr <mitch@xxxxxxxxxx> wrote: > We *can't* use it to protect the state of the vcc list though because we > need to do lookups in both interrupt and bh context. Using a sleeping > lock alone is a non-starter. > > That's why we need to do the three-step spinlock->semaphore->spinlock > dance in the vcc open and close paths. The semaphore protects "modifications", it basically serializes them. You still need a rwlock to protect the actual lists and this rwlock is what the interrupt/bh context code takes to traverse the lists and tables. This is how the netdev list works, for example. |
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | [PATCH] janitor: remove verify_area() in net/wan/sbni, Randy.Dunlap |
|---|---|
| Next by Date: | Re: [RFC] add rtnl semaphore to linux-atm, Mitchell Blank Jr |
| Previous by Thread: | Re: [RFC] add rtnl semaphore to linux-atm, Mitchell Blank Jr |
| Next by Thread: | Re: [RFC] add rtnl semaphore to linux-atm, Mitchell Blank Jr |
| Indexes: | [Date] [Thread] [Top] [All Lists] |