lkml.org 
[lkml]   [2023]   [Mar]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v5 1/2] fs/proc: optimize register ctl_tables
From


On 2023/3/2 09:12, Luis Chamberlain wrote:

> That would solve the first part -- the fragile odd checks to bail out
> early. But not the odd accounting we have to do at times. So it begs
> the question if we can instead deprecate register_sysctl_table() and
> then have a counter for us at all times. Also maybe an even simpler
> alternative may just be to see to have the nr_entries be inferred with
> ARRAY_SIZE() if count_subheaders() == 1? I haven't looked into that yet.
>
> Luis
>
The current difficulty is to get the ARRAY_SIZE() of table->child table.

It would be great if have a better way to solve this problem.

Meng

\
 
 \ /
  Last update: 2023-03-27 00:41    [W:0.178 / U:0.120 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site