Re: [PATCH][ATM] make atm (and clip) modular + try_module_get()

chas williams (chas@locutus.cmf.nrl.navy.mil)
Wed, 05 Mar 2003 10:28:52 -0500


In message <20030305.065341.35361286.davem@redhat.com>,"David S. Miller" writes
:
>I understand why you think you have to lock, that isn't the issue.
>I'm telling you that you should be locking this crap at a much
>higher level.

ok, i see what you are saying now. since this is used to move the
stuff queued from the old connection to the new connection i suppose
clip might want something like?

spin_lock_bh(&vcc->recvq.lock)
skb_migrate(&vcc->recvq,&copy);
spin_unlock_bh(&vcc->recvq.lock);

that would block any more additions to the recvq (which should be
sk->receieve_queue i suspect -- more on that later) while the skb are
moved to copy. i am afraid i dont know much about how the clip driver
operates.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/