Linux-Next Archive mirror
 help / color / mirror / Atom feed
From: Stephen Rothwell <sfr@canb.auug.org.au>
To: David Miller <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>, Paolo Abeni <pabeni@redhat.com>,
	Christoph Hellwig <hch@lst.de>
Cc: Alexander Lobakin <aleksander.lobakin@intel.com>,
	Tony Nguyen <anthony.l.nguyen@intel.com>,
	Networking <netdev@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Linux Next Mailing List <linux-next@vger.kernel.org>
Subject: linux-next: manual merge of the net-next tree with the dma-mapping tree
Date: Thu, 9 May 2024 11:53:07 +1000	[thread overview]
Message-ID: <20240509115307.71ae8787@canb.auug.org.au> (raw)

[-- Attachment #1: Type: text/plain, Size: 2775 bytes --]

Hi all,

Today's linux-next merge of the net-next tree got a conflict in:

  net/core/page_pool.c

between commit:

  4321de4497b2 ("page_pool: check for DMA sync shortcut earlier")

from the dma-mapping tree and commit:

  ef9226cd56b7 ("page_pool: constify some read-only function arguments")

from the net-next 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 net/core/page_pool.c
index 4f9d1bd7f4d1,8bcc7014a61a..000000000000
--- a/net/core/page_pool.c
+++ b/net/core/page_pool.c
@@@ -398,26 -384,16 +399,26 @@@ static struct page *__page_pool_get_cac
  	return page;
  }
  
 -static void page_pool_dma_sync_for_device(const struct page_pool *pool,
 -					  const struct page *page,
 -					  unsigned int dma_sync_size)
 +static void __page_pool_dma_sync_for_device(const struct page_pool *pool,
- 					    struct page *page,
++					    const struct page *page,
 +					    u32 dma_sync_size)
  {
 +#if defined(CONFIG_HAS_DMA) && defined(CONFIG_DMA_NEED_SYNC)
  	dma_addr_t dma_addr = page_pool_get_dma_addr(page);
  
  	dma_sync_size = min(dma_sync_size, pool->p.max_len);
 -	dma_sync_single_range_for_device(pool->p.dev, dma_addr,
 -					 pool->p.offset, dma_sync_size,
 -					 pool->p.dma_dir);
 +	__dma_sync_single_for_device(pool->p.dev, dma_addr + pool->p.offset,
 +				     dma_sync_size, pool->p.dma_dir);
 +#endif
 +}
 +
 +static __always_inline void
 +page_pool_dma_sync_for_device(const struct page_pool *pool,
- 			      struct page *page,
++			      const struct page *page,
 +			      u32 dma_sync_size)
 +{
 +	if (pool->dma_sync && dma_dev_need_sync(pool->p.dev))
 +		__page_pool_dma_sync_for_device(pool, page, dma_sync_size);
  }
  
  static bool page_pool_dma_map(struct page_pool *pool, struct page *page)
@@@ -708,10 -688,11 +710,9 @@@ __page_pool_put_page(struct page_pool *
  	if (likely(__page_pool_page_can_be_recycled(page))) {
  		/* Read barrier done in page_ref_count / READ_ONCE */
  
 -		if (pool->p.flags & PP_FLAG_DMA_SYNC_DEV)
 -			page_pool_dma_sync_for_device(pool, page,
 -						      dma_sync_size);
 +		page_pool_dma_sync_for_device(pool, page, dma_sync_size);
  
- 		if (allow_direct && in_softirq() &&
- 		    page_pool_recycle_in_cache(page, pool))
+ 		if (allow_direct && page_pool_recycle_in_cache(page, pool))
  			return NULL;
  
  		/* Page found as candidate for recycling */

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

             reply	other threads:[~2024-05-09  1:53 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-09  1:53 Stephen Rothwell [this message]
2024-05-15 23:24 ` linux-next: manual merge of the net-next tree with the dma-mapping tree 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=20240509115307.71ae8787@canb.auug.org.au \
    --to=sfr@canb.auug.org.au \
    --cc=aleksander.lobakin@intel.com \
    --cc=anthony.l.nguyen@intel.com \
    --cc=davem@davemloft.net \
    --cc=hch@lst.de \
    --cc=kuba@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-next@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).