From: Geliang Tang Date: Sat, 11 Mar 2017 00:47:01 +0000 (+0800) Subject: libata: use setup_deferrable_timer X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=7c92357c91a917fd882801604bba2cb1f1fdde23;p=openwrt%2Fstaging%2Fblogic.git libata: use setup_deferrable_timer Use setup_deferrable_timer() instead of init_timer_deferrable() to simplify the code. Signed-off-by: Geliang Tang Signed-off-by: Tejun Heo --- diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c index ca75823697dd..55d3c8b8b35b 100644 --- a/drivers/ata/libata-core.c +++ b/drivers/ata/libata-core.c @@ -5902,9 +5902,9 @@ struct ata_port *ata_port_alloc(struct ata_host *host) INIT_LIST_HEAD(&ap->eh_done_q); init_waitqueue_head(&ap->eh_wait_q); init_completion(&ap->park_req_pending); - init_timer_deferrable(&ap->fastdrain_timer); - ap->fastdrain_timer.function = ata_eh_fastdrain_timerfn; - ap->fastdrain_timer.data = (unsigned long)ap; + setup_deferrable_timer(&ap->fastdrain_timer, + ata_eh_fastdrain_timerfn, + (unsigned long)ap); ap->cbl = ATA_CBL_NONE;