[PATCH] USB: Fix kmalloc's flags type in USB
Greg, This patch fixes the kmalloc() flags argument type in USB subsystem; hopefully all of its occurences. The patch was made against patch-2.6.12-git2 from Jun 20. Cleanup of flags for kmalloc() in USB subsystem. Signed-off-by: Olav Kongas <ok@artecdesign.ee> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
17f8bb7312
commit
5db539e49f
@ -106,7 +106,7 @@ void hcd_buffer_destroy (struct usb_hcd *hcd)
|
||||
void *hcd_buffer_alloc (
|
||||
struct usb_bus *bus,
|
||||
size_t size,
|
||||
int mem_flags,
|
||||
unsigned mem_flags,
|
||||
dma_addr_t *dma
|
||||
)
|
||||
{
|
||||
|
@ -1112,7 +1112,7 @@ static void urb_unlink (struct urb *urb)
|
||||
* expects usb_submit_urb() to have sanity checked and conditioned all
|
||||
* inputs in the urb
|
||||
*/
|
||||
static int hcd_submit_urb (struct urb *urb, int mem_flags)
|
||||
static int hcd_submit_urb (struct urb *urb, unsigned mem_flags)
|
||||
{
|
||||
int status;
|
||||
struct usb_hcd *hcd = urb->dev->bus->hcpriv;
|
||||
|
@ -142,12 +142,12 @@ struct hcd_timeout { /* timeouts we allocate */
|
||||
|
||||
struct usb_operations {
|
||||
int (*get_frame_number) (struct usb_device *usb_dev);
|
||||
int (*submit_urb) (struct urb *urb, int mem_flags);
|
||||
int (*submit_urb) (struct urb *urb, unsigned mem_flags);
|
||||
int (*unlink_urb) (struct urb *urb, int status);
|
||||
|
||||
/* allocate dma-consistent buffer for URB_DMA_NOMAPPING */
|
||||
void *(*buffer_alloc)(struct usb_bus *bus, size_t size,
|
||||
int mem_flags,
|
||||
unsigned mem_flags,
|
||||
dma_addr_t *dma);
|
||||
void (*buffer_free)(struct usb_bus *bus, size_t size,
|
||||
void *addr, dma_addr_t dma);
|
||||
@ -200,7 +200,7 @@ struct hc_driver {
|
||||
int (*urb_enqueue) (struct usb_hcd *hcd,
|
||||
struct usb_host_endpoint *ep,
|
||||
struct urb *urb,
|
||||
int mem_flags);
|
||||
unsigned mem_flags);
|
||||
int (*urb_dequeue) (struct usb_hcd *hcd, struct urb *urb);
|
||||
|
||||
/* hw synch, freeing endpoint resources that urb_dequeue can't */
|
||||
@ -247,7 +247,7 @@ int hcd_buffer_create (struct usb_hcd *hcd);
|
||||
void hcd_buffer_destroy (struct usb_hcd *hcd);
|
||||
|
||||
void *hcd_buffer_alloc (struct usb_bus *bus, size_t size,
|
||||
int mem_flags, dma_addr_t *dma);
|
||||
unsigned mem_flags, dma_addr_t *dma);
|
||||
void hcd_buffer_free (struct usb_bus *bus, size_t size,
|
||||
void *addr, dma_addr_t dma);
|
||||
|
||||
|
@ -320,7 +320,7 @@ int usb_sg_init (
|
||||
struct scatterlist *sg,
|
||||
int nents,
|
||||
size_t length,
|
||||
int mem_flags
|
||||
unsigned mem_flags
|
||||
)
|
||||
{
|
||||
int i;
|
||||
|
@ -60,7 +60,7 @@ void usb_init_urb(struct urb *urb)
|
||||
*
|
||||
* The driver must call usb_free_urb() when it is finished with the urb.
|
||||
*/
|
||||
struct urb *usb_alloc_urb(int iso_packets, int mem_flags)
|
||||
struct urb *usb_alloc_urb(int iso_packets, unsigned mem_flags)
|
||||
{
|
||||
struct urb *urb;
|
||||
|
||||
@ -224,7 +224,7 @@ struct urb * usb_get_urb(struct urb *urb)
|
||||
* GFP_NOIO, unless b) or c) apply
|
||||
*
|
||||
*/
|
||||
int usb_submit_urb(struct urb *urb, int mem_flags)
|
||||
int usb_submit_urb(struct urb *urb, unsigned mem_flags)
|
||||
{
|
||||
int pipe, temp, max;
|
||||
struct usb_device *dev;
|
||||
|
@ -1129,7 +1129,7 @@ int __usb_get_extra_descriptor(char *buffer, unsigned size,
|
||||
void *usb_buffer_alloc (
|
||||
struct usb_device *dev,
|
||||
size_t size,
|
||||
int mem_flags,
|
||||
unsigned mem_flags,
|
||||
dma_addr_t *dma
|
||||
)
|
||||
{
|
||||
|
Reference in New Issue
Block a user