[PATCH] nvmem: qnap-mcu-eeprom: Fix struct assignments using commas instead of semicolons

Felix Gu posted 1 patch 1 month, 2 weeks ago
drivers/nvmem/qnap-mcu-eeprom.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
[PATCH] nvmem: qnap-mcu-eeprom: Fix struct assignments using commas instead of semicolons
Posted by Felix Gu 1 month, 2 weeks ago
The nvcfg struct member assignments were incorrectly using commas instead
of semicolons.

Signed-off-by: Felix Gu <ustc.gu@gmail.com>
---
 drivers/nvmem/qnap-mcu-eeprom.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/drivers/nvmem/qnap-mcu-eeprom.c b/drivers/nvmem/qnap-mcu-eeprom.c
index 0b919895b3b2..07bdaa2a33fa 100644
--- a/drivers/nvmem/qnap-mcu-eeprom.c
+++ b/drivers/nvmem/qnap-mcu-eeprom.c
@@ -86,10 +86,10 @@ static int qnap_mcu_eeprom_probe(struct platform_device *pdev)
 	nvcfg.read_only = true;
 	nvcfg.root_only = false;
 	nvcfg.reg_read = qnap_mcu_eeprom_read;
-	nvcfg.size = QNAP_MCU_EEPROM_SIZE,
-	nvcfg.word_size = 1,
-	nvcfg.stride = 1,
-	nvcfg.priv = mcu,
+	nvcfg.size = QNAP_MCU_EEPROM_SIZE;
+	nvcfg.word_size = 1;
+	nvcfg.stride = 1;
+	nvcfg.priv = mcu;
 
 	ndev = devm_nvmem_register(&pdev->dev, &nvcfg);
 	if (IS_ERR(ndev))

---
base-commit: 3fa5e5702a82d259897bd7e209469bc06368bf31
change-id: 20260301-qnap-f91e2ca99aab

Best regards,
-- 
Felix Gu <ustc.gu@gmail.com>
Re: [PATCH] nvmem: qnap-mcu-eeprom: Fix struct assignments using commas instead of semicolons
Posted by Srinivas Kandagatla 1 month ago
On Sun, 01 Mar 2026 17:51:16 +0800, Felix Gu wrote:
> The nvcfg struct member assignments were incorrectly using commas instead
> of semicolons.
> 
> 

Applied, thanks!

[1/1] nvmem: qnap-mcu-eeprom: Fix struct assignments using commas instead of semicolons
      commit: 5a992737b28d0c0869dccf64fa19b135d2c008d8

Best regards,
-- 
Srinivas Kandagatla <srini@kernel.org>
Re: [PATCH] nvmem: qnap-mcu-eeprom: Fix struct assignments using commas instead of semicolons
Posted by Markus Elfring 1 month, 1 week ago
> The nvcfg struct member assignments were incorrectly using commas instead
> of semicolons.

Would a summary phrase like “Prefer separate variable assignment statements
over comma expressions” be more appropriate here?

See also once more:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v7.0-rc2#n94

Regards,
Markus
Re: [PATCH] nvmem: qnap-mcu-eeprom: Fix struct assignments using commas instead of semicolons
Posted by Heiko Stuebner 1 month, 2 weeks ago
Am Sonntag, 1. März 2026, 10:51:16 Mitteleuropäische Normalzeit schrieb Felix Gu:
> The nvcfg struct member assignments were incorrectly using commas instead
> of semicolons.
> 
> Signed-off-by: Felix Gu <ustc.gu@gmail.com>

Reviewed-by: Heiko Stuebner <heiko@sntech.de>

I wonder how I managed to make that mistake :-)

Thanks for noticing
Heiko

> ---
>  drivers/nvmem/qnap-mcu-eeprom.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/nvmem/qnap-mcu-eeprom.c b/drivers/nvmem/qnap-mcu-eeprom.c
> index 0b919895b3b2..07bdaa2a33fa 100644
> --- a/drivers/nvmem/qnap-mcu-eeprom.c
> +++ b/drivers/nvmem/qnap-mcu-eeprom.c
> @@ -86,10 +86,10 @@ static int qnap_mcu_eeprom_probe(struct platform_device *pdev)
>  	nvcfg.read_only = true;
>  	nvcfg.root_only = false;
>  	nvcfg.reg_read = qnap_mcu_eeprom_read;
> -	nvcfg.size = QNAP_MCU_EEPROM_SIZE,
> -	nvcfg.word_size = 1,
> -	nvcfg.stride = 1,
> -	nvcfg.priv = mcu,
> +	nvcfg.size = QNAP_MCU_EEPROM_SIZE;
> +	nvcfg.word_size = 1;
> +	nvcfg.stride = 1;
> +	nvcfg.priv = mcu;
>  
>  	ndev = devm_nvmem_register(&pdev->dev, &nvcfg);
>  	if (IS_ERR(ndev))
> 
> ---
> base-commit: 3fa5e5702a82d259897bd7e209469bc06368bf31
> change-id: 20260301-qnap-f91e2ca99aab
> 
> Best regards,
>