From: Dave Jiang <dave.jiang@intel.com>
To: <coolrrsh@gmail.com>, <fenghua.yu@intel.com>, <vkoul@kernel.org>,
<dmaengine@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Cc: <linux-kernel-mentees@lists.linuxfoundation.org>
Subject: Re: [PATCH] dma: device: Remove redundant code
Date: Mon, 28 Aug 2023 11:19:13 -0700 [thread overview]
Message-ID: <37795c12-85f2-a9fb-dafb-fd181e04b86f@intel.com> (raw)
In-Reply-To: <20230813132203.139580-1-coolrrsh@gmail.com>
On 8/13/23 06:22, coolrrsh@gmail.com wrote:
> From: Rajeshwar R Shinde <coolrrsh@gmail.com>
>
> dma_alloc_coherent function already zeroes the array 'addr'.
> So, memset function call is not needed.
>
> This fixes warning such as:
> drivers/dma/idxd/device.c:783:8-26:
> WARNING: dma_alloc_coherent used in addr already zeroes out memory,
> so memset is not needed.
>
> Signed-off-by: Rajeshwar R Shinde <coolrrsh@gmail.com>
Please rename subject line to:
dmaengine: idxd: Remove redundant memset() for eventlog allocation
With the change,
Reviewed-by: Dave Jiang <dave.jiang@intel.com>
> ---
> drivers/dma/idxd/device.c | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/drivers/dma/idxd/device.c b/drivers/dma/idxd/device.c
> index 5abbcc61c528..7c74bc60f582 100644
> --- a/drivers/dma/idxd/device.c
> +++ b/drivers/dma/idxd/device.c
> @@ -786,8 +786,6 @@ static int idxd_device_evl_setup(struct idxd_device *idxd)
> goto err_alloc;
> }
>
> - memset(addr, 0, size);
> -
> spin_lock(&evl->lock);
> evl->log = addr;
> evl->dma = dma_addr;
prev parent reply other threads:[~2023-08-28 18:20 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-13 13:22 [PATCH] dma: device: Remove redundant code coolrrsh
2023-08-28 18:19 ` Dave Jiang [this message]
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=37795c12-85f2-a9fb-dafb-fd181e04b86f@intel.com \
--to=dave.jiang@intel.com \
--cc=coolrrsh@gmail.com \
--cc=dmaengine@vger.kernel.org \
--cc=fenghua.yu@intel.com \
--cc=linux-kernel-mentees@lists.linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
--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