[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <87tswz74jb.fsf@linux.dev>
Date: Mon, 05 Jan 2026 20:23:36 -0800
From: Roman Gushchin <roman.gushchin@...ux.dev>
To: Alexei Starovoitov <alexei.starovoitov@...il.com>
Cc: Stephen Rothwell <sfr@...b.auug.org.au>, Daniel Borkmann
<daniel@...earbox.net>, Alexei Starovoitov <ast@...nel.org>, Andrii
Nakryiko <andrii@...nel.org>, Andrew Morton <akpm@...ux-foundation.org>,
bpf <bpf@...r.kernel.org>, Networking <netdev@...r.kernel.org>, Chen
Ridong <chenridong@...wei.com>, JP Kobryn <inwardvessel@...il.com>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>, Linux Next
Mailing List <linux-next@...r.kernel.org>
Subject: Re: linux-next: manual merge of the bpf-next tree with the
mm-unstable tree
Alexei Starovoitov <alexei.starovoitov@...il.com> writes:
> On Sun, Jan 4, 2026 at 6:04 PM Stephen Rothwell <sfr@...b.auug.org.au> wrote:
>>
>> Hi all,
>>
>> Today's linux-next merge of the bpf-next tree got a semantic conflict in:
>>
>> include/linux/memcontrol.h
>> mm/memcontrol-v1.c
>> mm/memcontrol.c
>>
>> between commit:
>>
>> eb557e10dcac ("memcg: move mem_cgroup_usage memcontrol-v1.c")
>>
>> from the mm-unstable tree and commit:
>>
>> 99430ab8b804 ("mm: introduce BPF kfuncs to access memcg statistics and events")
>>
>> from the bpf-next tree producing this build failure:
>>
>> mm/memcontrol-v1.c:430:22: error: static declaration of 'mem_cgroup_usage' follows non-static declaration
>> 430 | static unsigned long mem_cgroup_usage(struct mem_cgroup *memcg, bool swap)
>> | ^~~~~~~~~~~~~~~~
>> In file included from mm/memcontrol-v1.c:3:
>> include/linux/memcontrol.h:953:15: note: previous declaration of
>> 'mem_cgroup_usage' with type 'long unsigned int(struct mem_cgroup *,
>> bool)' {aka 'long unsigned int(struct mem_cgroup *, _Bool)'}
>> 953 | unsigned long mem_cgroup_usage(struct mem_cgroup *memcg, bool swap);
>> | ^~~~~~~~~~~~~~~~
>>
>> I fixed it up (I reverted the mm-unstable tree commit) and can carry the
>> fix as necessary. This is now fixed as far as linux-next is concerned,
>> but any non trivial conflicts should be mentioned to your upstream
>> maintainer when your tree is submitted for merging. You may also want
>> to consider cooperating with the maintainer of the conflicting tree to
>> minimise any particularly complex conflicts.
>
> Hey All,
>
> what's the proper fix here?
>
> Roman,
>
> looks like adding mem_cgroup_usage() to include/linux/memcontrol.h
> wasn't really necessary, since kfuncs don't use it anyway?
> Should we just remove that line in bpf-next?
Yep. It was used in the previous version, but not in the latest one.
Just sent an official fix.
Thanks!
Powered by blists - more mailing lists