git: 7efef20a8da3 - stable/15 - sx: Sprinkle const qualifiers where appropriate

From: Zhenlei Huang <zlei_at_FreeBSD.org>
Date: Fri, 19 Sep 2025 02:02:00 UTC
The branch stable/15 has been updated by zlei:

URL: https://cgit.FreeBSD.org/src/commit/?id=7efef20a8da332218f5930dc648a6583d53398b6

commit 7efef20a8da332218f5930dc648a6583d53398b6
Author:     Zhenlei Huang <zlei@FreeBSD.org>
AuthorDate: 2025-09-05 16:00:05 +0000
Commit:     Zhenlei Huang <zlei@FreeBSD.org>
CommitDate: 2025-09-19 02:00:51 +0000

    sx: Sprinkle const qualifiers where appropriate
    
    No functional change intended.
    
    MFC after:      2 weeks
    
    (cherry picked from commit 306f0c4cf1a2f58a56993d29d666b4643326493b)
---
 sys/kern/kern_sx.c | 4 ++--
 sys/sys/sx.h       | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/sys/kern/kern_sx.c b/sys/kern/kern_sx.c
index accea5d288eb..c005e112d3b9 100644
--- a/sys/kern/kern_sx.c
+++ b/sys/kern/kern_sx.c
@@ -222,9 +222,9 @@ owner_sx(const struct lock_object *lock, struct thread **owner)
 #endif
 
 void
-sx_sysinit(void *arg)
+sx_sysinit(const void *arg)
 {
-	struct sx_args *sargs = arg;
+	const struct sx_args *sargs = arg;
 
 	sx_init_flags(sargs->sa_sx, sargs->sa_desc, sargs->sa_flags);
 }
diff --git a/sys/sys/sx.h b/sys/sys/sx.h
index deb277decc75..d28cae9d01e5 100644
--- a/sys/sys/sx.h
+++ b/sys/sys/sx.h
@@ -99,7 +99,7 @@
  * Function prototipes.  Routines that start with an underscore are not part
  * of the public interface and are wrappered with a macro.
  */
-void	sx_sysinit(void *arg);
+void	sx_sysinit(const void *arg);
 #define	sx_init(sx, desc)	sx_init_flags((sx), (desc), 0)
 void	sx_init_flags(struct sx *sx, const char *description, int opts);
 void	sx_destroy(struct sx *sx);