Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 289667
b: refs/heads/master
c: 8111e4e
h: refs/heads/master
i:
  289665: f9ddcf9
  289663: bc9c1a2
v: v3
  • Loading branch information
Greg Kroah-Hartman committed Mar 8, 2012
1 parent 0621dcd commit 0ab2a06
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 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: dd63b0b4d6d036e1d5f7008c97c30789415489de
refs/heads/master: 8111e4ecf9373f6d76504416b0e76b18372f3598
7 changes: 2 additions & 5 deletions trunk/drivers/usb/serial/metro-usb.c
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ static bool debug;

static void metrousb_read_int_callback(struct urb *urb)
{
struct usb_serial_port *port = (struct usb_serial_port *)urb->context;
struct usb_serial_port *port = urb->context;
struct metrousb_private *metro_priv = usb_get_serial_port_data(port);
struct tty_struct *tty;
unsigned char *data = urb->transfer_buffer;
Expand Down Expand Up @@ -253,13 +253,10 @@ static int metrousb_startup(struct usb_serial *serial)
port = serial->port[i];

/* Declare memory. */
metro_priv = kmalloc(sizeof(struct metrousb_private), GFP_KERNEL);
metro_priv = kzalloc(sizeof(struct metrousb_private), GFP_KERNEL);
if (!metro_priv)
return -ENOMEM;

/* Clear memory. */
memset(metro_priv, 0x00, sizeof(struct metrousb_private));

/* Initialize memory. */
spin_lock_init(&metro_priv->lock);
usb_set_serial_port_data(port, metro_priv);
Expand Down

0 comments on commit 0ab2a06

Please sign in to comment.