diff options
Diffstat (limited to 'drivers/usb/class/cdc-acm.c')
-rw-r--r-- | drivers/usb/class/cdc-acm.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/usb/class/cdc-acm.c b/drivers/usb/class/cdc-acm.c index 0c2f14ff9696..61d75507d5d0 100644 --- a/drivers/usb/class/cdc-acm.c +++ b/drivers/usb/class/cdc-acm.c | |||
@@ -1201,7 +1201,7 @@ made_compressed_probe: | |||
1201 | if (rcv->urb == NULL) { | 1201 | if (rcv->urb == NULL) { |
1202 | dev_dbg(&intf->dev, | 1202 | dev_dbg(&intf->dev, |
1203 | "out of memory (read urbs usb_alloc_urb)\n"); | 1203 | "out of memory (read urbs usb_alloc_urb)\n"); |
1204 | goto alloc_fail7; | 1204 | goto alloc_fail6; |
1205 | } | 1205 | } |
1206 | 1206 | ||
1207 | rcv->urb->transfer_flags |= URB_NO_TRANSFER_DMA_MAP; | 1207 | rcv->urb->transfer_flags |= URB_NO_TRANSFER_DMA_MAP; |
@@ -1225,7 +1225,7 @@ made_compressed_probe: | |||
1225 | if (snd->urb == NULL) { | 1225 | if (snd->urb == NULL) { |
1226 | dev_dbg(&intf->dev, | 1226 | dev_dbg(&intf->dev, |
1227 | "out of memory (write urbs usb_alloc_urb)"); | 1227 | "out of memory (write urbs usb_alloc_urb)"); |
1228 | goto alloc_fail7; | 1228 | goto alloc_fail8; |
1229 | } | 1229 | } |
1230 | 1230 | ||
1231 | if (usb_endpoint_xfer_int(epwrite)) | 1231 | if (usb_endpoint_xfer_int(epwrite)) |
@@ -1264,6 +1264,7 @@ made_compressed_probe: | |||
1264 | i = device_create_file(&intf->dev, | 1264 | i = device_create_file(&intf->dev, |
1265 | &dev_attr_iCountryCodeRelDate); | 1265 | &dev_attr_iCountryCodeRelDate); |
1266 | if (i < 0) { | 1266 | if (i < 0) { |
1267 | device_remove_file(&intf->dev, &dev_attr_wCountryCodes); | ||
1267 | kfree(acm->country_codes); | 1268 | kfree(acm->country_codes); |
1268 | goto skip_countries; | 1269 | goto skip_countries; |
1269 | } | 1270 | } |
@@ -1300,6 +1301,7 @@ alloc_fail8: | |||
1300 | usb_free_urb(acm->wb[i].urb); | 1301 | usb_free_urb(acm->wb[i].urb); |
1301 | alloc_fail7: | 1302 | alloc_fail7: |
1302 | acm_read_buffers_free(acm); | 1303 | acm_read_buffers_free(acm); |
1304 | alloc_fail6: | ||
1303 | for (i = 0; i < num_rx_buf; i++) | 1305 | for (i = 0; i < num_rx_buf; i++) |
1304 | usb_free_urb(acm->ru[i].urb); | 1306 | usb_free_urb(acm->ru[i].urb); |
1305 | usb_free_urb(acm->ctrlurb); | 1307 | usb_free_urb(acm->ctrlurb); |