diff options
author | Johan Hovold <jhovold@gmail.com> | 2013-04-16 18:01:19 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-04-17 10:05:34 -0700 |
commit | 81f58c67b1d71b3a1a6c2bb077844249790807c8 (patch) | |
tree | ac5422619e6f43b38bd29236c436b627e057f01a /drivers/usb | |
parent | 2bef64b89ae315e7935067ce8db901783deaf857 (diff) | |
download | op-kernel-dev-81f58c67b1d71b3a1a6c2bb077844249790807c8.zip op-kernel-dev-81f58c67b1d71b3a1a6c2bb077844249790807c8.tar.gz |
USB: omninet: use kzalloc for private data
Make sure the port private data, which contains the write sequence
number, is cleared at allocation.
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb')
-rw-r--r-- | drivers/usb/serial/omninet.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/usb/serial/omninet.c b/drivers/usb/serial/omninet.c index 1e1cafe..ea1105c 100644 --- a/drivers/usb/serial/omninet.c +++ b/drivers/usb/serial/omninet.c @@ -112,7 +112,7 @@ static int omninet_port_probe(struct usb_serial_port *port) { struct omninet_data *od; - od = kmalloc(sizeof(struct omninet_data), GFP_KERNEL); + od = kzalloc(sizeof(*od), GFP_KERNEL); if (!od) return -ENOMEM; |