Commit 687f5f34 authored by Alan Stern's avatar Alan Stern Committed by Greg Kroah-Hartman

[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: default avatarAlan Stern <stern@rowland.harvard.edu>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent fa346568
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
* UHCI-specific debugging code. Invaluable when something * UHCI-specific debugging code. Invaluable when something
* goes wrong, but don't get in my face. * goes wrong, but don't get in my face.
* *
* Kernel visible pointers are surrounded in []'s and bus * Kernel visible pointers are surrounded in []s and bus
* visible pointers are surrounded in ()'s * visible pointers are surrounded in ()s
* *
* (C) Copyright 1999 Linus Torvalds * (C) Copyright 1999 Linus Torvalds
* (C) Copyright 1999-2001 Johannes Erdfelt * (C) Copyright 1999-2001 Johannes Erdfelt
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
static struct dentry *uhci_debugfs_root = NULL; static struct dentry *uhci_debugfs_root = NULL;
/* Handle REALLY large printk's so we don't overflow buffers */ /* Handle REALLY large printks so we don't overflow buffers */
static inline void lprintk(char *buf) static inline void lprintk(char *buf)
{ {
char *p; char *p;
...@@ -160,7 +160,7 @@ static int uhci_show_qh(struct uhci_qh *qh, char *buf, int len, int space) ...@@ -160,7 +160,7 @@ static int uhci_show_qh(struct uhci_qh *qh, char *buf, int len, int space)
} }
if (active && ni > i) { if (active && ni > i) {
out += sprintf(out, "%*s[skipped %d active TD's]\n", space, "", ni - i); out += sprintf(out, "%*s[skipped %d active TDs]\n", space, "", ni - i);
tmp = ntmp; tmp = ntmp;
td = ntd; td = ntd;
i = ni; i = ni;
...@@ -173,7 +173,7 @@ static int uhci_show_qh(struct uhci_qh *qh, char *buf, int len, int space) ...@@ -173,7 +173,7 @@ static int uhci_show_qh(struct uhci_qh *qh, char *buf, int len, int space)
if (list_empty(&urbp->queue_list) || urbp->queued) if (list_empty(&urbp->queue_list) || urbp->queued)
goto out; goto out;
out += sprintf(out, "%*sQueued QH's:\n", -space, "--"); out += sprintf(out, "%*sQueued QHs:\n", -space, "--");
head = &urbp->queue_list; head = &urbp->queue_list;
tmp = head->next; tmp = head->next;
...@@ -464,7 +464,7 @@ static int uhci_sprint_schedule(struct uhci_hcd *uhci, char *buf, int len) ...@@ -464,7 +464,7 @@ static int uhci_sprint_schedule(struct uhci_hcd *uhci, char *buf, int len)
} while (tmp != head); } while (tmp != head);
} }
out += sprintf(out, "Skeleton QH's\n"); out += sprintf(out, "Skeleton QHs\n");
for (i = 0; i < UHCI_NUM_SKELQH; ++i) { for (i = 0; i < UHCI_NUM_SKELQH; ++i) {
int shown = 0; int shown = 0;
......
...@@ -62,10 +62,10 @@ Alan Stern" ...@@ -62,10 +62,10 @@ Alan Stern"
/* /*
* debug = 0, no debugging messages * debug = 0, no debugging messages
* debug = 1, dump failed URB's except for stalls * debug = 1, dump failed URBs except for stalls
* debug = 2, dump all failed URB's (including stalls) * debug = 2, dump all failed URBs (including stalls)
* show all queues in /debug/uhci/[pci_addr] * show all queues in /debug/uhci/[pci_addr]
* debug = 3, show all TD's in URB's when dumping * debug = 3, show all TDs in URBs when dumping
*/ */
#ifdef DEBUG #ifdef DEBUG
static int debug = 1; static int debug = 1;
...@@ -88,7 +88,7 @@ static void uhci_get_current_frame_number(struct uhci_hcd *uhci); ...@@ -88,7 +88,7 @@ static void uhci_get_current_frame_number(struct uhci_hcd *uhci);
#define FSBR_DELAY msecs_to_jiffies(50) #define FSBR_DELAY msecs_to_jiffies(50)
/* When we timeout an idle transfer for FSBR, we'll switch it over to */ /* When we timeout an idle transfer for FSBR, we'll switch it over to */
/* depth first traversal. We'll do it in groups of this number of TD's */ /* depth first traversal. We'll do it in groups of this number of TDs */
/* to make sure it doesn't hog all of the bandwidth */ /* to make sure it doesn't hog all of the bandwidth */
#define DEPTH_INTERVAL 5 #define DEPTH_INTERVAL 5
...@@ -728,8 +728,9 @@ static int uhci_resume(struct usb_hcd *hcd) ...@@ -728,8 +728,9 @@ static int uhci_resume(struct usb_hcd *hcd)
dev_dbg(uhci_dev(uhci), "%s\n", __FUNCTION__); dev_dbg(uhci_dev(uhci), "%s\n", __FUNCTION__);
/* We aren't in D3 state anymore, we do that even if dead as I /* Since we aren't in D3 any more, it's safe to set this flag
* really don't want to keep a stale HCD_FLAG_HW_ACCESSIBLE=0 * even if the controller was dead. It might not even be dead
* any more, if the firmware or quirks code has reset it.
*/ */
set_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags); set_bit(HCD_FLAG_HW_ACCESSIBLE, &hcd->flags);
mb(); mb();
...@@ -879,7 +880,7 @@ static int __init uhci_hcd_init(void) ...@@ -879,7 +880,7 @@ static int __init uhci_hcd_init(void)
init_failed: init_failed:
if (kmem_cache_destroy(uhci_up_cachep)) if (kmem_cache_destroy(uhci_up_cachep))
warn("not all urb_priv's were freed!"); warn("not all urb_privs were freed!");
up_failed: up_failed:
debugfs_remove(uhci_debugfs_root); debugfs_remove(uhci_debugfs_root);
...@@ -897,7 +898,7 @@ static void __exit uhci_hcd_cleanup(void) ...@@ -897,7 +898,7 @@ static void __exit uhci_hcd_cleanup(void)
pci_unregister_driver(&uhci_pci_driver); pci_unregister_driver(&uhci_pci_driver);
if (kmem_cache_destroy(uhci_up_cachep)) if (kmem_cache_destroy(uhci_up_cachep))
warn("not all urb_priv's were freed!"); warn("not all urb_privs were freed!");
debugfs_remove(uhci_debugfs_root); debugfs_remove(uhci_debugfs_root);
kfree(errbuf); kfree(errbuf);
......
...@@ -223,10 +223,10 @@ static u32 inline td_status(struct uhci_td *td) { ...@@ -223,10 +223,10 @@ static u32 inline td_status(struct uhci_td *td) {
*/ */
/* /*
* The UHCI driver places Interrupt, Control and Bulk into QH's both * The UHCI driver places Interrupt, Control and Bulk into QHs both
* to group together TD's for one transfer, and also to faciliate queuing * to group together TDs for one transfer, and also to facilitate queuing
* of URB's. To make it easy to insert entries into the schedule, we have * of URBs. To make it easy to insert entries into the schedule, we have
* a skeleton of QH's for each predefined Interrupt latency, low-speed * a skeleton of QHs for each predefined Interrupt latency, low-speed
* control, full-speed control and terminating QH (see explanation for * control, full-speed control and terminating QH (see explanation for
* the terminating QH below). * the terminating QH below).
* *
...@@ -257,8 +257,8 @@ static u32 inline td_status(struct uhci_td *td) { ...@@ -257,8 +257,8 @@ static u32 inline td_status(struct uhci_td *td) {
* reclamation. * reclamation.
* *
* Isochronous transfers are stored before the start of the skeleton * Isochronous transfers are stored before the start of the skeleton
* schedule and don't use QH's. While the UHCI spec doesn't forbid the * schedule and don't use QHs. While the UHCI spec doesn't forbid the
* use of QH's for Isochronous, it doesn't use them either. And the spec * use of QHs for Isochronous, it doesn't use them either. And the spec
* says that queues never advance on an error completion status, which * says that queues never advance on an error completion status, which
* makes them totally unsuitable for Isochronous transfers. * makes them totally unsuitable for Isochronous transfers.
*/ */
...@@ -359,7 +359,7 @@ struct uhci_hcd { ...@@ -359,7 +359,7 @@ struct uhci_hcd {
struct dma_pool *td_pool; struct dma_pool *td_pool;
struct uhci_td *term_td; /* Terminating TD, see UHCI bug */ struct uhci_td *term_td; /* Terminating TD, see UHCI bug */
struct uhci_qh *skelqh[UHCI_NUM_SKELQH]; /* Skeleton QH's */ struct uhci_qh *skelqh[UHCI_NUM_SKELQH]; /* Skeleton QHs */
spinlock_t lock; spinlock_t lock;
...@@ -389,22 +389,22 @@ struct uhci_hcd { ...@@ -389,22 +389,22 @@ struct uhci_hcd {
unsigned long resuming_ports; unsigned long resuming_ports;
unsigned long ports_timeout; /* Time to stop signalling */ unsigned long ports_timeout; /* Time to stop signalling */
/* Main list of URB's currently controlled by this HC */ /* Main list of URBs currently controlled by this HC */
struct list_head urb_list; struct list_head urb_list;
/* List of QH's that are done, but waiting to be unlinked (race) */ /* List of QHs that are done, but waiting to be unlinked (race) */
struct list_head qh_remove_list; struct list_head qh_remove_list;
unsigned int qh_remove_age; /* Age in frames */ unsigned int qh_remove_age; /* Age in frames */
/* List of TD's that are done, but waiting to be freed (race) */ /* List of TDs that are done, but waiting to be freed (race) */
struct list_head td_remove_list; struct list_head td_remove_list;
unsigned int td_remove_age; /* Age in frames */ unsigned int td_remove_age; /* Age in frames */
/* List of asynchronously unlinked URB's */ /* List of asynchronously unlinked URBs */
struct list_head urb_remove_list; struct list_head urb_remove_list;
unsigned int urb_remove_age; /* Age in frames */ unsigned int urb_remove_age; /* Age in frames */
/* List of URB's awaiting completion callback */ /* List of URBs awaiting completion callback */
struct list_head complete_list; struct list_head complete_list;
int rh_numports; /* Number of root-hub ports */ int rh_numports; /* Number of root-hub ports */
......
...@@ -80,7 +80,7 @@ static inline void uhci_fill_td(struct uhci_td *td, u32 status, ...@@ -80,7 +80,7 @@ static inline void uhci_fill_td(struct uhci_td *td, u32 status,
} }
/* /*
* We insert Isochronous URB's directly into the frame list at the beginning * We insert Isochronous URBs directly into the frame list at the beginning
*/ */
static void uhci_insert_td_frame_list(struct uhci_hcd *uhci, struct uhci_td *td, unsigned framenum) static void uhci_insert_td_frame_list(struct uhci_hcd *uhci, struct uhci_td *td, unsigned framenum)
{ {
...@@ -369,7 +369,7 @@ static void uhci_append_queued_urb(struct uhci_hcd *uhci, struct urb *eurb, stru ...@@ -369,7 +369,7 @@ static void uhci_append_queued_urb(struct uhci_hcd *uhci, struct urb *eurb, stru
uhci_fixup_toggle(urb, uhci_fixup_toggle(urb,
uhci_toggle(td_token(lltd)) ^ 1)); uhci_toggle(td_token(lltd)) ^ 1));
/* All qh's in the queue need to link to the next queue */ /* All qhs in the queue need to link to the next queue */
urbp->qh->link = eurbp->qh->link; urbp->qh->link = eurbp->qh->link;
wmb(); /* Make sure we flush everything */ wmb(); /* Make sure we flush everything */
...@@ -502,7 +502,7 @@ static void uhci_destroy_urb_priv(struct uhci_hcd *uhci, struct urb *urb) ...@@ -502,7 +502,7 @@ static void uhci_destroy_urb_priv(struct uhci_hcd *uhci, struct urb *urb)
} }
/* Check to see if the remove list is empty. Set the IOC bit */ /* Check to see if the remove list is empty. Set the IOC bit */
/* to force an interrupt so we can remove the TD's*/ /* to force an interrupt so we can remove the TDs*/
if (list_empty(&uhci->td_remove_list)) if (list_empty(&uhci->td_remove_list))
uhci_set_next_interrupt(uhci); uhci_set_next_interrupt(uhci);
...@@ -612,7 +612,7 @@ static int uhci_submit_control(struct uhci_hcd *uhci, struct urb *urb, struct ur ...@@ -612,7 +612,7 @@ static int uhci_submit_control(struct uhci_hcd *uhci, struct urb *urb, struct ur
} }
/* /*
* Build the DATA TD's * Build the DATA TDs
*/ */
while (len > 0) { while (len > 0) {
int pktsze = len; int pktsze = len;
...@@ -744,7 +744,7 @@ static int uhci_result_control(struct uhci_hcd *uhci, struct urb *urb) ...@@ -744,7 +744,7 @@ static int uhci_result_control(struct uhci_hcd *uhci, struct urb *urb)
urb->actual_length = 0; urb->actual_length = 0;
/* The rest of the TD's (but the last) are data */ /* The rest of the TDs (but the last) are data */
tmp = tmp->next; tmp = tmp->next;
while (tmp != head && tmp->next != head) { while (tmp != head && tmp->next != head) {
unsigned int ctrlstat; unsigned int ctrlstat;
...@@ -848,7 +848,7 @@ static int uhci_submit_common(struct uhci_hcd *uhci, struct urb *urb, struct urb ...@@ -848,7 +848,7 @@ static int uhci_submit_common(struct uhci_hcd *uhci, struct urb *urb, struct urb
status |= TD_CTRL_SPD; status |= TD_CTRL_SPD;
/* /*
* Build the DATA TD's * Build the DATA TDs
*/ */
do { /* Allow zero length packets */ do { /* Allow zero length packets */
int pktsze = maxsze; int pktsze = maxsze;
...@@ -1025,7 +1025,7 @@ static int isochronous_find_limits(struct uhci_hcd *uhci, struct urb *urb, unsig ...@@ -1025,7 +1025,7 @@ static int isochronous_find_limits(struct uhci_hcd *uhci, struct urb *urb, unsig
list_for_each_entry(up, &uhci->urb_list, urb_list) { list_for_each_entry(up, &uhci->urb_list, urb_list) {
struct urb *u = up->urb; struct urb *u = up->urb;
/* look for pending URB's with identical pipe handle */ /* look for pending URBs with identical pipe handle */
if ((urb->pipe == u->pipe) && (urb->dev == u->dev) && if ((urb->pipe == u->pipe) && (urb->dev == u->dev) &&
(u->status == -EINPROGRESS) && (u != urb)) { (u->status == -EINPROGRESS) && (u != urb)) {
if (!last_urb) if (!last_urb)
...@@ -1355,7 +1355,7 @@ static void uhci_unlink_generic(struct uhci_hcd *uhci, struct urb *urb) ...@@ -1355,7 +1355,7 @@ static void uhci_unlink_generic(struct uhci_hcd *uhci, struct urb *urb)
uhci_delete_queued_urb(uhci, urb); uhci_delete_queued_urb(uhci, urb);
/* The interrupt loop will reclaim the QH's */ /* The interrupt loop will reclaim the QHs */
uhci_remove_qh(uhci, urbp->qh); uhci_remove_qh(uhci, urbp->qh);
urbp->qh = NULL; urbp->qh = NULL;
} }
...@@ -1413,7 +1413,7 @@ static int uhci_fsbr_timeout(struct uhci_hcd *uhci, struct urb *urb) ...@@ -1413,7 +1413,7 @@ static int uhci_fsbr_timeout(struct uhci_hcd *uhci, struct urb *urb)
list_for_each_entry(td, head, list) { list_for_each_entry(td, head, list) {
/* /*
* Make sure we don't do the last one (since it'll have the * Make sure we don't do the last one (since it'll have the
* TERM bit set) as well as we skip every so many TD's to * TERM bit set) as well as we skip every so many TDs to
* make sure it doesn't hog the bandwidth * make sure it doesn't hog the bandwidth
*/ */
if (td->list.next != head && (count % DEPTH_INTERVAL) == if (td->list.next != head && (count % DEPTH_INTERVAL) ==
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment