osd/osd_types: add pg_pool_t FLAG_POOL_CREATING

Signed-off-by: Sage Weil <sage@redhat.com>
This commit is contained in:
Sage Weil 2018-04-06 21:38:26 -05:00
parent 52e18ec08a
commit 0e526b467a
2 changed files with 5 additions and 1 deletions

View File

@ -1661,7 +1661,7 @@ void pg_pool_t::encode(bufferlist& bl, uint64_t features) const
encode(flags, bl);
} else {
auto tmp = flags;
tmp &= ~(FLAG_SELFMANAGED_SNAPS | FLAG_POOL_SNAPS);
tmp &= ~(FLAG_SELFMANAGED_SNAPS | FLAG_POOL_SNAPS | FLAG_CREATING);
encode(tmp, bl);
}
encode((uint32_t)0, bl); // crash_replay_interval

View File

@ -1190,6 +1190,7 @@ struct pg_pool_t {
FLAG_BACKFILLFULL = 1<<12, // pool is backfillfull
FLAG_SELFMANAGED_SNAPS = 1<<13, // pool uses selfmanaged snaps
FLAG_POOL_SNAPS = 1<<14, // pool has pool snaps
FLAG_CREATING = 1<<15, // initial pool PGs are being created
};
static const char *get_flag_name(int f) {
@ -1209,6 +1210,7 @@ struct pg_pool_t {
case FLAG_BACKFILLFULL: return "backfillfull";
case FLAG_SELFMANAGED_SNAPS: return "selfmanaged_snaps";
case FLAG_POOL_SNAPS: return "pool_snaps";
case FLAG_CREATING: return "creating";
default: return "???";
}
}
@ -1257,6 +1259,8 @@ struct pg_pool_t {
return FLAG_SELFMANAGED_SNAPS;
if (name == "pool_snaps")
return FLAG_POOL_SNAPS;
if (name == "creating")
return FLAG_CREATING;
return 0;
}