datapath: Add get_vport_protected().
authorJesse Gross <jesse@nicira.com>
Sat, 25 Dec 2010 03:53:26 +0000 (19:53 -0800)
committerJesse Gross <jesse@nicira.com>
Wed, 29 Dec 2010 18:30:09 +0000 (10:30 -0800)
commit1452b28ca636521b6e16f76787524f83205ec7a3
tree5e3ee71204c05b27f0913c36c345312133171418
parent6f20002c1201c1fc78fc7cedb49b103d8afe9da6
datapath: Add get_vport_protected().

In some places we access the array of datapath ports without
RCU protection.  This introduces a new function to check that in
these case the dp mutex is held for protection.

Found with sparse.

Signed-off-by: Jesse Gross <jesse@nicira.com>
Acked-by: Ben Pfaff <blp@nicira.com>
datapath/datapath.c