genode/repos/dde_linux/patches/mem.patch
Sebastian Sumpf 98165dd91b dde_linux: Update to Linux 3.14.5
Update patch files and file lists.
2014-08-28 12:35:55 +02:00

783 lines
28 KiB
Diff

diff --git a/drivers/hid/usbhid/hid-core.c b/drivers/hid/usbhid/hid-core.c
index 44df131..0d0aa68 100644
--- a/drivers/hid/usbhid/hid-core.c
+++ b/drivers/hid/usbhid/hid-core.c
@@ -840,7 +840,7 @@ static int hid_alloc_buffers(struct usb_device *dev, struct hid_device *hid)
&usbhid->inbuf_dma);
usbhid->outbuf = usb_alloc_coherent(dev, usbhid->bufsize, GFP_KERNEL,
&usbhid->outbuf_dma);
- usbhid->cr = kmalloc(sizeof(*usbhid->cr), GFP_KERNEL);
+ usbhid->cr = kmalloc(sizeof(*usbhid->cr), GFP_NOIO);
usbhid->ctrlbuf = usb_alloc_coherent(dev, usbhid->bufsize, GFP_KERNEL,
&usbhid->ctrlbuf_dma);
if (!usbhid->inbuf || !usbhid->outbuf || !usbhid->cr ||
@@ -998,7 +998,7 @@ static int usbhid_parse(struct hid_device *hid)
return -EINVAL;
}
- if (!(rdesc = kmalloc(rsize, GFP_KERNEL))) {
+ if (!(rdesc = kmalloc(rsize, GFP_NOIO))) {
dbg_hid("couldn't allocate rdesc memory\n");
return -ENOMEM;
}
diff --git a/drivers/net/usb/usbnet.c b/drivers/net/usb/usbnet.c
index 3242006..d03d2ed 100644
--- a/drivers/net/usb/usbnet.c
+++ b/drivers/net/usb/usbnet.c
@@ -250,7 +250,7 @@ static int init_status (struct usbnet *dev, struct usb_interface *intf)
period = max ((int) dev->status->desc.bInterval,
(dev->udev->speed == USB_SPEED_HIGH) ? 7 : 3);
- buf = kmalloc (maxp, GFP_KERNEL);
+ buf = kmalloc (maxp, GFP_NOIO);
if (buf) {
dev->interrupt = usb_alloc_urb (0, GFP_KERNEL);
if (!dev->interrupt) {
@@ -1794,7 +1794,7 @@ int usbnet_resume (struct usb_interface *intf)
if (!--dev->suspend_count) {
/* resume interrupt URB if it was previously submitted */
- __usbnet_status_start_force(dev, GFP_NOIO);
+ __usbnet_status_start_force(dev, GFP_KERNEL);
spin_lock_irq(&dev->txq.lock);
while ((res = usb_get_from_anchor(&dev->deferred))) {
@@ -1823,7 +1823,7 @@ int usbnet_resume (struct usb_interface *intf)
if (netif_device_present(dev->net) &&
!timer_pending(&dev->delay) &&
!test_bit(EVENT_RX_HALT, &dev->flags))
- rx_alloc_submit(dev, GFP_NOIO);
+ rx_alloc_submit(dev, GFP_KERNEL);
if (!(dev->txq.qlen >= TX_QLEN(dev)))
netif_tx_wake_all_queues(dev->net);
@@ -1889,7 +1889,7 @@ static int __usbnet_read_cmd(struct usbnet *dev, u8 cmd, u8 reqtype,
cmd, reqtype, value, index, size);
if (data) {
- buf = kmalloc(size, GFP_KERNEL);
+ buf = kmalloc(size, GFP_NOIO);
if (!buf)
goto out;
}
@@ -1916,7 +1916,7 @@ static int __usbnet_write_cmd(struct usbnet *dev, u8 cmd, u8 reqtype,
cmd, reqtype, value, index, size);
if (data) {
- buf = kmemdup(data, size, GFP_KERNEL);
+ buf = kmemdup(data, size, GFP_NOIO);
if (!buf)
goto out;
}
@@ -2028,7 +2028,7 @@ int usbnet_write_cmd_async(struct usbnet *dev, u8 cmd, u8 reqtype,
}
if (data) {
- buf = kmemdup(data, size, GFP_ATOMIC);
+ buf = kmemdup(data, size, GFP_NOIO);
if (!buf) {
netdev_err(dev->net, "Error allocating buffer"
" in %s!\n", __func__);
@@ -2036,7 +2036,7 @@ int usbnet_write_cmd_async(struct usbnet *dev, u8 cmd, u8 reqtype,
}
}
- req = kmalloc(sizeof(struct usb_ctrlrequest), GFP_ATOMIC);
+ req = kmalloc(sizeof(struct usb_ctrlrequest), GFP_NOIO);
if (!req)
goto fail_free_buf;
diff --git a/drivers/usb/core/config.c b/drivers/usb/core/config.c
index 062967c..f5da439 100644
--- a/drivers/usb/core/config.c
+++ b/drivers/usb/core/config.c
@@ -683,7 +683,7 @@ int usb_get_configuration(struct usb_device *dev)
if (!dev->rawdescriptors)
goto err2;
- desc = kmalloc(USB_DT_CONFIG_SIZE, GFP_KERNEL);
+ desc = kmalloc(USB_DT_CONFIG_SIZE, GFP_NOIO);
if (!desc)
goto err2;
@@ -712,7 +712,7 @@ int usb_get_configuration(struct usb_device *dev)
USB_DT_CONFIG_SIZE);
/* Now that we know the length, get the whole thing */
- bigbuffer = kmalloc(length, GFP_KERNEL);
+ bigbuffer = kmalloc(length, GFP_NOIO);
if (!bigbuffer) {
result = -ENOMEM;
goto err;
@@ -774,7 +774,7 @@ int usb_get_bos_descriptor(struct usb_device *dev)
int length, total_len, num, i;
int ret;
- bos = kzalloc(sizeof(struct usb_bos_descriptor), GFP_KERNEL);
+ bos = kzalloc(sizeof(struct usb_bos_descriptor), GFP_NOIO);
if (!bos)
return -ENOMEM;
@@ -800,7 +800,7 @@ int usb_get_bos_descriptor(struct usb_device *dev)
return -ENOMEM;
/* Now let's get the whole BOS descriptor set */
- buffer = kzalloc(total_len, GFP_KERNEL);
+ buffer = kzalloc(total_len, GFP_NOIO);
if (!buffer) {
ret = -ENOMEM;
goto err;
diff --git a/drivers/usb/core/devices.c b/drivers/usb/core/devices.c
index 2a3bbdf..c78eedd 100644
--- a/drivers/usb/core/devices.c
+++ b/drivers/usb/core/devices.c
@@ -513,7 +513,7 @@ static ssize_t usb_device_dump(char __user **buffer, size_t *nbytes,
return 0;
/* allocate 2^1 pages = 8K (on i386);
* should be more than enough for one device */
- pages_start = (char *)__get_free_pages(GFP_NOIO, 1);
+ pages_start = (char *)__get_free_pages(GFP_KERNEL, 1);
if (!pages_start)
return -ENOMEM;
diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
index d498d03..87b0b6b 100644
--- a/drivers/usb/core/hub.c
+++ b/drivers/usb/core/hub.c
@@ -1056,7 +1056,7 @@ static void hub_activate(struct usb_hub *hub, enum hub_activation_type type)
hcd = bus_to_hcd(hdev->bus);
if (hcd->driver->update_hub_device) {
ret = hcd->driver->update_hub_device(hcd, hdev,
- &hub->tt, GFP_NOIO);
+ &hub->tt, GFP_KERNEL);
if (ret < 0) {
dev_err(hub->intfdev, "Host not "
"accepting hub info "
@@ -1205,7 +1205,7 @@ static void hub_activate(struct usb_hub *hub, enum hub_activation_type type)
init3:
hub->quiescing = 0;
- status = usb_submit_urb(hub->urb, GFP_NOIO);
+ status = usb_submit_urb(hub->urb, GFP_KERNEL);
if (status < 0)
dev_err(hub->intfdev, "activate --> %d\n", status);
if (hub->has_indicators && blinkenlights)
@@ -1296,20 +1296,20 @@ static int hub_configure(struct usb_hub *hub,
unsigned unit_load;
unsigned full_load;
- hub->buffer = kmalloc(sizeof(*hub->buffer), GFP_KERNEL);
+ hub->buffer = kmalloc(sizeof(*hub->buffer), GFP_NOIO);
if (!hub->buffer) {
ret = -ENOMEM;
goto fail;
}
- hub->status = kmalloc(sizeof(*hub->status), GFP_KERNEL);
+ hub->status = kmalloc(sizeof(*hub->status), GFP_NOIO);
if (!hub->status) {
ret = -ENOMEM;
goto fail;
}
mutex_init(&hub->status_mutex);
- hub->descriptor = kmalloc(sizeof(*hub->descriptor), GFP_KERNEL);
+ hub->descriptor = kmalloc(sizeof(*hub->descriptor), GFP_NOIO);
if (!hub->descriptor) {
ret = -ENOMEM;
goto fail;
@@ -3464,9 +3464,9 @@ static int usb_req_set_sel(struct usb_device *udev, enum usb3_link_state state)
/*
* usb_enable_lpm() can be called as part of a failed device reset,
* which may be initiated by an error path of a mass storage driver.
- * Therefore, use GFP_NOIO.
+ * Therefore, use GFP_KERNEL.
*/
- sel_values = kmalloc(sizeof *(sel_values), GFP_NOIO);
+ sel_values = kmalloc(sizeof *(sel_values), GFP_KERNEL);
if (!sel_values)
return -ENOMEM;
@@ -4299,7 +4299,7 @@ check_highspeed (struct usb_hub *hub, struct usb_device *udev, int port1)
struct usb_qualifier_descriptor *qual;
int status;
- qual = kmalloc (sizeof *qual, GFP_KERNEL);
+ qual = kmalloc (sizeof *qual, GFP_NOIO);
if (qual == NULL)
return;
@@ -5030,7 +5030,7 @@ static int descriptors_changed(struct usb_device *udev,
len = max(len, old_length);
}
- buf = kmalloc(len, GFP_NOIO);
+ buf = kmalloc(len, GFP_KERNEL);
if (buf == NULL) {
dev_err(&udev->dev, "no mem to re-read configs after reset\n");
/* assume the worst */
diff --git a/drivers/usb/core/message.c b/drivers/usb/core/message.c
index f829a1a..91aa41a 100644
--- a/drivers/usb/core/message.c
+++ b/drivers/usb/core/message.c
@@ -49,7 +49,7 @@ static int usb_start_wait_urb(struct urb *urb, int timeout, int *actual_length)
init_completion(&ctx.done);
urb->context = &ctx;
urb->actual_length = 0;
- retval = usb_submit_urb(urb, GFP_NOIO);
+ retval = usb_submit_urb(urb, GFP_KERNEL);
if (unlikely(retval))
goto out;
@@ -86,7 +86,7 @@ static int usb_internal_control_msg(struct usb_device *usb_dev,
int retv;
int length;
- urb = usb_alloc_urb(0, GFP_NOIO);
+ urb = usb_alloc_urb(0, GFP_KERNEL);
if (!urb)
return -ENOMEM;
@@ -869,11 +869,11 @@ char *usb_cache_string(struct usb_device *udev, int index)
if (index <= 0)
return NULL;
- buf = kmalloc(MAX_USB_STRING_SIZE, GFP_NOIO);
+ buf = kmalloc(MAX_USB_STRING_SIZE, GFP_KERNEL);
if (buf) {
len = usb_string(udev, index, buf, MAX_USB_STRING_SIZE);
if (len > 0) {
- smallbuf = kmalloc(++len, GFP_NOIO);
+ smallbuf = kmalloc(++len, GFP_KERNEL);
if (!smallbuf)
return buf;
memcpy(smallbuf, buf, len);
@@ -944,7 +944,7 @@ int usb_get_device_descriptor(struct usb_device *dev, unsigned int size)
int usb_get_status(struct usb_device *dev, int type, int target, void *data)
{
int ret;
- __le16 *status = kmalloc(sizeof(*status), GFP_KERNEL);
+ __le16 *status = kmalloc(sizeof(*status), GFP_NOIO);
if (!status)
return -ENOMEM;
@@ -1743,7 +1743,7 @@ int usb_set_configuration(struct usb_device *dev, int configuration)
if (cp) {
nintf = cp->desc.bNumInterfaces;
new_interfaces = kmalloc(nintf * sizeof(*new_interfaces),
- GFP_NOIO);
+ GFP_KERNEL);
if (!new_interfaces) {
dev_err(&dev->dev, "Out of memory\n");
return -ENOMEM;
@@ -1752,7 +1752,7 @@ int usb_set_configuration(struct usb_device *dev, int configuration)
for (; n < nintf; ++n) {
new_interfaces[n] = kzalloc(
sizeof(struct usb_interface),
- GFP_NOIO);
+ GFP_KERNEL);
if (!new_interfaces[n]) {
dev_err(&dev->dev, "Out of memory\n");
ret = -ENOMEM;
diff --git a/drivers/usb/host/ehci-mem.c b/drivers/usb/host/ehci-mem.c
index c0fb6a8..107f41d 100644
--- a/drivers/usb/host/ehci-mem.c
+++ b/drivers/usb/host/ehci-mem.c
@@ -82,7 +82,7 @@ static struct ehci_qh *ehci_qh_alloc (struct ehci_hcd *ehci, gfp_t flags)
struct ehci_qh *qh;
dma_addr_t dma;
- qh = kzalloc(sizeof *qh, GFP_ATOMIC);
+ qh = kzalloc(sizeof *qh, GFP_NOIO);
if (!qh)
goto done;
qh->hw = (struct ehci_qh_hw *)
diff --git a/drivers/usb/host/xhci-hub.c b/drivers/usb/host/xhci-hub.c
index 9992fbf..10f539c 100644
--- a/drivers/usb/host/xhci-hub.c
+++ b/drivers/usb/host/xhci-hub.c
@@ -276,7 +276,7 @@ static int xhci_stop_device(struct xhci_hcd *xhci, int slot_id, int suspend)
ret = 0;
virt_dev = xhci->devs[slot_id];
- cmd = xhci_alloc_command(xhci, false, true, GFP_NOIO);
+ cmd = xhci_alloc_command(xhci, false, true, GFP_KERNEL);
if (!cmd) {
xhci_dbg(xhci, "Couldn't allocate command structure.\n");
return -ENOMEM;
diff --git a/drivers/usb/host/xhci.c b/drivers/usb/host/xhci.c
index cca2896..9b5c07e 100644
--- a/drivers/usb/host/xhci.c
+++ b/drivers/usb/host/xhci.c
@@ -1279,7 +1279,7 @@ int xhci_urb_enqueue(struct usb_hcd *hcd, struct urb *urb, gfp_t mem_flags)
size = 1;
urb_priv = kzalloc(sizeof(struct urb_priv) +
- size * sizeof(struct xhci_td *), mem_flags);
+ size * sizeof(struct xhci_td *), GFP_NOIO);
if (!urb_priv)
return -ENOMEM;
@@ -1722,7 +1722,7 @@ int xhci_add_endpoint(struct usb_hcd *hcd, struct usb_device *udev,
* process context, not interrupt context (or so documenation
* for usb_set_interface() and usb_set_configuration() claim).
*/
- if (xhci_endpoint_init(xhci, virt_dev, udev, ep, GFP_NOIO) < 0) {
+ if (xhci_endpoint_init(xhci, virt_dev, udev, ep, GFP_KERNEL) < 0) {
dev_dbg(&udev->dev, "%s - could not initialize ep %#x\n",
__func__, ep->desc.bEndpointAddress);
return -ENOMEM;
@@ -3435,10 +3435,10 @@ int xhci_discover_or_reset_device(struct usb_hcd *hcd, struct usb_device *udev)
/* Allocate the command structure that holds the struct completion.
* Assume we're in process context, since the normal device reset
* process has to wait for the device anyway. Storage devices are
- * reset as part of error handling, so use GFP_NOIO instead of
+ * reset as part of error handling, so use GFP_KERNEL instead of
* GFP_KERNEL.
*/
- reset_device_cmd = xhci_alloc_command(xhci, false, true, GFP_NOIO);
+ reset_device_cmd = xhci_alloc_command(xhci, false, true, GFP_KERNEL);
if (!reset_device_cmd) {
xhci_dbg(xhci, "Couldn't allocate command structure.\n");
return -ENOMEM;
@@ -3682,11 +3682,11 @@ int xhci_alloc_dev(struct usb_hcd *hcd, struct usb_device *udev)
}
spin_unlock_irqrestore(&xhci->lock, flags);
}
- /* Use GFP_NOIO, since this function can be called from
+ /* Use GFP_KERNEL, since this function can be called from
* xhci_discover_or_reset_device(), which may be called as part of
* mass storage driver error handling.
*/
- if (!xhci_alloc_virt_device(xhci, xhci->slot_id, udev, GFP_NOIO)) {
+ if (!xhci_alloc_virt_device(xhci, xhci->slot_id, udev, GFP_KERNEL)) {
xhci_warn(xhci, "Could not allocate xHCI USB device data structures\n");
goto disable_slot;
}
diff --git a/drivers/usb/storage/alauda.c b/drivers/usb/storage/alauda.c
index 6636a58..0bedf73 100644
--- a/drivers/usb/storage/alauda.c
+++ b/drivers/usb/storage/alauda.c
@@ -443,8 +443,8 @@ static int alauda_init_media(struct us_data *us)
num_zones = MEDIA_INFO(us).capacity >> (MEDIA_INFO(us).zoneshift
+ MEDIA_INFO(us).blockshift + MEDIA_INFO(us).pageshift);
- MEDIA_INFO(us).pba_to_lba = kcalloc(num_zones, sizeof(u16*), GFP_NOIO);
- MEDIA_INFO(us).lba_to_pba = kcalloc(num_zones, sizeof(u16*), GFP_NOIO);
+ MEDIA_INFO(us).pba_to_lba = kcalloc(num_zones, sizeof(u16*), GFP_KERNEL);
+ MEDIA_INFO(us).lba_to_pba = kcalloc(num_zones, sizeof(u16*), GFP_KERNEL);
if (alauda_reset_media(us) != USB_STOR_XFER_GOOD)
return USB_STOR_TRANSPORT_ERROR;
@@ -572,8 +572,8 @@ static int alauda_read_map(struct us_data *us, unsigned int zone)
unsigned int lba_offset, lba_real, blocknum;
unsigned int zone_base_lba = zone * uzonesize;
unsigned int zone_base_pba = zone * zonesize;
- u16 *lba_to_pba = kcalloc(zonesize, sizeof(u16), GFP_NOIO);
- u16 *pba_to_lba = kcalloc(zonesize, sizeof(u16), GFP_NOIO);
+ u16 *lba_to_pba = kcalloc(zonesize, sizeof(u16), GFP_KERNEL);
+ u16 *pba_to_lba = kcalloc(zonesize, sizeof(u16), GFP_KERNEL);
if (lba_to_pba == NULL || pba_to_lba == NULL) {
result = USB_STOR_TRANSPORT_ERROR;
goto error;
@@ -931,7 +931,7 @@ static int alauda_read_data(struct us_data *us, unsigned long address,
*/
len = min(sectors, blocksize) * (pagesize + 64);
- buffer = kmalloc(len, GFP_NOIO);
+ buffer = kmalloc(len, GFP_KERNEL);
if (buffer == NULL) {
printk(KERN_WARNING "alauda_read_data: Out of memory\n");
return USB_STOR_TRANSPORT_ERROR;
@@ -1023,7 +1023,7 @@ static int alauda_write_data(struct us_data *us, unsigned long address,
*/
len = min(sectors, blocksize) * pagesize;
- buffer = kmalloc(len, GFP_NOIO);
+ buffer = kmalloc(len, GFP_KERNEL);
if (buffer == NULL) {
printk(KERN_WARNING "alauda_write_data: Out of memory\n");
return USB_STOR_TRANSPORT_ERROR;
@@ -1033,7 +1033,7 @@ static int alauda_write_data(struct us_data *us, unsigned long address,
* We also need a temporary block buffer, where we read in the old data,
* overwrite parts with the new data, and manipulate the redundancy data
*/
- blockbuffer = kmalloc((pagesize + 64) * blocksize, GFP_NOIO);
+ blockbuffer = kmalloc((pagesize + 64) * blocksize, GFP_KERNEL);
if (blockbuffer == NULL) {
printk(KERN_WARNING "alauda_write_data: Out of memory\n");
kfree(buffer);
@@ -1111,7 +1111,7 @@ static int init_alauda(struct us_data *us)
struct usb_host_interface *altsetting = us->pusb_intf->cur_altsetting;
nand_init_ecc();
- us->extra = kzalloc(sizeof(struct alauda_info), GFP_NOIO);
+ us->extra = kzalloc(sizeof(struct alauda_info), GFP_KERNEL);
if (!us->extra)
return USB_STOR_TRANSPORT_ERROR;
diff --git a/drivers/usb/storage/datafab.c b/drivers/usb/storage/datafab.c
index 7b17c21..941f8c7 100644
--- a/drivers/usb/storage/datafab.c
+++ b/drivers/usb/storage/datafab.c
@@ -174,7 +174,7 @@ static int datafab_read_data(struct us_data *us,
// bounce buffer and the actual transfer buffer.
alloclen = min(totallen, 65536u);
- buffer = kmalloc(alloclen, GFP_NOIO);
+ buffer = kmalloc(alloclen, GFP_KERNEL);
if (buffer == NULL)
return USB_STOR_TRANSPORT_ERROR;
@@ -258,7 +258,7 @@ static int datafab_write_data(struct us_data *us,
// bounce buffer and the actual transfer buffer.
alloclen = min(totallen, 65536u);
- buffer = kmalloc(alloclen, GFP_NOIO);
+ buffer = kmalloc(alloclen, GFP_KERNEL);
if (buffer == NULL)
return USB_STOR_TRANSPORT_ERROR;
@@ -337,7 +337,7 @@ static int datafab_determine_lun(struct us_data *us,
return USB_STOR_TRANSPORT_ERROR;
memcpy(command, scommand, 8);
- buf = kmalloc(512, GFP_NOIO);
+ buf = kmalloc(512, GFP_KERNEL);
if (!buf)
return USB_STOR_TRANSPORT_ERROR;
@@ -408,7 +408,7 @@ static int datafab_id_device(struct us_data *us,
}
memcpy(command, scommand, 8);
- reply = kmalloc(512, GFP_NOIO);
+ reply = kmalloc(512, GFP_KERNEL);
if (!reply)
return USB_STOR_TRANSPORT_ERROR;
@@ -564,7 +564,7 @@ static int datafab_transport(struct scsi_cmnd *srb, struct us_data *us)
};
if (!us->extra) {
- us->extra = kzalloc(sizeof(struct datafab_info), GFP_NOIO);
+ us->extra = kzalloc(sizeof(struct datafab_info), GFP_KERNEL);
if (!us->extra)
return USB_STOR_TRANSPORT_ERROR;
diff --git a/drivers/usb/storage/jumpshot.c b/drivers/usb/storage/jumpshot.c
index 563078b..4b2a45e 100644
--- a/drivers/usb/storage/jumpshot.c
+++ b/drivers/usb/storage/jumpshot.c
@@ -187,7 +187,7 @@ static int jumpshot_read_data(struct us_data *us,
// bounce buffer and the actual transfer buffer.
alloclen = min(totallen, 65536u);
- buffer = kmalloc(alloclen, GFP_NOIO);
+ buffer = kmalloc(alloclen, GFP_KERNEL);
if (buffer == NULL)
return USB_STOR_TRANSPORT_ERROR;
@@ -264,7 +264,7 @@ static int jumpshot_write_data(struct us_data *us,
// bounce buffer and the actual transfer buffer.
alloclen = min(totallen, 65536u);
- buffer = kmalloc(alloclen, GFP_NOIO);
+ buffer = kmalloc(alloclen, GFP_KERNEL);
if (buffer == NULL)
return USB_STOR_TRANSPORT_ERROR;
@@ -339,7 +339,7 @@ static int jumpshot_id_device(struct us_data *us,
command[0] = 0xE0;
command[1] = 0xEC;
- reply = kmalloc(512, GFP_NOIO);
+ reply = kmalloc(512, GFP_KERNEL);
if (!reply)
return USB_STOR_TRANSPORT_ERROR;
@@ -491,7 +491,7 @@ static int jumpshot_transport(struct scsi_cmnd *srb, struct us_data *us)
};
if (!us->extra) {
- us->extra = kzalloc(sizeof(struct jumpshot_info), GFP_NOIO);
+ us->extra = kzalloc(sizeof(struct jumpshot_info), GFP_KERNEL);
if (!us->extra)
return USB_STOR_TRANSPORT_ERROR;
diff --git a/drivers/usb/storage/karma.c b/drivers/usb/storage/karma.c
index 94d16ee..5c0dffa 100644
--- a/drivers/usb/storage/karma.c
+++ b/drivers/usb/storage/karma.c
@@ -182,11 +182,11 @@ static void rio_karma_destructor(void *extra)
static int rio_karma_init(struct us_data *us)
{
int ret = 0;
- struct karma_data *data = kzalloc(sizeof(struct karma_data), GFP_NOIO);
+ struct karma_data *data = kzalloc(sizeof(struct karma_data), GFP_KERNEL);
if (!data)
goto out;
- data->recv = kmalloc(RIO_RECV_LEN, GFP_NOIO);
+ data->recv = kmalloc(RIO_RECV_LEN, GFP_KERNEL);
if (!data->recv) {
kfree(data);
goto out;
diff --git a/drivers/usb/storage/onetouch.c b/drivers/usb/storage/onetouch.c
index 74e2aa2..f18c9ed 100644
--- a/drivers/usb/storage/onetouch.c
+++ b/drivers/usb/storage/onetouch.c
@@ -162,7 +162,7 @@ static void usb_onetouch_pm_hook(struct us_data *us, int action)
usb_kill_urb(onetouch->irq);
break;
case US_RESUME:
- if (usb_submit_urb(onetouch->irq, GFP_NOIO) != 0)
+ if (usb_submit_urb(onetouch->irq, GFP_KERNEL) != 0)
dev_err(&onetouch->irq->dev->dev,
"usb_submit_urb failed\n");
break;
diff --git a/drivers/usb/storage/realtek_cr.c b/drivers/usb/storage/realtek_cr.c
index 281be56..0c62dbd 100644
--- a/drivers/usb/storage/realtek_cr.c
+++ b/drivers/usb/storage/realtek_cr.c
@@ -368,7 +368,7 @@ static int rts51x_read_mem(struct us_data *us, u16 addr, u8 *data, u16 len)
u8 cmnd[12] = { 0 };
u8 *buf;
- buf = kmalloc(len, GFP_NOIO);
+ buf = kmalloc(len, GFP_KERNEL);
if (buf == NULL)
return USB_STOR_TRANSPORT_ERROR;
@@ -399,7 +399,7 @@ static int rts51x_write_mem(struct us_data *us, u16 addr, u8 *data, u16 len)
u8 cmnd[12] = { 0 };
u8 *buf;
- buf = kmemdup(data, len, GFP_NOIO);
+ buf = kmemdup(data, len, GFP_KERNEL);
if (buf == NULL)
return USB_STOR_TRANSPORT_ERROR;
@@ -428,7 +428,7 @@ static int rts51x_read_status(struct us_data *us,
u8 cmnd[12] = { 0 };
u8 *buf;
- buf = kmalloc(len, GFP_NOIO);
+ buf = kmalloc(len, GFP_KERNEL);
if (buf == NULL)
return USB_STOR_TRANSPORT_ERROR;
@@ -512,7 +512,7 @@ static int __do_config_autodelink(struct us_data *us, u8 *data, u16 len)
usb_stor_dbg(us, "addr = 0xfe47, len = %d\n", len);
- buf = kmemdup(data, len, GFP_NOIO);
+ buf = kmemdup(data, len, GFP_KERNEL);
if (!buf)
return USB_STOR_TRANSPORT_ERROR;
diff --git a/drivers/usb/storage/sddr09.c b/drivers/usb/storage/sddr09.c
index 073a2c3..72d4346 100644
--- a/drivers/usb/storage/sddr09.c
+++ b/drivers/usb/storage/sddr09.c
@@ -685,7 +685,7 @@ sddr09_read_sg_test_only(struct us_data *us) {
return result;
}
- buf = kmalloc(bulklen, GFP_NOIO);
+ buf = kmalloc(bulklen, GFP_KERNEL);
if (!buf)
return -ENOMEM;
@@ -761,7 +761,7 @@ sddr09_read_data(struct us_data *us,
// bounce buffer and the actual transfer buffer.
len = min(sectors, (unsigned int) info->blocksize) * info->pagesize;
- buffer = kmalloc(len, GFP_NOIO);
+ buffer = kmalloc(len, GFP_KERNEL);
if (buffer == NULL) {
printk(KERN_WARNING "sddr09_read_data: Out of memory\n");
return -ENOMEM;
@@ -991,7 +991,7 @@ sddr09_write_data(struct us_data *us,
pagelen = (1 << info->pageshift) + (1 << CONTROL_SHIFT);
blocklen = (pagelen << info->blockshift);
- blockbuffer = kmalloc(blocklen, GFP_NOIO);
+ blockbuffer = kmalloc(blocklen, GFP_KERNEL);
if (!blockbuffer) {
printk(KERN_WARNING "sddr09_write_data: Out of memory\n");
return -ENOMEM;
@@ -1002,7 +1002,7 @@ sddr09_write_data(struct us_data *us,
// at a time between the bounce buffer and the actual transfer buffer.
len = min(sectors, (unsigned int) info->blocksize) * info->pagesize;
- buffer = kmalloc(len, GFP_NOIO);
+ buffer = kmalloc(len, GFP_KERNEL);
if (buffer == NULL) {
printk(KERN_WARNING "sddr09_write_data: Out of memory\n");
kfree(blockbuffer);
@@ -1221,7 +1221,7 @@ sddr09_read_map(struct us_data *us) {
alloc_blocks = min(numblocks, SDDR09_READ_MAP_BUFSZ >> CONTROL_SHIFT);
alloc_len = (alloc_blocks << CONTROL_SHIFT);
- buffer = kmalloc(alloc_len, GFP_NOIO);
+ buffer = kmalloc(alloc_len, GFP_KERNEL);
if (buffer == NULL) {
printk(KERN_WARNING "sddr09_read_map: out of memory\n");
result = -1;
@@ -1233,8 +1233,8 @@ sddr09_read_map(struct us_data *us) {
kfree(info->lba_to_pba);
kfree(info->pba_to_lba);
- info->lba_to_pba = kmalloc(numblocks*sizeof(int), GFP_NOIO);
- info->pba_to_lba = kmalloc(numblocks*sizeof(int), GFP_NOIO);
+ info->lba_to_pba = kmalloc(numblocks*sizeof(int), GFP_KERNEL);
+ info->pba_to_lba = kmalloc(numblocks*sizeof(int), GFP_KERNEL);
if (info->lba_to_pba == NULL || info->pba_to_lba == NULL) {
printk(KERN_WARNING "sddr09_read_map: out of memory\n");
@@ -1429,7 +1429,7 @@ sddr09_common_init(struct us_data *us) {
return -EINVAL;
}
- us->extra = kzalloc(sizeof(struct sddr09_card_info), GFP_NOIO);
+ us->extra = kzalloc(sizeof(struct sddr09_card_info), GFP_KERNEL);
if (!us->extra)
return -ENOMEM;
us->extra_destructor = sddr09_card_info_destructor;
diff --git a/drivers/usb/storage/sddr55.c b/drivers/usb/storage/sddr55.c
index aacedef..50550e0 100644
--- a/drivers/usb/storage/sddr55.c
+++ b/drivers/usb/storage/sddr55.c
@@ -215,7 +215,7 @@ static int sddr55_read_data(struct us_data *us,
len = min((unsigned int) sectors, (unsigned int) info->blocksize >>
info->smallpageshift) * PAGESIZE;
- buffer = kmalloc(len, GFP_NOIO);
+ buffer = kmalloc(len, GFP_KERNEL);
if (buffer == NULL)
return USB_STOR_TRANSPORT_ERROR; /* out of memory */
offset = 0;
@@ -342,7 +342,7 @@ static int sddr55_write_data(struct us_data *us,
len = min((unsigned int) sectors, (unsigned int) info->blocksize >>
info->smallpageshift) * PAGESIZE;
- buffer = kmalloc(len, GFP_NOIO);
+ buffer = kmalloc(len, GFP_KERNEL);
if (buffer == NULL)
return USB_STOR_TRANSPORT_ERROR;
offset = 0;
@@ -658,7 +658,7 @@ static int sddr55_read_map(struct us_data *us) {
numblocks = info->capacity >> (info->blockshift + info->pageshift);
- buffer = kmalloc( numblocks * 2, GFP_NOIO );
+ buffer = kmalloc( numblocks * 2, GFP_KERNEL );
if (!buffer)
return -1;
@@ -691,8 +691,8 @@ static int sddr55_read_map(struct us_data *us) {
kfree(info->lba_to_pba);
kfree(info->pba_to_lba);
- info->lba_to_pba = kmalloc(numblocks*sizeof(int), GFP_NOIO);
- info->pba_to_lba = kmalloc(numblocks*sizeof(int), GFP_NOIO);
+ info->lba_to_pba = kmalloc(numblocks*sizeof(int), GFP_KERNEL);
+ info->pba_to_lba = kmalloc(numblocks*sizeof(int), GFP_KERNEL);
if (info->lba_to_pba == NULL || info->pba_to_lba == NULL) {
kfree(info->lba_to_pba);
@@ -796,7 +796,7 @@ static int sddr55_transport(struct scsi_cmnd *srb, struct us_data *us)
if (!us->extra) {
us->extra = kzalloc(
- sizeof(struct sddr55_card_info), GFP_NOIO);
+ sizeof(struct sddr55_card_info), GFP_KERNEL);
if (!us->extra)
return USB_STOR_TRANSPORT_ERROR;
us->extra_destructor = sddr55_card_info_destructor;
diff --git a/drivers/usb/storage/shuttle_usbat.c b/drivers/usb/storage/shuttle_usbat.c
index 4ef2a80..b3968db 100644
--- a/drivers/usb/storage/shuttle_usbat.c
+++ b/drivers/usb/storage/shuttle_usbat.c
@@ -1071,7 +1071,7 @@ static int usbat_flash_get_sector_count(struct us_data *us,
if (!us || !info)
return USB_STOR_TRANSPORT_ERROR;
- reply = kmalloc(512, GFP_NOIO);
+ reply = kmalloc(512, GFP_KERNEL);
if (!reply)
return USB_STOR_TRANSPORT_ERROR;
@@ -1156,7 +1156,7 @@ static int usbat_flash_read_data(struct us_data *us,
*/
alloclen = min(totallen, 65536u);
- buffer = kmalloc(alloclen, GFP_NOIO);
+ buffer = kmalloc(alloclen, GFP_KERNEL);
if (buffer == NULL)
return USB_STOR_TRANSPORT_ERROR;
@@ -1247,7 +1247,7 @@ static int usbat_flash_write_data(struct us_data *us,
*/
alloclen = min(totallen, 65536u);
- buffer = kmalloc(alloclen, GFP_NOIO);
+ buffer = kmalloc(alloclen, GFP_KERNEL);
if (buffer == NULL)
return USB_STOR_TRANSPORT_ERROR;
@@ -1350,7 +1350,7 @@ static int usbat_hp8200e_handle_read10(struct us_data *us,
len = (65535/srb->transfersize) * srb->transfersize;
usb_stor_dbg(us, "Max read is %d bytes\n", len);
len = min(len, scsi_bufflen(srb));
- buffer = kmalloc(len, GFP_NOIO);
+ buffer = kmalloc(len, GFP_KERNEL);
if (buffer == NULL) /* bloody hell! */
return USB_STOR_TRANSPORT_FAILED;
sector = short_pack(data[7+3], data[7+2]);
@@ -1461,7 +1461,7 @@ static int init_usbat(struct us_data *us, int devicetype)
unsigned char subcountL = USBAT_ATA_LBA_ME;
unsigned char *status = us->iobuf;
- us->extra = kzalloc(sizeof(struct usbat_info), GFP_NOIO);
+ us->extra = kzalloc(sizeof(struct usbat_info), GFP_KERNEL);
if (!us->extra)
return 1;
diff --git a/drivers/usb/storage/transport.c b/drivers/usb/storage/transport.c
index 22c7d43..783f745 100644
--- a/drivers/usb/storage/transport.c
+++ b/drivers/usb/storage/transport.c
@@ -151,7 +151,7 @@ static int usb_stor_msg_common(struct us_data *us, int timeout)
us->current_urb->transfer_dma = us->iobuf_dma;
/* submit the URB */
- status = usb_submit_urb(us->current_urb, GFP_NOIO);
+ status = usb_submit_urb(us->current_urb, GFP_KERNEL);
if (status) {
/* something went wrong */
return status;
@@ -427,7 +427,7 @@ static int usb_stor_bulk_transfer_sglist(struct us_data *us, unsigned int pipe,
/* initialize the scatter-gather request block */
usb_stor_dbg(us, "xfer %u bytes, %d entries\n", length, num_sg);
result = usb_sg_init(&us->current_sg, us->pusb_dev, pipe, 0,
- sg, num_sg, length, GFP_NOIO);
+ sg, num_sg, length, GFP_KERNEL);
if (result) {
usb_stor_dbg(us, "usb_sg_init returned %d\n", result);
return USB_STOR_XFER_ERROR;
diff --git a/drivers/usb/storage/usb.c b/drivers/usb/storage/usb.c
index 1c0b89f..e34e087 100644
--- a/drivers/usb/storage/usb.c
+++ b/drivers/usb/storage/usb.c
@@ -442,7 +442,7 @@ static int associate_dev(struct us_data *us, struct usb_interface *intf)
usb_set_intfdata(intf, us);
/* Allocate the control/setup and DMA-mapped buffers */
- us->cr = kmalloc(sizeof(*us->cr), GFP_KERNEL);
+ us->cr = kmalloc(sizeof(*us->cr), GFP_NOIO);
if (!us->cr)
return -ENOMEM;