diff options
author | Linus Torvalds <torvalds@g5.osdl.org> | 2005-07-11 13:18:18 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@g5.osdl.org> | 2005-07-11 13:18:18 -0400 |
commit | 200d481f28be4522464bb849dd0eb5f8cb6be781 (patch) | |
tree | 8cd00ead1b202dfd377cf34000a5193959aa2e8b /drivers/mtd/cmdlinepart.c | |
parent | f43a64c5e1a65d12b9b53a35ed2d5db441fcb64c (diff) | |
parent | 97f927a4d7dbccde0a854a62c3ea54d90bae8679 (diff) |
Merge master.kernel.org:/pub/scm/linux/kernel/git/tglx/mtd-2.6
Diffstat (limited to 'drivers/mtd/cmdlinepart.c')
-rw-r--r-- | drivers/mtd/cmdlinepart.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/mtd/cmdlinepart.c b/drivers/mtd/cmdlinepart.c index 60ab4b89a2f9..ef24837019d3 100644 --- a/drivers/mtd/cmdlinepart.c +++ b/drivers/mtd/cmdlinepart.c | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * $Id: cmdlinepart.c,v 1.17 2004/11/26 11:18:47 lavinen Exp $ | 2 | * $Id: cmdlinepart.c,v 1.18 2005/06/07 15:04:26 joern Exp $ |
3 | * | 3 | * |
4 | * Read flash partition table from command line | 4 | * Read flash partition table from command line |
5 | * | 5 | * |
@@ -239,7 +239,8 @@ static int mtdpart_setup_real(char *s) | |||
239 | &num_parts, /* out: number of parts */ | 239 | &num_parts, /* out: number of parts */ |
240 | 0, /* first partition */ | 240 | 0, /* first partition */ |
241 | (unsigned char**)&this_mtd, /* out: extra mem */ | 241 | (unsigned char**)&this_mtd, /* out: extra mem */ |
242 | mtd_id_len + 1 + sizeof(*this_mtd)); | 242 | mtd_id_len + 1 + sizeof(*this_mtd) + |
243 | sizeof(void*)-1 /*alignment*/); | ||
243 | if(!parts) | 244 | if(!parts) |
244 | { | 245 | { |
245 | /* | 246 | /* |
@@ -252,6 +253,9 @@ static int mtdpart_setup_real(char *s) | |||
252 | return 0; | 253 | return 0; |
253 | } | 254 | } |
254 | 255 | ||
256 | /* align this_mtd */ | ||
257 | this_mtd = (struct cmdline_mtd_partition *) | ||
258 | ALIGN((unsigned long)this_mtd, sizeof(void*)); | ||
255 | /* enter results */ | 259 | /* enter results */ |
256 | this_mtd->parts = parts; | 260 | this_mtd->parts = parts; |
257 | this_mtd->num_parts = num_parts; | 261 | this_mtd->num_parts = num_parts; |