Skip to content

Commit

Permalink
mtd: mark const init data with __initconst instead of __initdata
Browse files Browse the repository at this point in the history
As long as there is no other non-const variable marked __initdata in the
same compilation unit it doesn't hurt. If there were one however
compilation would fail with

	error: $variablename causes a section type conflict

because a section containing const variables is marked read only and so
cannot contain non-const variables.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
  • Loading branch information
Uwe Kleine-König authored and David Woodhouse committed May 14, 2012
1 parent ce4bbee commit 6d56b9d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/mtd/maps/wr_sbc82xx_flash.c
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ static struct mtd_partition bigflash_parts[] = {
}
};

static const char *part_probes[] __initdata = {"cmdlinepart", "RedBoot", NULL};
static const char *part_probes[] __initconst = {"cmdlinepart", "RedBoot", NULL};

#define init_sbc82xx_one_flash(map, br, or) \
do { \
Expand Down

0 comments on commit 6d56b9d

Please sign in to comment.