From: Nicolin Chen <nicoleotsuka@gmail.com>
To: Christoph Hellwig <hch@lst.de>
Cc: iommu@lists.linux-foundation.org, robin.murphy@arm.com
Subject: Re: [PATCH v2] dma-contiguous: cleanup dma_alloc_contiguous
Date: Thu, 23 Jul 2020 19:12:53 -0700 [thread overview]
Message-ID: <20200724021246.GA10498@Asurada-Nvidia> (raw)
In-Reply-To: <20200723120133.94105-1-hch@lst.de>
Hi Christoph,
On Thu, Jul 23, 2020 at 02:01:33PM +0200, Christoph Hellwig wrote:
> Split out a cma_alloc_aligned helper to deal with the "interesting"
> calling conventions for cma_alloc, which then allows to the main
> function to be written straight forward. This also takes advantage
> of the fact that NULL dev arguments have been gone from the DMA API
> for a while.
I am still seeing some potential NULL dev callers:
drivers/staging/emxx_udc/emxx_udc.c:2596: ep->virt_buf = dma_alloc_coherent(NULL, PAGE_SIZE,
drivers/tty/synclink.c:3667: info->buffer_list = dma_alloc_coherent(NULL, BUFFERLISTSIZE, &info->buffer_list_dma_addr, GFP_KERNEL);
drivers/tty/synclink.c:3777: BufferList[i].virt_addr = dma_alloc_coherent(NULL, DMABUFFERSIZE, &BufferList[i].dma_addr, GFP_KERNEL);
Personally I don't feel that it hurts to check the dev pointer
as we do now, but if you are confident with this version:
Reviewed-by: Nicolin Chen <nicoleotsuka@gmail.com>
Thanks
_______________________________________________
iommu mailing list
iommu@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/iommu
next prev parent reply other threads:[~2020-07-24 2:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-07-23 12:01 [PATCH v2] dma-contiguous: cleanup dma_alloc_contiguous Christoph Hellwig
2020-07-24 2:12 ` Nicolin Chen [this message]
2020-07-27 6:59 ` Song Bao Hua (Barry Song)
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=20200724021246.GA10498@Asurada-Nvidia \
--to=nicoleotsuka@gmail.com \
--cc=hch@lst.de \
--cc=iommu@lists.linux-foundation.org \
--cc=robin.murphy@arm.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