From 49d084139d5b90dcb7fda8254b5efe9c37121bd7 Mon Sep 17 00:00:00 2001 From: Shinya Kuribayashi Date: Thu, 10 May 2012 10:31:21 +0900 Subject: [PATCH] --- yaml --- r: 303933 b: refs/heads/master c: 934ccec4da14dc0586dfe08b36166364bdd2181b h: refs/heads/master i: 303931: ce95532e493454aa557fa66ac82409f8e2c130a1 v: v3 --- [refs] | 2 +- trunk/drivers/usb/otg/gpio_vbus.c | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/[refs] b/[refs] index 4a38145049ad..6835030b8ae6 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 0d13eebcab76ff8f2b5e479747f66ffbf6c78b57 +refs/heads/master: 934ccec4da14dc0586dfe08b36166364bdd2181b diff --git a/trunk/drivers/usb/otg/gpio_vbus.c b/trunk/drivers/usb/otg/gpio_vbus.c index 5a13657ef077..66af743ec598 100644 --- a/trunk/drivers/usb/otg/gpio_vbus.c +++ b/trunk/drivers/usb/otg/gpio_vbus.c @@ -37,7 +37,7 @@ struct gpio_vbus_data { struct regulator *vbus_draw; int vbus_draw_enabled; unsigned mA; - struct work_struct work; + struct delayed_work work; }; @@ -94,7 +94,7 @@ static int is_vbus_powered(struct gpio_vbus_mach_info *pdata) static void gpio_vbus_work(struct work_struct *work) { struct gpio_vbus_data *gpio_vbus = - container_of(work, struct gpio_vbus_data, work); + container_of(work, struct gpio_vbus_data, work.work); struct gpio_vbus_mach_info *pdata = gpio_vbus->dev->platform_data; int gpio, status; @@ -152,7 +152,7 @@ static irqreturn_t gpio_vbus_irq(int irq, void *data) otg->gadget ? otg->gadget->name : "none"); if (otg->gadget) - schedule_work(&gpio_vbus->work); + schedule_delayed_work(&gpio_vbus->work, msecs_to_jiffies(100)); return IRQ_HANDLED; } @@ -300,7 +300,7 @@ static int __init gpio_vbus_probe(struct platform_device *pdev) ATOMIC_INIT_NOTIFIER_HEAD(&gpio_vbus->phy.notifier); - INIT_WORK(&gpio_vbus->work, gpio_vbus_work); + INIT_DELAYED_WORK(&gpio_vbus->work, gpio_vbus_work); gpio_vbus->vbus_draw = regulator_get(&pdev->dev, "vbus_draw"); if (IS_ERR(gpio_vbus->vbus_draw)) {