* linux-next: manual merge of the mm tree with the bpf-next tree
@ 2023-02-15 2:57 Stephen Rothwell
2023-02-15 3:26 ` Roman Gushchin
0 siblings, 1 reply; 2+ messages in thread
From: Stephen Rothwell @ 2023-02-15 2:57 UTC (permalink / raw)
To: Andrew Morton, Daniel Borkmann, Alexei Starovoitov,
Andrii Nakryiko
Cc: bpf, Networking, Linux Kernel Mailing List,
Linux Next Mailing List, Roman Gushchin, Yafang Shao
[-- Attachment #1: Type: text/plain, Size: 2671 bytes --]
Hi all,
Today's linux-next merge of the mm tree got conflicts in:
include/linux/memcontrol.h
mm/memcontrol.c
between commit:
b6c1a8af5b1e ("mm: memcontrol: add new kernel parameter cgroup.memory=nobpf")
from the bpf-next tree and commit:
2006d382484e ("mm: memcontrol: rename memcg_kmem_enabled()")
from the mm tree.
I fixed it up (see below) 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.
--
Cheers,
Stephen Rothwell
diff --cc include/linux/memcontrol.h
index e7310363f0cb,5567319027d1..000000000000
--- a/include/linux/memcontrol.h
+++ b/include/linux/memcontrol.h
@@@ -1776,17 -1776,11 +1776,17 @@@ struct obj_cgroup *get_obj_cgroup_from_
int obj_cgroup_charge(struct obj_cgroup *objcg, gfp_t gfp, size_t size);
void obj_cgroup_uncharge(struct obj_cgroup *objcg, size_t size);
+extern struct static_key_false memcg_bpf_enabled_key;
+static inline bool memcg_bpf_enabled(void)
+{
+ return static_branch_likely(&memcg_bpf_enabled_key);
+}
+
- extern struct static_key_false memcg_kmem_enabled_key;
+ extern struct static_key_false memcg_kmem_online_key;
- static inline bool memcg_kmem_enabled(void)
+ static inline bool memcg_kmem_online(void)
{
- return static_branch_likely(&memcg_kmem_enabled_key);
+ return static_branch_likely(&memcg_kmem_online_key);
}
static inline int memcg_kmem_charge_page(struct page *page, gfp_t gfp,
@@@ -1860,12 -1854,7 +1860,12 @@@ static inline struct obj_cgroup *get_ob
return NULL;
}
+static inline bool memcg_bpf_enabled(void)
+{
+ return false;
+}
+
- static inline bool memcg_kmem_enabled(void)
+ static inline bool memcg_kmem_online(void)
{
return false;
}
diff --cc mm/memcontrol.c
index 186a3a56dd7c,3e3cdb9bed95..000000000000
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@@ -348,11 -345,8 +348,11 @@@ static void memcg_reparent_objcgs(struc
* conditional to this static branch, we'll have to allow modules that does
* kmem_cache_alloc and the such to see this symbol as well
*/
- DEFINE_STATIC_KEY_FALSE(memcg_kmem_enabled_key);
- EXPORT_SYMBOL(memcg_kmem_enabled_key);
+ DEFINE_STATIC_KEY_FALSE(memcg_kmem_online_key);
+ EXPORT_SYMBOL(memcg_kmem_online_key);
+
+DEFINE_STATIC_KEY_FALSE(memcg_bpf_enabled_key);
+EXPORT_SYMBOL(memcg_bpf_enabled_key);
#endif
/**
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: linux-next: manual merge of the mm tree with the bpf-next tree
2023-02-15 2:57 linux-next: manual merge of the mm tree with the bpf-next tree Stephen Rothwell
@ 2023-02-15 3:26 ` Roman Gushchin
0 siblings, 0 replies; 2+ messages in thread
From: Roman Gushchin @ 2023-02-15 3:26 UTC (permalink / raw)
To: Stephen Rothwell
Cc: Andrew Morton, Daniel Borkmann, Alexei Starovoitov,
Andrii Nakryiko, bpf, Networking, Linux Kernel Mailing List,
Linux Next Mailing List, Yafang Shao
Hi Stephen,
the merge looks good to me. Thank you for doing this!
Roman
> On Feb 14, 2023, at 6:57 PM, Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> Hi all,
>
> Today's linux-next merge of the mm tree got conflicts in:
>
> include/linux/memcontrol.h
> mm/memcontrol.c
>
> between commit:
>
> b6c1a8af5b1e ("mm: memcontrol: add new kernel parameter cgroup.memory=nobpf")
>
> from the bpf-next tree and commit:
>
> 2006d382484e ("mm: memcontrol: rename memcg_kmem_enabled()")
>
> from the mm tree.
>
> I fixed it up (see below) 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.
>
> --
> Cheers,
> Stephen Rothwell
>
> diff --cc include/linux/memcontrol.h
> index e7310363f0cb,5567319027d1..000000000000
> --- a/include/linux/memcontrol.h
> +++ b/include/linux/memcontrol.h
> @@@ -1776,17 -1776,11 +1776,17 @@@ struct obj_cgroup *get_obj_cgroup_from_
> int obj_cgroup_charge(struct obj_cgroup *objcg, gfp_t gfp, size_t size);
> void obj_cgroup_uncharge(struct obj_cgroup *objcg, size_t size);
>
> +extern struct static_key_false memcg_bpf_enabled_key;
> +static inline bool memcg_bpf_enabled(void)
> +{
> + return static_branch_likely(&memcg_bpf_enabled_key);
> +}
> +
> - extern struct static_key_false memcg_kmem_enabled_key;
> + extern struct static_key_false memcg_kmem_online_key;
>
> - static inline bool memcg_kmem_enabled(void)
> + static inline bool memcg_kmem_online(void)
> {
> - return static_branch_likely(&memcg_kmem_enabled_key);
> + return static_branch_likely(&memcg_kmem_online_key);
> }
>
> static inline int memcg_kmem_charge_page(struct page *page, gfp_t gfp,
> @@@ -1860,12 -1854,7 +1860,12 @@@ static inline struct obj_cgroup *get_ob
> return NULL;
> }
>
> +static inline bool memcg_bpf_enabled(void)
> +{
> + return false;
> +}
> +
> - static inline bool memcg_kmem_enabled(void)
> + static inline bool memcg_kmem_online(void)
> {
> return false;
> }
> diff --cc mm/memcontrol.c
> index 186a3a56dd7c,3e3cdb9bed95..000000000000
> --- a/mm/memcontrol.c
> +++ b/mm/memcontrol.c
> @@@ -348,11 -345,8 +348,11 @@@ static void memcg_reparent_objcgs(struc
> * conditional to this static branch, we'll have to allow modules that does
> * kmem_cache_alloc and the such to see this symbol as well
> */
> - DEFINE_STATIC_KEY_FALSE(memcg_kmem_enabled_key);
> - EXPORT_SYMBOL(memcg_kmem_enabled_key);
> + DEFINE_STATIC_KEY_FALSE(memcg_kmem_online_key);
> + EXPORT_SYMBOL(memcg_kmem_online_key);
> +
> +DEFINE_STATIC_KEY_FALSE(memcg_bpf_enabled_key);
> +EXPORT_SYMBOL(memcg_bpf_enabled_key);
> #endif
>
> /**
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2023-02-15 3:32 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-02-15 2:57 linux-next: manual merge of the mm tree with the bpf-next tree Stephen Rothwell
2023-02-15 3:26 ` Roman Gushchin
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox