diff options
author | Alan Stern <stern@rowland.harvard.edu> | 2005-11-30 17:16:19 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-01-04 16:51:41 -0500 |
commit | 687f5f3428157bea4940dd967fd7b4e59c1b13b4 (patch) | |
tree | 1f3051906989d2e80df0985c1a48f41c6c283f64 /drivers/usb | |
parent | fa3465689f93331834a831bbe98e3863701e1068 (diff) |
[PATCH] USB: UHCI: edit some comments
This patch (as615b) edits a large number of comments in the uhci-hcd code,
mainly removing excess apostrophes.
Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/host/uhci-debug.c | 12 | ||||
-rw-r--r-- | drivers/usb/host/uhci-hcd.c | 17 | ||||
-rw-r--r-- | drivers/usb/host/uhci-hcd.h | 24 | ||||
-rw-r--r-- | drivers/usb/host/uhci-q.c | 18 |
4 files changed, 36 insertions, 35 deletions
diff --git a/drivers/usb/host/uhci-debug.c b/drivers/usb/host/uhci-debug.c index cab02e15bfee..5832953086f8 100644 --- a/drivers/usb/host/uhci-debug.c +++ b/drivers/usb/host/uhci-debug.c | |||
@@ -2,8 +2,8 @@ | |||
2 | * UHCI-specific debugging code. Invaluable when something | 2 | * UHCI-specific debugging code. Invaluable when something |
3 | * goes wrong, but don't get in my face. | 3 | * goes wrong, but don't get in my face. |
4 | * | 4 | * |
5 | * Kernel visible pointers are surrounded in []'s and bus | 5 | * Kernel visible pointers are surrounded in []s and bus |
6 | * visible pointers are surrounded in ()'s | 6 | * visible pointers are surrounded in ()s |
7 | * | 7 | * |
8 | * (C) Copyright 1999 Linus Torvalds | 8 | * (C) Copyright 1999 Linus Torvalds |
9 | * (C) Copyright 1999-2001 Johannes Erdfelt | 9 | * (C) Copyright 1999-2001 Johannes Erdfelt |
@@ -19,7 +19,7 @@ | |||
19 | 19 | ||
20 | static struct dentry *uhci_debugfs_root = NULL; | 20 | static struct dentry *uhci_debugfs_root = NULL; |
21 | 21 | ||
22 | /* Handle REALLY large printk's so we don't overflow buffers */ | 22 | /* Handle REALLY large printks so we don't overflow buffers */ |
23 | static inline void lprintk(char *buf) | 23 | static inline void lprintk(char *buf) |
24 | { | 24 | { |
25 | char *p; | 25 | char *p; |
@@ -160,7 +160,7 @@ static int uhci_show_qh(struct uhci_qh *qh, char *buf, int len, int space) | |||
160 | } | 160 | } |
161 | 161 | ||
162 | if (active && ni > i) { | 162 | if (active && ni > i) { |
163 | out += sprintf(out, "%*s[skipped %d active TD's]\n", space, "", ni - i); | 163 | out += sprintf(out, "%*s[skipped %d active TDs]\n", space, "", ni - i); |
164 | tmp = ntmp; | 164 | tmp = ntmp; |
165 | td = ntd; | 165 | td = ntd; |
166 | i = ni; | 166 | i = ni; |
@@ -173,7 +173,7 @@ static int uhci_show_qh(struct uhci_qh *qh, char *buf, int len, int space) | |||
173 | if (list_empty(&urbp->queue_list) || urbp->queued) | 173 | if (list_empty(&urbp->queue_list) || urbp->queued) |
174 | goto out; | 174 | goto out; |
175 | 175 | ||
176 | out += sprintf(out, "%*sQueued QH's:\n", -space, "--"); | 176 | out += sprintf(out, "%*sQueued QHs:\n", -space, "--"); |
177 | 177 | ||
178 | head = &urbp->queue_list; | 178 | head = &urbp->queue_list; |
179 | tmp = head->next; | 179 | tmp = head->next; |
@@ -464,7 +464,7 @@ static int uhci_sprint_schedule(struct uhci_hcd *uhci, char *buf, int len) | |||
464 | } while (tmp != head); | 464 | } while (tmp != head); |
465 | } | 465 | } |
466 | 466 | ||
467 | out += sprintf(out, "Skeleton QH's\n"); | 467 | out += sprintf(out, "Skeleton QHs\n"); |
468 | 468 | ||
469 | for (i = 0; i < UHCI_NUM_SKELQH; ++i) { | 469 | for (i = 0; i < UHCI_NUM_SKELQH; ++i) { |
470 | int shown = 0; | 470 | int shown = 0; |
diff --git a/drivers/usb/host/uhci-hcd.c b/drivers/usb/host/uhci-hcd.c index 120ca64fe3f7..dfe121d35887 100644 --- a/drivers/usb/host/uhci-hcd.c +++ b/drivers/usb/host/uhci-hcd.c | |||
@@ -62,10 +62,10 @@ Alan Stern" | |||
62 | 62 | ||
63 | /* | 63 | /* |
64 | * debug = 0, no debugging messages | 64 | * debug = 0, no debugging messages |
65 | * debug = 1, dump failed URB's except for stalls | 65 | * debug = 1, dump failed URBs except for stalls |
66 | * debug = 2, dump all failed URB's (including stalls) | 66 | * debug = 2, dump all failed URBs (including stalls) |
67 | * show all queues in /debug/uhci/[pci_addr] | 67 | * show all queues in /debug/uhci/[pci_addr] |
68 | * debug = 3, show all TD's in URB's when dumping | 68 | * debug = 3, show all TDs in URBs when dumping |
69 | */ | 69 | */ |
70 | #ifdef DEBUG | 70 | #ifdef DEBUG |
71 | static int debug = 1; | 71 | static int debug = 1; |
@@ -88,7 +88,7 @@ static void uhci_get_current_frame_number(struct uhci_hcd *uhci); | |||
88 | #define FSBR_DELAY msecs_to_jiffies(50) | 88 | #define FSBR_DELAY msecs_to_jiffies(50) |
89 | 89 | ||
90 | /* When we timeout an idle transfer for FSBR, we'll switch it over to */ | 90 | /* When we timeout an idle transfer for FSBR, we'll switch it over to */ |
91 | /* depth first traversal. We'll do it in groups of this number of TD's */ | 91 | /* depth first traversal. We'll do it in groups of this number of TDs */ |
92 | /* to make sure it doesn't hog all of the bandwidth */ | 92 | /* to make sure it doesn't hog all of the bandwidth */ |
93 | #define DEPTH_INTERVAL 5 | 93 | #define DEPTH_INTERVAL 5 |
94 | 94 | ||
@@ -728,8 +728,9 @@ static int uhci_resume(struct usb_hcd *hcd) | |||
728 | 728 | ||
729 | dev_dbg(uhci_dev(uhci), "%s\n", __FUNCTION__); | 729 | dev_dbg(uhci_dev(uhci), "%s\n", __FUNCTION__); |
730 | 730 | ||
731 | /* We aren't in D3 state anymore, we do that even if dead as I | 731 | /* Since we aren't in D3 any more, it's safe to set this flag |
732 | * really don't want to keep a stale HCD_FLAG_HW_ACCESSIBLE=0 | 732 | * even if the controller was dead. It might not even be dead |
733 | * any more, if the firmware or quirks code has reset it. | ||
733 | */ | 734 | */ |
734 | set_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags); | 735 | set_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags); |
735 | mb(); | 736 | mb(); |
@@ -879,7 +880,7 @@ static int __init uhci_hcd_init(void) | |||
879 | 880 | ||
880 | init_failed: | 881 | init_failed: |
881 | if (kmem_cache_destroy(uhci_up_cachep)) | 882 | if (kmem_cache_destroy(uhci_up_cachep)) |
882 | warn("not all urb_priv's were freed!"); | 883 | warn("not all urb_privs were freed!"); |
883 | 884 | ||
884 | up_failed: | 885 | up_failed: |
885 | debugfs_remove(uhci_debugfs_root); | 886 | debugfs_remove(uhci_debugfs_root); |
@@ -897,7 +898,7 @@ static void __exit uhci_hcd_cleanup(void) | |||
897 | pci_unregister_driver(&uhci_pci_driver); | 898 | pci_unregister_driver(&uhci_pci_driver); |
898 | 899 | ||
899 | if (kmem_cache_destroy(uhci_up_cachep)) | 900 | if (kmem_cache_destroy(uhci_up_cachep)) |
900 | warn("not all urb_priv's were freed!"); | 901 | warn("not all urb_privs were freed!"); |
901 | 902 | ||
902 | debugfs_remove(uhci_debugfs_root); | 903 | debugfs_remove(uhci_debugfs_root); |
903 | kfree(errbuf); | 904 | kfree(errbuf); |
diff --git a/drivers/usb/host/uhci-hcd.h b/drivers/usb/host/uhci-hcd.h index e43282e4e806..8b4b887a7d41 100644 --- a/drivers/usb/host/uhci-hcd.h +++ b/drivers/usb/host/uhci-hcd.h | |||
@@ -223,10 +223,10 @@ static u32 inline td_status(struct uhci_td *td) { | |||
223 | */ | 223 | */ |
224 | 224 | ||
225 | /* | 225 | /* |
226 | * The UHCI driver places Interrupt, Control and Bulk into QH's both | 226 | * The UHCI driver places Interrupt, Control and Bulk into QHs both |
227 | * to group together TD's for one transfer, and also to faciliate queuing | 227 | * to group together TDs for one transfer, and also to facilitate queuing |
228 | * of URB's. To make it easy to insert entries into the schedule, we have | 228 | * of URBs. To make it easy to insert entries into the schedule, we have |
229 | * a skeleton of QH's for each predefined Interrupt latency, low-speed | 229 | * a skeleton of QHs for each predefined Interrupt latency, low-speed |
230 | * control, full-speed control and terminating QH (see explanation for | 230 | * control, full-speed control and terminating QH (see explanation for |
231 | * the terminating QH below). | 231 | * the terminating QH below). |
232 | * | 232 | * |
@@ -257,8 +257,8 @@ static u32 inline td_status(struct uhci_td *td) { | |||
257 | * reclamation. | 257 | * reclamation. |
258 | * | 258 | * |
259 | * Isochronous transfers are stored before the start of the skeleton | 259 | * Isochronous transfers are stored before the start of the skeleton |
260 | * schedule and don't use QH's. While the UHCI spec doesn't forbid the | 260 | * schedule and don't use QHs. While the UHCI spec doesn't forbid the |
261 | * use of QH's for Isochronous, it doesn't use them either. And the spec | 261 | * use of QHs for Isochronous, it doesn't use them either. And the spec |
262 | * says that queues never advance on an error completion status, which | 262 | * says that queues never advance on an error completion status, which |
263 | * makes them totally unsuitable for Isochronous transfers. | 263 | * makes them totally unsuitable for Isochronous transfers. |
264 | */ | 264 | */ |
@@ -359,7 +359,7 @@ struct uhci_hcd { | |||
359 | struct dma_pool *td_pool; | 359 | struct dma_pool *td_pool; |
360 | 360 | ||
361 | struct uhci_td *term_td; /* Terminating TD, see UHCI bug */ | 361 | struct uhci_td *term_td; /* Terminating TD, see UHCI bug */ |
362 | struct uhci_qh *skelqh[UHCI_NUM_SKELQH]; /* Skeleton QH's */ | 362 | struct uhci_qh *skelqh[UHCI_NUM_SKELQH]; /* Skeleton QHs */ |
363 | 363 | ||
364 | spinlock_t lock; | 364 | spinlock_t lock; |
365 | 365 | ||
@@ -389,22 +389,22 @@ struct uhci_hcd { | |||
389 | unsigned long resuming_ports; | 389 | unsigned long resuming_ports; |
390 | unsigned long ports_timeout; /* Time to stop signalling */ | 390 | unsigned long ports_timeout; /* Time to stop signalling */ |
391 | 391 | ||
392 | /* Main list of URB's currently controlled by this HC */ | 392 | /* Main list of URBs currently controlled by this HC */ |
393 | struct list_head urb_list; | 393 | struct list_head urb_list; |
394 | 394 | ||
395 | /* List of QH's that are done, but waiting to be unlinked (race) */ | 395 | /* List of QHs that are done, but waiting to be unlinked (race) */ |
396 | struct list_head qh_remove_list; | 396 | struct list_head qh_remove_list; |
397 | unsigned int qh_remove_age; /* Age in frames */ | 397 | unsigned int qh_remove_age; /* Age in frames */ |
398 | 398 | ||
399 | /* List of TD's that are done, but waiting to be freed (race) */ | 399 | /* List of TDs that are done, but waiting to be freed (race) */ |
400 | struct list_head td_remove_list; | 400 | struct list_head td_remove_list; |
401 | unsigned int td_remove_age; /* Age in frames */ | 401 | unsigned int td_remove_age; /* Age in frames */ |
402 | 402 | ||
403 | /* List of asynchronously unlinked URB's */ | 403 | /* List of asynchronously unlinked URBs */ |
404 | struct list_head urb_remove_list; | 404 | struct list_head urb_remove_list; |
405 | unsigned int urb_remove_age; /* Age in frames */ | 405 | unsigned int urb_remove_age; /* Age in frames */ |
406 | 406 | ||
407 | /* List of URB's awaiting completion callback */ | 407 | /* List of URBs awaiting completion callback */ |
408 | struct list_head complete_list; | 408 | struct list_head complete_list; |
409 | 409 | ||
410 | int rh_numports; /* Number of root-hub ports */ | 410 | int rh_numports; /* Number of root-hub ports */ |
diff --git a/drivers/usb/host/uhci-q.c b/drivers/usb/host/uhci-q.c index ace9d15f85d2..b6076004a437 100644 --- a/drivers/usb/host/uhci-q.c +++ b/drivers/usb/host/uhci-q.c | |||
@@ -80,7 +80,7 @@ static inline void uhci_fill_td(struct uhci_td *td, u32 status, | |||
80 | } | 80 | } |
81 | 81 | ||
82 | /* | 82 | /* |
83 | * We insert Isochronous URB's directly into the frame list at the beginning | 83 | * We insert Isochronous URBs directly into the frame list at the beginning |
84 | */ | 84 | */ |
85 | static void uhci_insert_td_frame_list(struct uhci_hcd *uhci, struct uhci_td *td, unsigned framenum) | 85 | static void uhci_insert_td_frame_list(struct uhci_hcd *uhci, struct uhci_td *td, unsigned framenum) |
86 | { | 86 | { |
@@ -369,7 +369,7 @@ static void uhci_append_queued_urb(struct uhci_hcd *uhci, struct urb *eurb, stru | |||
369 | uhci_fixup_toggle(urb, | 369 | uhci_fixup_toggle(urb, |
370 | uhci_toggle(td_token(lltd)) ^ 1)); | 370 | uhci_toggle(td_token(lltd)) ^ 1)); |
371 | 371 | ||
372 | /* All qh's in the queue need to link to the next queue */ | 372 | /* All qhs in the queue need to link to the next queue */ |
373 | urbp->qh->link = eurbp->qh->link; | 373 | urbp->qh->link = eurbp->qh->link; |
374 | 374 | ||
375 | wmb(); /* Make sure we flush everything */ | 375 | wmb(); /* Make sure we flush everything */ |
@@ -502,7 +502,7 @@ static void uhci_destroy_urb_priv(struct uhci_hcd *uhci, struct urb *urb) | |||
502 | } | 502 | } |
503 | 503 | ||
504 | /* Check to see if the remove list is empty. Set the IOC bit */ | 504 | /* Check to see if the remove list is empty. Set the IOC bit */ |
505 | /* to force an interrupt so we can remove the TD's*/ | 505 | /* to force an interrupt so we can remove the TDs*/ |
506 | if (list_empty(&uhci->td_remove_list)) | 506 | if (list_empty(&uhci->td_remove_list)) |
507 | uhci_set_next_interrupt(uhci); | 507 | uhci_set_next_interrupt(uhci); |
508 | 508 | ||
@@ -612,7 +612,7 @@ static int uhci_submit_control(struct uhci_hcd *uhci, struct urb *urb, struct ur | |||
612 | } | 612 | } |
613 | 613 | ||
614 | /* | 614 | /* |
615 | * Build the DATA TD's | 615 | * Build the DATA TDs |
616 | */ | 616 | */ |
617 | while (len > 0) { | 617 | while (len > 0) { |
618 | int pktsze = len; | 618 | int pktsze = len; |
@@ -744,7 +744,7 @@ static int uhci_result_control(struct uhci_hcd *uhci, struct urb *urb) | |||
744 | 744 | ||
745 | urb->actual_length = 0; | 745 | urb->actual_length = 0; |
746 | 746 | ||
747 | /* The rest of the TD's (but the last) are data */ | 747 | /* The rest of the TDs (but the last) are data */ |
748 | tmp = tmp->next; | 748 | tmp = tmp->next; |
749 | while (tmp != head && tmp->next != head) { | 749 | while (tmp != head && tmp->next != head) { |
750 | unsigned int ctrlstat; | 750 | unsigned int ctrlstat; |
@@ -848,7 +848,7 @@ static int uhci_submit_common(struct uhci_hcd *uhci, struct urb *urb, struct urb | |||
848 | status |= TD_CTRL_SPD; | 848 | status |= TD_CTRL_SPD; |
849 | 849 | ||
850 | /* | 850 | /* |
851 | * Build the DATA TD's | 851 | * Build the DATA TDs |
852 | */ | 852 | */ |
853 | do { /* Allow zero length packets */ | 853 | do { /* Allow zero length packets */ |
854 | int pktsze = maxsze; | 854 | int pktsze = maxsze; |
@@ -1025,7 +1025,7 @@ static int isochronous_find_limits(struct uhci_hcd *uhci, struct urb *urb, unsig | |||
1025 | list_for_each_entry(up, &uhci->urb_list, urb_list) { | 1025 | list_for_each_entry(up, &uhci->urb_list, urb_list) { |
1026 | struct urb *u = up->urb; | 1026 | struct urb *u = up->urb; |
1027 | 1027 | ||
1028 | /* look for pending URB's with identical pipe handle */ | 1028 | /* look for pending URBs with identical pipe handle */ |
1029 | if ((urb->pipe == u->pipe) && (urb->dev == u->dev) && | 1029 | if ((urb->pipe == u->pipe) && (urb->dev == u->dev) && |
1030 | (u->status == -EINPROGRESS) && (u != urb)) { | 1030 | (u->status == -EINPROGRESS) && (u != urb)) { |
1031 | if (!last_urb) | 1031 | if (!last_urb) |
@@ -1355,7 +1355,7 @@ static void uhci_unlink_generic(struct uhci_hcd *uhci, struct urb *urb) | |||
1355 | 1355 | ||
1356 | uhci_delete_queued_urb(uhci, urb); | 1356 | uhci_delete_queued_urb(uhci, urb); |
1357 | 1357 | ||
1358 | /* The interrupt loop will reclaim the QH's */ | 1358 | /* The interrupt loop will reclaim the QHs */ |
1359 | uhci_remove_qh(uhci, urbp->qh); | 1359 | uhci_remove_qh(uhci, urbp->qh); |
1360 | urbp->qh = NULL; | 1360 | urbp->qh = NULL; |
1361 | } | 1361 | } |
@@ -1413,7 +1413,7 @@ static int uhci_fsbr_timeout(struct uhci_hcd *uhci, struct urb *urb) | |||
1413 | list_for_each_entry(td, head, list) { | 1413 | list_for_each_entry(td, head, list) { |
1414 | /* | 1414 | /* |
1415 | * Make sure we don't do the last one (since it'll have the | 1415 | * Make sure we don't do the last one (since it'll have the |
1416 | * TERM bit set) as well as we skip every so many TD's to | 1416 | * TERM bit set) as well as we skip every so many TDs to |
1417 | * make sure it doesn't hog the bandwidth | 1417 | * make sure it doesn't hog the bandwidth |
1418 | */ | 1418 | */ |
1419 | if (td->list.next != head && (count % DEPTH_INTERVAL) == | 1419 | if (td->list.next != head && (count % DEPTH_INTERVAL) == |