From 28984c8584d2c96a9beb2dcebef2985bc041ca7b Mon Sep 17 00:00:00 2001 From: Justus Winter <4winter@informatik.uni-hamburg.de> Date: Sat, 25 Jul 2015 01:55:22 +0200 Subject: device: use general lock for port lists * device/if_hdr.h (struct ifnet): Turn the port list locks into general locks. (port_list_{lock_init,lock,unlock): New macros. * device/net_io.c (net_filter, net_set_filter): Use new macros. * device/subrs.c (if_init_queues): Likewise. --- device/subrs.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'device/subrs.c') diff --git a/device/subrs.c b/device/subrs.c index a10b72d..cfaaecd 100644 --- a/device/subrs.c +++ b/device/subrs.c @@ -80,8 +80,8 @@ void if_init_queues(struct ifnet *ifp) IFQ_INIT(&ifp->if_snd); queue_init(&ifp->if_rcv_port_list); queue_init(&ifp->if_snd_port_list); - simple_lock_init(&ifp->if_rcv_port_list_lock); - simple_lock_init(&ifp->if_snd_port_list_lock); + port_list_lock_init(&ifp->if_rcv_port_list_lock); + port_list_lock_init(&ifp->if_snd_port_list_lock); } -- cgit v1.2.3