Skip to contentSkip to conversation

staging: lustre: remove IOC_LIBCFS_PING_TEST ioctl

PATCH Dilger, Andreas 3 participants 4 messages Nov 27, 2015 – Dec 21, 2015

lore
Share & tools
lore
#0 lore raw
Quoted 6 lines · James Simmons

The ioctl IOC_LIBCFS_PING_TEST has not been used in ages. The recent nidstring changes which moved all the nidstring operations from libcfs to the LNet layer but this ioctl code was still using an nidstring operation that was causing an circular dependency loop between libcfs and LNet:

Hi Greg,
are you planning on pushing this patch to Linus for 4.4? It was resent on 11/08 per your request on 11/07 but I don't see it in staging or staging-next yet. Since it fixes the depmod dependency cycle for allmodconfig builds on mainline it seems worthwhile to include into 4.4-rc3 rather than waiting for 4.5.

Cheers, Andreas

Quoted 52 lines

---
.../lustre/include/linux/libcfs/libcfs_ioctl.h | 1 -
drivers/staging/lustre/lustre/libcfs/module.c | 17
-----------------

2 files changed, 0 insertions(+), 18 deletions(-)
drivers/staging/lustre/include/linux/libcfs/libcfs_ioctl.h +0 -1
index f5d741f..485ab26 100644
@@ -110,7 +110,6 @@ struct libcfs_ioctl_handler {
 #define IOC_LIBCFS_CLEAR_DEBUG	     _IOWR('e', 31, long)
 #define IOC_LIBCFS_MARK_DEBUG	      _IOWR('e', 32, long)
 #define IOC_LIBCFS_MEMHOG		  _IOWR('e', 36, long)
-#define IOC_LIBCFS_PING_TEST	       _IOWR('e', 37, long)
 /* lnet ioctls */
 #define IOC_LIBCFS_GET_NI		  _IOWR('e', 50, long)
 #define IOC_LIBCFS_FAIL_NID		_IOWR('e', 51, long)
drivers/staging/lustre/lustre/libcfs/module.c +0 -17
index 570f05c..89038ed 100644
@@ -274,23 +274,6 @@ static int libcfs_ioctl_int(struct cfs_psdev_file
 		}
 		break;
 
-	case IOC_LIBCFS_PING_TEST: {
-		extern void (kping_client)(struct libcfs_ioctl_data *);
-		void (*ping)(struct libcfs_ioctl_data *);
-
-		CDEBUG(D_IOCTL, "doing %d pings to nid %s (%s)\n",
-		       data->ioc_count, libcfs_nid2str(data->ioc_nid),
-		       libcfs_nid2str(data->ioc_nid));
-		ping = symbol_get(kping_client);
-		if (!ping)
-			CERROR("symbol_get failed\n");
-		else {
-			ping(data);
-			symbol_put(kping_client);
-		}
-		return 0;
-	}
-
 	default: {
 		struct libcfs_ioctl_handler *hand;
 
Signature · 2 lines
-- 
1.7.1
#1 lore raw
Quoted 9 lines · Andreas
Quoted 6 lines · James Simmons

The ioctl IOC_LIBCFS_PING_TEST has not been used in ages. The recent nidstring changes which moved all the nidstring operations from libcfs to the LNet layer but this ioctl code was still using an nidstring operation that was causing an circular dependency loop between libcfs and LNet:

Quoted 6 lines

Hi Greg,
are you planning on pushing this patch to Linus for 4.4? It was resent on 11/08 per your request on 11/07 but I don't see it in staging or staging-next yet. Since it fixes the depmod dependency cycle for allmodconfig builds on mainline it seems worthwhile to include into 4.4-rc3 rather than waiting for 4.5.

No one told me it fixed a bug, let me see if it's still even needed...

#2 lore raw
Quoted 2 lines · Greg Kroah-Hartman

No one told me it fixed a bug, let me see if it's still even needed...

You were definitely cc'd on a couple of the threads..

But it's done now (well, two weeks ago), I applied it as commit d035e336287b ("staging/lustre: remove IOC_LIBCFS_PING_TEST ioctl").

Linus

#3 lore raw
Quoted 9 lines · Linus Torvalds
Quoted 2 lines · Greg Kroah-Hartman

No one told me it fixed a bug, let me see if it's still even needed...

You were definitely cc'd on a couple of the threads..

But it's done now (well, two weeks ago), I applied it as commit d035e336287b ("staging/lustre: remove IOC_LIBCFS_PING_TEST ioctl").

Ah, see it now, sorry about that, catching up on old staging patches right now...