Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

scsi: Revert "scsi: ufs: core: Probe for EXT_IID support"

This reverts commit 6e1d850acff9477ae4c18a73c19ef52841ac2010.

Although added a while ago, to date no one make use of ext_iid,
specifically incorporates it in the upiu header. Therefore, remove it as
it is currently unused and not serving any purpose.

Signed-off-by: Avri Altman <avri.altman@wdc.com>
Link: https://lore.kernel.org/r/20250103080204.63951-1-avri.altman@wdc.com
Cc: Can Guo <quic_cang@quicinc.com>
Cc: Asutosh Das <quic_asutoshd@quicinc.com>
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>

authored by

Avri Altman and committed by
Martin K. Petersen
815940bb d2138eab

-45
-33
drivers/ufs/core/ufshcd.c
··· 2411 2411 else 2412 2412 hba->lsdb_sup = true; 2413 2413 2414 - if (!hba->mcq_sup) 2415 - return 0; 2416 - 2417 2414 hba->mcq_capabilities = ufshcd_readl(hba, REG_MCQCAP); 2418 - hba->ext_iid_sup = FIELD_GET(MASK_EXT_IID_SUPPORT, 2419 - hba->mcq_capabilities); 2420 2415 2421 2416 return 0; 2422 2417 } ··· 8115 8120 } 8116 8121 } 8117 8122 8118 - static void ufshcd_ext_iid_probe(struct ufs_hba *hba, u8 *desc_buf) 8119 - { 8120 - struct ufs_dev_info *dev_info = &hba->dev_info; 8121 - u32 ext_ufs_feature; 8122 - u32 ext_iid_en = 0; 8123 - int err; 8124 - 8125 - /* Only UFS-4.0 and above may support EXT_IID */ 8126 - if (dev_info->wspecversion < 0x400) 8127 - goto out; 8128 - 8129 - ext_ufs_feature = get_unaligned_be32(desc_buf + 8130 - DEVICE_DESC_PARAM_EXT_UFS_FEATURE_SUP); 8131 - if (!(ext_ufs_feature & UFS_DEV_EXT_IID_SUP)) 8132 - goto out; 8133 - 8134 - err = ufshcd_query_attr_retry(hba, UPIU_QUERY_OPCODE_READ_ATTR, 8135 - QUERY_ATTR_IDN_EXT_IID_EN, 0, 0, &ext_iid_en); 8136 - if (err) 8137 - dev_err(hba->dev, "failed reading bEXTIIDEn. err = %d\n", err); 8138 - 8139 - out: 8140 - dev_info->b_ext_iid_en = ext_iid_en; 8141 - } 8142 - 8143 8123 static void ufshcd_set_rtt(struct ufs_hba *hba) 8144 8124 { 8145 8125 struct ufs_dev_info *dev_info = &hba->dev_info; ··· 8309 8339 ufshcd_temp_notif_probe(hba, desc_buf); 8310 8340 8311 8341 ufs_init_rtc(hba, desc_buf); 8312 - 8313 - if (hba->ext_iid_sup) 8314 - ufshcd_ext_iid_probe(hba, desc_buf); 8315 8342 8316 8343 /* 8317 8344 * ufshcd_read_string_desc returns size of the string
-5
include/ufs/ufs.h
··· 180 180 QUERY_ATTR_IDN_AVAIL_WB_BUFF_SIZE = 0x1D, 181 181 QUERY_ATTR_IDN_WB_BUFF_LIFE_TIME_EST = 0x1E, 182 182 QUERY_ATTR_IDN_CURR_WB_BUFF_SIZE = 0x1F, 183 - QUERY_ATTR_IDN_EXT_IID_EN = 0x2A, 184 183 QUERY_ATTR_IDN_TIMESTAMP = 0x30 185 184 }; 186 185 ··· 390 391 UFS_DEV_EXT_TEMP_NOTIF = BIT(6), 391 392 UFS_DEV_HPB_SUPPORT = BIT(7), 392 393 UFS_DEV_WRITE_BOOSTER_SUP = BIT(8), 393 - UFS_DEV_EXT_IID_SUP = BIT(16), 394 394 }; 395 395 #define UFS_DEV_HPB_SUPPORT_VERSION 0x310 396 396 ··· 582 584 u8 b_presrv_uspc_en; 583 585 584 586 bool b_advanced_rpmb_en; 585 - 586 - /* UFS EXT_IID Enable */ 587 - bool b_ext_iid_en; 588 587 589 588 /* UFS RTC */ 590 589 enum ufs_rtc_time rtc_type;
-2
include/ufs/ufshcd.h
··· 952 952 * @nr_queues: number of Queues of different queue types 953 953 * @complete_put: whether or not to call ufshcd_rpm_put() from inside 954 954 * ufshcd_resume_complete() 955 - * @ext_iid_sup: is EXT_IID is supported by UFSHC 956 955 * @mcq_sup: is mcq supported by UFSHC 957 956 * @mcq_enabled: is mcq ready to accept requests 958 957 * @res: array of resource info of MCQ registers ··· 1117 1118 unsigned int nr_hw_queues; 1118 1119 unsigned int nr_queues[HCTX_MAX_TYPES]; 1119 1120 bool complete_put; 1120 - bool ext_iid_sup; 1121 1121 bool scsi_host_added; 1122 1122 bool mcq_sup; 1123 1123 bool lsdb_sup;
-5
include/ufs/ufshci.h
··· 82 82 MASK_MCQ_SUPPORT = 0x40000000, 83 83 }; 84 84 85 - /* MCQ capability mask */ 86 - enum { 87 - MASK_EXT_IID_SUPPORT = 0x00000400, 88 - }; 89 - 90 85 enum { 91 86 REG_SQATTR = 0x0, 92 87 REG_SQLBA = 0x4,