linux-xfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Darrick J. Wong" <djwong@kernel.org>
To: djwong@kernel.org, guaneryu@gmail.com
Cc: linux-xfs@vger.kernel.org, fstests@vger.kernel.org, guan@eryu.me
Subject: [PATCH 2/3] common/populate: create fifos when pre-populating filesystems
Date: Mon, 22 Mar 2021 21:19:53 -0700	[thread overview]
Message-ID: <161647319358.3429609.6818899550213439595.stgit@magnolia> (raw)
In-Reply-To: <161647318241.3429609.1862044070327396092.stgit@magnolia>

From: Darrick J. Wong <djwong@kernel.org>

Create fifos when populating the scratch filesystem for completeness.

Signed-off-by: Darrick J. Wong <djwong@kernel.org>
---
 common/populate |    4 ++++
 1 file changed, 4 insertions(+)


diff --git a/common/populate b/common/populate
index 8f42a528..c01b7e0e 100644
--- a/common/populate
+++ b/common/populate
@@ -231,6 +231,7 @@ _scratch_xfs_populate() {
 	echo "+ special"
 	mknod "${SCRATCH_MNT}/S_IFCHR" c 1 1
 	mknod "${SCRATCH_MNT}/S_IFBLK" b 1 1
+	mknod "${SCRATCH_MNT}/S_IFIFO" p
 
 	# special file with an xattr
 	setfacl -P -m u:nobody:r ${SCRATCH_MNT}/S_IFCHR
@@ -403,6 +404,7 @@ _scratch_ext4_populate() {
 	echo "+ special"
 	mknod "${SCRATCH_MNT}/S_IFCHR" c 1 1
 	mknod "${SCRATCH_MNT}/S_IFBLK" b 1 1
+	mknod "${SCRATCH_MNT}/S_IFIFO" p
 
 	# special file with an xattr
 	setfacl -P -m u:nobody:r ${SCRATCH_MNT}/S_IFCHR
@@ -580,6 +582,7 @@ _scratch_xfs_populate_check() {
 	extents_slink="$(__populate_find_inode "${SCRATCH_MNT}/S_IFLNK.FMT_EXTENTS")"
 	bdev="$(__populate_find_inode "${SCRATCH_MNT}/S_IFBLK")"
 	cdev="$(__populate_find_inode "${SCRATCH_MNT}/S_IFCHR")"
+	fifo="$(__populate_find_inode "${SCRATCH_MNT}/S_IFIFO")"
 	local_attr="$(__populate_find_inode "${SCRATCH_MNT}/ATTR.FMT_LOCAL")"
 	leaf_attr="$(__populate_find_inode "${SCRATCH_MNT}/ATTR.FMT_LEAF")"
 	node_attr="$(__populate_find_inode "${SCRATCH_MNT}/ATTR.FMT_NODE")"
@@ -605,6 +608,7 @@ _scratch_xfs_populate_check() {
 	__populate_check_xfs_dformat "${btree_dir}" "btree"
 	__populate_check_xfs_dformat "${bdev}" "dev"
 	__populate_check_xfs_dformat "${cdev}" "dev"
+	__populate_check_xfs_dformat "${fifo}" "dev"
 	__populate_check_xfs_attr "${local_attr}" "local"
 	__populate_check_xfs_attr "${leaf_attr}" "leaf"
 	__populate_check_xfs_attr "${node_attr}" "node"


  parent reply	other threads:[~2021-03-23  4:20 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-23  4:19 [PATCHSET 0/3] populate: fix a few bugs with fs pre-population Darrick J. Wong
2021-03-23  4:19 ` [PATCH 1/3] populate: create block devices when pre-populating filesystems Darrick J. Wong
2021-03-24 18:03   ` Christoph Hellwig
2021-03-23  4:19 ` Darrick J. Wong [this message]
2021-03-24 18:05   ` [PATCH 2/3] common/populate: create fifos " Christoph Hellwig
2021-03-23  4:19 ` [PATCH 3/3] common/populate: change how we describe cached populated images Darrick J. Wong
2021-03-24 18:11   ` Christoph Hellwig
2021-03-24 18:15     ` Darrick J. Wong
2021-03-24 18:17   ` [PATCH v1.1 " Darrick J. Wong
2021-03-24 18:22     ` Christoph Hellwig

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=161647319358.3429609.6818899550213439595.stgit@magnolia \
    --to=djwong@kernel.org \
    --cc=fstests@vger.kernel.org \
    --cc=guan@eryu.me \
    --cc=guaneryu@gmail.com \
    --cc=linux-xfs@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).