1Notes on the (20000210) SMP-ization of the bridging code:
2
3Each bridge has a hash table of MAC addresses. This table is protected
4by a rwlock hash_lock. The entries are refcounted; 'getting' an entry
5is done in the usual way: read_lock the table, find the entry,
6increment it's refcount and unlock the table. Bottom half context
7acquires this lock in read as well as write mode, therefore we always
8need to locally disable BHs when acquiring this lock.
9
10Each bridge also has an rwlock called lock. This slightly misnamed
11lock protects the bridge's port_list. All stp code acquires this lock
12in read mode, the only piece of code that acquires this lock in write
13mode is the ioctl code (br_ioctl.c). Bottom halves never acquire this
14lock in write mode, therefore we can use read_lock instead of
15read_lock_bh in all cases.
16
17All ioctls are globally serialized by the semaphore ioctl_mutex. All
18code which acquires the bridge lock in write mode also acquires
19ioctl_mutex. Therefore, if we have already grabbed ioctl_mutex we
20don't need to read_lock the bridge lock anymore; the ioctl_mutex will
21protect against concurrent writers.
22