Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1656444
| From | David Miller <davem@davemloft.net> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] net: davicom: dm9000: Avoid spinlock recursion during dm9000_timeout routine |
| Date | 2017-06-02 20:20 +0200 |
| Message-ID | <tNZkZ-4FP-1@gated-at.bofh.it> (permalink) |
| References | <tNdzH-6yx-1@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
From: Liu Xiang <liu.xiang6@zte.com.cn> Date: Wed, 31 May 2017 23:06:42 +0800 > On the DM9000B, dm9000_phy_write() is called after the main spinlock > is held, during the dm9000_timeout() routine. Spinlock recursion > occurs because the main spinlock is requested again in > dm9000_phy_write(). So spinlock should be avoided in dm9000_phy_write() > during the dm9000_timeout() routine. > > Signed-off-by: Liu Xiang <liu.xiang6@zte.com.cn> It think this is racy. Now, during a timeout device reset, another thread of control can come in and access phy registers without any synchronization whatsoever.
Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread
[PATCH] net: davicom: dm9000: Avoid spinlock recursion during dm9000_timeout routine Liu Xiang <liu.xiang6@zte.com.cn> - 2017-05-31 17:20 +0200 Re: [PATCH] net: davicom: dm9000: Avoid spinlock recursion during dm9000_timeout routine David Miller <davem@davemloft.net> - 2017-06-02 20:20 +0200
csiph-web