skbuff query

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,
  As I was reading the source of
include/linux/skbuff.h, I came accross this function.
THe comparison on line 704 apparently is redundant. Am
I missing something basic? Please clarify.

696 static inline void skb_unlink(struct sk_buff *skb)
697 {
698         struct sk_buff_head *list = skb->list;
699 
700         if(list) {
701                 unsigned long flags;
702 
703                 spin_lock_irqsave(&list->lock,
flags);
704                 if(skb->list == list)
705                         __skb_unlink(skb,
skb->list);
706                
spin_unlock_irqrestore(&list->lock, flags);
707         }
708 }



=====
Regards,
Kiran Kumar Immidi

__________________________________
Do you Yahoo!?
Find out what made the Top Yahoo! Searches of 2003
http://search.yahoo.com/top2003

--
Kernelnewbies: Help each other learn about the Linux kernel.
Archive:       http://mail.nl.linux.org/kernelnewbies/
FAQ:           http://kernelnewbies.org/faq/


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux