提交 9bc65970 编写于 作者: Y yu kuai 提交者: Moritz Fischer

fpga: dfl: afu: remove set but not used variable 'afu'

Fixes gcc '-Wunused-but-set-variable' warning:

drivers/fpga/dfl-afu-main.c: In function ‘afu_dev_destroy’:
drivers/fpga/dfl-afu-main.c:816:18: warning: variable ‘afu’
set but not used [-Wunused-but-set-variable]

It is never used, and so can be removed.
Acked-by: NWu Hao <hao.wu@intel.com>
Signed-off-by: Nyu kuai <yukuai3@huawei.com>
Signed-off-by: NMoritz Fischer <mdf@kernel.org>
上级 8082c51a
...@@ -813,10 +813,8 @@ static int afu_dev_init(struct platform_device *pdev) ...@@ -813,10 +813,8 @@ static int afu_dev_init(struct platform_device *pdev)
static int afu_dev_destroy(struct platform_device *pdev) static int afu_dev_destroy(struct platform_device *pdev)
{ {
struct dfl_feature_platform_data *pdata = dev_get_platdata(&pdev->dev); struct dfl_feature_platform_data *pdata = dev_get_platdata(&pdev->dev);
struct dfl_afu *afu;
mutex_lock(&pdata->lock); mutex_lock(&pdata->lock);
afu = dfl_fpga_pdata_get_private(pdata);
afu_mmio_region_destroy(pdata); afu_mmio_region_destroy(pdata);
afu_dma_region_destroy(pdata); afu_dma_region_destroy(pdata);
dfl_fpga_pdata_set_private(pdata, NULL); dfl_fpga_pdata_set_private(pdata, NULL);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册