From: Stephen Rothwell <sfr@canb.auug.org.au>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: Kees Cook <kees@kernel.org>, Jeff Xu <jeffxu@chromium.org>,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
Linux Next Mailing List <linux-next@vger.kernel.org>,
Yu Zhao <yuzhao@google.com>
Subject: Re: linux-next: manual merge of the execve tree with the mm tree
Date: Thu, 19 Sep 2024 09:04:07 +1000 [thread overview]
Message-ID: <20240919090407.30c30759@canb.auug.org.au> (raw)
In-Reply-To: <20240909171843.78c294da@canb.auug.org.au>
[-- Attachment #1: Type: text/plain, Size: 3206 bytes --]
Hi all,
On Mon, 9 Sep 2024 17:18:43 +1000 Stephen Rothwell <sfr@canb.auug.org.au> wrote:
>
> Today's linux-next merge of the execve tree got a conflict in:
>
> include/linux/mm.h
>
> between commits:
>
> 99ab6f0a6854 ("mm/codetag: fix pgalloc_tag_split()")
> 4d42ecdbd2fb ("mm/codetag: add pgalloc_tag_copy()")
>
> from the mm-unstable branch of the mm tree and commit:
>
> 44f65d900698 ("binfmt_elf: mseal address zero")
>
> from the execve 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.
>
> diff --cc include/linux/mm.h
> index 79d69e998649,a178c15812eb..000000000000
> --- a/include/linux/mm.h
> +++ b/include/linux/mm.h
> @@@ -4148,61 -4201,14 +4148,71 @@@ void vma_pgtable_walk_end(struct vm_are
>
> int reserve_mem_find_by_name(const char *name, phys_addr_t *start, phys_addr_t *size);
>
> +#ifdef CONFIG_MEM_ALLOC_PROFILING
> +static inline void pgalloc_tag_split(struct folio *folio, int old_order, int new_order)
> +{
> + int i;
> + struct alloc_tag *tag;
> + unsigned int nr_pages = 1 << new_order;
> +
> + if (!mem_alloc_profiling_enabled())
> + return;
> +
> + tag = pgalloc_tag_get(&folio->page);
> + if (!tag)
> + return;
> +
> + for (i = nr_pages; i < (1 << old_order); i += nr_pages) {
> + union codetag_ref *ref = get_page_tag_ref(folio_page(folio, i));
> +
> + if (ref) {
> + /* Set new reference to point to the original tag */
> + alloc_tag_ref_set(ref, tag);
> + put_page_tag_ref(ref);
> + }
> + }
> +}
> +
> +static inline void pgalloc_tag_copy(struct folio *new, struct folio *old)
> +{
> + struct alloc_tag *tag;
> + union codetag_ref *ref;
> +
> + tag = pgalloc_tag_get(&old->page);
> + if (!tag)
> + return;
> +
> + ref = get_page_tag_ref(&new->page);
> + if (!ref)
> + return;
> +
> + /* Clear the old ref to the original allocation tag. */
> + clear_page_tag_ref(&old->page);
> + /* Decrement the counters of the tag on get_new_folio. */
> + alloc_tag_sub(ref, folio_nr_pages(new));
> +
> + __alloc_tag_ref_set(ref, tag);
> +
> + put_page_tag_ref(ref);
> +}
> +#else /* !CONFIG_MEM_ALLOC_PROFILING */
> +static inline void pgalloc_tag_split(struct folio *folio, int old_order, int new_order)
> +{
> +}
> +
> +static inline void pgalloc_tag_copy(struct folio *new, struct folio *old)
> +{
> +}
> +#endif /* CONFIG_MEM_ALLOC_PROFILING */
> +
> + #ifdef CONFIG_64BIT
> + int do_mseal(unsigned long start, size_t len_in, unsigned long flags);
> + #else
> + static inline int do_mseal(unsigned long start, size_t len_in, unsigned long flags)
> + {
> + /* noop on 32 bit */
> + return 0;
> + }
> + #endif
> +
> #endif /* _LINUX_MM_H */
This is now a conflict between the mm-stable tree and Linus' tree.
--
Cheers,
Stephen Rothwell
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
next prev parent reply other threads:[~2024-09-18 23:04 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-09-09 7:18 linux-next: manual merge of the execve tree with the mm tree Stephen Rothwell
2024-09-09 7:29 ` Yu Zhao
2024-09-18 23:04 ` Stephen Rothwell [this message]
-- strict thread matches above, loose matches on Subject: below --
2024-04-26 5:57 Stephen Rothwell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20240919090407.30c30759@canb.auug.org.au \
--to=sfr@canb.auug.org.au \
--cc=akpm@linux-foundation.org \
--cc=jeffxu@chromium.org \
--cc=kees@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--cc=yuzhao@google.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox