mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: <micky_ching@realsil.com.cn>
To: <devel@linuxdriverproject.org>, <linux-kernel@vger.kernel.org>
Cc: <sameo@linux.intel.com>, <maximlevitsky@gmail.com>,
	<gregkh@linuxfoundation.org>, <oakad@yahoo.com>,
	<rogerable@realtek.com>, <wei_wang@realsil.com.cn>,
	Micky Ching <micky_ching@realsil.com.cn>
Subject: [PATCH] memorystick: rtsx: add cancel_work when remove driver
Date: Thu, 5 Jun 2014 10:34:24 +0800	[thread overview]
Message-ID: <1401935664-9111-1-git-send-email-micky_ching@realsil.com.cn> (raw)

From: Micky Ching <micky_ching@realsil.com.cn>

Add cancel_work_sync() in rtsx_pci_ms_drv_remove(). Using
cancel_work_sync() to cancel pending request handle work when remove
driver.

Signed-off-by: Micky Ching <micky_ching@realsil.com.cn>
---
 drivers/memstick/host/rtsx_pci_ms.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/memstick/host/rtsx_pci_ms.c b/drivers/memstick/host/rtsx_pci_ms.c
index 2a635b6..c880ba6 100644
--- a/drivers/memstick/host/rtsx_pci_ms.c
+++ b/drivers/memstick/host/rtsx_pci_ms.c
@@ -601,6 +601,7 @@ static int rtsx_pci_ms_drv_remove(struct platform_device *pdev)
 	pcr->slots[RTSX_MS_CARD].card_event = NULL;
 	msh = host->msh;
 	host->eject = true;
+	cancel_work_sync(&host->handle_req);
 
 	mutex_lock(&host->host_mutex);
 	if (host->req) {
-- 
1.7.9.5


                 reply	other threads:[~2014-06-05  2:30 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1401935664-9111-1-git-send-email-micky_ching@realsil.com.cn \
    --to=micky_ching@realsil.com.cn \
    --cc=devel@linuxdriverproject.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maximlevitsky@gmail.com \
    --cc=oakad@yahoo.com \
    --cc=rogerable@realtek.com \
    --cc=sameo@linux.intel.com \
    --cc=wei_wang@realsil.com.cn \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®