Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 165031
b: refs/heads/master
c: 87a5d15
h: refs/heads/master
i:
  165029: 48315e4
  165027: c523d48
  165023: 61e8a60
v: v3
  • Loading branch information
Jason Wessel authored and Greg Kroah-Hartman committed Sep 23, 2009
1 parent afa7f8f commit 3f7a212
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 7 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: df6c516900d48df3581b23d37d6516a22ec4f2ca
refs/heads/master: 87a5d15154ae2389251e6ad99216a846b905375c
22 changes: 16 additions & 6 deletions trunk/drivers/usb/early/ehci-dbgp.c
Original file line number Diff line number Diff line change
Expand Up @@ -700,17 +700,27 @@ int __init early_dbgp_init(char *s)
static void early_dbgp_write(struct console *con, const char *str, u32 n)
{
int chunk, ret;
char buf[DBGP_MAX_PACKET];
int use_cr = 0;

if (!ehci_debug)
return;
while (n > 0) {
chunk = n;
if (chunk > DBGP_MAX_PACKET)
chunk = DBGP_MAX_PACKET;
for (chunk = 0; chunk < DBGP_MAX_PACKET && n > 0;
str++, chunk++, n--) {
if (!use_cr && *str == '\n') {
use_cr = 1;
buf[chunk] = '\r';
str--;
n++;
continue;
}
if (use_cr)
use_cr = 0;
buf[chunk] = *str;
}
ret = dbgp_bulk_write(USB_DEBUG_DEVNUM,
dbgp_endpoint_out, str, chunk);
str += chunk;
n -= chunk;
dbgp_endpoint_out, buf, chunk);
}
}

Expand Down

0 comments on commit 3f7a212

Please sign in to comment.