Re: [syzbot] BUG: unable to handle kernel access to user memory in sock_ioctl

2021-03-18 Thread Ben Dooks
On 18/03/2021 15:18, Dmitry Vyukov wrote: On Mon, Mar 15, 2021 at 3:41 PM Ben Dooks wrote: On 15/03/2021 11:52, Dmitry Vyukov wrote: On Mon, Mar 15, 2021 at 12:30 PM Ben Dooks wrote: On 14/03/2021 11:03, Dmitry Vyukov wrote: On Sun, Mar 14, 2021 at 11:01 AM Dmitry Vyukov wrote: On Wed

Re: [syzbot] BUG: unable to handle kernel access to user memory in sock_ioctl

2021-03-15 Thread Ben Dooks
On 15/03/2021 11:52, Dmitry Vyukov wrote: On Mon, Mar 15, 2021 at 12:30 PM Ben Dooks wrote: On 14/03/2021 11:03, Dmitry Vyukov wrote: On Sun, Mar 14, 2021 at 11:01 AM Dmitry Vyukov wrote: On Wed, Mar 10, 2021 at 7:28 PM syzbot wrote: Hello, syzbot found the following issue on: HEAD

Re: [syzbot] BUG: unable to handle kernel access to user memory in sock_ioctl

2021-03-15 Thread Ben Dooks
re-install the machine to get development work done on it. -- Ben Dooks http://www.codethink.co.uk/ Senior Engineer Codethink - Providing Genius https://www.codethink.co.uk/privacy.html

Re: [PATCH 0/6] ks8851 fixes & cleanups

2019-03-20 Thread Ben Dooks
for a few weeks to raise the confidence, even though we've tested them extensively on our Revolution Pi open source PLCs. I have done a visual review, but have not had the hardware to do any testing on this in a long time. -- Ben Dooks http://www.codethin

[PATCH] net: fixup address-space warnings in compat_mc_{get,set}sockopt()

2019-03-01 Thread Ben Dooks
-by: Ben Dooks --- net/compat.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/net/compat.c b/net/compat.c index 3d348198004f..8c8c57d814af 100644 --- a/net/compat.c +++ b/net/compat.c @@ -589,7 +589,7 @@ int compat_mc_setsockopt(struct sock *sock, int level, int

[PATCH] net: cdc_ncm: use tasklet_init() for tasklet_struct init

2018-10-11 Thread Ben Dooks
The tasklet initialisation would be better done by tasklet_init() instead of assuming all the fields are in an ok state by default. This does not fix any actual know bug. Signed-off-by: Ben Dooks --- drivers/net/usb/cdc_ncm.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git

Re: net: stmmac: Meson GXBB: attempting to execute userspace memory

2016-11-26 Thread Ben Dooks
On 2016-11-26 07:53, Heinrich Schuchardt wrote: For Odroid C2 I have compiled kernel 4.9.0-rc6-next-20161124-1-gbf7e142 with one additional patch https://github.com/xypron/kernel-odroid-c2/blob/master/patch/0001-stmmac-RTL8211F-Meson-GXBB-TX-throughput-problems.patch I repeatedly see fault

[PATCH] [V3] net: ipconfig: avoid warning by making ic_addrservaddr static

2016-06-10 Thread Ben Dooks
The symbol ic_addrservaddr is not static, but has no declaration to match so make it static to fix the following warning: net/ipv4/ipconfig.c:130:8: warning: symbol 'ic_addrservaddr' was not declared. Should it be static? Signed-off-by: Ben Dooks --- V3: fix the title from V

Re: [PATCH] [V2] net: ipconfig: add declaration for ic_addrservaddr

2016-06-10 Thread Ben Dooks
On 09/06/16 21:35, David Miller wrote: > From: Ben Dooks > Date: Thu, 9 Jun 2016 18:54:37 +0100 > >> The symbol ic_addrservaddr is not static, but has no declaration >> to match so make it static to fix the following warning: >> >> net/ipv4/ipconfig.c:130:8:

[PATCH] [V2] net: ipconfig: add declaration for ic_addrservaddr

2016-06-09 Thread Ben Dooks
The symbol ic_addrservaddr is not static, but has no declaration to match so make it static to fix the following warning: net/ipv4/ipconfig.c:130:8: warning: symbol 'ic_addrservaddr' was not declared. Should it be static? Signed-off-by: Ben Dooks --- V2: make ic_addrservaddr static

[PATCH] [V2] net: diag: add missing declarations

2016-06-09 Thread Ben Dooks
tatic? net/ipv4/inet_diag.c:108:5: warning: symbol 'inet_diag_msg_attrs_fill' was not declared. Should it be static? Signed-off-by: Ben Dooks --- V2: remove duplicates from net/sctp/sctp_diag.c --- Cc: "David S. Miller" Cc: netdev@vger.kernel.org Cc: linux-ker...@vger

Re: [PATCH] net: diag: add missing declarations

2016-06-09 Thread Ben Dooks
On 09/06/16 15:10, Eric Dumazet wrote: > On Thu, 2016-06-09 at 12:17 +0100, Ben Dooks wrote: >> The functions inet_diag_msg_common_fill and inet_diag_msg_attrs_fill >> seem to have been missed from the include/linux/inet_diag.h header >> file. Add them to fix the following war

Re: [PATCH] net: dsa: mv88e6xxx: make unexported functions static

2016-06-09 Thread Ben Dooks
es in net-next fixing a few checkpatch.pl issue. If > you don't mind I can rebase your fix and integrate the missing static. Ah, didn't check net-next. You are welcome to rebase. -- Ben Dooks http://www.codethink.co.uk/ Senior Engineer Codethink - Providing Genius

Re: [PATCH] net: ipconfgi: add declaration for ic_addrservaddr

2016-06-09 Thread Ben Dooks
On 09/06/16 12:35, Daniel Borkmann wrote: > On 06/09/2016 01:07 PM, Ben Dooks wrote: >> The symbol ic_addrservaddr is not static, but has no declaration >> to match. Since the similar variables are all exported, add this >> one to the header file as well. >> >>

[PATCH] net: diag: add missing declarations

2016-06-09 Thread Ben Dooks
tatic? net/ipv4/inet_diag.c:108:5: warning: symbol 'inet_diag_msg_attrs_fill' was not declared. Should it be static? Signed-off-by: Ben Dooks --- Cc: "David S. Miller" Cc: netdev@vger.kernel.org Cc: linux-ker...@vger.kernel.org --- include/linux/inet_diag.h | 6 ++

[PATCH] net: ipconfgi: add declaration for ic_addrservaddr

2016-06-09 Thread Ben Dooks
be static? Signed-off-by: Ben Dooks --- Cc: "David S. Miller" Cc: Alexey Kuznetsov Cc: James Morris Cc: Hideaki YOSHIFUJI Cc: Patrick McHardy Cc: netdev@vger.kernel.org --- include/net/ipconfig.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/net/ipconfig.h b/include/

[PATCH] net: dsa: mv88e6xxx: make unexported functions static

2016-06-09 Thread Ben Dooks
static? drivers/net/dsa/mv88e6xxx.c:3583:26: warning: symbol 'mv88e6xxx_switch_driver' was not declared. Should it be static? drivers/net/dsa/mv88e6xxx.c:3621:5: warning: symbol 'mv88e6xxx_probe' was not declared. Should it be static? Signed-off-by: Ben Dooks --- Cc: Vivien Di

[PATCH] stmmac: fix parameter to dwmac4_set_umac_addr()

2016-06-08 Thread Ben Dooks
: Ben Dooks --- Cc: Giuseppe Cavallaro Cc: Alexandre Torgue Cc: netdev@vger.kernel.org --- drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ethernet/stmicro/stmmac/dwmac4_core.c b/drivers/net/ethernet/stmicro/stmmac

[PATCH] net-sysfs: fix missing

2016-06-07 Thread Ben Dooks
The of_find_net_device_by_node() function is defined in but not included in the .c file that implements it. Fix the following warning by including the header: net/core/net-sysfs.c:1494:19: warning: symbol 'of_find_net_device_by_node' was not declared. Should it be static? Signed-o

Re: [git patches] net driver updates

2008-02-12 Thread Ben Dooks
> Please pull from 'upstream-davem' branch of > master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6.git > upstream-davem > > Ben Dooks (24): > DM9000: Fix endian-ness of data accesses. > DM9000: Add platform data to specify external phy

Re: [PATCH 07/24 for-2.6.25] DM9000: Add initial ethtool support

2008-02-06 Thread Ben Dooks
On Wed, Feb 06, 2008 at 10:52:54PM +0100, Francois Romieu wrote: > Ben Dooks <[EMAIL PROTECTED]> : > [...] > > The next patch in the series changes the locking. > > Do you mean patch #08 ? Sorry, looked at the wrong patch, it is #11 which changes the locking for a

Re: [PATCH 07/24 for-2.6.25] DM9000: Add initial ethtool support

2008-02-06 Thread Ben Dooks
On Tue, Feb 05, 2008 at 11:50:45PM +0100, Francois Romieu wrote: > Ben Dooks <[EMAIL PROTECTED]> : > > Add support for ethtool operations for the DM9000. > > > > Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> > > > > In

Re: [PATCH 00/24 for-2.6.25] DM9000 updates for 2.6.25

2008-02-04 Thread Ben Dooks
On Mon, Feb 04, 2008 at 04:19:40PM -0800, Andrew Morton wrote: > On Tue, 05 Feb 2008 00:01:59 + > Ben Dooks <[EMAIL PROTECTED]> wrote: > > > Subject: [PATCH 00/24 for-2.6.25] DM9000 updates for 2.6.25 > > Holy cow. > > > This patch set is a series of u

Re: [PATCH 02/24 for-2.6.25] DM9000: Add platform data to specify external phy

2008-02-04 Thread Ben Dooks
This should have been: Patch from: Laurent Pinchart <[EMAIL PROTECTED]> This patch adds a flag to the DM9000 platform data which, when set, configures the device to use an external PHY. Signed-off-by: Laurent Pinchart <[EMAIL PROTECTED]> Signed-off-by: Ben Dooks <[EMAIL PROTE

Re: [PATCH 01/24 for-2.6.25] DM9000: Fix endian-ness of data accesses.

2008-02-04 Thread Ben Dooks
On Tue, Feb 05, 2008 at 12:02:00AM +, Ben Dooks wrote: This should have been: Patch From: Laurent Pinchart <[EMAIL PROTECTED]> This patch splits the receive status in 8bit wide fields and convert the packet length from little endian to CPU byte order. Signed-off-by: Laurent Pinchart &

[PATCH 10/24 for-2.6.25] DM9000: Remove barely used SROM array read.

2008-02-04 Thread Ben Dooks
dm9000_read_eeprom to bring it into line with the rest of the driver. No change is made to the delay in this function, which will be dealt with in a later patch. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm

[PATCH 24/24 for-2.6.25] DM9000: Show the MAC address source after printing MAC

2008-02-04 Thread Ben Dooks
Show whether the MAC address was read from the EEPROM or the onboard PAR registers. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm9000.c === --- linux-2.6.24-quilt3.orig/drivers/net/dm

[PATCH 18/24 for-2.6.25] DM9000: Fix delays used by EEPROM read and write

2008-02-04 Thread Ben Dooks
The code was using a delay of 8ms, when it should have been using the EEPROM status flag from the device to indicate the EEPROM transaction had finished. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm

[PATCH 02/24 for-2.6.25] DM9000: Add platform data to specify external phy Patch from: Laurent Pinchart

2008-02-04 Thread Ben Dooks
This patch adds a flag to the DM9000 platform data which, when set, configures the device to use an external PHY. Signed-off-by: Laurent Pinchart <[EMAIL PROTECTED]> Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-git5-dm9k/drivers/

[PATCH 20/24 for-2.6.25] DM9000: Remove redudant use of "& 0xff"

2008-02-04 Thread Ben Dooks
The writing of the data should implicitly truncate the data to 8bits, so do not bother with the ands in the code. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm9000.c === --- linux-

[PATCH 19/24 for-2.6.25] DM9000: Remove cal_CRC() and use ether_crc_le instead

2008-02-04 Thread Ben Dooks
Remove the cal_CRC as this is basically wrappering the ether_crc_le function, and is only being used by the multicast hash table functions. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm

[PATCH 06/24 for-2.6.25] DM9000: Remove old timer based poll routines

2008-02-04 Thread Ben Dooks
changing this patch, which is early in the sequence has quite a knock-on effect. Once this series is merged, then a new presentation of an patch to poll the MII link status can be added. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt2/drivers/net/dm

[PATCH 07/24 for-2.6.25] DM9000: Add initial ethtool support

2008-02-04 Thread Ben Dooks
Add support for ethtool operations for the DM9000. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm9000.c === --- linux-2.6.24-quilt3.orig/drivers/net/dm9000.c +++ linux-2.6.24-quilt3/d

[PATCH 23/24 for-2.6.25] DM9000: Update retry count whilst identifying chip

2008-02-04 Thread Ben Dooks
-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm9000.c === --- linux-2.6.24-quilt3.orig/drivers/net/dm9000.c +++ linux-2.6.24-quilt3/drivers/net/dm9000.c @@ -643,7 +643,7 @@ dm9000_probe(

[PATCH 08/24 for-2.6.25] DM9000: Do not sleep with spinlock and IRQs held

2008-02-04 Thread Ben Dooks
g and then restore the state before the delay and then repeat the process once the delay has happened. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm9000.c === --- linux-2.6.24-quilt3.o

[PATCH 05/24 for-2.6.25] DM9000: Pass IRQ flags via platform resources

2008-02-04 Thread Ben Dooks
IRQT_ flags not sharing the same definition, at least notes these are the same. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> CC: Daniel Mack <[EMAIL PROTECTED]> CC: Bryan Wu <[EMAIL PROTECTED]> CC: Alex Landau <[EMAIL PROTECTED]> Index: linux-2.6.24-qui

[PATCH 11/24 for-2.6.25] DM9000: Add mutex to protect access

2008-02-04 Thread Ben Dooks
Add a mutex to serialise access to the chip functions from entries such as the ethtool and the MII code. This should reduce the amount of time the spinlock is held to protect the address register. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm

[PATCH 09/24 for-2.6.25] DM9000: Use msleep() instead of udelay()

2008-02-04 Thread Ben Dooks
We can use sleeping functions when reading and writing the PHY registers, so let us sleep instead of busy waiting for the PHY. Note, this also fixes a bug reading the PHY where only 100uS was being used instead of 150uS Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-

[PATCH 17/24 for-2.6.25] DM9000: Use netif_msg to enable debugging options

2008-02-04 Thread Ben Dooks
Use the netif_msg_*() macros to enable the debugging based on the board's msg_enable field. The output still goes via the dev_dbg() macros, so will be tagged and output as appropriate. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/n

[PATCH 22/24 for-2.6.25] DM9000: Add support for MII ioctl() calls

2008-02-04 Thread Ben Dooks
Add entry to handle the MII ioctl() calls via the generic_mii_ioctl call. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm9000.c === --- linux-2.6.24-quilt3.orig/drivers/net/dm9000.c +++

[PATCH 04/24 for-2.6.25] DM9000 update debugging macros to use debug level

2008-02-04 Thread Ben Dooks
Change the debug macros to use the compiler to elide any unnecessary debug level, and to allow device configurable debug control. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-git5-dm9k/drivers/net/K

[PATCH 21/24 for-2.6.25] DM9000: Add platform flag for no attached EEPROM

2008-02-04 Thread Ben Dooks
Allow the platform data to specify to the DM9000 driver that there is no posibility of an attached EEPROM on the device, so default all reads to 0xff and ignore any write operations. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm

[PATCH 00/24 for-2.6.25] DM9000 updates for 2.6.25

2008-02-04 Thread Ben Dooks
This patch set is a series of updates for the DM9000 driver, to tidy-up some of the source, stop the accesses to the PHY and EEPROM sitting and spinning with locks held, and to add ethtool support. This set includes a pair of patches from Laurent Pinchart for addition platform-data based configura

[PATCH 13/24 for-2.6.25] DM9000: Add ethtool control of msg_enable value

2008-02-04 Thread Ben Dooks
Allow the msg_enable value to be read and written by the ethtool interface. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm9000.c === --- linux-2.6.24-quilt3.orig/drivers/net/dm9000.c +++

[PATCH 16/24 for-2.6.25] DM9000: Remove unnecessary changelog in header comment

2008-02-04 Thread Ben Dooks
We have a perfectly good version control system, so we do not need to duplicate change comments in the header for this code. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm9000.c === ---

[PATCH 12/24 for-2.6.25] DM9000: Add ethtool support for reading and writing EEPROM

2008-02-04 Thread Ben Dooks
Add ethtool support to access the configuration EEPROM connected to the DM9000. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm9000.c === --- linux-2.6.24-quilt3.orig/drivers/net/dm

[PATCH 15/24 for-2.6.25] DM9000: Ensure spinlock held whilst accessing EEPROM registers

2008-02-04 Thread Ben Dooks
Ensure we hold the spinlock whilst the registers and being modified even though we hold the overall lock. This should protect against an interrupt happening whilst we are using the device. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm

[PATCH 01/24 for-2.6.25] DM9000: Fix endian-ness of data accesses. Patch from: Laurent Pinchart

2008-02-04 Thread Ben Dooks
This patch splits the receive status in 8bit wide fields and convert the packet length from little endian to CPU byte order. Signed-off-by: Laurent Pinchart <[EMAIL PROTECTED]> Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-git5-dm9k/drivers/

[PATCH 14/24 for-2.6.25] DM9000: Remove EEPROM initialisation code.

2008-02-04 Thread Ben Dooks
Remove the old hack to program an initial EEPROM setting into the DM9000 as we now have ethtool support for reading and writing the EEPROM. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt3/drivers/net/dm

[PATCH 03/24 for-2.6.25] DM9000 use dev_xxx() instead of printk for output.

2008-02-04 Thread Ben Dooks
Move to using dev_dbg() and friends for the output of information to the user. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-git5-dm9k/drivers/net/dm9000.c === --- linux-2.6.24-git5-dm9k.orig/drivers/net/dm

NET: AX88796 use dev_dbg() instead of printk()

2008-01-31 Thread Ben Dooks
Change to using dev_dbg() and the other dev_xxx() macros instead of printk, and update to use the print_mac() helper. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.24-quilt1/drivers/net/ax88796.c === --- linux-

Re: [PATCH] dm9000 - fix spinlock issue, updated

2007-12-22 Thread Ben Dooks
has > to be called with db->lock held > > Signed-off-by: dmitry pervushin <[EMAIL PROTECTED]> Acked-by: Ben Dooks <[EMAIL PROTECTED]> > Index: linux/drivers/net/dm9000.c > === > --- linux.orig/drivers/

Re: DM9000_IRQ_FLAGS

2007-12-20 Thread Ben Dooks
On Wed, Dec 12, 2007 at 02:41:53PM +0100, Daniel Mack wrote: > Hi Remy, > > On Tue, Dec 11, 2007 at 09:31:03PM +0100, Remy Bohmer wrote: > > This controller is also used on many other boards, like the e.g. Atmel > > AT91sam9261-ek board. On that board on both the rising _and_ falling > > edge an i

Re: DM9000_IRQ_FLAGS

2007-12-20 Thread Ben Dooks
On Tue, Dec 11, 2007 at 08:18:23PM +0100, Daniel Mack wrote: > Hi, > > on Toradex' Colibri, a PXA270 based board with a DM9000 ethernet > controller, this driver won't work due to unsuitable DM9000_IRQ_FLAGS. > If I understood the code behind request_irq() correctly, it's not > recommended to regi

Re: [patch 06/22] NET: DM9000: Use kthread to probe MII status when device open

2007-12-07 Thread Ben Dooks
On Fri, Nov 23, 2007 at 08:38:51PM -0500, Jeff Garzik wrote: > seems like a delayed workqueue would be most appropriate for this. I like the fact that the use of kthread shows the user how much cpu time is being used by the execution of monitoring the phy. How badly do people object to using a kth

Re: [patch 22/22] NET: DM9000: Show the MAC address source after printing MAC

2007-12-07 Thread Ben Dooks
On Fri, Nov 23, 2007 at 08:43:04PM -0500, Jeff Garzik wrote: > ACK patches 16-22 Is reposting here ok to get these queued for the next kernel release, or are there people to CC: for this? -- Ben ([EMAIL PROTECTED], http://www.fluff.org/) 'a smiley only costs 4 bytes' -- To unsubscribe from th

Re: [patch 07/22] NET: DM9000: Use msleep() instead of udelay()

2007-12-07 Thread Ben Dooks
On Fri, Nov 23, 2007 at 08:39:45PM -0500, Jeff Garzik wrote: > are you sure you cannot sleep during suspend? Yes. This is not the first driver that has had this problem, see the sm501 as another example. -- Ben ([EMAIL PROTECTED], http://www.fluff.org/) 'a smiley only costs 4 bytes' -- To uns

Re: [patch 00/22] DM9000 updates for 2.6.25

2007-11-20 Thread Ben Dooks
On Mon, Nov 19, 2007 at 08:39:10PM +, Ben Dooks wrote: > This is my current proposed patch series to the DM9000 > driver for both general cleanups, support for ethtool > and to make the code better. Apologies, it seems that when I updated it to 2.6.24-rc3 it turns out I applied i

Re: [PATCH] dm9000: fix spinlock issue and introduce platform_init callback

2007-11-20 Thread Ben Dooks
On Tue, Nov 20, 2007 at 05:59:49PM +0300, dmitry pervushin wrote: > > On ???, 2007-11-20 at 14:51 +0000, Ben Dooks wrote: > > On Tue, Nov 20, 2007 at 05:43:42PM +0300, dmitry pervushin wrote: > > > Hey all, > > > > > > The patch below is intended to fix

Re: [PATCH] dm9000: fix spinlock issue and introduce platform_init callback

2007-11-20 Thread Ben Dooks
On Tue, Nov 20, 2007 at 05:43:42PM +0300, dmitry pervushin wrote: > Hey all, > > The patch below is intended to fix two problems: > - trying to acquire spinlock twice on timeout condition I'll have a look into this, although I think we may be better of not dropping the spinlock and simply moving

Re: [patch 00/22] DM9000 updates for 2.6.25

2007-11-20 Thread Ben Dooks
On Mon, Nov 19, 2007 at 03:04:31PM -0800, Stephen Hemminger wrote: > On Mon, 19 Nov 2007 20:39:10 + > Ben Dooks <[EMAIL PROTECTED]> wrote: > > > This is my current proposed patch series to the DM9000 > > driver for both general cleanups, support for ethtool >

Re: [patch 06/22] NET: DM9000: Use kthread to probe MII status when device open

2007-11-20 Thread Ben Dooks
On Tue, Nov 20, 2007 at 07:46:27AM +, Christoph Hellwig wrote: > > +static void dm9000_start_thread(struct net_device *dev) > > +{ > > + board_info_t *db = (board_info_t *) dev->priv; > > + > > + /* Create a thread to keep track of the state of the phy > > +* as we do not get an interru

[patch 12/22] NET: DM9000: Remove EEPROM initialisation code.

2007-11-19 Thread Ben Dooks
Remove the old hack to program an initial EEPROM setting into the DM9000 as we now have ethtool support for reading and writing the EEPROM. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm

[patch 07/22] NET: DM9000: Use msleep() instead of udelay()

2007-11-19 Thread Ben Dooks
We can use sleeping functions when reading and writing the PHY registers, so let us sleep instead of busy waiting for the PHY. Note, this also fixes a bug reading the PHY where only 100uS was being used instead of 150uS Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-

[patch 14/22] NET: DM9000: Remove unnecessary changelog in header comment

2007-11-19 Thread Ben Dooks
We have a perfectly good version control system, so we do not need to duplicate change comments in the header for this code. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt2/drivers/net/dm9000.c === ---

[patch 01/22] NET: DM9000 use dev_xxx() instead of printk for output.

2007-11-19 Thread Ben Dooks
Move to using dev_dbg() and friends for the output of information to the user. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.22-quilt4/drivers/net/dm9000.c === --- linux-2.6.22-quilt4.orig/drivers/net/dm

[patch 10/22] NET: DM9000: Add ethtool support for reading and writing EEPROM

2007-11-19 Thread Ben Dooks
Add ethtool support to access the configuration EEPROM connected to the DM9000. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm9000.c === --- linux-2.6.23-quilt3.orig/drivers/net/dm

[patch 03/22] NET: DM9000: Pass IRQ flags via platform data

2007-11-19 Thread Ben Dooks
Use the platform data to pass modifications to the flags passed to request_irq() to alter the behaviour of the IRQ. This can be used to specify IRQ type for the platform the DM9000 is connected to. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.22-quilt6/drivers/net/dm

[patch 16/22] NET: DM9000: Fix delays used by EEPROM read and write

2007-11-19 Thread Ben Dooks
The code was using a delay of 8ms, when it should have been using the EEPROM status flag from the device to indicate the EEPROM transaction had finished. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm

[patch 02/22] NET: DM9000 update debugging macros to use debug level

2007-11-19 Thread Ben Dooks
Change the debug macros to use the compiler to elide any unnecessary debug level, and to allow device configurable debug control. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt1/drivers/net/K

[patch 08/22] NET: DM9000: Remove barely used SROM array read.

2007-11-19 Thread Ben Dooks
dm9000_read_eeprom to bring it into line with the rest of the driver. No change is made to the delay in this function, which will be dealt with in a later patch. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt5/drivers/net/dm

[patch 15/22] NET: DM9000: Use netif_msg to enable debugging options

2007-11-19 Thread Ben Dooks
Use the netif_msg_*() macros to enable the debugging based on the board's msg_enable field. The output still goes via the dev_dbg() macros, so will be tagged and output as appropriate. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt4/drivers/n

[patch 05/22] NET: DM9000: Do not sleep with spinlock and IRQs held

2007-11-19 Thread Ben Dooks
g and then restore the state before the delay and then repeat the process once the delay has happened. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm9000.c === --- linux-2.6.23-quilt3.o

[patch 00/22] DM9000 updates for 2.6.25

2007-11-19 Thread Ben Dooks
This is my current proposed patch series to the DM9000 driver for both general cleanups, support for ethtool and to make the code better. -- Ben ([EMAIL PROTECTED], http://www.fluff.org/) 'a smiley only costs 4 bytes' - To unsubscribe from this list: send the line "unsubscribe netdev" in the b

[patch 19/22] NET: DM9000: Add platform flag for no attached EEPROM

2007-11-19 Thread Ben Dooks
Allow the platform data to specify to the DM9000 driver that there is no posibility of an attached EEPROM on the device, so default all reads to 0xff and ignore any write operations. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm

[patch 13/22] NET: DM9000: Ensure spinlock held whilst accessing EEPROM registers

2007-11-19 Thread Ben Dooks
Ensure we hold the spinlock whilst the registers and being modified even though we hold the overall lock. This should protect against an interrupt happening whilst we are using the device. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm

[patch 20/22] NET: DM9000: Add support for MII ioctl() calls

2007-11-19 Thread Ben Dooks
Add entry to handle the MII ioctl() calls via the generic_mii_ioctl call. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm9000.c === --- linux-2.6.23-quilt3.orig/drivers/net/dm9000.c +++

[patch 09/22] NET: DM9000: Add mutex to protect access

2007-11-19 Thread Ben Dooks
Add a mutex to serialise access to the chip functions from entries such as the ethtool and the MII code. This should reduce the amount of time the spinlock is held to protect the address register. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm

[patch 06/22] NET: DM9000: Use kthread to probe MII status when device open

2007-11-19 Thread Ben Dooks
When the device is open, we have to probe the PHY's MII status periodically as there is no status change interrupt. As the phy code is going to change to using calls which might sleep we move to using a kthread instead of a timer. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: l

[patch 22/22] NET: DM9000: Show the MAC address source after printing MAC

2007-11-19 Thread Ben Dooks
Show whether the MAC address was read from the EEPROM or the onboard PAR registers. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt5/drivers/net/dm9000.c === --- linux-2.6.23-quilt5.orig/drivers/net/dm

[patch 18/22] NET: DM9000: Remove redudant use of "& 0xff"

2007-11-19 Thread Ben Dooks
The writing of the data should implicitly truncate the data to 8bits, so do not bother with the ands in the code. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm9000.c === --- linux-

[patch 11/22] NET: DM9000: Add ethtool control of msg_enable value

2007-11-19 Thread Ben Dooks
Allow the msg_enable value to be read and written by the ethtool interface. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm9000.c === --- linux-2.6.23-quilt3.orig/drivers/net/dm9000.c +++

[patch 04/22] NET: DM9000: Add initial ethtool support

2007-11-19 Thread Ben Dooks
Add support for ethtool operations for the DM9000. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm9000.c === --- linux-2.6.23-quilt3.orig/drivers/net/dm9000.c +++ linux-2.6.23-quilt3/d

[patch 21/22] NET: DM9000: Update retry count whilst identifying chip

2007-11-19 Thread Ben Dooks
-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm9000.c === --- linux-2.6.23-quilt3.orig/drivers/net/dm9000.c +++ linux-2.6.23-quilt3/drivers/net/dm9000.c @@ -652,7 +652,7 @@ dm9000_probe(

[patch 17/22] NET: DM9000: Remove cal_CRC() and use ether_crc_le instead

2007-11-19 Thread Ben Dooks
Remove the cal_CRC as this is basically wrappering the ether_crc_le function, and is only being used by the multicast hash table functions. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.23-quilt3/drivers/net/dm

Re: [BUG] New Kernel Bugs

2007-11-15 Thread Ben Dooks
On Tue, Nov 13, 2007 at 10:34:37PM +, Russell King wrote: > On Tue, Nov 13, 2007 at 06:25:16PM +, Alan Cox wrote: > > > Given the wide range of ARM platforms today, it is utterly idiotic to > > > expect a single person to be able to provide responses for all ARM bugs. > > > I for one wish I

Re: [RFC] dependencies for platform drivers (was Re: ax88796: add superh to kconfig dependencies)

2007-11-09 Thread Ben Dooks
On Thu, Nov 08, 2007 at 08:18:54AM +, Al Viro wrote: > On Thu, Nov 08, 2007 at 04:31:05PM +0900, Magnus Damm wrote: > > config AX88796 > > tristate "ASIX AX88796 NE2000 clone support" > > - depends on ARM || MIPS > > + depends on ARM || MIPS || SUPERH > > You know, that really sucks m

Re: [RFC] dependencies for platform drivers (was Re: ax88796: add superh to kconfig dependencies)

2007-11-09 Thread Ben Dooks
On Fri, Nov 09, 2007 at 06:40:23PM +0900, Paul Mundt wrote: > On Fri, Nov 09, 2007 at 09:26:52AM +, Ralf Baechle wrote: > > If writesb() is not an official API then maybe the answer should have been > > to either add that API to other architectures or fix the driver. > > > > I guess this incid

Re: [PATCH] DM9000: fix interface hang under load

2007-08-23 Thread Ben Dooks
t for after the 2.6.23 release. > Signed-off-by: Florian Westphal <[EMAIL PROTECTED]> Acked-by: Ben Dooks <[EMAIL PROTECTED]> > --- > Actually the comments ('Disable all interrupts, iow(db, DM9000_IMR, IMR_PAR) > etc) > give the impression that the interrupt

Re: [PATCH 2/2] [DM9000] External PHY support

2007-08-16 Thread Ben Dooks
On Thu, Aug 16, 2007 at 10:16:08AM +0200, Laurent Pinchart wrote: > This patch adds a flag to the DM9000 platform data which, when set, > configures the device to use an external PHY. > > Signed-off-by: Laurent Pinchart <[EMAIL PROTECTED]> Acked-by: Ben Dooks <[EMAIL PROTECT

Re: [PATCH 1/2] [DM9000] Added support for big-endian hosts

2007-08-16 Thread Ben Dooks
On Thu, Aug 16, 2007 at 10:15:35AM +0200, Laurent Pinchart wrote: > This patch splits the receive status in 8bit wide fields and convert the > packet length from little endian to CPU byte order. > > Signed-off-by: Laurent Pinchart <[EMAIL PROTECTED]> Acked-by: Ben Dooks

Re: [PATCH] [DM9000] Add support for big-endian hosts

2007-08-14 Thread Ben Dooks
On Tue, Aug 14, 2007 at 01:22:32PM +0200, Laurent Pinchart wrote: > This patch splits the receive status in 8bit wide fields and convert the > packet length from little endian to CPU byte order. Which version of the the kernel was this against, it applies with fuzz to 2.6.23-rc3: $ patch -p1 < ~/

Re: [PATCH] [DM9000] External PHY support

2007-08-14 Thread Ben Dooks
On Tue, Aug 14, 2007 at 01:29:35PM +0200, Laurent Pinchart wrote: > This patch adds a flag to the DM9000 platform data which, when set, > configures the device to use an external PHY. This patch applies with fuzz: $ patch -p1 < ~/dm9000-external-phy.patch patching file drivers/net/dm9000.c Hun

Re: Davicom Ethernet (onboard) with many Tx timeouts...

2007-08-14 Thread Ben Dooks
On Wed, Jan 03, 2007 at 10:33:08PM -0200, D?niel Fraga wrote: > Linux 2.6.19 (but this problem occurs with previous kernels too) > gcc 4.1.1 > pentium 3 > Module dmfe.ko > > dmfe: Davicom DM9xxx net driver, version 1.36.4 (2002-01-17) hmm, dmfe does not cover the dm9000, a little missleading? --

Re: dm9000: add set_mac_address()

2007-08-14 Thread Ben Dooks
On Sun, Aug 12, 2007 at 07:08:52PM -0400, Jeff Garzik wrote: > set_mac_address should not write to the SROM, as Michael noted. > > The proper operations are: > > probe time: > read MAC address from SROM > > dev open (interface up): > write dev->dev_addr[] to RX filter (or ide

ethtool locking

2007-07-11 Thread Ben Dooks
I am currently upgrading the DM9000 network driver to support ethtool for items such as controlling the MII interface and have the following question about locking with the ethtool interface: Most devices use an overall spinlock when changing the settings such as in the 8139too.c driver: static i

[PATCH] AX88796 network driver

2007-07-03 Thread Ben Dooks
Support for the Asix AX88796 network controller, an NE2000 compatible 10/100 ethernet device with internal PHY. The driver supports PHY settings via either ioctl() or the ethtool driver ops. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> Index: linux-2.6.21-quilt4/drivers/net/

Re: [info] What's in netdev-2.6.git?

2007-07-02 Thread Ben Dooks
On Mon, Jul 02, 2007 at 11:08:26AM -0400, Jeff Garzik wrote: > > This is what is currently queued for 2.6.23. There are a few patches > in my mbox not yet applied to the git tree, but this is most of them. I sent driver support for the AX88796 a few weeks ago with no feedback, should I re-send t

Feedback on AX88796 driver

2007-05-28 Thread Ben Dooks
I posted [1] an driver for the Asix AX88796 network controller a while back, and have had no feedback. Is this driver suitable for submission for the next kernel window, or is there anything that needs to be done for it? If it is, then is jgarzik the right person to send this patch to, or is there

[PATCH] ASIX AX88796 10/100 network driver

2007-05-11 Thread Ben Dooks
BAST and several Simtec development boards. Signed-off-by: Ben Dooks <[EMAIL PROTECTED]> diff -urNp linux-2.6.21-git14/drivers/net/8390.h linux-2.6.21-git14-ax88796/drivers/net/8390.h --- linux-2.6.21-git14/drivers/net/8390.h 2007-05-10 13:41:19.0 +0100 +++ linux-2.6.21

  1   2   >