lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 21 Nov 2007 15:09:52 +0800
From:	<wyb@...sec.com.cn>
To:	<netdev@...r.kernel.org>
Cc:	"'Herbert Xu'" <herbert@...dor.apana.org.au>
Subject: RE:RE: is it useful testing __LINK_STATE_RX_SCHED in dev_close()?


__LINK_STATE_RX_SCHED still exist in kernel 2.6.23.8.

Netdevice.h:

/* Test if receive needs to be scheduled */
static inline int __netif_rx_schedule_prep(struct net_device *dev)
{
	return !test_and_set_bit(__LINK_STATE_RX_SCHED, &dev->state);
}

/* Test if receive needs to be scheduled but only if up */
static inline int netif_rx_schedule_prep(struct net_device *dev)
{
	return netif_running(dev) && __netif_rx_schedule_prep(dev);
}

Dev.c:
int dev_close(struct net_device *dev)
{
	...
	while (test_bit(__LINK_STATE_RX_SCHED, &dev->state)) {
     	/* No hurry. */
         msleep(1);
    }
	...
}

Test_bit() in dev_close() maybe between the calling of netif_running() and
__netif_rx_schedule_prep() in netif_rx_schedule_prep.



-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists