mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
To: Frank.Li@oss.nxp.com
Cc: Mark Brown <broonie@kernel.org>, Daniel Mack <daniel@zonque.org>,
	Haojian Zhuang <haojian.zhuang@gmail.com>,
	Robert Jarzmik <robert.jarzmik@free.fr>,
	"open list:SPI SUBSYSTEM" <linux-spi@vger.kernel.org>,
	open list <linux-kernel@vger.kernel.org>,
	"moderated list:PXA2xx/PXA3xx SUPPORT"
	<linux-arm-kernel@lists.infradead.org>,
	imx@lists.linux.dev, vkoul@kernel.org,
	Frank Li <Frank.Li@nxp.com>
Subject: Re: [PATCH 1/1] spi: replace chan->device->dev with dmaengine_get_provider_device()
Date: Wed, 4 Nov 2026 10:46:02 +0200	[thread overview]
Message-ID: <aurwylnNpkKi_Bx-@ashevche-desk.local> (raw)
In-Reply-To: <20261103215824.1823272-1-Frank.Li@oss.nxp.com>

On Tue, Nov 03, 2026 at 04:58:23PM -0500, Frank.Li@oss.nxp.com wrote:

> Use the dmaengine_get_provider_device() API instead of directly
> accessing chan->device->dev to get the DMA provider device.
> 
> No functional change. Prepare make to struct dma_device private to the DMA
> engine.

...

>  	struct dw_dma_slave *s = param;
>  
> -	if (s->dma_dev != chan->device->dev)
> +	if (s->dma_dev != dmaengine_get_provider_device(chan))
>  		return false;

It's obvious that we need another helper to match.

// void * and EXPORT to be able to use as filter function
bool dmaengine_match_provider_device(struct dma_chan *chan, void *dma_dev)
{
	return dmaengine_get_provider_device(chan) == dma_dev;
}
EXPORT_SYMBOL_GPL(dmaengine_match_provider_device);

...

>  static bool pxa2xx_spi_idma_filter(struct dma_chan *chan, void *param)
>  {
> -	return param == chan->device->dev;
> +	return param == dmaengine_get_provider_device(chan);
>  }

With that being done this function is gone.

-- 
With Best Regards,
Andy Shevchenko



  reply	other threads:[~2026-11-04  8:46 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-03 21:58 Frank.Li
2026-11-04  8:46 ` Andy Shevchenko [this message]
2026-11-04 14:41   ` Frank Li

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=aurwylnNpkKi_Bx-@ashevche-desk.local \
    --to=andriy.shevchenko@linux.intel.com \
    --cc=Frank.Li@nxp.com \
    --cc=Frank.Li@oss.nxp.com \
    --cc=broonie@kernel.org \
    --cc=daniel@zonque.org \
    --cc=haojian.zhuang@gmail.com \
    --cc=imx@lists.linux.dev \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-spi@vger.kernel.org \
    --cc=robert.jarzmik@free.fr \
    --cc=vkoul@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®