mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2025-01-19 12:24:34 +08:00
char: hwicap: Remove unnecessary dev_set_drvdata()
Driver core clears the driver data to NULL after device_release or on probe failure, so just remove it from here. Signed-off-by: Michal Simek <michal.simek@xilinx.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
bc34268976
commit
12b3af3096
@ -731,7 +731,6 @@ static int hwicap_remove(struct device *dev)
|
|||||||
iounmap(drvdata->base_address);
|
iounmap(drvdata->base_address);
|
||||||
release_mem_region(drvdata->mem_start, drvdata->mem_size);
|
release_mem_region(drvdata->mem_start, drvdata->mem_size);
|
||||||
kfree(drvdata);
|
kfree(drvdata);
|
||||||
dev_set_drvdata(dev, NULL);
|
|
||||||
|
|
||||||
mutex_lock(&icap_sem);
|
mutex_lock(&icap_sem);
|
||||||
probed_devices[MINOR(dev->devt)-XHWICAP_MINOR] = 0;
|
probed_devices[MINOR(dev->devt)-XHWICAP_MINOR] = 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user