lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <a1a499b0-a5f6-4c20-dbb1-d5f0a20df818@infradead.org>
Date:   Mon, 2 Aug 2021 22:49:32 -0700
From:   Randy Dunlap <rdunlap@...radead.org>
To:     akpm@...ux-foundation.org, broonie@...nel.org,
        linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
        linux-mm@...ck.org, linux-next@...r.kernel.org, mhocko@...e.cz,
        mm-commits@...r.kernel.org, sfr@...b.auug.org.au,
        Nicholas Piggin <npiggin@...il.com>
Subject: Re: mmotm 2021-08-02-18-51 uploaded (struct user_struct when
 CONFIG_EPOLL is not set)

On 8/2/21 10:41 PM, Randy Dunlap wrote:
> On 8/2/21 6:52 PM, akpm@...ux-foundation.org wrote:
>> The mm-of-the-moment snapshot 2021-08-02-18-51 has been uploaded to
>>
>>     https://www.ozlabs.org/~akpm/mmotm/
>>
>> mmotm-readme.txt says
>>
>> README for mm-of-the-moment:
>>
>> https://www.ozlabs.org/~akpm/mmotm/
>>
>> This is a snapshot of my -mm patch queue.  Uploaded at random hopefully
>> more than once a week.
>>
>> You will need quilt to apply these patches to the latest Linus release 
>> (5.x
>> or 5.x-rcY).  The series file is in broken-out.tar.gz and is 
>> duplicated in
>> https://ozlabs.org/~akpm/mmotm/series
>>
>> The file broken-out.tar.gz contains two datestamp files: .DATE and
>> .DATE-yyyy-mm-dd-hh-mm-ss.  Both contain the string yyyy-mm-dd-hh-mm-ss,
>> followed by the base kernel version against which this patch series is to
>> be applied.
>>
> 
> I am seeing build errors on i386 or x86_64 when CONFIG_EPOLL is not set:
> 
> ../kernel/user.c: In function ‘free_user’:
> ../kernel/user.c:141:30: error: ‘struct user_struct’ has no member named 
> ‘epoll_watches’; did you mean ‘nr_watches’?
>    percpu_counter_destroy(&up->epoll_watches);
>                                ^~~~~~~~~~~~~
>                                nr_watches
> In file included from ../include/linux/sched/user.h:7:0,
>                   from ../kernel/user.c:17:
> ../kernel/user.c: In function ‘alloc_uid’:
> ../kernel/user.c:189:33: error: ‘struct user_struct’ has no member named 
> ‘epoll_watches’; did you mean ‘nr_watches’?
>     if (percpu_counter_init(&new->epoll_watches, 0, GFP_KERNEL)) {
>                                   ^
> ../include/linux/percpu_counter.h:38:25: note: in definition of macro 
> ‘percpu_counter_init’
>     __percpu_counter_init(fbc, value, gfp, &__key);  \
>                           ^~~
> ../kernel/user.c:203:33: error: ‘struct user_struct’ has no member named 
> ‘epoll_watches’; did you mean ‘nr_watches’?
>      percpu_counter_destroy(&new->epoll_watches);
>                                   ^~~~~~~~~~~~~
>                                   nr_watches
> In file included from ../include/linux/sched/user.h:7:0,
>                   from ../kernel/user.c:17:
> ../kernel/user.c: In function ‘uid_cache_init’:
> ../kernel/user.c:225:37: error: ‘struct user_struct’ has no member named 
> ‘epoll_watches’; did you mean ‘nr_watches’?
>    if (percpu_counter_init(&root_user.epoll_watches, 0, GFP_KERNEL))
>                                       ^
> ../include/linux/percpu_counter.h:38:25: note: in definition of macro 
> ‘percpu_counter_init’
>     __percpu_counter_init(fbc, value, gfp, &__key);  \
>                           ^~~
> 
> 

Also do this change in kernel/user.c please:

         if (percpu_counter_init(&root_user.epoll_watches, 0, GFP_KERNEL))
-               panic("percpu cpunter alloc failed");
+               panic("percpu counter alloc failed");


-- 
~Randy
Reported-by: Randy Dunlap <rdunlap@...radead.org>
https://people.kernel.org/tglx/notes-about-netiquette

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ