All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v1] ath11k: change fw build id format in driver init log
@ 2022-03-09 11:24 ` quic_haric
  0 siblings, 0 replies; 4+ messages in thread
From: quic_haric @ 2022-03-09 11:24 UTC (permalink / raw)
  To: quic_kvalo; +Cc: ath11k, linux-wireless, Hari Chandrakanthan

From: Hari Chandrakanthan <quic_haric@quicinc.com>

Currently fw build id is printed during init as follows.

fw_version 0x250684a5 fw_build_timestamp 2021-07-13 10:57
fw_build_id QC_IMAGE_VERSION_STRING=WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1

The string "QC_IMAGE_VERSION_STRING=" is removed from the log
to improve readability.

With this patch the fw build id is printed during init as follows.
fw_version 0x250684a5 fw_build_timestamp 2021-07-13 10:57
fw_build_id WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1

Signed-off-by: Hari Chandrakanthan <quic_haric@quicinc.com>
---
 drivers/net/wireless/ath/ath11k/qmi.c | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/drivers/net/wireless/ath/ath11k/qmi.c b/drivers/net/wireless/ath/ath11k/qmi.c
index b717813..a35cdaf 100644
--- a/drivers/net/wireless/ath/ath11k/qmi.c
+++ b/drivers/net/wireless/ath/ath11k/qmi.c
@@ -14,6 +14,8 @@
 #define SLEEP_CLOCK_SELECT_INTERNAL_BIT	0x02
 #define HOST_CSTATE_BIT			0x04
 
+#define FW_BUILD_ID_MASK "QC_IMAGE_VERSION_STRING="
+
 bool ath11k_cold_boot_cal = 1;
 EXPORT_SYMBOL(ath11k_cold_boot_cal);
 module_param_named(cold_boot_cal, ath11k_cold_boot_cal, bool, 0644);
@@ -1917,6 +1919,8 @@ static int ath11k_qmi_request_target_cap(struct ath11k_base *ab)
 	struct qmi_txn txn;
 	int ret = 0;
 	int r;
+	char *fw_build_id;
+	int fw_build_id_mask_len;
 
 	memset(&req, 0, sizeof(req));
 	memset(&resp, 0, sizeof(resp));
@@ -1982,6 +1986,11 @@ static int ath11k_qmi_request_target_cap(struct ath11k_base *ab)
 		ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi cal data supported from eeprom\n");
 	}
 
+	fw_build_id = ab->qmi.target.fw_build_id;
+	fw_build_id_mask_len = strlen(FW_BUILD_ID_MASK);
+	if (!strncmp(fw_build_id, FW_BUILD_ID_MASK, fw_build_id_mask_len))
+		fw_build_id = fw_build_id + fw_build_id_mask_len;
+
 	ath11k_info(ab, "chip_id 0x%x chip_family 0x%x board_id 0x%x soc_id 0x%x\n",
 		    ab->qmi.target.chip_id, ab->qmi.target.chip_family,
 		    ab->qmi.target.board_id, ab->qmi.target.soc_id);
@@ -1989,7 +1998,7 @@ static int ath11k_qmi_request_target_cap(struct ath11k_base *ab)
 	ath11k_info(ab, "fw_version 0x%x fw_build_timestamp %s fw_build_id %s",
 		    ab->qmi.target.fw_version,
 		    ab->qmi.target.fw_build_timestamp,
-		    ab->qmi.target.fw_build_id);
+		    fw_build_id);
 
 	r = ath11k_core_check_dt(ab);
 	if (r)
-- 
2.7.4


^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [PATCH v1] ath11k: change fw build id format in driver init log
@ 2022-03-09 11:24 ` quic_haric
  0 siblings, 0 replies; 4+ messages in thread
From: quic_haric @ 2022-03-09 11:24 UTC (permalink / raw)
  To: quic_kvalo; +Cc: ath11k, linux-wireless, Hari Chandrakanthan

From: Hari Chandrakanthan <quic_haric@quicinc.com>

Currently fw build id is printed during init as follows.

fw_version 0x250684a5 fw_build_timestamp 2021-07-13 10:57
fw_build_id QC_IMAGE_VERSION_STRING=WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1

The string "QC_IMAGE_VERSION_STRING=" is removed from the log
to improve readability.

With this patch the fw build id is printed during init as follows.
fw_version 0x250684a5 fw_build_timestamp 2021-07-13 10:57
fw_build_id WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1

Signed-off-by: Hari Chandrakanthan <quic_haric@quicinc.com>
---
 drivers/net/wireless/ath/ath11k/qmi.c | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/drivers/net/wireless/ath/ath11k/qmi.c b/drivers/net/wireless/ath/ath11k/qmi.c
index b717813..a35cdaf 100644
--- a/drivers/net/wireless/ath/ath11k/qmi.c
+++ b/drivers/net/wireless/ath/ath11k/qmi.c
@@ -14,6 +14,8 @@
 #define SLEEP_CLOCK_SELECT_INTERNAL_BIT	0x02
 #define HOST_CSTATE_BIT			0x04
 
+#define FW_BUILD_ID_MASK "QC_IMAGE_VERSION_STRING="
+
 bool ath11k_cold_boot_cal = 1;
 EXPORT_SYMBOL(ath11k_cold_boot_cal);
 module_param_named(cold_boot_cal, ath11k_cold_boot_cal, bool, 0644);
@@ -1917,6 +1919,8 @@ static int ath11k_qmi_request_target_cap(struct ath11k_base *ab)
 	struct qmi_txn txn;
 	int ret = 0;
 	int r;
+	char *fw_build_id;
+	int fw_build_id_mask_len;
 
 	memset(&req, 0, sizeof(req));
 	memset(&resp, 0, sizeof(resp));
@@ -1982,6 +1986,11 @@ static int ath11k_qmi_request_target_cap(struct ath11k_base *ab)
 		ath11k_dbg(ab, ATH11K_DBG_QMI, "qmi cal data supported from eeprom\n");
 	}
 
+	fw_build_id = ab->qmi.target.fw_build_id;
+	fw_build_id_mask_len = strlen(FW_BUILD_ID_MASK);
+	if (!strncmp(fw_build_id, FW_BUILD_ID_MASK, fw_build_id_mask_len))
+		fw_build_id = fw_build_id + fw_build_id_mask_len;
+
 	ath11k_info(ab, "chip_id 0x%x chip_family 0x%x board_id 0x%x soc_id 0x%x\n",
 		    ab->qmi.target.chip_id, ab->qmi.target.chip_family,
 		    ab->qmi.target.board_id, ab->qmi.target.soc_id);
@@ -1989,7 +1998,7 @@ static int ath11k_qmi_request_target_cap(struct ath11k_base *ab)
 	ath11k_info(ab, "fw_version 0x%x fw_build_timestamp %s fw_build_id %s",
 		    ab->qmi.target.fw_version,
 		    ab->qmi.target.fw_build_timestamp,
-		    ab->qmi.target.fw_build_id);
+		    fw_build_id);
 
 	r = ath11k_core_check_dt(ab);
 	if (r)
-- 
2.7.4


-- 
ath11k mailing list
ath11k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath11k

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH v1] ath11k: change fw build id format in driver init log
  2022-03-09 11:24 ` quic_haric
@ 2022-03-21 10:56   ` Kalle Valo
  -1 siblings, 0 replies; 4+ messages in thread
From: Kalle Valo @ 2022-03-21 10:56 UTC (permalink / raw)
  To: quic_haric; +Cc: quic_kvalo, ath11k, linux-wireless, Hari Chandrakanthan

<quic_haric@quicinc.com> wrote:

> Currently fw build id is printed during init as follows.
> 
> fw_version 0x250684a5 fw_build_timestamp 2021-07-13 10:57
> fw_build_id QC_IMAGE_VERSION_STRING=WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1
> 
> The string "QC_IMAGE_VERSION_STRING=" is removed from the log
> to improve readability.
> 
> With this patch the fw build id is printed during init as follows.
> fw_version 0x250684a5 fw_build_timestamp 2021-07-13 10:57
> fw_build_id WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1
> 
> Signed-off-by: Hari Chandrakanthan <quic_haric@quicinc.com>
> Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>

Patch applied to ath-next branch of ath.git, thanks.

72a9bff38654 ath11k: change fw build id format in driver init log

-- 
https://patchwork.kernel.org/project/linux-wireless/patch/1646825065-7736-1-git-send-email-quic_haric@quicinc.com/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH v1] ath11k: change fw build id format in driver init log
@ 2022-03-21 10:56   ` Kalle Valo
  0 siblings, 0 replies; 4+ messages in thread
From: Kalle Valo @ 2022-03-21 10:56 UTC (permalink / raw)
  To: quic_haric; +Cc: quic_kvalo, ath11k, linux-wireless, Hari Chandrakanthan

<quic_haric@quicinc.com> wrote:

> Currently fw build id is printed during init as follows.
> 
> fw_version 0x250684a5 fw_build_timestamp 2021-07-13 10:57
> fw_build_id QC_IMAGE_VERSION_STRING=WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1
> 
> The string "QC_IMAGE_VERSION_STRING=" is removed from the log
> to improve readability.
> 
> With this patch the fw build id is printed during init as follows.
> fw_version 0x250684a5 fw_build_timestamp 2021-07-13 10:57
> fw_build_id WLAN.HK.2.5.0.1-01100-QCAHKSWPL_SILICONZ-1
> 
> Signed-off-by: Hari Chandrakanthan <quic_haric@quicinc.com>
> Signed-off-by: Kalle Valo <quic_kvalo@quicinc.com>

Patch applied to ath-next branch of ath.git, thanks.

72a9bff38654 ath11k: change fw build id format in driver init log

-- 
https://patchwork.kernel.org/project/linux-wireless/patch/1646825065-7736-1-git-send-email-quic_haric@quicinc.com/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches


-- 
ath11k mailing list
ath11k@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/ath11k

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-03-21 10:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-09 11:24 [PATCH v1] ath11k: change fw build id format in driver init log quic_haric
2022-03-09 11:24 ` quic_haric
2022-03-21 10:56 ` Kalle Valo
2022-03-21 10:56   ` Kalle Valo

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.