From: Oleg Drokin Date: Sun, 3 Jan 2016 20:45:06 +0000 (-0500) Subject: LU-7623 lnet: Get rid of IOC_LIBCFS_PORTALS_COMPATIBILITY ioctl X-Git-Tag: 2.7.66~8 X-Git-Url: https://git.whamcloud.com/?p=fs%2Flustre-release.git;a=commitdiff_plain;h=9bafa64985cae09eee5adaba5725038df1bf12e3 LU-7623 lnet: Get rid of IOC_LIBCFS_PORTALS_COMPATIBILITY ioctl This has been unused for ages and could be safely removed now. Change-Id: I89af1bcce77119780de623b69ee1c74da1bfcce2 Signed-off-by: Oleg Drokin Reviewed-on: http://review.whamcloud.com/17779 Tested-by: Jenkins Tested-by: Maloo Reviewed-by: James Simmons Reviewed-by: John L. Hammond Reviewed-by: Dmitry Eremin --- diff --git a/libcfs/include/libcfs/libcfs_ioctl.h b/libcfs/include/libcfs/libcfs_ioctl.h index 898f613..ee9b86b 100644 --- a/libcfs/include/libcfs/libcfs_ioctl.h +++ b/libcfs/include/libcfs/libcfs_ioctl.h @@ -117,7 +117,7 @@ do { \ #define IOC_LIBCFS_FAIL_NID _IOWR('e', 51, IOCTL_LIBCFS_TYPE) #define IOC_LIBCFS_NOTIFY_ROUTER _IOWR('e', 55, IOCTL_LIBCFS_TYPE) #define IOC_LIBCFS_UNCONFIGURE _IOWR('e', 56, IOCTL_LIBCFS_TYPE) -#define IOC_LIBCFS_PORTALS_COMPATIBILITY _IOWR('e', 57, IOCTL_LIBCFS_TYPE) +/* IOC_LIBCFS_PORTALS_COMPATIBILITY _IOWR('e', 57, IOCTL_LIBCFS_TYPE) */ #define IOC_LIBCFS_LNET_DIST _IOWR('e', 58, IOCTL_LIBCFS_TYPE) #define IOC_LIBCFS_CONFIGURE _IOWR('e', 59, IOCTL_LIBCFS_TYPE) #define IOC_LIBCFS_TESTPROTOCOMPAT _IOWR('e', 60, IOCTL_LIBCFS_TYPE) diff --git a/lnet/lnet/api-ni.c b/lnet/lnet/api-ni.c index 40d3bb8..52a53cc 100644 --- a/lnet/lnet/api-ni.c +++ b/lnet/lnet/api-ni.c @@ -1855,7 +1855,7 @@ out: } /** - * IOC_LIBCFS_PORTALS_COMPATIBILITY is now deprecated, don't use it. + * LNet ioctl handler. * */ int @@ -2034,10 +2034,6 @@ LNetCtl(unsigned int cmd, void *arg) cfs_time_seconds(cfs_time_current_sec() - (time_t)data->ioc_u64[0])); - case IOC_LIBCFS_PORTALS_COMPATIBILITY: - /* This can be removed once lustre stops calling it */ - return 0; - case IOC_LIBCFS_LNET_DIST: rc = LNetDist(data->ioc_nid, &data->ioc_nid, &data->ioc_u32[1]); if (rc < 0 && rc != -EHOSTUNREACH) diff --git a/lustre/ptlrpc/events.c b/lustre/ptlrpc/events.c index adb8c03..035aa47 100644 --- a/lustre/ptlrpc/events.c +++ b/lustre/ptlrpc/events.c @@ -502,14 +502,11 @@ int ptlrpc_uuid_to_peer (struct obd_uuid *uuid, __u32 best_order = 0; int count = 0; int rc = -ENOENT; - int portals_compatibility; int dist; __u32 order; lnet_nid_t dst_nid; lnet_nid_t src_nid; - portals_compatibility = LNetCtl(IOC_LIBCFS_PORTALS_COMPATIBILITY, NULL); - peer->pid = LNET_PID_LUSTRE; /* Choose the matching UUID that's closest */ @@ -530,14 +527,6 @@ int ptlrpc_uuid_to_peer (struct obd_uuid *uuid, best_dist = dist; best_order = order; - if (portals_compatibility > 1) { - /* Strong portals compatibility: Zero the nid's - * NET, so if I'm reading new config logs, or - * getting configured by (new) lconf I can - * still talk to old servers. */ - dst_nid = LNET_MKNID(0, LNET_NIDADDR(dst_nid)); - src_nid = LNET_MKNID(0, LNET_NIDADDR(src_nid)); - } peer->nid = dst_nid; *self = src_nid; rc = 0;