mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2025-01-09 06:33:34 +00:00
nfc: virtual_ncidev: constify pointer to nfc_dev
virtual_ncidev_ioctl() does not modify struct nfc_dev, so local variable can be a pointer to const. Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
ea050c5ee7
commit
83428dbbac
@ -170,7 +170,7 @@ static int virtual_ncidev_close(struct inode *inode, struct file *file)
|
||||
static long virtual_ncidev_ioctl(struct file *flip, unsigned int cmd,
|
||||
unsigned long arg)
|
||||
{
|
||||
struct nfc_dev *nfc_dev = ndev->nfc_dev;
|
||||
const struct nfc_dev *nfc_dev = ndev->nfc_dev;
|
||||
void __user *p = (void __user *)arg;
|
||||
|
||||
if (cmd != IOCTL_GET_NCIDEV_IDX)
|
||||
|
Loading…
Reference in New Issue
Block a user