linux/drivers/usb/misc
Michal Nazarewicz e538dfdae8 usb: Provide usb_speed_string() function
In a few places in the kernel, the code prints
a human-readable USB device speed (eg. "high speed").
This involves a switch statement sometimes wrapped
around in ({ ... }) block leading to code repetition.

To mitigate this issue, this commit introduces
usb_speed_string() function, which returns
a human-readable name of provided speed.

It also changes a few places switch was used to use
this new function.  This changes a bit the way the
speed is printed in few instances at the same time
standardising it.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-09-18 01:29:04 -07:00
..
sisusbvga usb: misc: sisusbvga: fix information leak to userland 2010-11-11 07:14:06 -08:00
Kconfig USB: add driver for Meywa-Denki & Kayac YUREX 2010-10-22 10:21:51 -07:00
Makefile usb: makefile cleanup 2010-10-22 10:22:07 -07:00
adutux.c USB: use usb_endpoint_maxp() instead of le16_to_cpu() 2011-08-23 09:47:40 -07:00
appledisplay.c atomic: use <linux/atomic.h> 2011-07-26 16:49:47 -07:00
cypress_cy7c63.c USB: misc: cypress_cy7c63: fix up some sysfs attribute permissions 2010-11-15 14:04:14 -08:00
cytherm.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
emi26.c USB misc: make USB device id constant 2010-03-02 14:54:17 -08:00
emi62.c USB misc: make USB device id constant 2010-03-02 14:54:17 -08:00
ftdi-elan.c USB: use usb_endpoint_maxp() instead of le16_to_cpu() 2011-08-23 09:47:40 -07:00
idmouse.c USB: use usb_endpoint_maxp() instead of le16_to_cpu() 2011-08-23 09:47:40 -07:00
iowarrior.c USB: use usb_endpoint_maxp() instead of le16_to_cpu() 2011-08-23 09:47:40 -07:00
isight_firmware.c include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h 2010-03-30 22:02:32 +09:00
ldusb.c USB: use usb_endpoint_maxp() instead of le16_to_cpu() 2011-08-23 09:47:40 -07:00
legousbtower.c USB: use usb_endpoint_maxp() instead of le16_to_cpu() 2011-08-23 09:47:40 -07:00
rio500.c llseek: automatically add .llseek fop 2010-10-15 15:53:27 +02:00
rio500_usb.h
trancevibrator.c USB: misc: trancevibrator: fix up a sysfs attribute permission 2010-11-15 14:04:15 -08:00
usb_u132.h Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/usb-2.6 2006-12-01 16:41:58 -08:00
usblcd.c USB: use usb_endpoint_maxp() instead of le16_to_cpu() 2011-08-23 09:47:40 -07:00
usbled.c usb: misc: usbled: fixed coding style issues 2011-08-22 15:21:16 -07:00
usbsevseg.c USB: misc: usbsevseg: fix up some sysfs attribute permissions 2010-11-15 14:04:15 -08:00
usbtest.c usb: Provide usb_speed_string() function 2011-09-18 01:29:04 -07:00
uss720.c USB: uss720 fixup refcount position 2011-03-23 13:14:31 -07:00
yurex.c USB: yurex: add .llseek fop to file_operations 2010-11-30 10:24:50 -08:00