Re: [PATCH 2/2] mm/memblock: Add reserve_mem debugfs info
From: Guilherme G. Piccoli
Date: Sun Feb 22 2026 - 15:19:28 EST
On 22/02/2026 16:19, Mike Rapoport wrote:
> [...]
>> First of all, what should we do regarding patch 1? Should I resubmit as
>> part of V2, even with no changes - or pick it now and I only submit
>> patch 2 as V2, with changes?
>
> Please resend both patches together.
>
Hi Mike! OK, thanks.
>> [...]
>> Specifically here, by magic number you mean my choice of 16, right? What
>> do you suggest me to pick? It's the length of the string carrying the
>> size of reserved_mem, some number must be selected for this
>> length...lemme know WDYT.
>
> sizeof(txtsz) should work :)
>
Ahh OK heh
I thought you were not happy with 16 as the size (this is an arbitrary
number itself), but it's just on the func argument - cool, will fix it!
>>> [...]
>> Very good suggestions here, but just let me clarify: so I could continue
>> showing the "reserved_mem_param" inside the "<debugfs>/memblock" folder,
>> just using a different function for that attribute?
>
> Yes, something like
>
> static int memblock_reserve_mem_show(struct seq_file *m, void *private)
> {
> ...
> }
> DEFINE_SHOW_ATTRIBUTE(memblock_reserve_mem);
>
>> I understood that, based on your (good) suggestion to hide the memblock
>> folder if ARCH_KEEP_MEMBLOCK is not defined and there is no reserved_mem
>> set ... just want to confirm to follow-up the implementation.
>
> Yes, that's what I meant.
>
Great, thanks a lot again!
Cheers,
Guilherme