Re: [RFC PATCH v2 0/6] slub: Delay freezing of CPU partial slabs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 10/24/23 04:20, Chengming Zhou wrote:
> On 2023/10/23 23:46, Vlastimil Babka wrote:
>> Or more precisely, instead of returning the acquired "object" we would
>> return the first slab removed from partial list. I think it would simplify
>> the code a bit, and further reduce list_lock holding times.
> 
> Ok, I will do this in the next version. But I find we have to return the object
> in the "IS_ENABLED(CONFIG_SLUB_TINY) || kmem_cache_debug(s)" case, in which
> we need to allocate a single object under the node list_lock.

Ah, right.

> Maybe we can use "struct partial_context" to return the object in this case?
> 
>  struct partial_context {
> -       struct slab **slab;
>         gfp_t flags;
>         unsigned int orig_size;
> +       void *object;
>  };
> 
> Then we can change all get_partial interfaces to return a slab. Do you agree
> with this way?

Yeah, good idea! Thanks!





[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux