linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bean Huo <huobean@gmail.com>
To: daejun7.park@samsung.com, Greg KH <gregkh@linuxfoundation.org>,
	"avri.altman@wdc.com" <avri.altman@wdc.com>,
	"jejb@linux.ibm.com" <jejb@linux.ibm.com>,
	"martin.petersen@oracle.com" <martin.petersen@oracle.com>,
	"asutoshd@codeaurora.org" <asutoshd@codeaurora.org>,
	"stanley.chu@mediatek.com" <stanley.chu@mediatek.com>,
	"cang@codeaurora.org" <cang@codeaurora.org>,
	"bvanassche@acm.org" <bvanassche@acm.org>,
	ALIM AKHTAR <alim.akhtar@samsung.com>
Cc: "linux-scsi@vger.kernel.org" <linux-scsi@vger.kernel.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	JinHwan Park <jh.i.park@samsung.com>,
	Javier Gonzalez <javier.gonz@samsung.com>,
	SEUNGUK SHIN <seunguk.shin@samsung.com>,
	Sung-Jun Park <sungjun07.park@samsung.com>,
	Jinyoung CHOI <j-young.choi@samsung.com>,
	BoRam Shin <boram.shin@samsung.com>
Subject: Re: [PATCH v26 4/4] scsi: ufs: Add HPB 2.0 support
Date: Wed, 03 Mar 2021 15:50:29 +0100	[thread overview]
Message-ID: <2f1b8ff5aec540ef731bf5b2c3691dd23ea2e6b0.camel@gmail.com> (raw)
In-Reply-To: <20210303062926epcms2p6aa6737e5ed3916eed9ab80011aad3d83@epcms2p6>

On Wed, 2021-03-03 at 15:29 +0900, Daejun Park wrote:
> +
> +static inline void ufshpb_put_pre_req(struct ufshpb_lu *hpb,
> +                                     struct ufshpb_req *pre_req)
> +{
> +       pre_req->req = NULL;
> +       pre_req->bio = NULL;
> +       list_add_tail(&pre_req->list_req, &hpb->lh_pre_req_free);
> +       hpb->num_inflight_pre_req--;
> +}
> +
> +static void ufshpb_pre_req_compl_fn(struct request *req,
> blk_status_t error)
> +{
> +       struct ufshpb_req *pre_req = (struct ufshpb_req *)req-
> >end_io_data;
> +       struct ufshpb_lu *hpb = pre_req->hpb;
> +       unsigned long flags;
> +       struct scsi_sense_hdr sshdr;
> +
> +       if (error) {
> +               dev_err(&hpb->sdev_ufs_lu->sdev_dev, "block status
> %d", error);
> +               scsi_normalize_sense(pre_req->sense,
> SCSI_SENSE_BUFFERSIZE,
> +                                    &sshdr);
> +               dev_err(&hpb->sdev_ufs_lu->sdev_dev,
> +                       "code %x sense_key %x asc %x ascq %x",
> +                       sshdr.response_code,
> +                       sshdr.sense_key, sshdr.asc, sshdr.ascq);
> +               dev_err(&hpb->sdev_ufs_lu->sdev_dev,
> +                       "byte4 %x byte5 %x byte6 %x additional_len
> %x",
> +                       sshdr.byte4, sshdr.byte5,
> +                       sshdr.byte6, sshdr.additional_length);
> +       }


How can you print out sense_key and sense code here? sense code will
not be copied to pre_req->sense. you should directly use
scsi_request->sense or let pre_req->sense point to scsi_request->sense.

You update the new version patch so quickly. In another word, I am
wondering if you tested your patch before submitting?

Bean






  reply	other threads:[~2021-03-03 18:40 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20210303062633epcms2p252227acd30ad15c1ca821d7e3f547b9e@epcms2p2>
2021-03-03  6:26 ` [PATCH v26 0/4] scsi: ufs: Add Host Performance Booster Support Daejun Park
     [not found]   ` <CGME20210303062633epcms2p252227acd30ad15c1ca821d7e3f547b9e@epcms2p1>
2021-03-03  6:28     ` [PATCH v26 1/4] scsi: ufs: Introduce HPB feature Daejun Park
2021-03-09  3:15       ` [PATCH] [v26,1/4] " Wang Qing
2021-03-09  6:21       ` [Resend]Re: " Wang Qing
     [not found]   ` <CGME20210303062633epcms2p252227acd30ad15c1ca821d7e3f547b9e@epcms2p6>
2021-03-03  6:28     ` [PATCH v26 2/4] scsi: ufs: L2P map management for HPB read Daejun Park
2021-03-11  8:56       ` Can Guo
2021-03-12  1:19       ` Can Guo
     [not found]       ` <CGME20210303062633epcms2p252227acd30ad15c1ca821d7e3f547b9e@epcms2p8>
2021-03-12  1:23         ` Daejun Park
     [not found]       ` <CGME20210303062633epcms2p252227acd30ad15c1ca821d7e3f547b9e@epcms2p3>
2021-03-12  1:48         ` Daejun Park
2021-03-12  2:03           ` Can Guo
2021-03-12  7:17         ` Daejun Park
2021-03-15  1:54           ` Can Guo
2021-03-03  6:29     ` [PATCH v26 4/4] scsi: ufs: Add HPB 2.0 support Daejun Park
2021-03-03 14:50       ` Bean Huo [this message]
2021-03-04  8:37         ` Can Guo
2021-03-04  6:25       ` Can Guo
2021-03-04  8:21       ` Can Guo
2021-03-04  9:59       ` Bean Huo
2021-03-09  1:38       ` Can Guo
2021-03-10  9:14         ` Can Guo
     [not found]   ` <CGME20210303062633epcms2p252227acd30ad15c1ca821d7e3f547b9e@epcms2p5>
2021-03-03  6:28     ` [PATCH v26 3/4] scsi: ufs: Prepare HPB read for cached sub-region Daejun Park
2021-03-12  1:23       ` Can Guo
2021-03-05  0:35     ` Re: [PATCH v26 4/4] scsi: ufs: Add HPB 2.0 support Daejun Park
2021-03-15  2:19     ` Re: [PATCH v26 2/4] scsi: ufs: L2P map management for HPB read Daejun Park
2021-03-05  0:24 ` Re: [PATCH v26 4/4] scsi: ufs: Add HPB 2.0 support Daejun Park
2021-03-05  0:33 ` Daejun Park

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=2f1b8ff5aec540ef731bf5b2c3691dd23ea2e6b0.camel@gmail.com \
    --to=huobean@gmail.com \
    --cc=alim.akhtar@samsung.com \
    --cc=asutoshd@codeaurora.org \
    --cc=avri.altman@wdc.com \
    --cc=boram.shin@samsung.com \
    --cc=bvanassche@acm.org \
    --cc=cang@codeaurora.org \
    --cc=daejun7.park@samsung.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=j-young.choi@samsung.com \
    --cc=javier.gonz@samsung.com \
    --cc=jejb@linux.ibm.com \
    --cc=jh.i.park@samsung.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    --cc=seunguk.shin@samsung.com \
    --cc=stanley.chu@mediatek.com \
    --cc=sungjun07.park@samsung.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;
as well as URLs for NNTP newsgroup(s).