From: Fan Yong Date: Tue, 3 Dec 2013 13:58:43 +0000 (+0800) Subject: staging/lustre/scrub: OI scrub on OST X-Git-Tag: firefly_0821_release~176^2~4489^2~678 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=c0ac76d9bc12d5485c899265ef1309a7dd00d854;p=firefly-linux-kernel-4.4.55.git staging/lustre/scrub: OI scrub on OST Main part of original patch in Lustre tree (http://review.whamcloud.com/6669) changes server code and is unneeded by client. The patch only picks up common functions and data structures change. Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3335 Lustre-change: http://review.whamcloud.com/6669 Signed-off-by: Fan Yong Reviewed-by: Andreas Dilger Reviewed-by: Alex Zhuravlev Signed-off-by: Peng Tao Signed-off-by: Andreas Dilger Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/lustre/lustre/include/lustre/lustre_idl.h b/drivers/staging/lustre/lustre/include/lustre/lustre_idl.h index 7dfb925a536b..08da4f331f23 100644 --- a/drivers/staging/lustre/lustre/include/lustre/lustre_idl.h +++ b/drivers/staging/lustre/lustre/include/lustre/lustre_idl.h @@ -321,8 +321,11 @@ static inline int range_compare_loc(const struct lu_seq_range *r1, * xattr. */ enum lma_compat { - LMAC_HSM = 0x00000001, - LMAC_SOM = 0x00000002, + LMAC_HSM = 0x00000001, + LMAC_SOM = 0x00000002, + LMAC_NOT_IN_OI = 0x00000004, /* the object does NOT need OI mapping */ + LMAC_FID_ON_OST = 0x00000008, /* For OST-object, its OI mapping is + * under /O//d. */ }; /** diff --git a/drivers/staging/lustre/lustre/include/obd_support.h b/drivers/staging/lustre/lustre/include/obd_support.h index 825a0c95c585..1748985bb466 100644 --- a/drivers/staging/lustre/lustre/include/obd_support.h +++ b/drivers/staging/lustre/lustre/include/obd_support.h @@ -256,6 +256,7 @@ int obd_alloc_fail(const void *ptr, const char *name, const char *type, #define OBD_FAIL_OSD_SCRUB_FATAL 0x192 #define OBD_FAIL_OSD_FID_MAPPING 0x193 #define OBD_FAIL_OSD_LMA_INCOMPAT 0x194 +#define OBD_FAIL_OSD_COMPAT_INVALID_ENTRY 0x195 #define OBD_FAIL_OST 0x200 #define OBD_FAIL_OST_CONNECT_NET 0x201 diff --git a/drivers/staging/lustre/lustre/ptlrpc/wiretest.c b/drivers/staging/lustre/lustre/ptlrpc/wiretest.c index 6cc0d6e61f12..c2efd118ddf9 100644 --- a/drivers/staging/lustre/lustre/ptlrpc/wiretest.c +++ b/drivers/staging/lustre/lustre/ptlrpc/wiretest.c @@ -431,6 +431,10 @@ void lustre_assert_wire_constants(void) (unsigned)LMAC_HSM); LASSERTF(LMAC_SOM == 0x00000002UL, "found 0x%.8xUL\n", (unsigned)LMAC_SOM); + LASSERTF(LMAC_NOT_IN_OI == 0x00000004UL, "found 0x%.8xUL\n", + (unsigned)LMAC_NOT_IN_OI); + LASSERTF(LMAC_FID_ON_OST == 0x00000008UL, "found 0x%.8xUL\n", + (unsigned)LMAC_FID_ON_OST); LASSERTF(OBJ_CREATE == 1, "found %lld\n", (long long)OBJ_CREATE); LASSERTF(OBJ_DESTROY == 2, "found %lld\n",