[NET]: Transform skb_queue_len() binary tests into skb_queue_empty()
This is part of the grand scheme to eliminate the qlen member of skb_queue_head, and subsequently remove the 'list' member of sk_buff. Most users of skb_queue_len() want to know if the queue is empty or not, and that's trivially done with skb_queue_empty() which doesn't use the skb_queue_head->qlen member and instead uses the queue list emptyness as the test. Signed-off-by: David S. Miller <davem@davemloft.net>
Этот коммит содержится в:
@@ -1223,7 +1223,7 @@ isdn_tty_write(struct tty_struct *tty, const u_char * buf, int count)
|
||||
total += c;
|
||||
}
|
||||
atomic_dec(&info->xmit_lock);
|
||||
if ((info->xmit_count) || (skb_queue_len(&info->xmit_queue))) {
|
||||
if ((info->xmit_count) || !skb_queue_empty(&info->xmit_queue)) {
|
||||
if (m->mdmreg[REG_DXMT] & BIT_DXMT) {
|
||||
isdn_tty_senddown(info);
|
||||
isdn_tty_tint(info);
|
||||
@@ -1284,7 +1284,7 @@ isdn_tty_flush_chars(struct tty_struct *tty)
|
||||
|
||||
if (isdn_tty_paranoia_check(info, tty->name, "isdn_tty_flush_chars"))
|
||||
return;
|
||||
if ((info->xmit_count) || (skb_queue_len(&info->xmit_queue)))
|
||||
if ((info->xmit_count) || !skb_queue_empty(&info->xmit_queue))
|
||||
isdn_timer_ctrl(ISDN_TIMER_MODEMXMIT, 1);
|
||||
}
|
||||
|
||||
|
Ссылка в новой задаче
Block a user