From 22d68356f6fc57d4e4382d995c0d83bf001df292 Mon Sep 17 00:00:00 2001 From: huanghua <huanghua> Date: Fri, 11 Jul 2008 05:22:29 +0000 Subject: [PATCH] Branch b1_8_gate b=11930 i=adilger i=nikita.danilov i=alex --- lustre/obdclass/obd_config.c | 23 ++++++++++++++++++++++- 1 file changed, 22 insertions(+), 1 deletion(-) diff --git a/lustre/obdclass/obd_config.c b/lustre/obdclass/obd_config.c index c56aa8feab..6a2b6dbbe9 100644 --- a/lustre/obdclass/obd_config.c +++ b/lustre/obdclass/obd_config.c @@ -34,6 +34,7 @@ #include <obd_class.h> #include <obd.h> #endif +#include <lustre_disk.h> #include <lustre_log.h> #include <lprocfs_status.h> #include <libcfs/list.h> @@ -862,7 +863,7 @@ int class_process_proc_param(char *prefix, struct lprocfs_vars *lvars, ENTRY; if (lcfg->lcfg_command != LCFG_PARAM) { - CERROR("Unknown command: %d\n", lcfg->lcfg_command); + CERROR("Unknown command: %x\n", lcfg->lcfg_command); RETURN(-EINVAL); } @@ -1004,6 +1005,26 @@ static int class_config_llog_handler(struct llog_handle * handle, break; } + /** + * For interop mode between 1.8 and 2.0: + * skip "lmv" configuration which exists since 2.0. + */ + { + char *devname = lustre_cfg_string(lcfg, 0); + char *typename = lustre_cfg_string(lcfg, 1); + + if (devname) + devname += strlen(devname) - strlen("clilmv"); + + if ((lcfg->lcfg_command == LCFG_ATTACH && typename && + strcmp(typename, "lmv") == 0) || + (devname && strcmp(devname, "clilmv") == 0)) { + CWARN("skipping 'lmv' config: cmd=%x,%s:%s\n", + lcfg->lcfg_command, devname, typename); + GOTO(out, rc = 0); + } + } + if ((clli->cfg_flags & CFG_F_EXCLUDE) && (lcfg->lcfg_command == LCFG_LOV_ADD_OBD)) /* Add inactive instead */ -- GitLab