[PATCH 06/12] libfrog: move ptvar.h to libfrog/

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Darrick J. Wong <darrick.wong@xxxxxxxxxx>

Move this header to libfrog since the code is there already.

Signed-off-by: Darrick J. Wong <darrick.wong@xxxxxxxxxx>
---
 include/ptvar.h     |   18 ------------------
 libfrog/Makefile    |    1 +
 libfrog/ptvar.h     |   18 ++++++++++++++++++
 scrub/counter.c     |    2 +-
 scrub/phase7.c      |    2 +-
 scrub/read_verify.c |    2 +-
 6 files changed, 22 insertions(+), 21 deletions(-)
 delete mode 100644 include/ptvar.h
 create mode 100644 libfrog/ptvar.h


diff --git a/include/ptvar.h b/include/ptvar.h
deleted file mode 100644
index 90823da9..00000000
--- a/include/ptvar.h
+++ /dev/null
@@ -1,18 +0,0 @@
-// SPDX-License-Identifier: GPL-2.0+
-/*
- * Copyright (C) 2018 Oracle.  All Rights Reserved.
- * Author: Darrick J. Wong <darrick.wong@xxxxxxxxxx>
- */
-#ifndef LIBFROG_PERCPU_H_
-#define LIBFROG_PERCPU_H_
-
-struct ptvar;
-
-typedef bool (*ptvar_iter_fn)(struct ptvar *ptv, void *data, void *foreach_arg);
-
-struct ptvar *ptvar_init(size_t nr, size_t size);
-void ptvar_free(struct ptvar *ptv);
-void *ptvar_get(struct ptvar *ptv);
-bool ptvar_foreach(struct ptvar *ptv, ptvar_iter_fn fn, void *foreach_arg);
-
-#endif /* LIBFROG_PERCPU_H_ */
diff --git a/libfrog/Makefile b/libfrog/Makefile
index 98f2feb5..25ea248e 100644
--- a/libfrog/Makefile
+++ b/libfrog/Makefile
@@ -35,6 +35,7 @@ convert.h \
 crc32defs.h \
 crc32table.h \
 fsgeom.h \
+ptvar.h \
 topology.h
 
 LSRCFILES += gen_crc32table.c
diff --git a/libfrog/ptvar.h b/libfrog/ptvar.h
new file mode 100644
index 00000000..a8803c64
--- /dev/null
+++ b/libfrog/ptvar.h
@@ -0,0 +1,18 @@
+// SPDX-License-Identifier: GPL-2.0+
+/*
+ * Copyright (C) 2018 Oracle.  All Rights Reserved.
+ * Author: Darrick J. Wong <darrick.wong@xxxxxxxxxx>
+ */
+#ifndef __LIBFROG_PTVAR_H__
+#define __LIBFROG_PTVAR_H__
+
+struct ptvar;
+
+typedef bool (*ptvar_iter_fn)(struct ptvar *ptv, void *data, void *foreach_arg);
+
+struct ptvar *ptvar_init(size_t nr, size_t size);
+void ptvar_free(struct ptvar *ptv);
+void *ptvar_get(struct ptvar *ptv);
+bool ptvar_foreach(struct ptvar *ptv, ptvar_iter_fn fn, void *foreach_arg);
+
+#endif /* __LIBFROG_PTVAR_H__ */
diff --git a/scrub/counter.c b/scrub/counter.c
index 4800e751..43444927 100644
--- a/scrub/counter.c
+++ b/scrub/counter.c
@@ -9,7 +9,7 @@
 #include <string.h>
 #include <assert.h>
 #include <pthread.h>
-#include "ptvar.h"
+#include "libfrog/ptvar.h"
 #include "counter.h"
 
 /*
diff --git a/scrub/phase7.c b/scrub/phase7.c
index 8a028e19..8ac1da07 100644
--- a/scrub/phase7.c
+++ b/scrub/phase7.c
@@ -8,7 +8,7 @@
 #include <stdlib.h>
 #include <sys/statvfs.h>
 #include "path.h"
-#include "ptvar.h"
+#include "libfrog/ptvar.h"
 #include "xfs_scrub.h"
 #include "common.h"
 #include "fscounters.h"
diff --git a/scrub/read_verify.c b/scrub/read_verify.c
index 4a9b91f2..d56f4893 100644
--- a/scrub/read_verify.c
+++ b/scrub/read_verify.c
@@ -7,7 +7,7 @@
 #include <stdint.h>
 #include <stdlib.h>
 #include <sys/statvfs.h>
-#include "ptvar.h"
+#include "libfrog/ptvar.h"
 #include "workqueue.h"
 #include "path.h"
 #include "xfs_scrub.h"




[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux