media: saa7164: remove redundant assignment to variable idx
authorColin Ian King <colin.i.king@gmail.com>
Sun, 30 Jan 2022 23:21:40 +0000 (23:21 +0000)
committerHans Verkuil <hverkuil-cisco@xs4all.nl>
Tue, 22 Feb 2022 08:41:11 +0000 (09:41 +0100)
Variable idx is being assigned a value that is never read, it is being
re-assigned a new value in the following for-loop. The assignment is
redundant and can be removed.

Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
drivers/media/pci/saa7164/saa7164-cmd.c

index a65d810ce212b8ba4b810a3b606cc7194475a30f..42bd8e76005be69b667b060e30f50d96bcd43999 100644 (file)
@@ -187,7 +187,6 @@ static int saa7164_cmd_set(struct saa7164_dev *dev, struct tmComResInfo *msg,
        mutex_lock(&dev->cmds[msg->id].lock);
 
        size = msg->size;
-       idx = 0;
        cmds = size / bus->m_wMaxReqSize;
        if (size % bus->m_wMaxReqSize == 0)
                cmds -= 1;