[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2038148563.21624261202059.JavaMail.epsvc@epcpadp3>
Date: Mon, 21 Jun 2021 16:25:10 +0900
From: Daejun Park <daejun7.park@...sung.com>
To: Avri Altman <Avri.Altman@....com>,
Daejun Park <daejun7.park@...sung.com>,
"James E . J . Bottomley" <jejb@...ux.vnet.ibm.com>,
"Martin K . Petersen" <martin.petersen@...cle.com>,
"linux-scsi@...r.kernel.org" <linux-scsi@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
CC: "gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
Bart Van Assche <bvanassche@....org>,
yongmyung lee <ymhungry.lee@...sung.com>,
ALIM AKHTAR <alim.akhtar@...sung.com>,
"asutoshd@...eaurora.org" <asutoshd@...eaurora.org>,
Zang Leigang <zangleigang@...ilicon.com>,
Avi Shchislowski <Avi.Shchislowski@....com>,
Bean Huo <beanhuo@...ron.com>,
"cang@...eaurora.org" <cang@...eaurora.org>,
"stanley.chu@...iatek.com" <stanley.chu@...iatek.com>
Subject: RE: RE: [PATCH v11 12/12] scsi: ufshpb: Make host mode parameters
configurable
Hi Avri,
> > Hi Avri,
> >
> > >diff --git a/Documentation/ABI/testing/sysfs-driver-ufs
> > b/Documentation/ABI/testing/sysfs-driver-ufs
> > >index d001f008312b..b10cecb286df 100644
> > >--- a/Documentation/ABI/testing/sysfs-driver-ufs
> > >+++ b/Documentation/ABI/testing/sysfs-driver-ufs
> > >@@ -1449,7 +1449,7 @@ Description: This entry shows the maximum
> > HPB data size for using single HPB
> > >
> > > The file is read only.
> > >
> > >-What: /sys/bus/platform/drivers/ufshcd/*/flags/wb_enable
> > >+What: /sys/bus/platform/drivers/ufshcd/*/flags/hpb_enable
> >
> > This part seems to be the problem with my patch. I will correct it.
> Maybe if just another spin is really required?
OK, I will fix it in next re-spin and update the patches.
> >
> > ...
> >
> > >diff --git a/drivers/scsi/ufs/ufshpb.c b/drivers/scsi/ufs/ufshpb.c
> > >index ab66919f4065..6f2ded8c63b0 100644
> > >--- a/drivers/scsi/ufs/ufshpb.c
> > >+++ b/drivers/scsi/ufs/ufshpb.c
> >
> > ...
> >
> > >@@ -1697,6 +1704,7 @@ static void
> > ufshpb_normalization_work_handler(struct work_struct *work)
> > > struct ufshpb_lu *hpb = container_of(work, struct ufshpb_lu,
> > > ufshpb_normalization_work);
> > > int rgn_idx;
> > >+ u8 factor = hpb->params.normalization_factor;
> > >
> > > for (rgn_idx = 0; rgn_idx < hpb->rgns_per_lu; rgn_idx++) {
> > > struct ufshpb_region *rgn = hpb->rgn_tbl + rgn_idx;
> > >@@ -1707,7 +1715,7 @@ static void
> > ufshpb_normalization_work_handler(struct work_struct *work)
> > > for (srgn_idx = 0; srgn_idx < hpb->srgns_per_rgn; srgn_idx++) {
> > > struct ufshpb_subregion *srgn = rgn->srgn_tbl + srgn_idx;
> > >
> > >- srgn->reads >>= 1;
> > >+ srgn->reads >>= factor;
> > > rgn->reads += srgn->reads;
> >
> > How about changing it to "rgn->read >>=factor" and placing it outside the
> > for statement?
> I think zeroing rgn->reads before the loop and then rgn->reads += srgn->reads
> Making it clear, even as far as doc, that the region reads is the sum over its subregions.
OK, I understand your intention.
Thanks,
Daejun
>
> Anyway, this code was introduced in patch 4, so I will fix it there only if you find it really necessary.
>
> Thanks,
> Avri
>
>
>
Powered by blists - more mailing lists