From 5f77ed8aa58917ae6d5fe8133ef734bc97ae3803 Mon Sep 17 00:00:00 2001
From: Daniel Gustafsson <dgustafsson@postgresql.org>
Date: Wed, 29 Jul 2026 13:33:00 +0200
Subject: [PATCH v3 2/2] Add a comment to distinguish backend types

The data checksums entries were seemingly auxiliary processes from
reading the code, but they are in fact background workers.  Add a
comment to clarify.  Backpatch down to v19 where online checksums
were added.

Author: Daniel Gustafsson <daniel@yesql.se>
Reported-by: Fujii Masao <masao.fujii@gmail.com>
Reviewed-by: Fujii Masao <masao.fujii@gmail.com>
Discussion: https://postgr.es/m/CAHGQGwFsBjQs2fv7b72hxzGV_fJMh6LAg4E83pNfDOu1jVgWCA@mail.gmail.com
Backpatch-through: 19
---
 src/include/miscadmin.h | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/include/miscadmin.h b/src/include/miscadmin.h
index 7170a4bff98..0fc59af02b9 100644
--- a/src/include/miscadmin.h
+++ b/src/include/miscadmin.h
@@ -370,6 +370,10 @@ typedef enum BackendType
 	B_WAL_SUMMARIZER,
 	B_WAL_WRITER,
 
+	/*
+	 * Data checksums processes are dynamic background workers, but they use
+	 * dedicated backend types for pgstat I/O accounting.
+	 */
 	B_DATACHECKSUMSWORKER_LAUNCHER,
 	B_DATACHECKSUMSWORKER_WORKER,
 
-- 
2.39.3 (Apple Git-146)

