From: Dave Jiang <dave.jiang@intel.com>
To: YueHaibing <yuehaibing@huawei.com>,
dan.j.williams@intel.com, vkoul@kernel.org
Cc: dmaengine@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH -next] dmaengine: idxd: remove set but not used variable 'group'
Date: Tue, 11 Feb 2020 09:14:08 -0700 [thread overview]
Message-ID: <397d824a-8827-c5b8-4dda-60fe79c6512d@intel.com> (raw)
In-Reply-To: <20200211135335.55924-1-yuehaibing@huawei.com>
On 2/11/20 6:53 AM, YueHaibing wrote:
> drivers/dma/idxd/sysfs.c: In function engine_group_id_store:
> drivers/dma/idxd/sysfs.c:419:29: warning: variable group set but not used [-Wunused-but-set-variable]
>
> It is not used, so remove it.
>
> Reported-by: Hulk Robot <hulkci@huawei.com>
> Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Acked-by: Dave Jiang <dave.jiang@intel.com>
> ---
> drivers/dma/idxd/sysfs.c | 3 +--
> 1 file changed, 1 insertion(+), 2 deletions(-)
>
> diff --git a/drivers/dma/idxd/sysfs.c b/drivers/dma/idxd/sysfs.c
> index 6d907fe..e4f35bd 100644
> --- a/drivers/dma/idxd/sysfs.c
> +++ b/drivers/dma/idxd/sysfs.c
> @@ -416,7 +416,7 @@ static ssize_t engine_group_id_store(struct device *dev,
> struct idxd_device *idxd = engine->idxd;
> long id;
> int rc;
> - struct idxd_group *prevg, *group;
> + struct idxd_group *prevg;
>
> rc = kstrtol(buf, 10, &id);
> if (rc < 0)
> @@ -436,7 +436,6 @@ static ssize_t engine_group_id_store(struct device *dev,
> return count;
> }
>
> - group = &idxd->groups[id];
> prevg = engine->group;
>
> if (prevg)
>
next prev parent reply other threads:[~2020-02-11 16:14 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-11 13:53 [PATCH -next] dmaengine: idxd: remove set but not used variable 'group' YueHaibing
2020-02-11 16:14 ` Dave Jiang [this message]
2020-02-13 13:48 ` Vinod Koul
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=397d824a-8827-c5b8-4dda-60fe79c6512d@intel.com \
--to=dave.jiang@intel.com \
--cc=dan.j.williams@intel.com \
--cc=dmaengine@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=vkoul@kernel.org \
--cc=yuehaibing@huawei.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