Re: [PATCH v25 4/4] scsi: ufs: Add HPB 2.0 support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, 2021-02-26 at 16:35 +0900, Daejun Park wrote:
> +static void ufshpb_set_unmap_cmd(unsigned char *cdb, struct
> ufshpb_region *rgn)
> +{
> +       cdb[0] = UFSHPB_WRITE_BUFFER;
> +       cdb[1] = rgn ? UFSHPB_WRITE_BUFFER_INACT_SINGLE_ID :
> +                         UFSHPB_WRITE_BUFFER_INACT_ALL_ID;

Here is wrong, 
Valid HPB Region is (0 ~ (Ceiling( Region size calculated by
bHPBRegionSize )- 1) ). how do you know the region==0 is not 
a single normal region?

Bean


> +       if (rgn)
> +               put_unaligned_be16(rgn->rgn_idx, &cdb[2]);
> +       cdb[9] = 0x00;
> +}






[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux