mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hannes Reinecke <hare@suse.de>
To: Johannes Thumshirn <jthumshirn@suse.de>,
	"Martin K . Petersen" <martin.petersen@oracle.com>
Cc: Christoph Hellwig <hch@infradead.org>,
	Linux Kernel Mailinglist <linux-kernel@vger.kernel.org>,
	Linux SCSI Mailinglist <linux-scsi@vger.kernel.org>,
	Johannes Thumshirn <jth@kernel.org>,
	"James E.J. Bottomley" <jejb@linux.vnet.ibm.com>,
	"open list:FCOE SUBSYSTEM (libfc, libfcoe,
	fcoe)"  <fcoe-devel@open-fcoe.org>
Subject: Re: [PATCH v2 07/16] scsi: libfc: don't set FC_RQST_STATE_DONE before calling fc_bsg_jobdone()
Date: Thu, 13 Oct 2016 13:38:06 +0200	[thread overview]
Message-ID: <6eecb558-bd61-aa08-9582-d836ea2c343c@suse.de> (raw)
In-Reply-To: <c0be09bd5581f7993618132ed4bced8e5cb62ce1.1476276823.git.jthumshirn@suse.de>

On 10/12/2016 03:06 PM, Johannes Thumshirn wrote:
> Don't set FC_RQST_STATE_DONE before calling fc_bsg_jobdone() as
> fc_bsg_jobdone() calls blk_complete_requeust() which raises a soft-IRQ that
> ends up in fc_bsg_sofirq_done() and fc_bsg_softirq_done() sets the
> FC_RQST_STATE_DONE flag.
> 
> Signed-off-by: Johannes Thumshirn <jthumshirn@suse.de>
> ---
>  drivers/scsi/libfc/fc_lport.c | 2 --
>  1 file changed, 2 deletions(-)
> 
> diff --git a/drivers/scsi/libfc/fc_lport.c b/drivers/scsi/libfc/fc_lport.c
> index 156708a..53d13721 100644
> --- a/drivers/scsi/libfc/fc_lport.c
> +++ b/drivers/scsi/libfc/fc_lport.c
> @@ -1911,7 +1911,6 @@ static void fc_lport_bsg_resp(struct fc_seq *sp, struct fc_frame *fp,
>  		bsg_reply->result = (PTR_ERR(fp) == -FC_EX_CLOSED) ?
>  			-ECONNABORTED : -ETIMEDOUT;
>  		job->reply_len = sizeof(uint32_t);
> -		job->state_flags |= FC_RQST_STATE_DONE;
>  		fc_bsg_jobdone(job, bsg_reply->result,
>  			       bsg_reply->reply_payload_rcv_len);
>  		kfree(info);
> @@ -1947,7 +1946,6 @@ static void fc_lport_bsg_resp(struct fc_seq *sp, struct fc_frame *fp,
>  			bsg_reply->reply_payload_rcv_len =
>  				job->reply_payload.payload_len;
>  		bsg_reply->result = 0;
> -		job->state_flags |= FC_RQST_STATE_DONE;
>  		fc_bsg_jobdone(job, bsg_reply->result,
>  			       bsg_reply->reply_payload_rcv_len);
>  		kfree(info);
> 
Reviewed-by: Hannes Reinecke <hare@suse.com>

Cheers,

Hannes
-- 
Dr. Hannes Reinecke		   Teamlead Storage & Networking
hare@suse.de			               +49 911 74053 688
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: F. Imendörffer, J. Smithard, J. Guild, D. Upmanyu, G. Norton
HRB 21284 (AG Nürnberg)

  reply	other threads:[~2016-10-13 11:40 UTC|newest]

Thread overview: 43+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-12 13:06 [PATCH v2 00/16] Convert FibreChannel bsg code to use bsg-lib Johannes Thumshirn
2016-10-12 13:06 ` [PATCH v2 01/16] scsi: Get rid of struct fc_bsg_buffer Johannes Thumshirn
2016-10-13  9:01   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 02/16] scsi: don't use fc_bsg_job::request and fc_bsg_job::reply directly Johannes Thumshirn
2016-10-13 11:25   ` Hannes Reinecke
2016-10-13 15:15   ` Steffen Maier
2016-10-13 16:24     ` Johannes Thumshirn
2016-10-28  9:53       ` Steffen Maier
2016-10-28 11:31         ` Hannes Reinecke
2016-10-28 13:53           ` Steffen Maier
2016-10-28 16:29             ` Andreas Krebbel1
2016-10-30 17:56         ` Johannes Thumshirn
2016-10-12 13:06 ` [PATCH v2 03/16] scsi: fc: Export fc_bsg_jobdone and use it in FC drivers Johannes Thumshirn
2016-10-13 11:27   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 04/16] scsi: Unify interfaces of fc_bsg_jobdone and bsg_job_done Johannes Thumshirn
2016-10-13 11:33   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 05/16] scsi: fc: provide fc_bsg_to_shost() helper Johannes Thumshirn
2016-10-13 11:34   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 06/16] scsi: fc: provide fc_bsg_to_rport() helper Johannes Thumshirn
2016-10-13 11:34   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 07/16] scsi: libfc: don't set FC_RQST_STATE_DONE before calling fc_bsg_jobdone() Johannes Thumshirn
2016-10-13 11:38   ` Hannes Reinecke [this message]
2016-10-12 13:06 ` [PATCH v2 08/16] scsi: fc: implement kref backed reference counting Johannes Thumshirn
2016-10-13 11:42   ` Hannes Reinecke
2016-10-13 14:40     ` Johannes Thumshirn
2016-10-12 13:06 ` [PATCH v2 09/16] block: add reference counting for struct bsg_job Johannes Thumshirn
2016-10-13 11:43   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 10/16] scsi: change FC drivers to use 'struct bsg_job' Johannes Thumshirn
2016-10-13 11:44   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 11/16] scsi: fc: Use bsg_destroy_job Johannes Thumshirn
2016-10-13 11:45   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 12/16] scsi: fc: use bsg_softirq_done Johannes Thumshirn
2016-10-13 11:45   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 13/16] scsi: fc: use bsg_job_done Johannes Thumshirn
2016-10-13 11:46   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 14/16] block: add bsg_job_put() and bsg_job_get() Johannes Thumshirn
2016-10-13 11:47   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 15/16] scsi: fc: move FC transport's bsg code to bsg-lib Johannes Thumshirn
2016-10-13 11:49   ` Hannes Reinecke
2016-10-12 13:06 ` [PATCH v2 16/16] block: unexport bsg_softirq_done() again Johannes Thumshirn
2016-10-13 11:50   ` Hannes Reinecke
2016-10-12 15:54 ` [PATCH v2 00/16] Convert FibreChannel bsg code to use bsg-lib Steffen Maier
2016-10-13  7:39   ` Johannes Thumshirn

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=6eecb558-bd61-aa08-9582-d836ea2c343c@suse.de \
    --to=hare@suse.de \
    --cc=fcoe-devel@open-fcoe.org \
    --cc=hch@infradead.org \
    --cc=jejb@linux.vnet.ibm.com \
    --cc=jth@kernel.org \
    --cc=jthumshirn@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    /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®