public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH RESEND] platform/surface: Replace deprecated strcpy + strcat in blogic_rdconfig
@ 2026-01-12 22:37 Thorsten Blum
  0 siblings, 0 replies; 7+ messages in thread
From: Thorsten Blum @ 2026-01-12 22:37 UTC (permalink / raw)
  To: Khalid Aziz, James E.J. Bottomley, Martin K. Petersen
  Cc: Thorsten Blum, linux-scsi, linux-kernel

strcpy() is deprecated and using strcat() is discouraged. Replace them
with scnprintf().  No functional changes.

Link: https://github.com/KSPP/linux/issues/88
Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
---
 drivers/scsi/BusLogic.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/BusLogic.c b/drivers/scsi/BusLogic.c
index a86d780d1ba4..4382dc26bc05 100644
--- a/drivers/scsi/BusLogic.c
+++ b/drivers/scsi/BusLogic.c
@@ -1631,8 +1631,8 @@ static bool __init blogic_rdconfig(struct blogic_adapter *adapter)
 	/*
 	   Initialize the Host Adapter Full Model Name from the Model Name.
 	 */
-	strcpy(adapter->full_model, "BusLogic ");
-	strcat(adapter->full_model, adapter->model);
+	scnprintf(adapter->full_model, sizeof(adapter->full_model),
+		  "BusLogic %s", adapter->model);
 	/*
 	   Select an appropriate value for the Tagged Queue Depth either from a
 	   BusLogic Driver Options specification, or based on whether this Host
-- 
Thorsten Blum <thorsten.blum@linux.dev>
GPG: 1D60 735E 8AEF 3BE4 73B6  9D84 7336 78FD 8DFE EAD4


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

* [PATCH RESEND] platform/surface: Replace deprecated strcpy + strcat in blogic_rdconfig
@ 2026-01-27  1:29 Thorsten Blum
  0 siblings, 0 replies; 7+ messages in thread
From: Thorsten Blum @ 2026-01-27  1:29 UTC (permalink / raw)
  To: Khalid Aziz, James E.J. Bottomley, Martin K. Petersen
  Cc: Thorsten Blum, linux-scsi, linux-kernel

strcpy() is deprecated [1] and using strcat() is discouraged. Replace
them with scnprintf().  No functional changes.

Link: https://www.kernel.org/doc/html/latest/process/deprecated.html#strcpy [1]
Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
---
 drivers/scsi/BusLogic.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/BusLogic.c b/drivers/scsi/BusLogic.c
index 865fcbac8fa1..82e436a8f012 100644
--- a/drivers/scsi/BusLogic.c
+++ b/drivers/scsi/BusLogic.c
@@ -1631,8 +1631,8 @@ static bool __init blogic_rdconfig(struct blogic_adapter *adapter)
 	/*
 	   Initialize the Host Adapter Full Model Name from the Model Name.
 	 */
-	strcpy(adapter->full_model, "BusLogic ");
-	strcat(adapter->full_model, adapter->model);
+	scnprintf(adapter->full_model, sizeof(adapter->full_model),
+		  "BusLogic %s", adapter->model);
 	/*
 	   Select an appropriate value for the Tagged Queue Depth either from a
 	   BusLogic Driver Options specification, or based on whether this Host
-- 
Thorsten Blum <thorsten.blum@linux.dev>
GPG: 1D60 735E 8AEF 3BE4 73B6  9D84 7336 78FD 8DFE EAD4


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

* [PATCH RESEND] platform/surface: Replace deprecated strcpy + strcat in blogic_rdconfig
@ 2026-02-24 14:48 Thorsten Blum
  2026-02-24 18:15 ` Martin K. Petersen
  2026-02-28 22:22 ` Martin K. Petersen
  0 siblings, 2 replies; 7+ messages in thread
From: Thorsten Blum @ 2026-02-24 14:48 UTC (permalink / raw)
  To: Khalid Aziz, James E.J. Bottomley, Martin K. Petersen
  Cc: Thorsten Blum, linux-scsi, linux-kernel

strcpy() is deprecated [1] and using strcat() is discouraged. Replace
them with scnprintf().  No functional changes.

Link: https://www.kernel.org/doc/html/latest/process/deprecated.html#strcpy [1]
Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev>
---
 drivers/scsi/BusLogic.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/BusLogic.c b/drivers/scsi/BusLogic.c
index da6599ae3d0d..5304d2febd63 100644
--- a/drivers/scsi/BusLogic.c
+++ b/drivers/scsi/BusLogic.c
@@ -1632,8 +1632,8 @@ static bool __init blogic_rdconfig(struct blogic_adapter *adapter)
 	/*
 	   Initialize the Host Adapter Full Model Name from the Model Name.
 	 */
-	strcpy(adapter->full_model, "BusLogic ");
-	strcat(adapter->full_model, adapter->model);
+	scnprintf(adapter->full_model, sizeof(adapter->full_model),
+		  "BusLogic %s", adapter->model);
 	/*
 	   Select an appropriate value for the Tagged Queue Depth either from a
 	   BusLogic Driver Options specification, or based on whether this Host
-- 
Thorsten Blum <thorsten.blum@linux.dev>
GPG: 1D60 735E 8AEF 3BE4 73B6  9D84 7336 78FD 8DFE EAD4


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

* Re: [PATCH RESEND] platform/surface: Replace deprecated strcpy + strcat in blogic_rdconfig
  2026-02-24 14:48 Thorsten Blum
@ 2026-02-24 18:15 ` Martin K. Petersen
  2026-02-24 18:41   ` Thorsten Blum
  2026-02-28 22:22 ` Martin K. Petersen
  1 sibling, 1 reply; 7+ messages in thread
From: Martin K. Petersen @ 2026-02-24 18:15 UTC (permalink / raw)
  To: Thorsten Blum
  Cc: Khalid Aziz, James E.J. Bottomley, Martin K. Petersen, linux-scsi,
	linux-kernel


Thorsten,

> diff --git a/drivers/scsi/BusLogic.c b/drivers/scsi/BusLogic.c

...and yet tagged as "platform/surface:" in Subject. I fixed it up.

-- 
Martin K. Petersen

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

* Re: [PATCH RESEND] platform/surface: Replace deprecated strcpy + strcat in blogic_rdconfig
  2026-02-24 18:15 ` Martin K. Petersen
@ 2026-02-24 18:41   ` Thorsten Blum
  0 siblings, 0 replies; 7+ messages in thread
From: Thorsten Blum @ 2026-02-24 18:41 UTC (permalink / raw)
  To: Martin K. Petersen
  Cc: Khalid Aziz, James E.J. Bottomley, linux-scsi, linux-kernel

On 24. Feb 2026, at 19:15, Martin K. Petersen wrote:
>> diff --git a/drivers/scsi/BusLogic.c b/drivers/scsi/BusLogic.c
> 
> ...and yet tagged as "platform/surface:" in Subject. I fixed it up.

Sorry Martin, no idea how that happened. Thanks for fixing it.

Best,
Thorsten


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

* Re: [PATCH RESEND] platform/surface: Replace deprecated strcpy + strcat in blogic_rdconfig
  2026-02-24 14:48 Thorsten Blum
  2026-02-24 18:15 ` Martin K. Petersen
@ 2026-02-28 22:22 ` Martin K. Petersen
  2026-03-01  2:16   ` Martin K. Petersen
  1 sibling, 1 reply; 7+ messages in thread
From: Martin K. Petersen @ 2026-02-28 22:22 UTC (permalink / raw)
  To: Khalid Aziz, James E.J. Bottomley, Thorsten Blum
  Cc: Martin K . Petersen, linux-scsi, linux-kernel

On Tue, 24 Feb 2026 15:48:27 +0100, Thorsten Blum wrote:

> strcpy() is deprecated [1] and using strcat() is discouraged. Replace
> them with scnprintf().  No functional changes.
> 
> 

Applied to 7.1/scsi-queue, thanks!

[1/1] platform/surface: Replace deprecated strcpy + strcat in blogic_rdconfig
      https://git.kernel.org/mkp/scsi/c/931c105de11c

-- 
Martin K. Petersen

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

* Re: [PATCH RESEND] platform/surface: Replace deprecated strcpy + strcat in blogic_rdconfig
  2026-02-28 22:22 ` Martin K. Petersen
@ 2026-03-01  2:16   ` Martin K. Petersen
  0 siblings, 0 replies; 7+ messages in thread
From: Martin K. Petersen @ 2026-03-01  2:16 UTC (permalink / raw)
  To: Khalid Aziz, James E.J. Bottomley, Thorsten Blum
  Cc: Martin K . Petersen, linux-scsi, linux-kernel

On Tue, 24 Feb 2026 15:48:27 +0100, Thorsten Blum wrote:

> strcpy() is deprecated [1] and using strcat() is discouraged. Replace
> them with scnprintf().  No functional changes.
> 
> 

Applied to 7.1/scsi-queue, thanks!

[1/1] platform/surface: Replace deprecated strcpy + strcat in blogic_rdconfig
      https://git.kernel.org/mkp/scsi/c/931c105de11c

-- 
Martin K. Petersen

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

end of thread, other threads:[~2026-03-01  2:16 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-01-12 22:37 [PATCH RESEND] platform/surface: Replace deprecated strcpy + strcat in blogic_rdconfig Thorsten Blum
  -- strict thread matches above, loose matches on Subject: below --
2026-01-27  1:29 Thorsten Blum
2026-02-24 14:48 Thorsten Blum
2026-02-24 18:15 ` Martin K. Petersen
2026-02-24 18:41   ` Thorsten Blum
2026-02-28 22:22 ` Martin K. Petersen
2026-03-01  2:16   ` Martin K. Petersen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox