Browse Source

USB: UHCI: don't allocate frame list atomically

uhci_start() is executed one time during usb_add_hcd() call and by
default UHCI frame list is allocated from atomic DMA pool.

Do non-atomic allocation of uhci->frame and free some space in
coherent atomic DMA pool.

Signed-off-by: Vladimir Zapolskiy <vladimir_zapolskiy@mentor.com>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Vladimir Zapolskiy 11 years ago
parent
commit
f589b3e040
1 changed files with 1 additions and 1 deletions
  1. 1 1
      drivers/usb/host/uhci-hcd.c

+ 1 - 1
drivers/usb/host/uhci-hcd.c

@@ -591,7 +591,7 @@ static int uhci_start(struct usb_hcd *hcd)
 
 	uhci->frame = dma_alloc_coherent(uhci_dev(uhci),
 			UHCI_NUMFRAMES * sizeof(*uhci->frame),
-			&uhci->frame_dma_handle, 0);
+			&uhci->frame_dma_handle, GFP_KERNEL);
 	if (!uhci->frame) {
 		dev_err(uhci_dev(uhci),
 			"unable to allocate consistent memory for frame list\n");