Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 1 | /* |
| 2 | * BCM47XX MTD partitioning |
| 3 | * |
| 4 | * Copyright © 2012 Rafał Miłecki <zajec5@gmail.com> |
| 5 | * |
| 6 | * This program is free software; you can redistribute it and/or modify |
| 7 | * it under the terms of the GNU General Public License version 2 as |
| 8 | * published by the Free Software Foundation. |
| 9 | * |
| 10 | */ |
| 11 | |
Rafał Miłecki | 89a0d9a9 | 2017-01-10 23:15:25 +0100 | [diff] [blame] | 12 | #include <linux/bcm47xx_nvram.h> |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 13 | #include <linux/module.h> |
| 14 | #include <linux/kernel.h> |
| 15 | #include <linux/slab.h> |
| 16 | #include <linux/mtd/mtd.h> |
| 17 | #include <linux/mtd/partitions.h> |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 18 | |
Rafał Miłecki | 0b56d2d | 2014-12-16 09:50:25 +0100 | [diff] [blame] | 19 | #include <uapi/linux/magic.h> |
| 20 | |
Rafał Miłecki | 59af5c7 | 2014-10-02 11:48:46 +0200 | [diff] [blame] | 21 | /* |
| 22 | * NAND flash on Netgear R6250 was verified to contain 15 partitions. |
| 23 | * This will result in allocating too big array for some old devices, but the |
| 24 | * memory will be freed soon anyway (see mtd_device_parse_register). |
| 25 | */ |
| 26 | #define BCM47XXPART_MAX_PARTS 20 |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 27 | |
Rafał Miłecki | 5ca1088 | 2013-03-07 09:02:38 +0100 | [diff] [blame] | 28 | /* |
| 29 | * Amount of bytes we read when analyzing each block of flash memory. |
| 30 | * Set it big enough to allow detecting partition and reading important data. |
| 31 | */ |
Rafał Miłecki | 4f8aaf7 | 2013-12-21 19:39:11 +0100 | [diff] [blame] | 32 | #define BCM47XXPART_BYTES_TO_READ 0x4e8 |
Rafał Miłecki | 5ca1088 | 2013-03-07 09:02:38 +0100 | [diff] [blame] | 33 | |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 34 | /* Magics */ |
| 35 | #define BOARD_DATA_MAGIC 0x5246504D /* MPFR */ |
Rafał Miłecki | f0501e8 | 2013-12-21 19:39:12 +0100 | [diff] [blame] | 36 | #define BOARD_DATA_MAGIC2 0xBD0D0BBD |
Rafał Miłecki | 4f8aaf7 | 2013-12-21 19:39:11 +0100 | [diff] [blame] | 37 | #define CFE_MAGIC 0x43464531 /* 1EFC */ |
Rafał Miłecki | 33094c7 | 2013-10-21 22:35:34 +0200 | [diff] [blame] | 38 | #define FACTORY_MAGIC 0x59544346 /* FCTY */ |
Rafał Miłecki | 9e3afa5 | 2014-02-28 18:02:01 +0100 | [diff] [blame] | 39 | #define NVRAM_HEADER 0x48534C46 /* FLSH */ |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 40 | #define POT_MAGIC1 0x54544f50 /* POTT */ |
| 41 | #define POT_MAGIC2 0x504f /* OP */ |
| 42 | #define ML_MAGIC1 0x39685a42 |
| 43 | #define ML_MAGIC2 0x26594131 |
| 44 | #define TRX_MAGIC 0x30524448 |
Rafał Miłecki | 0b56d2d | 2014-12-16 09:50:25 +0100 | [diff] [blame] | 45 | #define SHSQ_MAGIC 0x71736873 /* shsq (weird ZTE H218N endianness) */ |
Rafał Miłecki | 99352af | 2017-06-21 08:26:47 +0200 | [diff] [blame] | 46 | |
| 47 | static const char * const trx_types[] = { "trx", NULL }; |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 48 | |
| 49 | struct trx_header { |
| 50 | uint32_t magic; |
| 51 | uint32_t length; |
| 52 | uint32_t crc32; |
| 53 | uint16_t flags; |
| 54 | uint16_t version; |
| 55 | uint32_t offset[3]; |
| 56 | } __packed; |
| 57 | |
Rafał Miłecki | bd10c26 | 2014-12-01 18:50:20 +0100 | [diff] [blame] | 58 | static void bcm47xxpart_add_part(struct mtd_partition *part, const char *name, |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 59 | u64 offset, uint32_t mask_flags) |
| 60 | { |
| 61 | part->name = name; |
| 62 | part->offset = offset; |
| 63 | part->mask_flags = mask_flags; |
| 64 | } |
| 65 | |
Rafał Miłecki | 89a0d9a9 | 2017-01-10 23:15:25 +0100 | [diff] [blame] | 66 | /** |
| 67 | * bcm47xxpart_bootpartition - gets index of TRX partition used by bootloader |
| 68 | * |
| 69 | * Some devices may have more than one TRX partition. In such case one of them |
| 70 | * is the main one and another a failsafe one. Bootloader may fallback to the |
| 71 | * failsafe firmware if it detects corruption of the main image. |
| 72 | * |
| 73 | * This function provides info about currently used TRX partition. It's the one |
| 74 | * containing kernel started by the bootloader. |
| 75 | */ |
| 76 | static int bcm47xxpart_bootpartition(void) |
| 77 | { |
| 78 | char buf[4]; |
| 79 | int bootpartition; |
| 80 | |
| 81 | /* Check CFE environment variable */ |
| 82 | if (bcm47xx_nvram_getenv("bootpartition", buf, sizeof(buf)) > 0) { |
| 83 | if (!kstrtoint(buf, 0, &bootpartition)) |
| 84 | return bootpartition; |
| 85 | } |
| 86 | |
| 87 | return 0; |
| 88 | } |
| 89 | |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 90 | static int bcm47xxpart_parse(struct mtd_info *master, |
Brian Norris | b9adf46 | 2015-12-04 15:25:14 -0800 | [diff] [blame] | 91 | const struct mtd_partition **pparts, |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 92 | struct mtd_part_parser_data *data) |
| 93 | { |
| 94 | struct mtd_partition *parts; |
| 95 | uint8_t i, curr_part = 0; |
| 96 | uint32_t *buf; |
| 97 | size_t bytes_read; |
| 98 | uint32_t offset; |
Hauke Mehrtens | 25bad1d | 2013-01-24 17:39:58 +0100 | [diff] [blame] | 99 | uint32_t blocksize = master->erasesize; |
Rafał Miłecki | 89a0d9a9 | 2017-01-10 23:15:25 +0100 | [diff] [blame] | 100 | int trx_parts[2]; /* Array with indexes of TRX partitions */ |
| 101 | int trx_num = 0; /* Number of found TRX partitions */ |
Rafał Miłecki | 91d542f | 2013-03-07 09:02:39 +0100 | [diff] [blame] | 102 | int possible_nvram_sizes[] = { 0x8000, 0xF000, 0x10000, }; |
Rafał Miłecki | 36bcc0c | 2015-12-06 11:31:38 +0100 | [diff] [blame] | 103 | int err; |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 104 | |
Rafał Miłecki | 16bd87b | 2014-12-08 18:45:00 +0100 | [diff] [blame] | 105 | /* |
| 106 | * Some really old flashes (like AT45DB*) had smaller erasesize-s, but |
| 107 | * partitions were aligned to at least 0x1000 anyway. |
| 108 | */ |
| 109 | if (blocksize < 0x1000) |
| 110 | blocksize = 0x1000; |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 111 | |
| 112 | /* Alloc */ |
Kees Cook | 6396bb2 | 2018-06-12 14:03:40 -0700 | [diff] [blame] | 113 | parts = kcalloc(BCM47XXPART_MAX_PARTS, sizeof(struct mtd_partition), |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 114 | GFP_KERNEL); |
Hauke Mehrtens | 99b1d18 | 2013-10-13 22:53:49 +0200 | [diff] [blame] | 115 | if (!parts) |
| 116 | return -ENOMEM; |
| 117 | |
Rafał Miłecki | 5ca1088 | 2013-03-07 09:02:38 +0100 | [diff] [blame] | 118 | buf = kzalloc(BCM47XXPART_BYTES_TO_READ, GFP_KERNEL); |
Hauke Mehrtens | 99b1d18 | 2013-10-13 22:53:49 +0200 | [diff] [blame] | 119 | if (!buf) { |
| 120 | kfree(parts); |
| 121 | return -ENOMEM; |
| 122 | } |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 123 | |
| 124 | /* Parse block by block looking for magics */ |
| 125 | for (offset = 0; offset <= master->size - blocksize; |
| 126 | offset += blocksize) { |
Rafał Miłecki | 2a36a5c | 2015-12-05 02:09:43 +0100 | [diff] [blame] | 127 | /* Nothing more in higher memory on BCM47XX (MIPS) */ |
Masahiro Yamada | 97f2645 | 2016-08-03 13:45:50 -0700 | [diff] [blame] | 128 | if (IS_ENABLED(CONFIG_BCM47XX) && offset >= 0x2000000) |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 129 | break; |
| 130 | |
Rafał Miłecki | 00b7986 | 2014-02-26 14:02:06 +0100 | [diff] [blame] | 131 | if (curr_part >= BCM47XXPART_MAX_PARTS) { |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 132 | pr_warn("Reached maximum number of partitions, scanning stopped!\n"); |
| 133 | break; |
| 134 | } |
| 135 | |
| 136 | /* Read beginning of the block */ |
Rafał Miłecki | 36bcc0c | 2015-12-06 11:31:38 +0100 | [diff] [blame] | 137 | err = mtd_read(master, offset, BCM47XXPART_BYTES_TO_READ, |
| 138 | &bytes_read, (uint8_t *)buf); |
| 139 | if (err && !mtd_is_bitflip(err)) { |
| 140 | pr_err("mtd_read error while parsing (offset: 0x%X): %d\n", |
| 141 | offset, err); |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 142 | continue; |
| 143 | } |
| 144 | |
Rafał Miłecki | 4f8aaf7 | 2013-12-21 19:39:11 +0100 | [diff] [blame] | 145 | /* Magic or small NVRAM at 0x400 */ |
| 146 | if ((buf[0x4e0 / 4] == CFE_MAGIC && buf[0x4e4 / 4] == CFE_MAGIC) || |
| 147 | (buf[0x400 / 4] == NVRAM_HEADER)) { |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 148 | bcm47xxpart_add_part(&parts[curr_part++], "boot", |
| 149 | offset, MTD_WRITEABLE); |
| 150 | continue; |
| 151 | } |
| 152 | |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 153 | /* |
| 154 | * board_data starts with board_id which differs across boards, |
| 155 | * but we can use 'MPFR' (hopefully) magic at 0x100 |
| 156 | */ |
| 157 | if (buf[0x100 / 4] == BOARD_DATA_MAGIC) { |
| 158 | bcm47xxpart_add_part(&parts[curr_part++], "board_data", |
| 159 | offset, MTD_WRITEABLE); |
| 160 | continue; |
| 161 | } |
| 162 | |
Rafał Miłecki | 33094c7 | 2013-10-21 22:35:34 +0200 | [diff] [blame] | 163 | /* Found on Huawei E970 */ |
| 164 | if (buf[0x000 / 4] == FACTORY_MAGIC) { |
| 165 | bcm47xxpart_add_part(&parts[curr_part++], "factory", |
| 166 | offset, MTD_WRITEABLE); |
| 167 | continue; |
| 168 | } |
| 169 | |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 170 | /* POT(TOP) */ |
| 171 | if (buf[0x000 / 4] == POT_MAGIC1 && |
| 172 | (buf[0x004 / 4] & 0xFFFF) == POT_MAGIC2) { |
| 173 | bcm47xxpart_add_part(&parts[curr_part++], "POT", offset, |
| 174 | MTD_WRITEABLE); |
| 175 | continue; |
| 176 | } |
| 177 | |
| 178 | /* ML */ |
| 179 | if (buf[0x010 / 4] == ML_MAGIC1 && |
| 180 | buf[0x014 / 4] == ML_MAGIC2) { |
| 181 | bcm47xxpart_add_part(&parts[curr_part++], "ML", offset, |
| 182 | MTD_WRITEABLE); |
| 183 | continue; |
| 184 | } |
| 185 | |
| 186 | /* TRX */ |
| 187 | if (buf[0x000 / 4] == TRX_MAGIC) { |
Rafał Miłecki | b522d7b | 2017-01-10 23:15:24 +0100 | [diff] [blame] | 188 | struct trx_header *trx; |
Rafał Miłecki | 237ea0d | 2018-04-12 07:24:52 +0200 | [diff] [blame] | 189 | uint32_t last_subpart; |
| 190 | uint32_t trx_size; |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 191 | |
Rafał Miłecki | 89a0d9a9 | 2017-01-10 23:15:25 +0100 | [diff] [blame] | 192 | if (trx_num >= ARRAY_SIZE(trx_parts)) |
| 193 | pr_warn("No enough space to store another TRX found at 0x%X\n", |
| 194 | offset); |
| 195 | else |
| 196 | trx_parts[trx_num++] = curr_part; |
Rafał Miłecki | 396afe5 | 2013-01-06 16:08:36 +0100 | [diff] [blame] | 197 | bcm47xxpart_add_part(&parts[curr_part++], "firmware", |
| 198 | offset, 0); |
| 199 | |
Rafał Miłecki | 237ea0d | 2018-04-12 07:24:52 +0200 | [diff] [blame] | 200 | /* |
| 201 | * Try to find TRX size. The "length" field isn't fully |
| 202 | * reliable as it could be decreased to make CRC32 cover |
| 203 | * only part of TRX data. It's commonly used as checksum |
| 204 | * can't cover e.g. ever-changing rootfs partition. |
| 205 | * Use offsets as helpers for assuming min TRX size. |
| 206 | */ |
Rafał Miłecki | b522d7b | 2017-01-10 23:15:24 +0100 | [diff] [blame] | 207 | trx = (struct trx_header *)buf; |
Rafał Miłecki | 237ea0d | 2018-04-12 07:24:52 +0200 | [diff] [blame] | 208 | last_subpart = max3(trx->offset[0], trx->offset[1], |
| 209 | trx->offset[2]); |
| 210 | trx_size = max(trx->length, last_subpart + blocksize); |
| 211 | |
| 212 | /* |
| 213 | * Skip the TRX data. Decrease offset by block size as |
| 214 | * the next loop iteration will increase it. |
| 215 | */ |
| 216 | offset += roundup(trx_size, blocksize) - blocksize; |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 217 | continue; |
| 218 | } |
Rafał Miłecki | 020c6bc | 2013-10-21 22:34:37 +0200 | [diff] [blame] | 219 | |
| 220 | /* Squashfs on devices not using TRX */ |
Rafał Miłecki | 0b56d2d | 2014-12-16 09:50:25 +0100 | [diff] [blame] | 221 | if (le32_to_cpu(buf[0x000 / 4]) == SQUASHFS_MAGIC || |
| 222 | buf[0x000 / 4] == SHSQ_MAGIC) { |
Rafał Miłecki | 020c6bc | 2013-10-21 22:34:37 +0200 | [diff] [blame] | 223 | bcm47xxpart_add_part(&parts[curr_part++], "rootfs", |
| 224 | offset, 0); |
| 225 | continue; |
| 226 | } |
Rafał Miłecki | f0501e8 | 2013-12-21 19:39:12 +0100 | [diff] [blame] | 227 | |
Rafał Miłecki | 024629f | 2014-08-18 20:20:27 +0200 | [diff] [blame] | 228 | /* |
| 229 | * New (ARM?) devices may have NVRAM in some middle block. Last |
| 230 | * block will be checked later, so skip it. |
| 231 | */ |
| 232 | if (offset != master->size - blocksize && |
| 233 | buf[0x000 / 4] == NVRAM_HEADER) { |
| 234 | bcm47xxpart_add_part(&parts[curr_part++], "nvram", |
| 235 | offset, 0); |
| 236 | continue; |
| 237 | } |
| 238 | |
Rafał Miłecki | f0501e8 | 2013-12-21 19:39:12 +0100 | [diff] [blame] | 239 | /* Read middle of the block */ |
Rafał Miłecki | 36bcc0c | 2015-12-06 11:31:38 +0100 | [diff] [blame] | 240 | err = mtd_read(master, offset + 0x8000, 0x4, &bytes_read, |
| 241 | (uint8_t *)buf); |
| 242 | if (err && !mtd_is_bitflip(err)) { |
| 243 | pr_err("mtd_read error while parsing (offset: 0x%X): %d\n", |
| 244 | offset, err); |
Rafał Miłecki | f0501e8 | 2013-12-21 19:39:12 +0100 | [diff] [blame] | 245 | continue; |
| 246 | } |
| 247 | |
| 248 | /* Some devices (ex. WNDR3700v3) don't have a standard 'MPFR' */ |
| 249 | if (buf[0x000 / 4] == BOARD_DATA_MAGIC2) { |
| 250 | bcm47xxpart_add_part(&parts[curr_part++], "board_data", |
| 251 | offset, MTD_WRITEABLE); |
| 252 | continue; |
| 253 | } |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 254 | } |
Rafał Miłecki | 91d542f | 2013-03-07 09:02:39 +0100 | [diff] [blame] | 255 | |
| 256 | /* Look for NVRAM at the end of the last block. */ |
| 257 | for (i = 0; i < ARRAY_SIZE(possible_nvram_sizes); i++) { |
Rafał Miłecki | 00b7986 | 2014-02-26 14:02:06 +0100 | [diff] [blame] | 258 | if (curr_part >= BCM47XXPART_MAX_PARTS) { |
Rafał Miłecki | 91d542f | 2013-03-07 09:02:39 +0100 | [diff] [blame] | 259 | pr_warn("Reached maximum number of partitions, scanning stopped!\n"); |
| 260 | break; |
| 261 | } |
| 262 | |
| 263 | offset = master->size - possible_nvram_sizes[i]; |
Rafał Miłecki | 36bcc0c | 2015-12-06 11:31:38 +0100 | [diff] [blame] | 264 | err = mtd_read(master, offset, 0x4, &bytes_read, |
| 265 | (uint8_t *)buf); |
| 266 | if (err && !mtd_is_bitflip(err)) { |
| 267 | pr_err("mtd_read error while reading (offset 0x%X): %d\n", |
| 268 | offset, err); |
Rafał Miłecki | 91d542f | 2013-03-07 09:02:39 +0100 | [diff] [blame] | 269 | continue; |
| 270 | } |
| 271 | |
| 272 | /* Standard NVRAM */ |
| 273 | if (buf[0] == NVRAM_HEADER) { |
| 274 | bcm47xxpart_add_part(&parts[curr_part++], "nvram", |
| 275 | master->size - blocksize, 0); |
| 276 | break; |
| 277 | } |
| 278 | } |
| 279 | |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 280 | kfree(buf); |
| 281 | |
| 282 | /* |
| 283 | * Assume that partitions end at the beginning of the one they are |
| 284 | * followed by. |
| 285 | */ |
Rafał Miłecki | 648bdbe | 2013-01-06 16:08:35 +0100 | [diff] [blame] | 286 | for (i = 0; i < curr_part; i++) { |
| 287 | u64 next_part_offset = (i < curr_part - 1) ? |
| 288 | parts[i + 1].offset : master->size; |
| 289 | |
| 290 | parts[i].size = next_part_offset - parts[i].offset; |
Rafał Miłecki | b522d7b | 2017-01-10 23:15:24 +0100 | [diff] [blame] | 291 | } |
| 292 | |
| 293 | /* If there was TRX parse it now */ |
Rafał Miłecki | 89a0d9a9 | 2017-01-10 23:15:25 +0100 | [diff] [blame] | 294 | for (i = 0; i < trx_num; i++) { |
| 295 | struct mtd_partition *trx = &parts[trx_parts[i]]; |
Rafał Miłecki | b522d7b | 2017-01-10 23:15:24 +0100 | [diff] [blame] | 296 | |
Rafał Miłecki | 99352af | 2017-06-21 08:26:47 +0200 | [diff] [blame] | 297 | if (i == bcm47xxpart_bootpartition()) |
| 298 | trx->types = trx_types; |
| 299 | else |
Rafał Miłecki | 89a0d9a9 | 2017-01-10 23:15:25 +0100 | [diff] [blame] | 300 | trx->name = "failsafe"; |
Rafał Miłecki | 648bdbe | 2013-01-06 16:08:35 +0100 | [diff] [blame] | 301 | } |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 302 | |
| 303 | *pparts = parts; |
| 304 | return curr_part; |
| 305 | }; |
| 306 | |
Rafał Miłecki | cf589ce | 2018-05-09 10:17:29 +0200 | [diff] [blame] | 307 | static const struct of_device_id bcm47xxpart_of_match_table[] = { |
| 308 | { .compatible = "brcm,bcm947xx-cfe-partitions" }, |
| 309 | {}, |
| 310 | }; |
| 311 | MODULE_DEVICE_TABLE(of, bcm47xxpart_of_match_table); |
| 312 | |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 313 | static struct mtd_part_parser bcm47xxpart_mtd_parser = { |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 314 | .parse_fn = bcm47xxpart_parse, |
| 315 | .name = "bcm47xxpart", |
Rafał Miłecki | cf589ce | 2018-05-09 10:17:29 +0200 | [diff] [blame] | 316 | .of_match_table = bcm47xxpart_of_match_table, |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 317 | }; |
Brian Norris | b8f70ba | 2015-11-11 19:13:30 -0800 | [diff] [blame] | 318 | module_mtd_part_parser(bcm47xxpart_mtd_parser); |
Rafał Miłecki | 3cf7f13 | 2012-08-30 07:41:16 +0200 | [diff] [blame] | 319 | |
| 320 | MODULE_LICENSE("GPL"); |
| 321 | MODULE_DESCRIPTION("MTD partitioning for BCM47XX flash memories"); |