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] [day] [month] [year] [list]
Message-ID: <20070129102503.GA30182@strauss.suse.de>
Date:	Mon, 29 Jan 2007 11:25:03 +0100
From:	Bernhard Walle <bwalle@...e.de>
To:	Francois Romieu <romieu@...zoreil.com>
Cc:	netdev@...r.kernel.org
Subject: Re: r8169: Crash after reloading driver if network hangs

Hello,

* Francois Romieu <romieu@...zoreil.com> [2007-01-29 08:56]:
> Bernhard Walle <bwalle@...e.de> :
> 
> > @@ -1371,10 +1371,9 @@ static inline void rtl8169_request_timer
> >                 return;
> >  
> >         init_timer(timer);
> > -       timer->expires = jiffies + RTL8169_PHY_TIMEOUT;
> >         timer->data = (unsigned long)(dev);
> >         timer->function = rtl8169_phy_timer;
> > -       add_timer(timer);
> > +       mod_timer(timer, jiffies + RTL8169_PHY_TIMEOUT);
> >  }
> > 
> > But I think _this_ change is unnecessary, ...
> 
> add_timer() is not supposed to modify an existing timer whereas mod_timer()
> encompasses both 

that's clear.

> and the race exists in both direction as netif_running()
> is true as soon as dev_open() starts but way before dev->open() completes.

But rtl8169_request_timer() is only called from change_mtu() and
dev->open(). And, if you call init_timer(), you always have a new
timer, and the reference to an existing tp->timer will be lost.

> [...]
> > ... but that looks good (better than my patch) and should resolve the issue,
> > too. I can't test because it's triggered only if the network hangs and you
> > know, the last one isn't reproducable.
> 
> There will be something to test in the merge of realtek's stuff #2.

Great.


Regards,
Bernhard
-- 
SUSE LINUX Products GmbH                E-Mail:  bwalle@...e.de
Maxfeldstr. 5                           Phone:   +49 (911) 74053-0
90409 Nürnberg, Germany
OpenPGP DDAF6454: F61F 34CC 09CA FB82 C9F6  BA4B 8865 3696 DDAF 6454
-
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

Powered by Openwall GNU/*/Linux Powered by OpenVZ