diff options
Diffstat (limited to 'drivers/usb')
| -rw-r--r-- | drivers/usb/core/hcd.c | 6 | ||||
| -rw-r--r-- | drivers/usb/gadget/function/f_midi.c | 3 | ||||
| -rw-r--r-- | drivers/usb/gadget/function/f_midi2.c | 3 | ||||
| -rw-r--r-- | drivers/usb/gadget/udc/bdc/bdc_core.c | 3 | ||||
| -rw-r--r-- | drivers/usb/host/uhci-hcd.c | 3 | ||||
| -rw-r--r-- | drivers/usb/host/xhci-mtk-sch.c | 3 | ||||
| -rw-r--r-- | drivers/usb/mon/mon_bin.c | 3 | ||||
| -rw-r--r-- | drivers/usb/serial/mos7840.c | 3 | ||||
| -rw-r--r-- | drivers/usb/typec/ucsi/ucsi.c | 3 | ||||
| -rw-r--r-- | drivers/usb/usbip/vhci_sysfs.c | 6 |
10 files changed, 12 insertions, 24 deletions
diff --git a/drivers/usb/core/hcd.c b/drivers/usb/core/hcd.c index c0e2fa2bd282..dee842ea6931 100644 --- a/drivers/usb/core/hcd.c +++ b/drivers/usb/core/hcd.c @@ -2567,16 +2567,14 @@ struct usb_hcd *__usb_create_hcd(const struct hc_driver *driver, if (!hcd) return NULL; if (primary_hcd == NULL) { - hcd->address0_mutex = kmalloc_obj(*hcd->address0_mutex, - GFP_KERNEL); + hcd->address0_mutex = kmalloc_obj(*hcd->address0_mutex); if (!hcd->address0_mutex) { kfree(hcd); dev_dbg(dev, "hcd address0 mutex alloc failed\n"); return NULL; } mutex_init(hcd->address0_mutex); - hcd->bandwidth_mutex = kmalloc_obj(*hcd->bandwidth_mutex, - GFP_KERNEL); + hcd->bandwidth_mutex = kmalloc_obj(*hcd->bandwidth_mutex); if (!hcd->bandwidth_mutex) { kfree(hcd->address0_mutex); kfree(hcd); diff --git a/drivers/usb/gadget/function/f_midi.c b/drivers/usb/gadget/function/f_midi.c index 218c180980f7..4d9e4bd700d8 100644 --- a/drivers/usb/gadget/function/f_midi.c +++ b/drivers/usb/gadget/function/f_midi.c @@ -931,8 +931,7 @@ static int f_midi_bind(struct usb_configuration *c, struct usb_function *f) goto fail; /* allocate temporary function list */ - midi_function = kzalloc_objs(*midi_function, (MAX_PORTS * 4) + 11, - GFP_KERNEL); + midi_function = kzalloc_objs(*midi_function, (MAX_PORTS * 4) + 11); if (!midi_function) { status = -ENOMEM; goto fail; diff --git a/drivers/usb/gadget/function/f_midi2.c b/drivers/usb/gadget/function/f_midi2.c index 61ce54c3392b..4c663431e99f 100644 --- a/drivers/usb/gadget/function/f_midi2.c +++ b/drivers/usb/gadget/function/f_midi2.c @@ -1187,8 +1187,7 @@ static int f_midi2_init_ep(struct f_midi2 *midi2, struct f_midi2_ep *ep, return -ENODEV; usb_ep->complete = complete; - usb_ep->reqs = kzalloc_objs(*usb_ep->reqs, midi2->info.num_reqs, - GFP_KERNEL); + usb_ep->reqs = kzalloc_objs(*usb_ep->reqs, midi2->info.num_reqs); if (!usb_ep->reqs) return -ENOMEM; for (i = 0; i < midi2->info.num_reqs; i++) { diff --git a/drivers/usb/gadget/udc/bdc/bdc_core.c b/drivers/usb/gadget/udc/bdc/bdc_core.c index 51602d9eca02..438201dc96ca 100644 --- a/drivers/usb/gadget/udc/bdc/bdc_core.c +++ b/drivers/usb/gadget/udc/bdc/bdc_core.c @@ -397,8 +397,7 @@ static int bdc_mem_alloc(struct bdc *bdc) "ieps:%d eops:%d num_eps:%d\n", num_ieps, num_oeps, bdc->num_eps); /* allocate array of ep pointers */ - bdc->bdc_ep_array = kzalloc_objs(struct bdc_ep *, bdc->num_eps, - GFP_KERNEL); + bdc->bdc_ep_array = kzalloc_objs(struct bdc_ep *, bdc->num_eps); if (!bdc->bdc_ep_array) goto fail; diff --git a/drivers/usb/host/uhci-hcd.c b/drivers/usb/host/uhci-hcd.c index 027c3798a581..433d64a5fab5 100644 --- a/drivers/usb/host/uhci-hcd.c +++ b/drivers/usb/host/uhci-hcd.c @@ -603,8 +603,7 @@ static int uhci_start(struct usb_hcd *hcd) goto err_alloc_frame; } - uhci->frame_cpu = kzalloc_objs(*uhci->frame_cpu, UHCI_NUMFRAMES, - GFP_KERNEL); + uhci->frame_cpu = kzalloc_objs(*uhci->frame_cpu, UHCI_NUMFRAMES); if (!uhci->frame_cpu) goto err_alloc_frame_cpu; diff --git a/drivers/usb/host/xhci-mtk-sch.c b/drivers/usb/host/xhci-mtk-sch.c index e3550acaf1a0..583623cd4d8f 100644 --- a/drivers/usb/host/xhci-mtk-sch.c +++ b/drivers/usb/host/xhci-mtk-sch.c @@ -179,8 +179,7 @@ static struct mu3h_sch_tt *find_tt(struct usb_device *udev) if (utt->multi) { tt_index = utt->hcpriv; if (!tt_index) { /* Create the index array */ - tt_index = kzalloc_objs(*tt_index, utt->hub->maxchild, - GFP_KERNEL); + tt_index = kzalloc_objs(*tt_index, utt->hub->maxchild); if (!tt_index) return ERR_PTR(-ENOMEM); utt->hcpriv = tt_index; diff --git a/drivers/usb/mon/mon_bin.c b/drivers/usb/mon/mon_bin.c index d84749829963..687f6a8981f3 100644 --- a/drivers/usb/mon/mon_bin.c +++ b/drivers/usb/mon/mon_bin.c @@ -1029,8 +1029,7 @@ static long mon_bin_ioctl(struct file *file, unsigned int cmd, unsigned long arg return -EINVAL; size = CHUNK_ALIGN(arg); - vec = kzalloc_objs(struct mon_pgmap, size / CHUNK_SIZE, - GFP_KERNEL); + vec = kzalloc_objs(struct mon_pgmap, size / CHUNK_SIZE); if (vec == NULL) { ret = -ENOMEM; break; diff --git a/drivers/usb/serial/mos7840.c b/drivers/usb/serial/mos7840.c index cc663d8191bd..c0d0c24b074b 100644 --- a/drivers/usb/serial/mos7840.c +++ b/drivers/usb/serial/mos7840.c @@ -1677,8 +1677,7 @@ static int mos7840_port_probe(struct usb_serial_port *port) /* Initialize LED timers */ if (mos7840_port->has_led) { mos7840_port->led_urb = usb_alloc_urb(0, GFP_KERNEL); - mos7840_port->led_dr = kmalloc_obj(*mos7840_port->led_dr, - GFP_KERNEL); + mos7840_port->led_dr = kmalloc_obj(*mos7840_port->led_dr); if (!mos7840_port->led_urb || !mos7840_port->led_dr) { status = -ENOMEM; goto error; diff --git a/drivers/usb/typec/ucsi/ucsi.c b/drivers/usb/typec/ucsi/ucsi.c index ba2c1e549968..f38a4d7ebc42 100644 --- a/drivers/usb/typec/ucsi/ucsi.c +++ b/drivers/usb/typec/ucsi/ucsi.c @@ -1865,8 +1865,7 @@ static int ucsi_init(struct ucsi *ucsi) } /* Allocate the connectors. Released in ucsi_unregister() */ - connector = kzalloc_objs(*connector, ucsi->cap.num_connectors + 1, - GFP_KERNEL); + connector = kzalloc_objs(*connector, ucsi->cap.num_connectors + 1); if (!connector) { ret = -ENOMEM; goto err_reset; diff --git a/drivers/usb/usbip/vhci_sysfs.c b/drivers/usb/usbip/vhci_sysfs.c index f7929b4a43a4..bfc10f665e52 100644 --- a/drivers/usb/usbip/vhci_sysfs.c +++ b/drivers/usb/usbip/vhci_sysfs.c @@ -476,8 +476,7 @@ static int init_status_attrs(void) { int id; - status_attrs = kzalloc_objs(struct status_attr, vhci_num_controllers, - GFP_KERNEL); + status_attrs = kzalloc_objs(struct status_attr, vhci_num_controllers); if (status_attrs == NULL) return -ENOMEM; @@ -501,8 +500,7 @@ int vhci_init_attr_group(void) struct attribute **attrs; int ret, i; - attrs = kzalloc_objs(struct attribute *, (vhci_num_controllers + 5), - GFP_KERNEL); + attrs = kzalloc_objs(struct attribute *, (vhci_num_controllers + 5)); if (attrs == NULL) return -ENOMEM; |
