meshcube patch for au1000 network driver
hi
i fixed the ioctl support in the net driver to support link detection by
ifplugd ond maybe netplugd(not tested)
here my patch fordrivers/net/au1000.c
bjoern riemer
9,11c9
< * Bjoern Riemer 2004 < * [email protected] or [email protected] < * // fixed the link beat detection with ioctls (SIOCGMIIPHY)
---
Quoted 1 line
*
120c118
< "au1000eth.c:1.5 [email protected]\n";
---
Quoted 1 line
"au1000eth.c:1.4 [email protected]\n";
1388,1391d1385
< /*riemer: fix for startup without cable */
< if (!link)
< dev->flags &= ~IFF_RUNNING;
<1448d1441
<
1846,1856c1839
< /*
< // This structure is used in all SIOCxMIIxxx ioctl calls < struct mii_ioctl_data {
< 0 u16 phy_id; < 1 u16 reg_num; < 2 u16 val_in; < 3 u16 val_out;
< };*/
< u16 *data = (u16 *)&rq->ifr_data;
< struct au1000_private *aup = (struct au1000_private *) dev->priv;
< //struct mii_ioctl_data *data = (struct mii_ioctl_data *) & rq->ifr_data;
---
Quoted 1 line
//u16 *data = (u16 *)&rq->ifr_data;
1859d1841
<
1862,1865c1844
< case SIOCGMIIPHY:
< if (!netif_running(dev))
< return -EINVAL;
< data[0] = aup->phy_addr;
---
Quoted 1 line
//data[0] = PHY_ADDRESS;
1867,1870c1846,1847
< case SIOCGMIIREG:
< data[3] = mdio_read(dev, data[0], data[1]);
< //data->val_out = mdio_read(dev,data->phy_id,data->reg_num);
< return 0;
---
Quoted 2 lines
//data[3] = mdio_read(ioaddr, data[0], data[1]); return 0;
1872,1876c1849,1850
< case SIOCSMIIREG:
< if (!capable(CAP_NET_ADMIN))
< return -EPERM;
< mdio_write(dev, data[0], data[1],data[2]);
< return 0;
---
Quoted 2 lines
//mdio_write(ioaddr, data[0], data[1], data[2]); return 0;
1878c1852
< return -EOPNOTSUPP;
---
Quoted 1 line
return -EOPNOTSUPP;
Quoted 5 lines · Bjoern Riemer
hi
i fixed the ioctl support in the net driver to support link detection by
ifplugd ond maybe netplugd(not tested)
here my patch fordrivers/net/au1000.c
Please never ever send ed-style patches, only unified (-u). They're totally unreadable and have several technical problems. And preferbly inline, not attachment.
Ralf
Quoted 9 lines · Ralf Baechle
Quoted 4 lines · Bjoern Riemer
i fixed the ioctl support in the net driver to support link detection by
ifplugd ond maybe netplugd(not tested)
here my patch fordrivers/net/au1000.cPlease never ever send ed-style patches, only unified (-u). They're totally unreadable and have several technical problems. And preferbly inline, not attachment.
And `-p' helps as wel...
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- [email protected]
In personal conversations with technical people, I call myself a hacker. But when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
Quoted 7 lines · Geert Uytterhoeven
Quoted 6 lines · Ralf Baechle
Quoted 4 lines · Bjoern Riemer
i fixed the ioctl support in the net driver to support link detection by
ifplugd ond maybe netplugd(not tested)
here my patch fordrivers/net/au1000.c
Quoted 5 lines
Quoted 3 lines
Please never ever send ed-style patches, only unified (-u). They're totally unreadable and have several technical problems. And preferbly inline, not attachment.
And `-p' helps as wel...
True, it makes patches more readable but there seems to be some trouble with -p and cvs diff and I certaily don't consider the non-use any kind of reason for rejecting a patch.
Ralf