aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/host/ehci-dbg.c
diff options
context:
space:
mode:
authorStefan Roese <ml@stefan-roese.de>2007-05-01 12:29:37 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2007-07-12 19:29:45 -0400
commit6dbd682b7c6d58916096616cdf94852641bc09d9 (patch)
tree74bc2fa9038a426ac5f81969ad85cae5e4262501 /drivers/usb/host/ehci-dbg.c
parent196705c9bbc03540429b0f7cf9ee35c2f928a534 (diff)
USB: EHCI support for big-endian descriptors
This patch implements supports for EHCI controllers whose in-memory data structures are represented in big-endian format. This is needed (unfortunately) for the AMCC PPC440EPx SoC EHCI controller; the EHCI spec doesn't specify little-endian format, although that's what most other implementations use. The guts of the patch are to introduce the hc32 type and change all references from le32 to hc32. All access routines are converted from cpu_to_le32(...) to cpu_to_hc32(ehci, ...) and similar for the other "direction". (This is the same approach used with OHCI.) David fixed: Whitespace fixes; refresh against ehci cpufreq patch; move glue for that PPC driver to the patch adding it; fix free symbol capture bugs in modified "constant" macros; and make "hc32" etc be "le32" unless we really need the BE options, so "sparse" can do some real good. Signed-off-by: Stefan Roese <sr@denx.de> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/host/ehci-dbg.c')
-rw-r--r--drivers/usb/host/ehci-dbg.c161
1 files changed, 85 insertions, 76 deletions
diff --git a/drivers/usb/host/ehci-dbg.c b/drivers/usb/host/ehci-dbg.c
index 43eddaecc3dd..5bb3d0962ebe 100644
--- a/drivers/usb/host/ehci-dbg.c
+++ b/drivers/usb/host/ehci-dbg.c
@@ -52,7 +52,7 @@ static void dbg_hcs_params (struct ehci_hcd *ehci, char *label)
52 HCS_INDICATOR (params) ? " ind" : "", 52 HCS_INDICATOR (params) ? " ind" : "",
53 HCS_N_CC (params), 53 HCS_N_CC (params),
54 HCS_N_PCC (params), 54 HCS_N_PCC (params),
55 HCS_PORTROUTED (params) ? "" : " ordered", 55 HCS_PORTROUTED (params) ? "" : " ordered",
56 HCS_PPC (params) ? "" : " !ppc", 56 HCS_PPC (params) ? "" : " !ppc",
57 HCS_N_PORTS (params) 57 HCS_N_PORTS (params)
58 ); 58 );
@@ -91,20 +91,20 @@ static void dbg_hcc_params (struct ehci_hcd *ehci, char *label)
91 91
92 if (HCC_ISOC_CACHE (params)) { 92 if (HCC_ISOC_CACHE (params)) {
93 ehci_dbg (ehci, 93 ehci_dbg (ehci,
94 "%s hcc_params %04x caching frame %s%s%s\n", 94 "%s hcc_params %04x caching frame %s%s%s\n",
95 label, params, 95 label, params,
96 HCC_PGM_FRAMELISTLEN (params) ? "256/512/1024" : "1024", 96 HCC_PGM_FRAMELISTLEN(params) ? "256/512/1024" : "1024",
97 HCC_CANPARK (params) ? " park" : "", 97 HCC_CANPARK(params) ? " park" : "",
98 HCC_64BIT_ADDR (params) ? " 64 bit addr" : ""); 98 HCC_64BIT_ADDR(params) ? " 64 bit addr" : "");
99 } else { 99 } else {
100 ehci_dbg (ehci, 100 ehci_dbg (ehci,
101 "%s hcc_params %04x thresh %d uframes %s%s%s\n", 101 "%s hcc_params %04x thresh %d uframes %s%s%s\n",
102 label, 102 label,
103 params, 103 params,
104 HCC_ISOC_THRES (params), 104 HCC_ISOC_THRES(params),
105 HCC_PGM_FRAMELISTLEN (params) ? "256/512/1024" : "1024", 105 HCC_PGM_FRAMELISTLEN(params) ? "256/512/1024" : "1024",
106 HCC_CANPARK (params) ? " park" : "", 106 HCC_CANPARK(params) ? " park" : "",
107 HCC_64BIT_ADDR (params) ? " 64 bit addr" : ""); 107 HCC_64BIT_ADDR(params) ? " 64 bit addr" : "");
108 } 108 }
109} 109}
110#else 110#else
@@ -118,17 +118,17 @@ static inline void dbg_hcc_params (struct ehci_hcd *ehci, char *label) {}
118static void __attribute__((__unused__)) 118static void __attribute__((__unused__))
119dbg_qtd (const char *label, struct ehci_hcd *ehci, struct ehci_qtd *qtd) 119dbg_qtd (const char *label, struct ehci_hcd *ehci, struct ehci_qtd *qtd)
120{ 120{
121 ehci_dbg (ehci, "%s td %p n%08x %08x t%08x p0=%08x\n", label, qtd, 121 ehci_dbg(ehci, "%s td %p n%08x %08x t%08x p0=%08x\n", label, qtd,
122 le32_to_cpup (&qtd->hw_next), 122 hc32_to_cpup(ehci, &qtd->hw_next),
123 le32_to_cpup (&qtd->hw_alt_next), 123 hc32_to_cpup(ehci, &qtd->hw_alt_next),
124 le32_to_cpup (&qtd->hw_token), 124 hc32_to_cpup(ehci, &qtd->hw_token),
125 le32_to_cpup (&qtd->hw_buf [0])); 125 hc32_to_cpup(ehci, &qtd->hw_buf [0]));
126 if (qtd->hw_buf [1]) 126 if (qtd->hw_buf [1])
127 ehci_dbg (ehci, " p1=%08x p2=%08x p3=%08x p4=%08x\n", 127 ehci_dbg(ehci, " p1=%08x p2=%08x p3=%08x p4=%08x\n",
128 le32_to_cpup (&qtd->hw_buf [1]), 128 hc32_to_cpup(ehci, &qtd->hw_buf[1]),
129 le32_to_cpup (&qtd->hw_buf [2]), 129 hc32_to_cpup(ehci, &qtd->hw_buf[2]),
130 le32_to_cpup (&qtd->hw_buf [3]), 130 hc32_to_cpup(ehci, &qtd->hw_buf[3]),
131 le32_to_cpup (&qtd->hw_buf [4])); 131 hc32_to_cpup(ehci, &qtd->hw_buf[4]));
132} 132}
133 133
134static void __attribute__((__unused__)) 134static void __attribute__((__unused__))
@@ -144,26 +144,27 @@ static void __attribute__((__unused__))
144dbg_itd (const char *label, struct ehci_hcd *ehci, struct ehci_itd *itd) 144dbg_itd (const char *label, struct ehci_hcd *ehci, struct ehci_itd *itd)
145{ 145{
146 ehci_dbg (ehci, "%s [%d] itd %p, next %08x, urb %p\n", 146 ehci_dbg (ehci, "%s [%d] itd %p, next %08x, urb %p\n",
147 label, itd->frame, itd, le32_to_cpu(itd->hw_next), itd->urb); 147 label, itd->frame, itd, hc32_to_cpu(ehci, itd->hw_next),
148 itd->urb);
148 ehci_dbg (ehci, 149 ehci_dbg (ehci,
149 " trans: %08x %08x %08x %08x %08x %08x %08x %08x\n", 150 " trans: %08x %08x %08x %08x %08x %08x %08x %08x\n",
150 le32_to_cpu(itd->hw_transaction[0]), 151 hc32_to_cpu(ehci, itd->hw_transaction[0]),
151 le32_to_cpu(itd->hw_transaction[1]), 152 hc32_to_cpu(ehci, itd->hw_transaction[1]),
152 le32_to_cpu(itd->hw_transaction[2]), 153 hc32_to_cpu(ehci, itd->hw_transaction[2]),
153 le32_to_cpu(itd->hw_transaction[3]), 154 hc32_to_cpu(ehci, itd->hw_transaction[3]),
154 le32_to_cpu(itd->hw_transaction[4]), 155 hc32_to_cpu(ehci, itd->hw_transaction[4]),
155 le32_to_cpu(itd->hw_transaction[5]), 156 hc32_to_cpu(ehci, itd->hw_transaction[5]),
156 le32_to_cpu(itd->hw_transaction[6]), 157 hc32_to_cpu(ehci, itd->hw_transaction[6]),
157 le32_to_cpu(itd->hw_transaction[7])); 158 hc32_to_cpu(ehci, itd->hw_transaction[7]));
158 ehci_dbg (ehci, 159 ehci_dbg (ehci,
159 " buf: %08x %08x %08x %08x %08x %08x %08x\n", 160 " buf: %08x %08x %08x %08x %08x %08x %08x\n",
160 le32_to_cpu(itd->hw_bufp[0]), 161 hc32_to_cpu(ehci, itd->hw_bufp[0]),
161 le32_to_cpu(itd->hw_bufp[1]), 162 hc32_to_cpu(ehci, itd->hw_bufp[1]),
162 le32_to_cpu(itd->hw_bufp[2]), 163 hc32_to_cpu(ehci, itd->hw_bufp[2]),
163 le32_to_cpu(itd->hw_bufp[3]), 164 hc32_to_cpu(ehci, itd->hw_bufp[3]),
164 le32_to_cpu(itd->hw_bufp[4]), 165 hc32_to_cpu(ehci, itd->hw_bufp[4]),
165 le32_to_cpu(itd->hw_bufp[5]), 166 hc32_to_cpu(ehci, itd->hw_bufp[5]),
166 le32_to_cpu(itd->hw_bufp[6])); 167 hc32_to_cpu(ehci, itd->hw_bufp[6]));
167 ehci_dbg (ehci, " index: %d %d %d %d %d %d %d %d\n", 168 ehci_dbg (ehci, " index: %d %d %d %d %d %d %d %d\n",
168 itd->index[0], itd->index[1], itd->index[2], 169 itd->index[0], itd->index[1], itd->index[2],
169 itd->index[3], itd->index[4], itd->index[5], 170 itd->index[3], itd->index[4], itd->index[5],
@@ -174,14 +175,15 @@ static void __attribute__((__unused__))
174dbg_sitd (const char *label, struct ehci_hcd *ehci, struct ehci_sitd *sitd) 175dbg_sitd (const char *label, struct ehci_hcd *ehci, struct ehci_sitd *sitd)
175{ 176{
176 ehci_dbg (ehci, "%s [%d] sitd %p, next %08x, urb %p\n", 177 ehci_dbg (ehci, "%s [%d] sitd %p, next %08x, urb %p\n",
177 label, sitd->frame, sitd, le32_to_cpu(sitd->hw_next), sitd->urb); 178 label, sitd->frame, sitd, hc32_to_cpu(ehci, sitd->hw_next),
179 sitd->urb);
178 ehci_dbg (ehci, 180 ehci_dbg (ehci,
179 " addr %08x sched %04x result %08x buf %08x %08x\n", 181 " addr %08x sched %04x result %08x buf %08x %08x\n",
180 le32_to_cpu(sitd->hw_fullspeed_ep), 182 hc32_to_cpu(ehci, sitd->hw_fullspeed_ep),
181 le32_to_cpu(sitd->hw_uframe), 183 hc32_to_cpu(ehci, sitd->hw_uframe),
182 le32_to_cpu(sitd->hw_results), 184 hc32_to_cpu(ehci, sitd->hw_results),
183 le32_to_cpu(sitd->hw_buf [0]), 185 hc32_to_cpu(ehci, sitd->hw_buf[0]),
184 le32_to_cpu(sitd->hw_buf [1])); 186 hc32_to_cpu(ehci, sitd->hw_buf[1]));
185} 187}
186 188
187static int __attribute__((__unused__)) 189static int __attribute__((__unused__))
@@ -267,8 +269,7 @@ dbg_port_buf (char *buf, unsigned len, const char *label, int port, u32 status)
267 (status & PORT_PEC) ? " PEC" : "", 269 (status & PORT_PEC) ? " PEC" : "",
268 (status & PORT_PE) ? " PE" : "", 270 (status & PORT_PE) ? " PE" : "",
269 (status & PORT_CSC) ? " CSC" : "", 271 (status & PORT_CSC) ? " CSC" : "",
270 (status & PORT_CONNECT) ? " CONNECT" : "" 272 (status & PORT_CONNECT) ? " CONNECT" : "");
271 );
272} 273}
273 274
274#else 275#else
@@ -332,9 +333,10 @@ static inline void remove_debug_files (struct ehci_hcd *bus) { }
332 default: tmp = '?'; break; \ 333 default: tmp = '?'; break; \
333 }; tmp; }) 334 }; tmp; })
334 335
335static inline char token_mark (__le32 token) 336static inline char token_mark(struct ehci_hcd *ehci, __hc32 token)
336{ 337{
337 __u32 v = le32_to_cpu (token); 338 __u32 v = hc32_to_cpu(ehci, token);
339
338 if (v & QTD_STS_ACTIVE) 340 if (v & QTD_STS_ACTIVE)
339 return '*'; 341 return '*';
340 if (v & QTD_STS_HALT) 342 if (v & QTD_STS_HALT)
@@ -360,46 +362,48 @@ static void qh_lines (
360 unsigned size = *sizep; 362 unsigned size = *sizep;
361 char *next = *nextp; 363 char *next = *nextp;
362 char mark; 364 char mark;
365 u32 list_end = EHCI_LIST_END(ehci);
363 366
364 if (qh->hw_qtd_next == EHCI_LIST_END) /* NEC does this */ 367 if (qh->hw_qtd_next == list_end) /* NEC does this */
365 mark = '@'; 368 mark = '@';
366 else 369 else
367 mark = token_mark (qh->hw_token); 370 mark = token_mark(ehci, qh->hw_token);
368 if (mark == '/') { /* qh_alt_next controls qh advance? */ 371 if (mark == '/') { /* qh_alt_next controls qh advance? */
369 if ((qh->hw_alt_next & QTD_MASK) == ehci->async->hw_alt_next) 372 if ((qh->hw_alt_next & QTD_MASK(ehci))
373 == ehci->async->hw_alt_next)
370 mark = '#'; /* blocked */ 374 mark = '#'; /* blocked */
371 else if (qh->hw_alt_next == EHCI_LIST_END) 375 else if (qh->hw_alt_next == list_end)
372 mark = '.'; /* use hw_qtd_next */ 376 mark = '.'; /* use hw_qtd_next */
373 /* else alt_next points to some other qtd */ 377 /* else alt_next points to some other qtd */
374 } 378 }
375 scratch = le32_to_cpup (&qh->hw_info1); 379 scratch = hc32_to_cpup(ehci, &qh->hw_info1);
376 hw_curr = (mark == '*') ? le32_to_cpup (&qh->hw_current) : 0; 380 hw_curr = (mark == '*') ? hc32_to_cpup(ehci, &qh->hw_current) : 0;
377 temp = scnprintf (next, size, 381 temp = scnprintf (next, size,
378 "qh/%p dev%d %cs ep%d %08x %08x (%08x%c %s nak%d)", 382 "qh/%p dev%d %cs ep%d %08x %08x (%08x%c %s nak%d)",
379 qh, scratch & 0x007f, 383 qh, scratch & 0x007f,
380 speed_char (scratch), 384 speed_char (scratch),
381 (scratch >> 8) & 0x000f, 385 (scratch >> 8) & 0x000f,
382 scratch, le32_to_cpup (&qh->hw_info2), 386 scratch, hc32_to_cpup(ehci, &qh->hw_info2),
383 le32_to_cpup (&qh->hw_token), mark, 387 hc32_to_cpup(ehci, &qh->hw_token), mark,
384 (__constant_cpu_to_le32 (QTD_TOGGLE) & qh->hw_token) 388 (cpu_to_hc32(ehci, QTD_TOGGLE) & qh->hw_token)
385 ? "data1" : "data0", 389 ? "data1" : "data0",
386 (le32_to_cpup (&qh->hw_alt_next) >> 1) & 0x0f); 390 (hc32_to_cpup(ehci, &qh->hw_alt_next) >> 1) & 0x0f);
387 size -= temp; 391 size -= temp;
388 next += temp; 392 next += temp;
389 393
390 /* hc may be modifying the list as we read it ... */ 394 /* hc may be modifying the list as we read it ... */
391 list_for_each (entry, &qh->qtd_list) { 395 list_for_each (entry, &qh->qtd_list) {
392 td = list_entry (entry, struct ehci_qtd, qtd_list); 396 td = list_entry (entry, struct ehci_qtd, qtd_list);
393 scratch = le32_to_cpup (&td->hw_token); 397 scratch = hc32_to_cpup(ehci, &td->hw_token);
394 mark = ' '; 398 mark = ' ';
395 if (hw_curr == td->qtd_dma) 399 if (hw_curr == td->qtd_dma)
396 mark = '*'; 400 mark = '*';
397 else if (qh->hw_qtd_next == cpu_to_le32(td->qtd_dma)) 401 else if (qh->hw_qtd_next == cpu_to_hc32(ehci, td->qtd_dma))
398 mark = '+'; 402 mark = '+';
399 else if (QTD_LENGTH (scratch)) { 403 else if (QTD_LENGTH (scratch)) {
400 if (td->hw_alt_next == ehci->async->hw_alt_next) 404 if (td->hw_alt_next == ehci->async->hw_alt_next)
401 mark = '#'; 405 mark = '#';
402 else if (td->hw_alt_next != EHCI_LIST_END) 406 else if (td->hw_alt_next != list_end)
403 mark = '/'; 407 mark = '/';
404 } 408 }
405 temp = snprintf (next, size, 409 temp = snprintf (next, size,
@@ -490,7 +494,7 @@ show_periodic (struct class_device *class_dev, char *buf)
490 unsigned temp, size, seen_count; 494 unsigned temp, size, seen_count;
491 char *next; 495 char *next;
492 unsigned i; 496 unsigned i;
493 __le32 tag; 497 __hc32 tag;
494 498
495 if (!(seen = kmalloc (DBG_SCHED_LIMIT * sizeof *seen, GFP_ATOMIC))) 499 if (!(seen = kmalloc (DBG_SCHED_LIMIT * sizeof *seen, GFP_ATOMIC)))
496 return 0; 500 return 0;
@@ -514,18 +518,19 @@ show_periodic (struct class_device *class_dev, char *buf)
514 p = ehci->pshadow [i]; 518 p = ehci->pshadow [i];
515 if (likely (!p.ptr)) 519 if (likely (!p.ptr))
516 continue; 520 continue;
517 tag = Q_NEXT_TYPE (ehci->periodic [i]); 521 tag = Q_NEXT_TYPE(ehci, ehci->periodic [i]);
518 522
519 temp = scnprintf (next, size, "%4d: ", i); 523 temp = scnprintf (next, size, "%4d: ", i);
520 size -= temp; 524 size -= temp;
521 next += temp; 525 next += temp;
522 526
523 do { 527 do {
524 switch (tag) { 528 switch (hc32_to_cpu(ehci, tag)) {
525 case Q_TYPE_QH: 529 case Q_TYPE_QH:
526 temp = scnprintf (next, size, " qh%d-%04x/%p", 530 temp = scnprintf (next, size, " qh%d-%04x/%p",
527 p.qh->period, 531 p.qh->period,
528 le32_to_cpup (&p.qh->hw_info2) 532 hc32_to_cpup(ehci,
533 &p.qh->hw_info2)
529 /* uframe masks */ 534 /* uframe masks */
530 & (QH_CMASK | QH_SMASK), 535 & (QH_CMASK | QH_SMASK),
531 p.qh); 536 p.qh);
@@ -543,7 +548,7 @@ show_periodic (struct class_device *class_dev, char *buf)
543 } 548 }
544 /* show more info the first time around */ 549 /* show more info the first time around */
545 if (temp == seen_count && p.ptr) { 550 if (temp == seen_count && p.ptr) {
546 u32 scratch = le32_to_cpup ( 551 u32 scratch = hc32_to_cpup(ehci,
547 &p.qh->hw_info1); 552 &p.qh->hw_info1);
548 struct ehci_qtd *qtd; 553 struct ehci_qtd *qtd;
549 char *type = ""; 554 char *type = "";
@@ -554,7 +559,8 @@ show_periodic (struct class_device *class_dev, char *buf)
554 &p.qh->qtd_list, 559 &p.qh->qtd_list,
555 qtd_list) { 560 qtd_list) {
556 temp++; 561 temp++;
557 switch (0x03 & (le32_to_cpu ( 562 switch (0x03 & (hc32_to_cpu(
563 ehci,
558 qtd->hw_token) >> 8)) { 564 qtd->hw_token) >> 8)) {
559 case 0: type = "out"; continue; 565 case 0: type = "out"; continue;
560 case 1: type = "in"; continue; 566 case 1: type = "in"; continue;
@@ -576,7 +582,7 @@ show_periodic (struct class_device *class_dev, char *buf)
576 } else 582 } else
577 temp = 0; 583 temp = 0;
578 if (p.qh) { 584 if (p.qh) {
579 tag = Q_NEXT_TYPE (p.qh->hw_next); 585 tag = Q_NEXT_TYPE(ehci, p.qh->hw_next);
580 p = p.qh->qh_next; 586 p = p.qh->qh_next;
581 } 587 }
582 break; 588 break;
@@ -584,23 +590,23 @@ show_periodic (struct class_device *class_dev, char *buf)
584 temp = scnprintf (next, size, 590 temp = scnprintf (next, size,
585 " fstn-%8x/%p", p.fstn->hw_prev, 591 " fstn-%8x/%p", p.fstn->hw_prev,
586 p.fstn); 592 p.fstn);
587 tag = Q_NEXT_TYPE (p.fstn->hw_next); 593 tag = Q_NEXT_TYPE(ehci, p.fstn->hw_next);
588 p = p.fstn->fstn_next; 594 p = p.fstn->fstn_next;
589 break; 595 break;
590 case Q_TYPE_ITD: 596 case Q_TYPE_ITD:
591 temp = scnprintf (next, size, 597 temp = scnprintf (next, size,
592 " itd/%p", p.itd); 598 " itd/%p", p.itd);
593 tag = Q_NEXT_TYPE (p.itd->hw_next); 599 tag = Q_NEXT_TYPE(ehci, p.itd->hw_next);
594 p = p.itd->itd_next; 600 p = p.itd->itd_next;
595 break; 601 break;
596 case Q_TYPE_SITD: 602 case Q_TYPE_SITD:
597 temp = scnprintf (next, size, 603 temp = scnprintf (next, size,
598 " sitd%d-%04x/%p", 604 " sitd%d-%04x/%p",
599 p.sitd->stream->interval, 605 p.sitd->stream->interval,
600 le32_to_cpup (&p.sitd->hw_uframe) 606 hc32_to_cpup(ehci, &p.sitd->hw_uframe)
601 & 0x0000ffff, 607 & 0x0000ffff,
602 p.sitd); 608 p.sitd);
603 tag = Q_NEXT_TYPE (p.sitd->hw_next); 609 tag = Q_NEXT_TYPE(ehci, p.sitd->hw_next);
604 p = p.sitd->sitd_next; 610 p = p.sitd->sitd_next;
605 break; 611 break;
606 } 612 }
@@ -673,7 +679,8 @@ show_registers (struct class_device *class_dev, char *buf)
673 unsigned count = 256/4; 679 unsigned count = 256/4;
674 680
675 pdev = to_pci_dev(ehci_to_hcd(ehci)->self.controller); 681 pdev = to_pci_dev(ehci_to_hcd(ehci)->self.controller);
676 offset = HCC_EXT_CAPS (ehci_readl(ehci, &ehci->caps->hcc_params)); 682 offset = HCC_EXT_CAPS(ehci_readl(ehci,
683 &ehci->caps->hcc_params));
677 while (offset && count--) { 684 while (offset && count--) {
678 pci_read_config_dword (pdev, offset, &cap); 685 pci_read_config_dword (pdev, offset, &cap);
679 switch (cap & 0xff) { 686 switch (cap & 0xff) {
@@ -740,14 +747,16 @@ show_registers (struct class_device *class_dev, char *buf)
740 747
741 for (i = 1; i <= HCS_N_PORTS (ehci->hcs_params); i++) { 748 for (i = 1; i <= HCS_N_PORTS (ehci->hcs_params); i++) {
742 temp = dbg_port_buf (scratch, sizeof scratch, label, i, 749 temp = dbg_port_buf (scratch, sizeof scratch, label, i,
743 ehci_readl(ehci, &ehci->regs->port_status [i - 1])); 750 ehci_readl(ehci,
751 &ehci->regs->port_status[i - 1]));
744 temp = scnprintf (next, size, fmt, temp, scratch); 752 temp = scnprintf (next, size, fmt, temp, scratch);
745 size -= temp; 753 size -= temp;
746 next += temp; 754 next += temp;
747 if (i == HCS_DEBUG_PORT(ehci->hcs_params) && ehci->debug) { 755 if (i == HCS_DEBUG_PORT(ehci->hcs_params) && ehci->debug) {
748 temp = scnprintf (next, size, 756 temp = scnprintf (next, size,
749 " debug control %08x\n", 757 " debug control %08x\n",
750 ehci_readl(ehci, &ehci->debug->control)); 758 ehci_readl(ehci,
759 &ehci->debug->control));
751 size -= temp; 760 size -= temp;
752 next += temp; 761 next += temp;
753 } 762 }