[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20101022185701H.fujita.tomonori@lab.ntt.co.jp>
Date: Fri, 22 Oct 2010 19:03:30 +0900
From: FUJITA Tomonori <fujita.tomonori@....ntt.co.jp>
To: tj@...nel.org
Cc: linux-scsi@...r.kernel.org, James.Bottomley@...e.de,
fujita.tomonori@....ntt.co.jp, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/2] scsi: don't use execute_in_process_context()
On Tue, 19 Oct 2010 14:58:04 +0200
Tejun Heo <tj@...nel.org> wrote:
> SCSI is the only subsystem which uses execute_in_process_context().
> With the recent workqueue updates, unconditionally using work wouldn't
> cause deadlocks around execution resources and the two places where
> SCSI uses them are cold paths where using work unconditionally
> wouldn't make any difference. Drop execute_in_process_context() and
> use work directly.
>
> * scsi_device->ew is replaced with release_work. scsi_target->ew is
> replaced with reap_work.
>
> * Both works are initialized with the respective release/reap function
> during device/target init. scsi_target_reap_usercontext() is moved
> upwards to avoid needing forward declaration.
>
> * scsi_alloc_target() now explicitly flushes the reap_work of the
> found dying target before putting it instead of depending on
> flush_scheduled_work().
>
> This is in preparation of deprecation of flush_scheduled_work() and
> execute_in_process_context().
>
> Signed-off-by: Tejun Heo <tj@...nel.org>
> ---
> drivers/scsi/scsi_scan.c | 26 +++++++++++++-------------
> drivers/scsi/scsi_sysfs.c | 8 +++++---
> include/scsi/scsi_device.h | 4 ++--
> 3 files changed, 20 insertions(+), 18 deletions(-)
Looks fine to me.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists