IXGB networl driver and locking

sivakumar.subramani at wipro.com sivakumar.subramani at wipro.com
Tue May 15 07:21:03 UTC 2007


Hi all,
 
Same lock is being used in ixgb_intr and ixgb_start. If we get Receive
interrupt while processing Xmit (ixgb_start), Will the calling of
ixgb_intr() handler be delayed as we will not be getting lock in
ixgb_intr since it is already locked in ixgb_start. If it is the case,
are we making it as Half duplex, I mean we are allowing either of one Tx
(or) Rx. Please clarify.
 
488 <http://fxr.watson.org/fxr/source/dev/ixgb/if_ixgb.c#L488>
ixgb_start <http://fxr.watson.org/fxr/ident?i=ixgb_start> (struct ifnet
<http://fxr.watson.org/fxr/ident?i=ifnet>  *ifp
<http://fxr.watson.org/fxr/ident?i=ifp> )
489 <http://fxr.watson.org/fxr/source/dev/ixgb/if_ixgb.c#L489>  {
490 <http://fxr.watson.org/fxr/source/dev/ixgb/if_ixgb.c#L490>
struct adapter <http://fxr.watson.org/fxr/ident?i=adapter>  *adapter
<http://fxr.watson.org/fxr/ident?i=adapter>  = ifp
<http://fxr.watson.org/fxr/ident?i=ifp> ->if_softc;
491 <http://fxr.watson.org/fxr/source/dev/ixgb/if_ixgb.c#L491>  
492 <http://fxr.watson.org/fxr/source/dev/ixgb/if_ixgb.c#L492>
IXGB_LOCK <http://fxr.watson.org/fxr/ident?i=IXGB_LOCK> (adapter
<http://fxr.watson.org/fxr/ident?i=adapter> );
493 <http://fxr.watson.org/fxr/source/dev/ixgb/if_ixgb.c#L493>
ixgb_start_locked <http://fxr.watson.org/fxr/ident?i=ixgb_start_locked>
(ifp <http://fxr.watson.org/fxr/ident?i=ifp> );
494 <http://fxr.watson.org/fxr/source/dev/ixgb/if_ixgb.c#L494>
IXGB_UNLOCK <http://fxr.watson.org/fxr/ident?i=IXGB_UNLOCK> (adapter
<http://fxr.watson.org/fxr/ident?i=adapter> );
495 <http://fxr.watson.org/fxr/source/dev/ixgb/if_ixgb.c#L495>
return;
496 <http://fxr.watson.org/fxr/source/dev/ixgb/if_ixgb.c#L496>  }

 
 
static void
795 <http://fxr.watson.org/fxr/source/dev/ixgb/if_ixgb.c#L795>
ixgb_intr <http://fxr.watson.org/fxr/ident?i=ixgb_intr> (void *arg
<http://fxr.watson.org/fxr/ident?i=arg> )
796 <http://fxr.watson.org/fxr/source/dev/ixgb/if_ixgb.c#L796>  {
.............
............
IXGB_LOCK <http://fxr.watson.org/fxr/ident?i=IXGB_LOCK> (adapter
<http://fxr.watson.org/fxr/ident?i=adapter> );
.....................
IXGB_UNLOCK <http://fxr.watson.org/fxr/ident?i=IXGB_UNLOCK> (adapter
<http://fxr.watson.org/fxr/ident?i=adapter> );

 
Thanks,
~Siva



The information contained in this electronic message and any attachments to this message are intended for the exclusive use of the addressee(s) and may contain proprietary, confidential or privileged information. If you are not the intended recipient, you should not disseminate, distribute or copy this e-mail. Please notify the sender immediately and destroy all copies of this message and any attachments. 

WARNING: Computer viruses can be transmitted via email. The recipient should check this email and any attachments for the presence of viruses. The company accepts no liability for any damage caused by any virus transmitted by this email.
 
www.wipro.com


More information about the freebsd-net mailing list