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  linux-cve-announce  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, 28 Feb 2007 14:18:01 -0800
From:	Stephen Hemminger <shemminger@...ux-foundation.org>
To:	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] bonding: replace system timer with work queue

On Wed, 28 Feb 2007 10:12:01 +0100 (CET)
Jaroslav Kysela <perex@...e.cz> wrote:

> Hi,
> 
> 	please, review and apply to mm tree for further testing. The patch 
> is also available at 
> ftp://ftp.alsa-project.org/pub/kernel-patches/bonding-workqueue.patch .
> 
> 					Thank you,
> 						Jaroslav
> 

You should submit network patches to the entry in the MAINTAINERS file.

BONDING DRIVER
P:	Chad Tindel
M:	ctindel@...rs.sourceforge.net
P:	Jay Vosburgh
M:	fubar@...ibm.com
L:	bonding-devel@...ts.sourceforge.net
W:	http://sourceforge.net/projects/bonding/
S:	Supported


> @@ -3569,20 +3552,20 @@ static int bond_close(struct net_device 
>  	 */
>  
>  	if (bond->params.miimon) {  /* link check interval, in milliseconds. */
> -		del_timer_sync(&bond->mii_timer);
> +		cancel_rearming_delayed_workqueue(bond_wq, &bond->mii_work);
>  	}
>  
>  	if (bond->params.arp_interval) {  /* arp interval, in milliseconds. */
> -		del_timer_sync(&bond->arp_timer);
> +		cancel_rearming_delayed_workqueue(bond_wq, &bond->arp_work);
>  	}
>  
>  	switch (bond->params.mode) {
>  	case BOND_MODE_8023AD:
> -		del_timer_sync(&(BOND_AD_INFO(bond).ad_timer));
> +		cancel_rearming_delayed_workqueue(bond_wq, &(BOND_AD_INFO(bond).ad_work));
>  		break;
>  	case BOND_MODE_TLB:
>  	case BOND_MODE_ALB:
> -		del_timer_sync(&(BOND_ALB_INFO(bond).alb_timer));
> +		cancel_rearming_delayed_workqueue(bond_wq, &(BOND_ALB_INFO(bond).alb_work));
>  		break;
>  	default:
>  		break;


This part will deadlock since it is not safe to cancel a workqueue
entry with RTNL mutex held. The cancel operation has to wait for the workqueue
to run, and the entry being run maybe stuck waiting for the RTNL.



-- 
Stephen Hemminger <shemminger@...ux-foundation.org>
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ