Skip to content

Commit f390777

Browse files
Colin Ian Kingr-vignesh
authored andcommitted
mtd: cfi_cmdset_0002: remove redundant assignment to variable timeo
The variable timeo is being initialized with a value that is never read and it is being updated later with a new value. The initialization is redundant and can be removed. Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Vignesh Raghavendra <vigneshr@ti.com> Link: https://lore.kernel.org/r/20210325174514.486272-1-colin.king@canonical.com Addresses-Coverity: ("Unused value")
1 parent 7e44041 commit f390777

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/mtd/chips/cfi_cmdset_0002.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1653,7 +1653,7 @@ static int __xipram do_write_oneword_once(struct map_info *map,
16531653
unsigned long adr, map_word datum,
16541654
int mode, struct cfi_private *cfi)
16551655
{
1656-
unsigned long timeo = jiffies + HZ;
1656+
unsigned long timeo;
16571657
/*
16581658
* We use a 1ms + 1 jiffies generic timeout for writes (most devices
16591659
* have a max write time of a few hundreds usec). However, we should

0 commit comments

Comments
 (0)