From e0a90a39ad3a6271b7fa510dca53a92b1ffe4832 Mon Sep 17 00:00:00 2001 From: "Thang Q. Nguyen" Date: Thu, 28 Mar 2024 21:14:17 +0700 Subject: meta-phosphor: add nfs distro feature Add include files for NFS distro features, which enables NFS kernel configuration and utility to mount NFS from BMC. Tested: 1. Check if CONFIG_NFS_* are enabled $ zcat /proc/config.gz | grep NFS 2. Mount remote NFS folder $ mount -t nfs 10.10.130.2:/tftpboot/ISO_file /tmp/mount_nfs Change-Id: I015f4f6ed9c5b60573340233aee1f781aa0c573a Signed-off-by: Thang Q. Nguyen --- meta-phosphor/conf/distro/include/nfs.inc | 2 ++ meta-phosphor/recipes-core/util-linux/util-linux_%.bbappend | 2 ++ meta-phosphor/recipes-kernel/linux/linux-%.bbappend | 4 ++++ meta-phosphor/recipes-kernel/linux/nfs/nfs.cfg | 5 +++++ meta-phosphor/recipes-kernel/linux/nfs/nfs.scc | 3 +++ 5 files changed, 16 insertions(+) create mode 100644 meta-phosphor/conf/distro/include/nfs.inc create mode 100644 meta-phosphor/recipes-core/util-linux/util-linux_%.bbappend create mode 100644 meta-phosphor/recipes-kernel/linux/nfs/nfs.cfg create mode 100644 meta-phosphor/recipes-kernel/linux/nfs/nfs.scc diff --git a/meta-phosphor/conf/distro/include/nfs.inc b/meta-phosphor/conf/distro/include/nfs.inc new file mode 100644 index 0000000000..de28475ee5 --- /dev/null +++ b/meta-phosphor/conf/distro/include/nfs.inc @@ -0,0 +1,2 @@ +DISTRO_FEATURES += "nfs" +DISTROOVERRIDES .= ":df-nfs" diff --git a/meta-phosphor/recipes-core/util-linux/util-linux_%.bbappend b/meta-phosphor/recipes-core/util-linux/util-linux_%.bbappend new file mode 100644 index 0000000000..26c6a103ef --- /dev/null +++ b/meta-phosphor/recipes-core/util-linux/util-linux_%.bbappend @@ -0,0 +1,2 @@ +PACKAGES:append = " ${PN}-mount" +RDEPENDS:${PN}-mount:append:class-target:df-nfs = " nfs-utils-mount" diff --git a/meta-phosphor/recipes-kernel/linux/linux-%.bbappend b/meta-phosphor/recipes-kernel/linux/linux-%.bbappend index 1e008159b0..2f759043e1 100644 --- a/meta-phosphor/recipes-kernel/linux/linux-%.bbappend +++ b/meta-phosphor/recipes-kernel/linux/linux-%.bbappend @@ -5,3 +5,7 @@ SRC_URI:append = " \ SRC_URI:append:df-mctp = " \ file://mctp/mctp.scc \ " +SRC_URI:append:df-nfs = " \ + file://nfs/nfs.scc \ + file://nfs/nfs.cfg \ + " diff --git a/meta-phosphor/recipes-kernel/linux/nfs/nfs.cfg b/meta-phosphor/recipes-kernel/linux/nfs/nfs.cfg new file mode 100644 index 0000000000..24a387d5d1 --- /dev/null +++ b/meta-phosphor/recipes-kernel/linux/nfs/nfs.cfg @@ -0,0 +1,5 @@ +CONFIG_NFS_FS=y +CONFIG_NFS_V3=y +CONFIG_NFS_V4=y +CONFIG_NFS_COMMON=y +CONFIG_NFSD=y diff --git a/meta-phosphor/recipes-kernel/linux/nfs/nfs.scc b/meta-phosphor/recipes-kernel/linux/nfs/nfs.scc new file mode 100644 index 0000000000..7d1acbad63 --- /dev/null +++ b/meta-phosphor/recipes-kernel/linux/nfs/nfs.scc @@ -0,0 +1,3 @@ +define KFEATURE_DESCRIPTION "Enable NFS" + +kconf non-hardware nfs.cfg -- cgit v1.2.3