Re: [PATCH] drivers/base/memory: Avoid overhead from for_each_present_section_nr()

From: David Hildenbrand
Date: Thu Apr 10 2025 - 10:29:08 EST


On 10.04.25 16:12, Oscar Salvador wrote:
On Thu, Apr 10, 2025 at 03:55:19PM +0200, Oscar Salvador wrote:
All in all, I think we are better, and the code is slightly simpler?

One thing to notice is that maybe we could further improve and leap 'nr'
by the number of sections_per_block, so in those scenarios where
a memory-block spans multiple sections this could be faster?

Essentially, when we created a block we could always start with the next section that starts after the block.

--
Cheers,

David / dhildenb