Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 25 May 2021 18:15:00 GMT
From:      "Bjoern A. Zeeb" <bz@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org
Subject:   git: c1661d59e68e - main - LinuxKPI: add LINUXKPI_PARAM_charp()
Message-ID:  <202105251815.14PIF0GZ043845@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by bz:

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

commit c1661d59e68e29a817c870f421a6871563039dbb
Author:     Bjoern A. Zeeb <bz@FreeBSD.org>
AuthorDate: 2021-05-24 18:32:11 +0000
Commit:     Bjoern A. Zeeb <bz@FreeBSD.org>
CommitDate: 2021-05-25 18:01:46 +0000

    LinuxKPI: add LINUXKPI_PARAM_charp()
    
    Add yet another version of the various module_param_named() use cases.
    This one deals with "charp".
    
    Sponsored by:   The FreeBSD Foundation
    MFC after:      2 weeks
    Reviewed by:    hselasky
    Differential Revision: https://reviews.freebsd.org/D30433
---
 sys/compat/linuxkpi/common/include/linux/moduleparam.h | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/sys/compat/linuxkpi/common/include/linux/moduleparam.h b/sys/compat/linuxkpi/common/include/linux/moduleparam.h
index 3a16c20fd92e..2b48ec1809b7 100644
--- a/sys/compat/linuxkpi/common/include/linux/moduleparam.h
+++ b/sys/compat/linuxkpi/common/include/linux/moduleparam.h
@@ -102,6 +102,12 @@
 	LINUXKPI_PARAM_NAME(name), LINUXKPI_PARAM_PERM(perm), &(var), 0, \
 	LINUXKPI_PARAM_DESC(name)))
 
+#define	LINUXKPI_PARAM_charp(name, var, perm)				\
+	extern const char LINUXKPI_PARAM_DESC(name)[];			\
+	LINUXKPI_PARAM_PASS(SYSCTL_STRING(LINUXKPI_PARAM_PARENT, OID_AUTO, \
+	LINUXKPI_PARAM_NAME(name), LINUXKPI_PARAM_PERM(perm), &(var), 0, \
+	LINUXKPI_PARAM_DESC(name)))
+
 #define	module_param_string(name, str, len, perm)			\
 	extern const char LINUXKPI_PARAM_DESC(name)[];			\
 	LINUXKPI_PARAM_PASS(SYSCTL_STRING(LINUXKPI_PARAM_PARENT, OID_AUTO, \



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202105251815.14PIF0GZ043845>