From 9e72aa51a7a9ac5f041bacab75fd4be1e2a3356c Mon Sep 17 00:00:00 2001 From: Stefan Reinauer Date: Wed, 16 Sep 2009 08:18:08 +0000 Subject: Fix some of the issues reported by LLVM/clang's scan-build Corresponding to flashrom svn r722. Signed-off-by: Stefan Reinauer This commit fixes only some of the issues, those that were Acked-by: Carl-Daniel Hailfinger --- sst28sf040.c | 32 ++++++++++++++------------------ 1 file changed, 14 insertions(+), 18 deletions(-) (limited to 'sst28sf040.c') diff --git a/sst28sf040.c b/sst28sf040.c index d3d7bdb..930ad5b 100644 --- a/sst28sf040.c +++ b/sst28sf040.c @@ -30,28 +30,24 @@ static void protect_28sf040(chipaddr bios) { - uint8_t tmp; - - tmp = chip_readb(bios + 0x1823); - tmp = chip_readb(bios + 0x1820); - tmp = chip_readb(bios + 0x1822); - tmp = chip_readb(bios + 0x0418); - tmp = chip_readb(bios + 0x041B); - tmp = chip_readb(bios + 0x0419); - tmp = chip_readb(bios + 0x040A); + chip_readb(bios + 0x1823); + chip_readb(bios + 0x1820); + chip_readb(bios + 0x1822); + chip_readb(bios + 0x0418); + chip_readb(bios + 0x041B); + chip_readb(bios + 0x0419); + chip_readb(bios + 0x040A); } static void unprotect_28sf040(chipaddr bios) { - uint8_t tmp; - - tmp = chip_readb(bios + 0x1823); - tmp = chip_readb(bios + 0x1820); - tmp = chip_readb(bios + 0x1822); - tmp = chip_readb(bios + 0x0418); - tmp = chip_readb(bios + 0x041B); - tmp = chip_readb(bios + 0x0419); - tmp = chip_readb(bios + 0x041A); + chip_readb(bios + 0x1823); + chip_readb(bios + 0x1820); + chip_readb(bios + 0x1822); + chip_readb(bios + 0x0418); + chip_readb(bios + 0x041B); + chip_readb(bios + 0x0419); + chip_readb(bios + 0x041A); } static int erase_sector_28sf040(struct flashchip *flash, unsigned long address, int sector_size) -- cgit v1.1