From fde6ef66d2f2f5898e28119399da8bfa137f9e5d Mon Sep 17 00:00:00 2001 From: Hongze Cheng Date: Fri, 20 Nov 2020 05:06:03 +0000 Subject: [PATCH] refact --- src/tfs/inc/ttier.h | 2 +- src/tfs/src/tfs.c | 2 +- src/tfs/src/ttier.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/tfs/inc/ttier.h b/src/tfs/inc/ttier.h index 3809890272..b0932909bb 100644 --- a/src/tfs/inc/ttier.h +++ b/src/tfs/inc/ttier.h @@ -34,7 +34,7 @@ typedef struct { void tdInitTier(STier *pTier, int level); void tdDestroyTier(STier *pTier); -SDisk *tdAddDiskToTier(STier *pTier, SDiskCfg *pCfg); +SDisk *tdMountToTier(STier *pTier, SDiskCfg *pCfg); int tdUpdateTierInfo(STier *pTier); #ifdef __cplusplus diff --git a/src/tfs/src/tfs.c b/src/tfs/src/tfs.c index 46e15fc9cf..fe2df03473 100644 --- a/src/tfs/src/tfs.c +++ b/src/tfs/src/tfs.c @@ -172,7 +172,7 @@ static int tfsMount(SDiskCfg *pCfg) { if (tfsCheckAndFormatCfg(pCfg) < 0) return -1; did.level = pCfg->level; - did.id = tdAddDiskToTier(TIER_AT(pCfg->level), pCfg); + did.id = tdMountToTier(TIER_AT(pCfg->level), pCfg); if (did.id < 0) { fError("failed to mount %s to FS since %s", pCfg->dir, tstrerror(terrno)); return -1; diff --git a/src/tfs/src/ttier.c b/src/tfs/src/ttier.c index 10db8678ec..876a281ceb 100644 --- a/src/tfs/src/ttier.c +++ b/src/tfs/src/ttier.c @@ -29,7 +29,7 @@ void tdDestroyTier(STier *pTier) { pTier->ndisk = 0; } -SDisk *tdAddDiskToTier(STier *pTier, SDiskCfg *pCfg) { +SDisk *tdMountToTier(STier *pTier, SDiskCfg *pCfg) { ASSERT(pTier->level == pCfg->level); int id = 0; -- GitLab