Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a68c5ec8 authored by Sachin Kamat's avatar Sachin Kamat Committed by David Woodhouse
Browse files

mtd: s3c2410: Do not initialise statics to 0 or NULL



Fixes the following checkpatch errors:
ERROR: do not initialise statics to 0 or NULL
+static int hardware_ecc = 0;

ERROR: do not initialise statics to 0 or NULL
+static const int clock_stop = 0;

Signed-off-by: default avatarSachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: default avatarArtem Bityutskiy <artem.bityutskiy@linux.intel.com>
Signed-off-by: default avatarDavid Woodhouse <David.Woodhouse@intel.com>
parent d2a89be8
Loading
Loading
Loading
Loading
+27 −37
Original line number Diff line number Diff line
@@ -49,19 +49,6 @@
#include <plat/regs-nand.h>
#include <plat/nand.h>

#ifdef CONFIG_MTD_NAND_S3C2410_HWECC
static int hardware_ecc = 1;
#else
static int hardware_ecc = 0;
#endif

#ifdef CONFIG_MTD_NAND_S3C2410_CLKSTOP
static const int clock_stop = 1;
#else
static const int clock_stop = 0;
#endif


/* new oob placement block for use with hardware ecc generation
 */

@@ -170,7 +157,11 @@ static struct s3c2410_platform_nand *to_nand_plat(struct platform_device *dev)

static inline int allow_clk_suspend(struct s3c2410_nand_info *info)
{
	return clock_stop;
#ifdef CONFIG_MTD_NAND_S3C2410_CLKSTOP
	return 1;
#else
	return 0;
#endif
}

/**
@@ -821,7 +812,7 @@ static void s3c2410_nand_init_chip(struct s3c2410_nand_info *info,
	nmtd->mtd.owner    = THIS_MODULE;
	nmtd->set	   = set;

	if (hardware_ecc) {
#ifdef CONFIG_MTD_NAND_S3C2410_HWECC
	chip->ecc.calculate = s3c2410_nand_calculate_ecc;
	chip->ecc.correct   = s3c2410_nand_correct_data;
	chip->ecc.mode	    = NAND_ECC_HW;
@@ -842,11 +833,10 @@ static void s3c2410_nand_init_chip(struct s3c2410_nand_info *info,
		chip->ecc.hwctl     = s3c2440_nand_enable_hwecc;
		chip->ecc.calculate = s3c2440_nand_calculate_ecc;
		break;

	}
	} else {
#else
	chip->ecc.mode	    = NAND_ECC_SOFT;
	}
#endif

	if (set->ecc_layout != NULL)
		chip->ecc.layout = set->ecc_layout;