mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andrew Morton <akpm@linux-foundation.org>
To: Mark Brown <broonie@kernel.org>
Cc: David Hildenbrand <david@kernel.org>,
	Mike Rapoport <rppt@kernel.org>,
	Vlastimil Babka <vbabka@kernel.org>,
	Chad Aldreda <ca@modelmiser.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Linux Next Mailing List <linux-next@vger.kernel.org>,
	Lorenzo Stoakes <ljs@kernel.org>, Paolo Abeni <pabeni@redhat.com>
Subject: Re: linux-next: manual merge of the mm tree with the origin tree
Date: Fri, 27 Nov 2026 13:04:07 -0800	[thread overview]
Message-ID: <20261127130407.a16eb8d76a635c13b024d234@linux-foundation.org> (raw)
In-Reply-To: <awmTUV81zRGpj0Tu@sirena.org.uk>

On Fri, 27 Nov 2026 14:27:29 +0000 Mark Brown <broonie@kernel.org> wrote:

> Hi all,
> 
> Today's linux-next merge of the mm tree got a conflict in:
> 
>   drivers/ptp/ptp_vmclock.c
> 
> between commit:
> 
>   e6474ead54b8a ("ptp: vmclock: keep the device state until the last file is closed")
> 
> from the origin tree and commit:
> 
>   92cdcfbf70344 ("ptp: vmclock: convert mmap hook to mmap_prepare")
> 
> from the mm tree.
> 

Yup, thanks.  I've resynced with upstream, hit the same thing and
resolved it thusly:

static int vmclock_miscdev_mmap_prepare(struct vm_area_desc *desc)
{
	struct vmclock_file_state *fst = desc->file->private_data;
	struct vmclock_state *st = fst->st;

	if (READ_ONCE(st->removed))
		return -ENODEV;

	if (!vma_desc_test(desc, VMA_READ_BIT) ||
	    vma_desc_test(desc, VMA_WRITE_BIT))
		return -EROFS;

	/*
	 * Restrict the read-only mapping so it cannot be upgraded to
	 * writable later with mprotect().
	 */
	vma_desc_clear_flags(desc, VMA_MAYWRITE_BIT);

	if (vma_desc_size(desc) != PAGE_SIZE || desc->pgoff)
		return -EINVAL;

	mmap_action_ioremap_full(desc, st->res.start >> PAGE_SHIFT);
	desc->action.error_override = -EAGAIN;

	return 0;
}


  parent reply	other threads:[~2026-11-27 21:04 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-27 14:27 Mark Brown
2026-11-27 14:31 ` Lorenzo Stoakes (ARM)
2026-11-27 21:04 ` Andrew Morton [this message]
  -- strict thread matches above, loose matches on Subject: below --
2026-10-21 13:06 Mark Brown
2026-10-21 14:44 ` Magnus Lindholm
2026-10-21 14:51   ` Lorenzo Stoakes (ARM)

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=20261127130407.a16eb8d76a635c13b024d234@linux-foundation.org \
    --to=akpm@linux-foundation.org \
    --cc=broonie@kernel.org \
    --cc=ca@modelmiser.com \
    --cc=david@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=ljs@kernel.org \
    --cc=pabeni@redhat.com \
    --cc=rppt@kernel.org \
    --cc=vbabka@kernel.org \
    /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

all inboxes | Powered by JetHome®