]> git.kernelconcepts.de Git - mv-sheeva.git/commitdiff
rtc: don't use flush_scheduled_work()
authorTejun Heo <tj@kernel.org>
Fri, 24 Dec 2010 15:00:17 +0000 (16:00 +0100)
committerTejun Heo <tj@kernel.org>
Fri, 24 Dec 2010 15:00:17 +0000 (16:00 +0100)
flush_scheduled_work() is deprecated and scheduled to be removed.  On
removal, directly cancel the work, and flush the uie_task in
rtc-dev.c::clear_uie().

Signed-off-by: Tejun Heo <tj@kernel.org>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Cc: rtc-linux@googlegroups.com
drivers/rtc/rtc-dev.c
drivers/rtc/rtc-ds1305.c
drivers/rtc/rtc-ds1374.c
drivers/rtc/rtc-ds3232.c
drivers/rtc/rtc-rx8025.c

index 62227cd5241053e14171c7ad2ab4daf2089a5db2..0cc0984d155b85109477e78254f91da4f6210e92 100644 (file)
@@ -104,7 +104,7 @@ static int clear_uie(struct rtc_device *rtc)
                }
                if (rtc->uie_task_active) {
                        spin_unlock_irq(&rtc->irq_lock);
-                       flush_scheduled_work();
+                       flush_work_sync(&rtc->uie_task);
                        spin_lock_irq(&rtc->irq_lock);
                }
                rtc->uie_irq_active = 0;
index 48da85e97ca4c589fd068f7930c157cc2c3b8154..077af1d7b9e4b7ccc2641887823a99cc79ad7359 100644 (file)
@@ -813,7 +813,7 @@ static int __devexit ds1305_remove(struct spi_device *spi)
        if (spi->irq) {
                set_bit(FLAG_EXITING, &ds1305->flags);
                free_irq(spi->irq, ds1305);
-               flush_scheduled_work();
+               cancel_work_sync(&ds1305->work);
        }
 
        rtc_device_unregister(ds1305->rtc);
index 1f0007fd44314c5b65ffc39fde6df81cc568d492..47fb6357c346a111abd5c9f5215ebf6cd644ee87 100644 (file)
@@ -417,7 +417,7 @@ static int __devexit ds1374_remove(struct i2c_client *client)
                mutex_unlock(&ds1374->mutex);
 
                free_irq(client->irq, client);
-               flush_scheduled_work();
+               cancel_work_sync(&ds1374->work);
        }
 
        rtc_device_unregister(ds1374->rtc);
index 57063552d3b76c538a64f692631a284f0d16a8dc..23a9ee19764cb5358b87eb5c935474a82bbbae4f 100644 (file)
@@ -463,7 +463,7 @@ static int __devexit ds3232_remove(struct i2c_client *client)
                mutex_unlock(&ds3232->mutex);
 
                free_irq(client->irq, client);
-               flush_scheduled_work();
+               cancel_work_sync(&ds3232->work);
        }
 
        rtc_device_unregister(ds3232->rtc);
index 1146e3522d3cdc82b512fc751e4ac6adf03c0440..af32a62e12a82365cf2e796f4d66d961505f42aa 100644 (file)
@@ -650,7 +650,7 @@ static int __devexit rx8025_remove(struct i2c_client *client)
                mutex_unlock(lock);
 
                free_irq(client->irq, client);
-               flush_scheduled_work();
+               cancel_work_sync(&rx8025->work);
        }
 
        rx8025_sysfs_unregister(&client->dev);