14 May, 2014
1 commit
-
net: get rid of SET_ETHTOOL_OPS
Dave Miller mentioned he'd like to see SET_ETHTOOL_OPS gone.
This does that.Mostly done via coccinelle script:
@@
struct ethtool_ops *ops;
struct net_device *dev;
@@
- SET_ETHTOOL_OPS(dev, ops);
+ dev->ethtool_ops = ops;Compile tested only, but I'd seriously wonder if this broke anything.
Suggested-by: Dave Miller
Signed-off-by: Wilfried Klaebe
Acked-by: Felipe Balbi
Signed-off-by: David S. Miller
17 Jan, 2014
1 commit
-
None of these files are actually using any __init type directives
and hence don't need to include . Most are just a
left over from __devinit and __cpuinit removal, or simply due to
code getting copied from one driver to the next.This covers everything under drivers/net except for wireless, which
has been submitted separately.Signed-off-by: Paul Gortmaker
Signed-off-by: David S. Miller
07 Dec, 2013
1 commit
-
Several files refer to an old address for the Free Software Foundation
in the file header comment. Resolve by replacing the address with
the URL so that we do not have to keep
updating the header comments anytime the address changes.CC: Oliver Neukum
CC: Steve Glendinning
CC: Oliver Neukum
Signed-off-by: Jeff Kirsher
Signed-off-by: David S. Miller
12 Oct, 2012
1 commit
-
We nowdays copy the buffer and free fw->data, so make the debug printk use
the right thing.Signed-off-by: Alan Cox
Signed-off-by: David S. Miller
21 Sep, 2012
1 commit
-
The dbg() USB macro is so old, it predates me. The USB networking drivers are
the last hold-out using this macro, and we want to get rid of it, so replace
the usage of it with the proper netdev_dbg() or dev_dbg() (depending on the
context) calls.Some places we end up using a local variable for the debug call, so also
convert the other existing dev_* calls to use it as well, to save tiny amounts
of code space.Signed-off-by: Greg Kroah-Hartman
Signed-off-by: David S. Miller
28 Jul, 2012
1 commit
-
The problem is that we call this with a spin lock held. The call tree
is:
kaweth_start_xmit() holds kaweth->device_lock.
-> kaweth_async_set_rx_mode()
-> kaweth_control()
-> kaweth_internal_control_msg()The kaweth_internal_control_msg() function is only called from
kaweth_control() which used GFP_ATOMIC for its allocations.Signed-off-by: Dan Carpenter
Signed-off-by: David S. Miller
19 May, 2012
1 commit
-
Hub-initiated LPM is not good for USB communications devices. Comms
devices should be able to tell when their link can go into a lower power
state, because they know when an incoming transmission is finished.
Ideally, these devices would slam their links into a lower power state,
using the device-initiated LPM, after finishing the last packet of their
data transfer.If we enable the idle timeouts for the parent hubs to enable
hub-initiated LPM, we will get a lot of useless LPM packets on the bus
as the devices reject LPM transitions when they're in the middle of
receiving data. Worse, some devices might blindly accept the
hub-initiated LPM and power down their radios while they're in the
middle of receiving a transmission.The Intel Windows folks are disabling hub-initiated LPM for all USB
communications devices under a xHCI USB 3.0 host. In order to keep
the Linux behavior as close as possible to Windows, we need to do the
same in Linux.Set the disable_hub_initiated_lpm flag for for all USB communications
drivers. I know there aren't currently any USB 3.0 devices that
implement these class specifications, but we should be ready if they do.Signed-off-by: Sarah Sharp
Cc: Marcel Holtmann
Cc: Gustavo Padovan
Cc: Johan Hedberg
Cc: Hansjoerg Lipp
Cc: Tilman Schmidt
Cc: Karsten Keil
Cc: Peter Korsgaard
Cc: Jan Dumon
Cc: Petko Manolov
Cc: Steve Glendinning
Cc: "John W. Linville"
Cc: Kalle Valo
Cc: "Luis R. Rodriguez"
Cc: Jouni Malinen
Cc: Vasanthakumar Thiagarajan
Cc: Senthil Balasubramanian
Cc: Christian Lamparter
Cc: Brett Rudley
Cc: Roland Vossen
Cc: Arend van Spriel
Cc: "Franky (Zhenhui) Lin"
Cc: Kan Yan
Cc: Dan Williams
Cc: Jussi Kivilinna
Cc: Ivo van Doorn
Cc: Gertjan van Wingerde
Cc: Helmut Schaa
Cc: Herton Ronaldo Krzesinski
Cc: Hin-Tak Leung
Cc: Larry Finger
Cc: Chaoming Li
Cc: Daniel Drake
Cc: Ulrich Kunitz
Signed-off-by: Sarah Sharp
26 Apr, 2012
1 commit
-
err() was a very old USB-specific macro that I thought had
gone away. This patch removes it from being used in the
driver and uses dev_err() instead.Signed-off-by: Greg Kroah-Hartman
25 Feb, 2012
1 commit
-
Print MAC/dev_addr via printk extended format specifier %pM
instead of custom code.Signed-off-by: Danny Kukawka
Acked-by: Oliver Neukum
Signed-off-by: David S. Miller
19 Nov, 2011
1 commit
-
This converts the drivers in drivers/net/* to use the
module_usb_driver() macro which makes the code smaller and a bit
simpler.Added bonus is that it removes some unneeded kernel log messages about
drivers loading and/or unloading.Cc: Wolfgang Grandegger
Cc: Samuel Ortiz
Cc: Oliver Neukum
Cc: Peter Korsgaard
Cc: Petko Manolov
Cc: Steve Glendinning
Cc: Christian Lamparter
Cc: "John W. Linville"
Cc: Dan Williams
Cc: Jussi Kivilinna
Cc: Ivo van Doorn
Cc: Gertjan van Wingerde
Cc: Helmut Schaa
Cc: Herton Ronaldo Krzesinski
Cc: Hin-Tak Leung
Cc: Larry Finger
Cc: Chaoming Li
Cc: Lucas De Marchi
Cc: "David S. Miller"
Cc: Roel Kluin
Cc: Paul Gortmaker
Cc: Jiri Pirko
Cc: Pavel Roskin
Cc: Yoann DI-RUZZA
Cc: George
Signed-off-by: Greg Kroah-Hartman
18 Aug, 2011
1 commit
-
replace it by ndo_set_rx_mode
Signed-off-by: Jiri Pirko
Signed-off-by: David S. Miller
31 Mar, 2011
1 commit
-
Fixes generated by 'codespell' and manually reviewed.
Signed-off-by: Lucas De Marchi
25 Jan, 2011
1 commit
-
We will leak the storage allocated by request_firmware() if the size of
the firmware is greater than KAWETH_FIRMWARE_BUF_SIZE.
This removes the leak by calling release_firmware() before we return
-ENOSPC.Signed-off-by: Jesper Juhl
Signed-off-by: David S. Miller
17 Aug, 2010
1 commit
-
The driver name and bus address for a net_device can normally be found
through the driver model now. Instead of requiring drivers to provide
this information redundantly through the ethtool_ops::get_drvinfo
operation, use the driver model to do so if the driver does not define
the operation. Since ETHTOOL_GDRVINFO no longer requires the driver
to implement any operations, do not require net_device::ethtool_ops to
be set either.Remove implementations of get_drvinfo and ethtool_ops that provide
only this information.Signed-off-by: Ben Hutchings
Signed-off-by: David S. Miller
03 Jun, 2010
1 commit
-
cleanup patch.
Use new __packed annotation in drivers/net/
Signed-off-by: Eric Dumazet
Signed-off-by: David S. Miller
21 May, 2010
2 commits
-
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: (229 commits)
USB: remove unused usb_buffer_alloc and usb_buffer_free macros
usb: musb: update gfp/slab.h includes
USB: ftdi_sio: fix legacy SIO-device header
USB: kl5usb105: reimplement using generic framework
USB: kl5usb105: minor clean ups
USB: kl5usb105: fix memory leak
USB: io_ti: use kfifo to implement write buffering
USB: io_ti: remove unsused private counter
USB: ti_usb: use kfifo to implement write buffering
USB: ir-usb: fix incorrect write-buffer length
USB: aircable: fix incorrect write-buffer length
USB: safe_serial: straighten out read processing
USB: safe_serial: reimplement read using generic framework
USB: safe_serial: reimplement write using generic framework
usb-storage: always print quirks
USB: usb-storage: trivial debug improvements
USB: oti6858: use port write fifo
USB: oti6858: use kfifo to implement write buffering
USB: cypress_m8: use kfifo to implement write buffering
USB: cypress_m8: remove unused drain define
...Fix up conflicts (due to usb_buffer_alloc/free renaming) in
drivers/input/tablet/acecad.c
drivers/input/tablet/kbtab.c
drivers/input/tablet/wacom_sys.c
drivers/media/video/gspca/gspca.c
sound/usb/usbaudio.c -
For more clearance what the functions actually do,
usb_buffer_alloc() is renamed to usb_alloc_coherent()
usb_buffer_free() is renamed to usb_free_coherent()They should only be used in code which really needs DMA coherency.
All call sites have been changed accordingly, except for staging
drivers.Signed-off-by: Daniel Mack
Cc: Alan Stern
Cc: Pedro Ribeiro
Signed-off-by: Greg Kroah-Hartman
10 May, 2010
1 commit
-
Now that core network takes care of trans_start updates, dont do it
in drivers themselves, if possible. Drivers can avoid one cache miss
(on dev->trans_start) in their start_xmit() handler.Exceptions are NETIF_F_LLTX drivers
Signed-off-by: Eric Dumazet
Signed-off-by: David S. Miller
28 Apr, 2010
1 commit
-
akpm: reluctantly typed in from
https://bugzilla.kernel.org/show_bug.cgi?id=15599Signed-off-by: Andrew Morton
Signed-off-by: David S. Miller
13 Feb, 2010
1 commit
-
This patch replaces dev->mc_count in all drivers (hopefully I didn't miss
anything). Used spatch and did small tweaks and conding style changes when
it was suitable.Jirka
Signed-off-by: Jiri Pirko
Signed-off-by: David S. Miller
12 Dec, 2009
1 commit
-
This patch removes a rare use of the USB power management API which
won't be supported after the conversion to the new generic runtime power
management framework. Functionality is not altered.Signed-off-by: Oliver Neukum
Signed-off-by: David S. Miller
30 Oct, 2009
1 commit
-
For USB 3.0 it is necessary that all drivers use the standard
API to reset a configuration. This removes a home-grown
implementation.Signed-off-by: Oliver Neukum
Hi David,
please take this for the next merge window.
Regards
Oliver
Signed-off-by: David S. Miller
23 Sep, 2009
1 commit
-
kaweth_control() never frees the buffer that it allocates for the USB
control message. Test case:while :; do ifconfig eth2 down ; ifconfig eth2 up ; done
This is a tiny buffer so it is a slow leak. If you want to speed up the
process, you can change the allocation size to e.g. 16384 bytes, and it
will consume several megabytes within a few minutes.Signed-off-by: Kevin Cernekee
Acked-by: Oliver Neukum
Signed-off-by: David S. Miller
02 Sep, 2009
1 commit
-
No need to put ethtool_ops in data, they should be const.
Signed-off-by: Stephen Hemminger
Signed-off-by: David S. Miller
01 Sep, 2009
1 commit
-
Signed-off-by: Stephen Hemminger
Signed-off-by: David S. Miller
17 Jul, 2009
1 commit
-
Conflicts:
drivers/net/wireless/orinoco/main.c
13 Jul, 2009
2 commits
-
alloc_etherdev() used to install a default implementation of this
operation, but it must now be explicitly installed in struct
net_device_ops.Signed-off-by: Ben Hutchings
Signed-off-by: David S. Miller -
alloc_etherdev() used to install default implementations of these
operations, but they must now be explicitly installed in struct
net_device_ops.Signed-off-by: Ben Hutchings
Signed-off-by: David S. Miller
06 Jul, 2009
1 commit
-
This patch is the result of an automatic spatch transformation to convert
all ndo_start_xmit() return values of 0 to NETDEV_TX_OK.Some occurences are missed by the automatic conversion, those will be
handled in a seperate patch.Signed-off-by: Patrick McHardy
Signed-off-by: David S. Miller
14 Apr, 2009
1 commit
-
The driver kaweth yields a -EBUSY error when starting, and a -ETIME
error when shutting down. These errors are avoided, and the RX status
is further checked for other potential errors.Signed-off-by: Larry Finger
Signed-off-by: David S. Miller
02 Apr, 2009
1 commit
-
On an SMP system, the following message is printed. The patch below gets
fixes the problem.=================================
[ INFO: inconsistent lock state ]
2.6.29-Linus-05093-gc31f403 #57
---------------------------------
inconsistent {hardirq-on-W} -> {in-hardirq-W} usage.
bash/4105 [HC1[1]:SC0[0]:HE0:SE1] takes:
(&kaweth->device_lock){+...}, at: []
kaweth_usb_receive+0x77/0x1af [kaw eth]
{hardirq-on-W} state was registered at:
[] __lock_acquire+0x753/0x1685
[] lock_acquire+0x55/0x71
[] _spin_lock+0x31/0x3d
[] kaweth_start_xmit+0x2b/0x1e1 [kaweth]
[] dev_hard_start_xmit+0x22e/0x2ad
[] __qdisc_run+0xf2/0x203
[] dev_queue_xmit+0x263/0x39b
[] packet_sendmsg_spkt+0x1c4/0x20a [af_packet]
[] sock_sendmsg+0xe4/0xfd
[] sys_sendto+0xe4/0x10c
[] system_call_fastpath+0x16/0x1b
[] 0xffffffffffffffff
irq event stamp: 1280
hardirqs last enabled at (1279): []
_spin_unlock_irqrestore+0x44/0x4c
hardirqs last disabled at (1280): []
save_args+0x67/0x70
softirqs last enabled at (660): []
__do_softirq+0x14d/0x15d
softirqs last disabled at (651): []
call_softirq+0x1c/0x28Signed-off-by: Larry Finger
Signed-off-by: David S. Miller
09 Jan, 2009
1 commit
-
This converts the kaweth ethernet USB driver to netdevops.
Signed-off-by: Oliver Neukum
Signed-off-by: David S. Miller
08 Jan, 2009
1 commit
-
There's no need to take the address of the function params or local variables
when the direct value byteswapping routines are available.Signed-off-by: Harvey Harrison
Signed-off-by: Andrew Morton
Signed-off-by: Greg Kroah-Hartman
19 Dec, 2008
1 commit
-
USB is going to switch the signature of the callbacks to
void callback(struct urb *urb, int status)
This patch will ease the transition.Signed-off-by: Oliver Neukum
Signed-off-by: David S. Miller
18 Oct, 2008
2 commits
-
USB should not be having it's own printk macros, so remove info() and
use the system-wide standard of dev_info() wherever possible.Cc: Jeff Garzik
Signed-off-by: Greg Kroah-Hartman -
USB should not be having it's own printk macros, so remove warn() and
use the system-wide standard of dev_warn() wherever possible. In the
few places that will not work out, use a basic printk().Cc: Jeff Garzik
Signed-off-by: Greg Kroah-Hartman
10 Jul, 2008
1 commit
-
Signed-off-by: David Woodhouse
12 Jun, 2008
1 commit
-
If the RTNL is held when we invoke flush_scheduled_work() we could
deadlock. One such case is linkwatch, it is a work struct which tries
to grab the RTNL semaphore.The most common case are net driver ->stop() methods. The
simplest conversion is to instead use cancel_{delayed_}work_sync()
explicitly on the various work struct the driver uses.This is an OK transformation because these work structs are doing
things like resetting the chip, restarting link negotiation, and so
forth. And if we're bringing down the device, we're about to turn the
chip off and reset it anways. So if we cancel a pending work event,
that's fine here.Some drivers were working around this deadlock by using a msleep()
polling loop of some sort, and those cases are converted to instead
use cancel_{delayed_}work_sync() as well.Signed-off-by: David S. Miller
19 Apr, 2008
1 commit
-
None of these files use any of the functionality promised by
asm/semaphore.h. It's possible that they rely on it dragging in some
unrelated header file, but I can't build all these files, so we'll have
fix any build failures as they come up.Signed-off-by: Matthew Wilcox
09 Jan, 2008
1 commit
-
Back in 2.6.12-pre, usb_start_wait_urb was switched over to take
milliseconds instead of jiffies. kaweth.c was never updated to match.Signed-off-by: Russ Dill
Signed-off-by: David S. Miller