Blob Blame History Raw
commit 1f608d21322339afad8cea32bcbbc840a0f5191a
Author: Frank Ch. Eigler <fche@redhat.com>
Date:   Tue Nov 10 20:15:48 2020 -0500

    PR26665: relayfs-on-procfs megapatch, rhel6 tweaks
    
    A few more compatibility macros needed to be moved over to transport/procfs.c.

diff --git a/runtime/procfs.c b/runtime/procfs.c
index 121b12fe3..c2b5aacf2 100644
--- a/runtime/procfs.c
+++ b/runtime/procfs.c
@@ -27,10 +27,6 @@
 #include "proc_fs_compatibility.h"
 #include "uidgid_compatibility.h"
 
-#if defined(STAPCONF_PATH_LOOKUP) && !defined(STAPCONF_KERN_PATH_PARENT)
-#define kern_path_parent(name, nameidata) \
-	path_lookup(name, LOOKUP_PARENT, nameidata)
-#endif
 
 /* If STAPCONF_PDE_DATA isn't defined, we're using the original /proc
  * interface (where 'struct proc_dir_entry' isn't opaque). In this
diff --git a/runtime/transport/procfs.c b/runtime/transport/procfs.c
index 520e17cd5..262409356 100644
--- a/runtime/transport/procfs.c
+++ b/runtime/transport/procfs.c
@@ -10,7 +10,12 @@
  */
 
 #include "relay_compat.h"
+#include "proc_fs_compatibility.h"
 
+#if defined(STAPCONF_PATH_LOOKUP) && !defined(STAPCONF_KERN_PATH_PARENT)
+#define kern_path_parent(name, nameidata) \
+	path_lookup(name, LOOKUP_PARENT, nameidata)
+#endif
 
 /* _stp_procfs_module_dir is the '/proc/systemtap/{module_name}' directory. */
 static struct proc_dir_entry *_stp_procfs_module_dir = NULL;
@@ -27,6 +32,7 @@ static struct path _stp_procfs_module_dir_path;
 static int _stp_mkdir_proc_module(void)
 {	
 	int found = 0;
+	int rc;
 	static char proc_root_name[STP_MODULE_NAME_LEN + sizeof("systemtap/")];
 #if defined(STAPCONF_PATH_LOOKUP) || defined(STAPCONF_KERN_PATH_PARENT)
 	struct nameidata nd;
@@ -35,7 +41,6 @@ static int _stp_mkdir_proc_module(void)
 #if defined(STAPCONF_VFS_PATH_LOOKUP)
 	struct vfsmount *mnt;
 #endif
-	int rc;
 #endif	/* STAPCONF_VFS_PATH_LOOKUP or STAPCONF_KERN_PATH */
 
         if (_stp_procfs_module_dir != NULL)