From 8f2f6cd2ac688916adb2caf979daf95365ccb48f Mon Sep 17 00:00:00 2001 From: Rob Norris Date: Mon, 19 Feb 2024 21:19:32 +1100 Subject: [PATCH] ddt: reduce DDT_NAMELEN This is the buffer size passed to ddt_object_name(), to expand the DMU_POOL_DDT format. That format inserts the table checksum, class and type names, which as I write this are max 6, 9 and 3, respectively. Reviewed by: Brian Behlendorf Signed-off-by: Rob Norris Sponsored-by: https://despairlabs.com/sponsor/ Closes #15908 --- include/sys/ddt_impl.h | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/include/sys/ddt_impl.h b/include/sys/ddt_impl.h index d669365888..52b927b751 100644 --- a/include/sys/ddt_impl.h +++ b/include/sys/ddt_impl.h @@ -66,7 +66,12 @@ extern void ddt_stat_update(ddt_t *ddt, ddt_entry_t *dde, uint64_t neg); * outside of the DDT implementation proper, and if you do, consider moving * them up. */ -#define DDT_NAMELEN 110 + +/* + * Enough room to expand DMU_POOL_DDT format for all possible DDT + * checksum/class/type combinations. + */ +#define DDT_NAMELEN 32 extern uint64_t ddt_phys_total_refcnt(const ddt_entry_t *dde);