]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
crimson/osd: fold the split-child setup into handle_split_pg_creation 69120/head
authorKefu Chai <k.chai@proxmox.com>
Wed, 3 Jun 2026 05:53:06 +0000 (13:53 +0800)
committerKefu Chai <k.chai@proxmox.com>
Wed, 3 Jun 2026 06:08:37 +0000 (14:08 +0800)
commita50819465029dfaed785496b470ca29f5a5f6e35
treef6fe5669d3c1f8451547b25e1e69a51261e127dc
parentc004b1fce8636ffa2cc95ed56915a8276234acb8
crimson/osd: fold the split-child setup into handle_split_pg_creation

A readability cleanup with no behaviour change.

split_pg()'s loop still did all the per-child setup inline (core
mapping, make_pg, split_colls, split_into, the snapmapper touch) and
then called handle_split_pg_creation() to kick off the child's
PGAdvanceMap. That is a lot of detail for what the loop is really doing.

So let's move that setup into handle_split_pg_creation() and have it
return the child PG. The loop then just asks it to create each child and
collects the result, and the per-child PeeringCtx never has to leave the
function. Children are still created one at a time, each with its own
PeeringCtx.

Signed-off-by: Kefu Chai <k.chai@proxmox.com>
src/crimson/osd/osd_operations/pg_advance_map.cc
src/crimson/osd/osd_operations/pg_advance_map.h