Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 3700
b: refs/heads/master
c: f070693
h: refs/heads/master
v: v3
  • Loading branch information
Duncan Sands authored and Greg Kroah-Hartman committed Jun 27, 2005
1 parent dfa9e8d commit 967f49d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 5 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: 843c944fb86e5e31ee7b319172e657ea22301322
refs/heads/master: f0706930091902641929f2229bfb106144782c94
5 changes: 1 addition & 4 deletions trunk/drivers/usb/atm/usbatm.c
Original file line number Diff line number Diff line change
Expand Up @@ -949,7 +949,6 @@ int usbatm_usb_probe(struct usb_interface *intf, const struct usb_device_id *id,
struct usb_device *usb_dev = interface_to_usbdev(intf);
struct usbatm_data *instance;
char *buf;
size_t instance_size = sizeof(*instance) + sizeof(struct urb *) * (num_rcv_urbs + num_snd_urbs);
int error = -ENOMEM;
int i, length;
int need_heavy;
Expand All @@ -961,14 +960,12 @@ int usbatm_usb_probe(struct usb_interface *intf, const struct usb_device_id *id,
intf->altsetting->desc.bInterfaceNumber);

/* instance init */
instance = kmalloc(instance_size, GFP_KERNEL);
instance = kcalloc(1, sizeof(*instance) + sizeof(struct urb *) * (num_rcv_urbs + num_snd_urbs), GFP_KERNEL);
if (!instance) {
dev_dbg(dev, "%s: no memory for instance data!\n", __func__);
return -ENOMEM;
}

memset(instance, 0, instance_size);

/* public fields */

instance->driver = driver;
Expand Down

0 comments on commit 967f49d

Please sign in to comment.