summaryrefslogtreecommitdiffstats
path: root/drivers/block/amiflop.c
diff options
context:
space:
mode:
authorKees Cook <keescook@chromium.org>2017-10-09 17:10:32 -0700
committerThomas Gleixner <tglx@linutronix.de>2017-10-17 17:37:36 +0200
commit3c557df67257c114401f18ee412f0b74091c3c6f (patch)
tree7822ebb9e209218df8221f58b60dc6f34232b556 /drivers/block/amiflop.c
parent4eb1bca1793385b8caff4b2e1f19b31a013dd1ec (diff)
downloadlinux-3c557df67257c114401f18ee412f0b74091c3c6f.tar.gz
linux-3c557df67257c114401f18ee412f0b74091c3c6f.tar.bz2
linux-3c557df67257c114401f18ee412f0b74091c3c6f.zip
timer: Remove meaningless .data/.function assignments
Several timer users needlessly reset their .function/.data fields during their timer callback, but nothing else changes them. Some users do not use their .data field at all. Each instance is removed here. Signed-off-by: Kees Cook <keescook@chromium.org> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Acked-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> # for staging Acked-by: Krzysztof Halasa <khc@pm.waw.pl> # for wan/hdlc* Acked-by: Jens Axboe <axboe@kernel.dk> # for amiflop Cc: devel@driverdev.osuosl.org Cc: netdev@vger.kernel.org Cc: linux-wireless@vger.kernel.org Cc: Jens Axboe <axboe@fb.com> Cc: Ganesh Krishna <ganesh.krishna@microchip.com> Cc: Aditya Shankar <aditya.shankar@microchip.com> Link: https://lkml.kernel.org/r/20171010001032.GA119829@beast
Diffstat (limited to 'drivers/block/amiflop.c')
-rw-r--r--drivers/block/amiflop.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/block/amiflop.c b/drivers/block/amiflop.c
index 49908c74bfcb..4e3fb9f104af 100644
--- a/drivers/block/amiflop.c
+++ b/drivers/block/amiflop.c
@@ -323,7 +323,7 @@ static void fd_deselect (int drive)
}
-static void motor_on_callback(unsigned long nr)
+static void motor_on_callback(unsigned long ignored)
{
if (!(ciaa.pra & DSKRDY) || --on_attempts == 0) {
complete_all(&motor_on_completion);
@@ -344,7 +344,6 @@ static int fd_motor_on(int nr)
fd_select(nr);
reinit_completion(&motor_on_completion);
- motor_on_timer.data = nr;
mod_timer(&motor_on_timer, jiffies + HZ/2);
on_attempts = 10;