aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/serial/option.c
diff options
context:
space:
mode:
authorJaroslav Kysela <perex@suse.cz>2006-03-22 05:02:08 -0500
committerJaroslav Kysela <perex@suse.cz>2006-03-22 05:02:08 -0500
commit5501972e0b5857bc8354770d900ceb9b40c7f6b7 (patch)
treeff239422827c4cd54d2998f8851304255de31b38 /drivers/usb/serial/option.c
parent9d2f928ddf64ca0361562e30faf584cd33055c60 (diff)
parente952f31bce6e9f64db01f607abc46529ba57ac9e (diff)
Merge with rsync://rsync.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git
Diffstat (limited to 'drivers/usb/serial/option.c')
-rw-r--r--drivers/usb/serial/option.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/usb/serial/option.c b/drivers/usb/serial/option.c
index 52bdf6fe46f2..a8455c9e79dd 100644
--- a/drivers/usb/serial/option.c
+++ b/drivers/usb/serial/option.c
@@ -631,13 +631,12 @@ static int option_startup(struct usb_serial *serial)
631 /* Now setup per port private data */ 631 /* Now setup per port private data */
632 for (i = 0; i < serial->num_ports; i++) { 632 for (i = 0; i < serial->num_ports; i++) {
633 port = serial->port[i]; 633 port = serial->port[i];
634 portdata = kmalloc(sizeof(*portdata), GFP_KERNEL); 634 portdata = kzalloc(sizeof(*portdata), GFP_KERNEL);
635 if (!portdata) { 635 if (!portdata) {
636 dbg("%s: kmalloc for option_port_private (%d) failed!.", 636 dbg("%s: kmalloc for option_port_private (%d) failed!.",
637 __FUNCTION__, i); 637 __FUNCTION__, i);
638 return (1); 638 return (1);
639 } 639 }
640 memset(portdata, 0, sizeof(struct option_port_private));
641 640
642 usb_set_serial_port_data(port, portdata); 641 usb_set_serial_port_data(port, portdata);
643 642