[PATCH] changing CONFIG_LOCALVERSION rebuilds too much, for no good reason
[pandora-kernel.git] / drivers / usb / gadget / pxa2xx_udc.c
index 1507738..510d28a 100644 (file)
@@ -32,7 +32,6 @@
 #include <linux/kernel.h>
 #include <linux/ioport.h>
 #include <linux/types.h>
-#include <linux/version.h>
 #include <linux/errno.h>
 #include <linux/delay.h>
 #include <linux/sched.h>
@@ -43,7 +42,7 @@
 #include <linux/interrupt.h>
 #include <linux/proc_fs.h>
 #include <linux/mm.h>
-#include <linux/device.h>
+#include <linux/platform_device.h>
 #include <linux/dma-mapping.h>
 
 #include <asm/byteorder.h>
@@ -332,7 +331,7 @@ static int pxa2xx_ep_disable (struct usb_ep *_ep)
  *     pxa2xx_ep_alloc_request - allocate a request data structure
  */
 static struct usb_request *
-pxa2xx_ep_alloc_request (struct usb_ep *_ep, unsigned gfp_flags)
+pxa2xx_ep_alloc_request (struct usb_ep *_ep, gfp_t gfp_flags)
 {
        struct pxa2xx_request *req;
 
@@ -367,7 +366,7 @@ pxa2xx_ep_free_request (struct usb_ep *_ep, struct usb_request *_req)
  */
 static void *
 pxa2xx_ep_alloc_buffer(struct usb_ep *_ep, unsigned bytes,
-       dma_addr_t *dma, unsigned gfp_flags)
+       dma_addr_t *dma, gfp_t gfp_flags)
 {
        char                    *retval;
 
@@ -874,7 +873,7 @@ done:
 /*-------------------------------------------------------------------------*/
 
 static int
-pxa2xx_ep_queue(struct usb_ep *_ep, struct usb_request *_req, unsigned gfp_flags)
+pxa2xx_ep_queue(struct usb_ep *_ep, struct usb_request *_req, gfp_t gfp_flags)
 {
        struct pxa2xx_request   *req;
        struct pxa2xx_ep        *ep;
@@ -2602,24 +2601,23 @@ static int __exit pxa2xx_udc_remove(struct device *_dev)
  * VBUS IRQs should probably be ignored so that the PXA device just acts
  * "dead" to USB hosts until system resume.
  */
-static int pxa2xx_udc_suspend(struct device *dev, u32 state, u32 level)
+static int pxa2xx_udc_suspend(struct device *dev, pm_message_t state)
 {
        struct pxa2xx_udc       *udc = dev_get_drvdata(dev);
 
-       if (level == SUSPEND_POWER_DOWN) {
-               if (!udc->mach->udc_command)
-                       WARN("USB host won't detect disconnect!\n");
-               pullup(udc, 0);
-       }
+       if (!udc->mach->udc_command)
+               WARN("USB host won't detect disconnect!\n");
+       pullup(udc, 0);
+
        return 0;
 }
 
-static int pxa2xx_udc_resume(struct device *dev, u32 level)
+static int pxa2xx_udc_resume(struct device *dev)
 {
        struct pxa2xx_udc       *udc = dev_get_drvdata(dev);
 
-       if (level == RESUME_POWER_ON)
-               pullup(udc, 1);
+       pullup(udc, 1);
+
        return 0;
 }
 
@@ -2632,6 +2630,7 @@ static int pxa2xx_udc_resume(struct device *dev, u32 level)
 
 static struct device_driver udc_driver = {
        .name           = "pxa2xx-udc",
+       .owner          = THIS_MODULE,
        .bus            = &platform_bus_type,
        .probe          = pxa2xx_udc_probe,
        .shutdown       = pxa2xx_udc_shutdown,