Skip to content

Commit 0cfd810

Browse files
committed
Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: (94 commits) USB: remove err() macro from more usb drivers USB: remove err() macro from usb misc drivers USB: remove err() macro from usb core code USB: remove err() macro from usb class drivers USB: remove use of err() in drivers/usb/serial USB: remove info() macro from usb mtd drivers USB: remove info() macro from usb input drivers USB: remove info() macro from usb network drivers USB: remove info() macro from remaining usb drivers USB: remove info() macro from usb/misc drivers USB: remove info() macro from usb/serial drivers USB: remove warn macro from HID core USB: remove warn() macro from usb drivers USB: remove warn() macro from usb net drivers USB: remove warn() macro from usb media drivers USB: remove warn() macro from usb input drivers usb/fsl_qe_udc: clear data toggle on clear halt request usb/fsl_qe_udc: fix response to get status request fsl_usb2_udc: Fix oops on probe failure. fsl_usb2_udc: Add a wmb before priming endpoint. ...
2 parents f7ea4a4 + 802f389 commit 0cfd810

File tree

171 files changed

+8474
-1533
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

171 files changed

+8474
-1533
lines changed
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
What: /sys/bus/usb/drivers/usbtmc/devices/*/interface_capabilities
2+
What: /sys/bus/usb/drivers/usbtmc/devices/*/device_capabilities
3+
Date: August 2008
4+
Contact: Greg Kroah-Hartman <[email protected]>
5+
Description:
6+
These files show the various USB TMC capabilities as described
7+
by the device itself. The full description of the bitfields
8+
can be found in the USB TMC documents from the USB-IF entitled
9+
"Universal Serial Bus Test and Measurement Class Specification
10+
(USBTMC) Revision 1.0" section 4.2.1.8.
11+
12+
The files are read only.
13+
14+
15+
What: /sys/bus/usb/drivers/usbtmc/devices/*/usb488_interface_capabilities
16+
What: /sys/bus/usb/drivers/usbtmc/devices/*/usb488_device_capabilities
17+
Date: August 2008
18+
Contact: Greg Kroah-Hartman <[email protected]>
19+
Description:
20+
These files show the various USB TMC capabilities as described
21+
by the device itself. The full description of the bitfields
22+
can be found in the USB TMC documents from the USB-IF entitled
23+
"Universal Serial Bus Test and Measurement Class, Subclass
24+
USB488 Specification (USBTMC-USB488) Revision 1.0" section
25+
4.2.2.
26+
27+
The files are read only.
28+
29+
30+
What: /sys/bus/usb/drivers/usbtmc/devices/*/TermChar
31+
Date: August 2008
32+
Contact: Greg Kroah-Hartman <[email protected]>
33+
Description:
34+
This file is the TermChar value to be sent to the USB TMC
35+
device as described by the document, "Universal Serial Bus Test
36+
and Measurement Class Specification
37+
(USBTMC) Revision 1.0" as published by the USB-IF.
38+
39+
Note that the TermCharEnabled file determines if this value is
40+
sent to the device or not.
41+
42+
43+
What: /sys/bus/usb/drivers/usbtmc/devices/*/TermCharEnabled
44+
Date: August 2008
45+
Contact: Greg Kroah-Hartman <[email protected]>
46+
Description:
47+
This file determines if the TermChar is to be sent to the
48+
device on every transaction or not. For more details about
49+
this, please see the document, "Universal Serial Bus Test and
50+
Measurement Class Specification (USBTMC) Revision 1.0" as
51+
published by the USB-IF.
52+
53+
54+
What: /sys/bus/usb/drivers/usbtmc/devices/*/auto_abort
55+
Date: August 2008
56+
Contact: Greg Kroah-Hartman <[email protected]>
57+
Description:
58+
This file determines if the the transaction of the USB TMC
59+
device is to be automatically aborted if there is any error.
60+
For more details about this, please see the document,
61+
"Universal Serial Bus Test and Measurement Class Specification
62+
(USBTMC) Revision 1.0" as published by the USB-IF.

Documentation/ABI/testing/sysfs-bus-usb

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,3 +85,19 @@ Description:
8585
Users:
8686
PowerTOP <[email protected]>
8787
http://www.lesswatts.org/projects/powertop/
88+
89+
What: /sys/bus/usb/device/<busnum>-<devnum>...:<config num>-<interface num>/supports_autosuspend
90+
Date: January 2008
91+
KernelVersion: 2.6.27
92+
Contact: Sarah Sharp <[email protected]>
93+
Description:
94+
When read, this file returns 1 if the interface driver
95+
for this interface supports autosuspend. It also
96+
returns 1 if no driver has claimed this interface, as an
97+
unclaimed interface will not stop the device from being
98+
autosuspended if all other interface drivers are idle.
99+
The file returns 0 if autosuspend support has not been
100+
added to the driver.
101+
Users:
102+
USB PM tool
103+
git://git.moblin.org/users/sarah/usb-pm-tool/
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
Where: /sys/bus/usb/.../powered
2+
Date: August 2008
3+
Kernel Version: 2.6.26
4+
Contact: Harrison Metzger <[email protected]>
5+
Description: Controls whether the device's display will powered.
6+
A value of 0 is off and a non-zero value is on.
7+
8+
Where: /sys/bus/usb/.../mode_msb
9+
Where: /sys/bus/usb/.../mode_lsb
10+
Date: August 2008
11+
Kernel Version: 2.6.26
12+
Contact: Harrison Metzger <[email protected]>
13+
Description: Controls the devices display mode.
14+
For a 6 character display the values are
15+
MSB 0x06; LSB 0x3F, and
16+
for an 8 character display the values are
17+
MSB 0x08; LSB 0xFF.
18+
19+
Where: /sys/bus/usb/.../textmode
20+
Date: August 2008
21+
Kernel Version: 2.6.26
22+
Contact: Harrison Metzger <[email protected]>
23+
Description: Controls the way the device interprets its text buffer.
24+
raw: each character controls its segment manually
25+
hex: each character is between 0-15
26+
ascii: each character is between '0'-'9' and 'A'-'F'.
27+
28+
Where: /sys/bus/usb/.../text
29+
Date: August 2008
30+
Kernel Version: 2.6.26
31+
Contact: Harrison Metzger <[email protected]>
32+
Description: The text (or data) for the device to display
33+
34+
Where: /sys/bus/usb/.../decimals
35+
Date: August 2008
36+
Kernel Version: 2.6.26
37+
Contact: Harrison Metzger <[email protected]>
38+
Description: Controls the decimal places on the device.
39+
To set the nth decimal place, give this field
40+
the value of 10 ** n. Assume this field has
41+
the value k and has 1 or more decimal places set,
42+
to set the mth place (where m is not already set),
43+
change this fields value to k + 10 ** m.

Documentation/DocBook/gadget.tmpl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -557,6 +557,9 @@ Near-term plans include converting all of them, except for "gadgetfs".
557557
</para>
558558

559559
!Edrivers/usb/gadget/f_acm.c
560+
!Edrivers/usb/gadget/f_ecm.c
561+
!Edrivers/usb/gadget/f_subset.c
562+
!Edrivers/usb/gadget/f_obex.c
560563
!Edrivers/usb/gadget/f_serial.c
561564

562565
</sect1>

Documentation/devices.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2571,6 +2571,9 @@ Your cooperation is appreciated.
25712571
160 = /dev/usb/legousbtower0 1st USB Legotower device
25722572
...
25732573
175 = /dev/usb/legousbtower15 16th USB Legotower device
2574+
176 = /dev/usb/usbtmc1 First USB TMC device
2575+
...
2576+
192 = /dev/usb/usbtmc16 16th USB TMC device
25742577
240 = /dev/usb/dabusb0 First daubusb device
25752578
...
25762579
243 = /dev/usb/dabusb3 Fourth dabusb device

Documentation/ioctl-number.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ Code Seq# Include File Comments
9292
'J' 00-1F drivers/scsi/gdth_ioctl.h
9393
'K' all linux/kd.h
9494
'L' 00-1F linux/loop.h
95+
'L' 20-2F driver/usb/misc/vstusb.h
9596
'L' E0-FF linux/ppdd.h encrypted disk device driver
9697
<http://linux01.gwdg.de/~alatham/ppdd.html>
9798
'M' all linux/soundcard.h
@@ -110,6 +111,8 @@ Code Seq# Include File Comments
110111
'W' 00-1F linux/wanrouter.h conflict!
111112
'X' all linux/xfs_fs.h
112113
'Y' all linux/cyclades.h
114+
'[' 00-07 linux/usb/usbtmc.h USB Test and Measurement Devices
115+
113116
'a' all ATM on linux
114117
<http://lrcwww.epfl.ch/linux-atm/magic.html>
115118
'b' 00-FF bit3 vme host bridge

Documentation/kernel-parameters.txt

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2253,6 +2253,25 @@ and is between 256 and 4096 characters. It is defined in the file
22532253
autosuspended. Devices for which the delay is set
22542254
to a negative value won't be autosuspended at all.
22552255

2256+
usbcore.usbfs_snoop=
2257+
[USB] Set to log all usbfs traffic (default 0 = off).
2258+
2259+
usbcore.blinkenlights=
2260+
[USB] Set to cycle leds on hubs (default 0 = off).
2261+
2262+
usbcore.old_scheme_first=
2263+
[USB] Start with the old device initialization
2264+
scheme (default 0 = off).
2265+
2266+
usbcore.use_both_schemes=
2267+
[USB] Try the other device initialization scheme
2268+
if the first one fails (default 1 = enabled).
2269+
2270+
usbcore.initial_descriptor_timeout=
2271+
[USB] Specifies timeout for the initial 64-byte
2272+
USB_REQ_GET_DESCRIPTOR request in milliseconds
2273+
(default 5000 = 5.0 seconds).
2274+
22562275
usbhid.mousepoll=
22572276
[USBHID] The interval which mice are to be polled at.
22582277

Documentation/usb/anchors.txt

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,28 @@ Therefore no guarantee is made that the URBs have been unlinked when
5252
the call returns. They may be unlinked later but will be unlinked in
5353
finite time.
5454

55+
usb_scuttle_anchored_urbs()
56+
---------------------------
57+
58+
All URBs of an anchor are unanchored en masse.
59+
5560
usb_wait_anchor_empty_timeout()
5661
-------------------------------
5762

5863
This function waits for all URBs associated with an anchor to finish
5964
or a timeout, whichever comes first. Its return value will tell you
6065
whether the timeout was reached.
6166

67+
usb_anchor_empty()
68+
------------------
69+
70+
Returns true if no URBs are associated with an anchor. Locking
71+
is the caller's responsibility.
72+
73+
usb_get_from_anchor()
74+
---------------------
6275

76+
Returns the oldest anchored URB of an anchor. The URB is unanchored
77+
and returned with a reference. As you may mix URBs to several
78+
destinations in one anchor you have no guarantee the chronologically
79+
first submitted URB is returned.

Documentation/usb/misc_usbsevseg.txt

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
USB 7-Segment Numeric Display
2+
Manufactured by Delcom Engineering
3+
4+
Device Information
5+
------------------
6+
USB VENDOR_ID 0x0fc5
7+
USB PRODUCT_ID 0x1227
8+
Both the 6 character and 8 character displays have PRODUCT_ID,
9+
and according to Delcom Engineering no queryable information
10+
can be obtained from the device to tell them apart.
11+
12+
Device Modes
13+
------------
14+
By default, the driver assumes the display is only 6 characters
15+
The mode for 6 characters is:
16+
MSB 0x06; LSB 0x3f
17+
For the 8 character display:
18+
MSB 0x08; LSB 0xff
19+
The device can accept "text" either in raw, hex, or ascii textmode.
20+
raw controls each segment manually,
21+
hex expects a value between 0-15 per character,
22+
ascii expects a value between '0'-'9' and 'A'-'F'.
23+
The default is ascii.
24+
25+
Device Operation
26+
----------------
27+
1. Turn on the device:
28+
echo 1 > /sys/bus/usb/.../powered
29+
2. Set the device's mode:
30+
echo $mode_msb > /sys/bus/usb/.../mode_msb
31+
echo $mode_lsb > /sys/bus/usb/.../mode_lsb
32+
3. Set the textmode:
33+
echo $textmode > /sys/bus/usb/.../textmode
34+
4. set the text (for example):
35+
echo "123ABC" > /sys/bus/usb/.../text (ascii)
36+
echo "A1B2" > /sys/bus/usb/.../text (ascii)
37+
echo -ne "\x01\x02\x03" > /sys/bus/usb/.../text (hex)
38+
5. Set the decimal places.
39+
The device has either 6 or 8 decimal points.
40+
to set the nth decimal place calculate 10 ** n
41+
and echo it in to /sys/bus/usb/.../decimals
42+
To set multiple decimals points sum up each power.
43+
For example, to set the 0th and 3rd decimal place
44+
echo 1001 > /sys/bus/usb/.../decimals
45+
46+

Documentation/usb/power-management.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -350,12 +350,12 @@ without holding the mutex.
350350

351351
There also are a couple of utility routines drivers can use:
352352

353-
usb_autopm_enable() sets pm_usage_cnt to 1 and then calls
354-
usb_autopm_set_interface(), which will attempt an autoresume.
355-
356-
usb_autopm_disable() sets pm_usage_cnt to 0 and then calls
353+
usb_autopm_enable() sets pm_usage_cnt to 0 and then calls
357354
usb_autopm_set_interface(), which will attempt an autosuspend.
358355

356+
usb_autopm_disable() sets pm_usage_cnt to 1 and then calls
357+
usb_autopm_set_interface(), which will attempt an autoresume.
358+
359359
The conventional usage pattern is that a driver calls
360360
usb_autopm_get_interface() in its open routine and
361361
usb_autopm_put_interface() in its close or release routine. But

drivers/block/ub.c

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -349,8 +349,6 @@ struct ub_dev {
349349

350350
struct work_struct reset_work;
351351
wait_queue_head_t reset_wait;
352-
353-
int sg_stat[6];
354352
};
355353

356354
/*
@@ -685,7 +683,6 @@ static int ub_request_fn_1(struct ub_lun *lun, struct request *rq)
685683
goto drop;
686684
}
687685
urq->nsg = n_elem;
688-
sc->sg_stat[n_elem < 5 ? n_elem : 5]++;
689686

690687
if (blk_pc_request(rq)) {
691688
ub_cmd_build_packet(sc, lun, cmd, urq);

drivers/hid/usbhid/hid-core.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -428,7 +428,7 @@ void usbhid_submit_report(struct hid_device *hid, struct hid_report *report, uns
428428
usbhid->out[usbhid->outhead].raw_report = kmalloc(len, GFP_ATOMIC);
429429
if (!usbhid->out[usbhid->outhead].raw_report) {
430430
spin_unlock_irqrestore(&usbhid->outlock, flags);
431-
warn("output queueing failed");
431+
dev_warn(&hid->dev, "output queueing failed\n");
432432
return;
433433
}
434434
hid_output_report(report, usbhid->out[usbhid->outhead].raw_report);
@@ -455,7 +455,7 @@ void usbhid_submit_report(struct hid_device *hid, struct hid_report *report, uns
455455
usbhid->ctrl[usbhid->ctrlhead].raw_report = kmalloc(len, GFP_ATOMIC);
456456
if (!usbhid->ctrl[usbhid->ctrlhead].raw_report) {
457457
spin_unlock_irqrestore(&usbhid->ctrllock, flags);
458-
warn("control queueing failed");
458+
dev_warn(&hid->dev, "control queueing failed\n");
459459
return;
460460
}
461461
hid_output_report(report, usbhid->ctrl[usbhid->ctrlhead].raw_report);

0 commit comments

Comments
 (0)