Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 1 | /* |
| 2 | * sst25l.c |
| 3 | * |
| 4 | * Driver for SST25L SPI Flash chips |
| 5 | * |
| 6 | * Copyright © 2009 Bluewater Systems Ltd |
| 7 | * Author: Andre Renaud <andre@bluewatersys.com> |
Ryan Mallon | 1c5454e | 2011-06-15 14:45:36 +1000 | [diff] [blame] | 8 | * Author: Ryan Mallon |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 9 | * |
| 10 | * Based on m25p80.c |
| 11 | * |
| 12 | * This code is free software; you can redistribute it and/or modify |
| 13 | * it under the terms of the GNU General Public License version 2 as |
| 14 | * published by the Free Software Foundation. |
| 15 | * |
| 16 | */ |
| 17 | |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 18 | #include <linux/module.h> |
| 19 | #include <linux/device.h> |
| 20 | #include <linux/mutex.h> |
| 21 | #include <linux/interrupt.h> |
Tejun Heo | 5a0e3ad | 2010-03-24 17:04:11 +0900 | [diff] [blame] | 22 | #include <linux/slab.h> |
Alexey Dobriyan | d43c36d | 2009-10-07 17:09:06 +0400 | [diff] [blame] | 23 | #include <linux/sched.h> |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 24 | |
| 25 | #include <linux/mtd/mtd.h> |
| 26 | #include <linux/mtd/partitions.h> |
| 27 | |
| 28 | #include <linux/spi/spi.h> |
| 29 | #include <linux/spi/flash.h> |
| 30 | |
| 31 | /* Erases can take up to 3 seconds! */ |
| 32 | #define MAX_READY_WAIT_JIFFIES msecs_to_jiffies(3000) |
| 33 | |
| 34 | #define SST25L_CMD_WRSR 0x01 /* Write status register */ |
| 35 | #define SST25L_CMD_WRDI 0x04 /* Write disable */ |
| 36 | #define SST25L_CMD_RDSR 0x05 /* Read status register */ |
| 37 | #define SST25L_CMD_WREN 0x06 /* Write enable */ |
| 38 | #define SST25L_CMD_READ 0x03 /* High speed read */ |
| 39 | |
| 40 | #define SST25L_CMD_EWSR 0x50 /* Enable write status register */ |
| 41 | #define SST25L_CMD_SECTOR_ERASE 0x20 /* Erase sector */ |
| 42 | #define SST25L_CMD_READ_ID 0x90 /* Read device ID */ |
| 43 | #define SST25L_CMD_AAI_PROGRAM 0xaf /* Auto address increment */ |
| 44 | |
| 45 | #define SST25L_STATUS_BUSY (1 << 0) /* Chip is busy */ |
| 46 | #define SST25L_STATUS_WREN (1 << 1) /* Write enabled */ |
| 47 | #define SST25L_STATUS_BP0 (1 << 2) /* Block protection 0 */ |
| 48 | #define SST25L_STATUS_BP1 (1 << 3) /* Block protection 1 */ |
| 49 | |
| 50 | struct sst25l_flash { |
| 51 | struct spi_device *spi; |
| 52 | struct mutex lock; |
| 53 | struct mtd_info mtd; |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 54 | }; |
| 55 | |
| 56 | struct flash_info { |
| 57 | const char *name; |
| 58 | uint16_t device_id; |
| 59 | unsigned page_size; |
| 60 | unsigned nr_pages; |
| 61 | unsigned erase_size; |
| 62 | }; |
| 63 | |
| 64 | #define to_sst25l_flash(x) container_of(x, struct sst25l_flash, mtd) |
| 65 | |
Bill Pemberton | 042a190 | 2012-11-19 13:24:23 -0500 | [diff] [blame] | 66 | static struct flash_info sst25l_flash_info[] = { |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 67 | {"sst25lf020a", 0xbf43, 256, 1024, 4096}, |
| 68 | {"sst25lf040a", 0xbf44, 256, 2048, 4096}, |
| 69 | }; |
| 70 | |
| 71 | static int sst25l_status(struct sst25l_flash *flash, int *status) |
| 72 | { |
H Hartley Sweeten | 0ffe0ce | 2010-04-29 13:34:24 -0500 | [diff] [blame] | 73 | struct spi_message m; |
| 74 | struct spi_transfer t; |
| 75 | unsigned char cmd_resp[2]; |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 76 | int err; |
| 77 | |
H Hartley Sweeten | 0ffe0ce | 2010-04-29 13:34:24 -0500 | [diff] [blame] | 78 | spi_message_init(&m); |
| 79 | memset(&t, 0, sizeof(struct spi_transfer)); |
| 80 | |
| 81 | cmd_resp[0] = SST25L_CMD_RDSR; |
| 82 | cmd_resp[1] = 0xff; |
| 83 | t.tx_buf = cmd_resp; |
| 84 | t.rx_buf = cmd_resp; |
| 85 | t.len = sizeof(cmd_resp); |
| 86 | spi_message_add_tail(&t, &m); |
| 87 | err = spi_sync(flash->spi, &m); |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 88 | if (err < 0) |
| 89 | return err; |
| 90 | |
H Hartley Sweeten | 0ffe0ce | 2010-04-29 13:34:24 -0500 | [diff] [blame] | 91 | *status = cmd_resp[1]; |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 92 | return 0; |
| 93 | } |
| 94 | |
| 95 | static int sst25l_write_enable(struct sst25l_flash *flash, int enable) |
| 96 | { |
| 97 | unsigned char command[2]; |
| 98 | int status, err; |
| 99 | |
| 100 | command[0] = enable ? SST25L_CMD_WREN : SST25L_CMD_WRDI; |
| 101 | err = spi_write(flash->spi, command, 1); |
| 102 | if (err) |
| 103 | return err; |
| 104 | |
| 105 | command[0] = SST25L_CMD_EWSR; |
| 106 | err = spi_write(flash->spi, command, 1); |
| 107 | if (err) |
| 108 | return err; |
| 109 | |
| 110 | command[0] = SST25L_CMD_WRSR; |
| 111 | command[1] = enable ? 0 : SST25L_STATUS_BP0 | SST25L_STATUS_BP1; |
| 112 | err = spi_write(flash->spi, command, 2); |
| 113 | if (err) |
| 114 | return err; |
| 115 | |
| 116 | if (enable) { |
| 117 | err = sst25l_status(flash, &status); |
| 118 | if (err) |
| 119 | return err; |
| 120 | if (!(status & SST25L_STATUS_WREN)) |
| 121 | return -EROFS; |
| 122 | } |
| 123 | |
| 124 | return 0; |
| 125 | } |
| 126 | |
| 127 | static int sst25l_wait_till_ready(struct sst25l_flash *flash) |
| 128 | { |
| 129 | unsigned long deadline; |
| 130 | int status, err; |
| 131 | |
| 132 | deadline = jiffies + MAX_READY_WAIT_JIFFIES; |
| 133 | do { |
| 134 | err = sst25l_status(flash, &status); |
| 135 | if (err) |
| 136 | return err; |
| 137 | if (!(status & SST25L_STATUS_BUSY)) |
| 138 | return 0; |
| 139 | |
| 140 | cond_resched(); |
| 141 | } while (!time_after_eq(jiffies, deadline)); |
| 142 | |
| 143 | return -ETIMEDOUT; |
| 144 | } |
| 145 | |
| 146 | static int sst25l_erase_sector(struct sst25l_flash *flash, uint32_t offset) |
| 147 | { |
| 148 | unsigned char command[4]; |
| 149 | int err; |
| 150 | |
| 151 | err = sst25l_write_enable(flash, 1); |
| 152 | if (err) |
| 153 | return err; |
| 154 | |
| 155 | command[0] = SST25L_CMD_SECTOR_ERASE; |
| 156 | command[1] = offset >> 16; |
| 157 | command[2] = offset >> 8; |
| 158 | command[3] = offset; |
| 159 | err = spi_write(flash->spi, command, 4); |
| 160 | if (err) |
| 161 | return err; |
| 162 | |
| 163 | err = sst25l_wait_till_ready(flash); |
| 164 | if (err) |
| 165 | return err; |
| 166 | |
| 167 | return sst25l_write_enable(flash, 0); |
| 168 | } |
| 169 | |
| 170 | static int sst25l_erase(struct mtd_info *mtd, struct erase_info *instr) |
| 171 | { |
| 172 | struct sst25l_flash *flash = to_sst25l_flash(mtd); |
| 173 | uint32_t addr, end; |
| 174 | int err; |
| 175 | |
| 176 | /* Sanity checks */ |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 177 | if ((uint32_t)instr->len % mtd->erasesize) |
| 178 | return -EINVAL; |
| 179 | |
| 180 | if ((uint32_t)instr->addr % mtd->erasesize) |
| 181 | return -EINVAL; |
| 182 | |
| 183 | addr = instr->addr; |
| 184 | end = addr + instr->len; |
| 185 | |
| 186 | mutex_lock(&flash->lock); |
| 187 | |
| 188 | err = sst25l_wait_till_ready(flash); |
Jiri Slaby | 2eaaa5f | 2009-09-18 12:51:42 -0700 | [diff] [blame] | 189 | if (err) { |
| 190 | mutex_unlock(&flash->lock); |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 191 | return err; |
Jiri Slaby | 2eaaa5f | 2009-09-18 12:51:42 -0700 | [diff] [blame] | 192 | } |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 193 | |
| 194 | while (addr < end) { |
| 195 | err = sst25l_erase_sector(flash, addr); |
| 196 | if (err) { |
| 197 | mutex_unlock(&flash->lock); |
| 198 | instr->state = MTD_ERASE_FAILED; |
| 199 | dev_err(&flash->spi->dev, "Erase failed\n"); |
| 200 | return err; |
| 201 | } |
| 202 | |
| 203 | addr += mtd->erasesize; |
| 204 | } |
| 205 | |
| 206 | mutex_unlock(&flash->lock); |
| 207 | |
| 208 | instr->state = MTD_ERASE_DONE; |
| 209 | mtd_erase_callback(instr); |
| 210 | return 0; |
| 211 | } |
| 212 | |
| 213 | static int sst25l_read(struct mtd_info *mtd, loff_t from, size_t len, |
| 214 | size_t *retlen, unsigned char *buf) |
| 215 | { |
| 216 | struct sst25l_flash *flash = to_sst25l_flash(mtd); |
| 217 | struct spi_transfer transfer[2]; |
| 218 | struct spi_message message; |
| 219 | unsigned char command[4]; |
| 220 | int ret; |
| 221 | |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 222 | spi_message_init(&message); |
| 223 | memset(&transfer, 0, sizeof(transfer)); |
| 224 | |
| 225 | command[0] = SST25L_CMD_READ; |
| 226 | command[1] = from >> 16; |
| 227 | command[2] = from >> 8; |
| 228 | command[3] = from; |
| 229 | |
| 230 | transfer[0].tx_buf = command; |
| 231 | transfer[0].len = sizeof(command); |
| 232 | spi_message_add_tail(&transfer[0], &message); |
| 233 | |
| 234 | transfer[1].rx_buf = buf; |
| 235 | transfer[1].len = len; |
| 236 | spi_message_add_tail(&transfer[1], &message); |
| 237 | |
| 238 | mutex_lock(&flash->lock); |
| 239 | |
| 240 | /* Wait for previous write/erase to complete */ |
| 241 | ret = sst25l_wait_till_ready(flash); |
| 242 | if (ret) { |
| 243 | mutex_unlock(&flash->lock); |
| 244 | return ret; |
| 245 | } |
| 246 | |
| 247 | spi_sync(flash->spi, &message); |
| 248 | |
| 249 | if (retlen && message.actual_length > sizeof(command)) |
| 250 | *retlen += message.actual_length - sizeof(command); |
| 251 | |
| 252 | mutex_unlock(&flash->lock); |
| 253 | return 0; |
| 254 | } |
| 255 | |
| 256 | static int sst25l_write(struct mtd_info *mtd, loff_t to, size_t len, |
| 257 | size_t *retlen, const unsigned char *buf) |
| 258 | { |
| 259 | struct sst25l_flash *flash = to_sst25l_flash(mtd); |
| 260 | int i, j, ret, bytes, copied = 0; |
| 261 | unsigned char command[5]; |
| 262 | |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 263 | if ((uint32_t)to % mtd->writesize) |
| 264 | return -EINVAL; |
| 265 | |
| 266 | mutex_lock(&flash->lock); |
| 267 | |
| 268 | ret = sst25l_write_enable(flash, 1); |
| 269 | if (ret) |
| 270 | goto out; |
| 271 | |
| 272 | for (i = 0; i < len; i += mtd->writesize) { |
| 273 | ret = sst25l_wait_till_ready(flash); |
| 274 | if (ret) |
| 275 | goto out; |
| 276 | |
| 277 | /* Write the first byte of the page */ |
| 278 | command[0] = SST25L_CMD_AAI_PROGRAM; |
| 279 | command[1] = (to + i) >> 16; |
| 280 | command[2] = (to + i) >> 8; |
| 281 | command[3] = (to + i); |
| 282 | command[4] = buf[i]; |
| 283 | ret = spi_write(flash->spi, command, 5); |
| 284 | if (ret < 0) |
| 285 | goto out; |
| 286 | copied++; |
| 287 | |
| 288 | /* |
| 289 | * Write the remaining bytes using auto address |
| 290 | * increment mode |
| 291 | */ |
| 292 | bytes = min_t(uint32_t, mtd->writesize, len - i); |
| 293 | for (j = 1; j < bytes; j++, copied++) { |
| 294 | ret = sst25l_wait_till_ready(flash); |
| 295 | if (ret) |
| 296 | goto out; |
| 297 | |
| 298 | command[1] = buf[i + j]; |
| 299 | ret = spi_write(flash->spi, command, 2); |
| 300 | if (ret) |
| 301 | goto out; |
| 302 | } |
| 303 | } |
| 304 | |
| 305 | out: |
| 306 | ret = sst25l_write_enable(flash, 0); |
| 307 | |
| 308 | if (retlen) |
| 309 | *retlen = copied; |
| 310 | |
| 311 | mutex_unlock(&flash->lock); |
| 312 | return ret; |
| 313 | } |
| 314 | |
Bill Pemberton | 06f2551 | 2012-11-19 13:23:07 -0500 | [diff] [blame] | 315 | static struct flash_info *sst25l_match_device(struct spi_device *spi) |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 316 | { |
| 317 | struct flash_info *flash_info = NULL; |
H Hartley Sweeten | 0ffe0ce | 2010-04-29 13:34:24 -0500 | [diff] [blame] | 318 | struct spi_message m; |
| 319 | struct spi_transfer t; |
| 320 | unsigned char cmd_resp[6]; |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 321 | int i, err; |
| 322 | uint16_t id; |
| 323 | |
H Hartley Sweeten | 0ffe0ce | 2010-04-29 13:34:24 -0500 | [diff] [blame] | 324 | spi_message_init(&m); |
| 325 | memset(&t, 0, sizeof(struct spi_transfer)); |
| 326 | |
| 327 | cmd_resp[0] = SST25L_CMD_READ_ID; |
| 328 | cmd_resp[1] = 0; |
| 329 | cmd_resp[2] = 0; |
| 330 | cmd_resp[3] = 0; |
| 331 | cmd_resp[4] = 0xff; |
| 332 | cmd_resp[5] = 0xff; |
| 333 | t.tx_buf = cmd_resp; |
| 334 | t.rx_buf = cmd_resp; |
| 335 | t.len = sizeof(cmd_resp); |
| 336 | spi_message_add_tail(&t, &m); |
| 337 | err = spi_sync(spi, &m); |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 338 | if (err < 0) { |
H Hartley Sweeten | 0ffe0ce | 2010-04-29 13:34:24 -0500 | [diff] [blame] | 339 | dev_err(&spi->dev, "error reading device id\n"); |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 340 | return NULL; |
| 341 | } |
| 342 | |
H Hartley Sweeten | 0ffe0ce | 2010-04-29 13:34:24 -0500 | [diff] [blame] | 343 | id = (cmd_resp[4] << 8) | cmd_resp[5]; |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 344 | |
| 345 | for (i = 0; i < ARRAY_SIZE(sst25l_flash_info); i++) |
| 346 | if (sst25l_flash_info[i].device_id == id) |
| 347 | flash_info = &sst25l_flash_info[i]; |
| 348 | |
| 349 | if (!flash_info) |
| 350 | dev_err(&spi->dev, "unknown id %.4x\n", id); |
| 351 | |
| 352 | return flash_info; |
| 353 | } |
| 354 | |
Bill Pemberton | 06f2551 | 2012-11-19 13:23:07 -0500 | [diff] [blame] | 355 | static int sst25l_probe(struct spi_device *spi) |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 356 | { |
| 357 | struct flash_info *flash_info; |
| 358 | struct sst25l_flash *flash; |
| 359 | struct flash_platform_data *data; |
Artem Bityutskiy | d81a32f | 2011-12-29 18:06:01 +0200 | [diff] [blame] | 360 | int ret; |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 361 | |
| 362 | flash_info = sst25l_match_device(spi); |
| 363 | if (!flash_info) |
| 364 | return -ENODEV; |
| 365 | |
Sachin Kamat | b38be28 | 2013-10-08 14:51:34 +0530 | [diff] [blame] | 366 | flash = devm_kzalloc(&spi->dev, sizeof(*flash), GFP_KERNEL); |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 367 | if (!flash) |
| 368 | return -ENOMEM; |
| 369 | |
| 370 | flash->spi = spi; |
| 371 | mutex_init(&flash->lock); |
Jingoo Han | 1594908 | 2013-04-06 15:40:30 +0900 | [diff] [blame] | 372 | spi_set_drvdata(spi, flash); |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 373 | |
Jingoo Han | 0278fd3 | 2013-07-30 17:17:44 +0900 | [diff] [blame] | 374 | data = dev_get_platdata(&spi->dev); |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 375 | if (data && data->name) |
| 376 | flash->mtd.name = data->name; |
| 377 | else |
| 378 | flash->mtd.name = dev_name(&spi->dev); |
| 379 | |
| 380 | flash->mtd.type = MTD_NORFLASH; |
| 381 | flash->mtd.flags = MTD_CAP_NORFLASH; |
| 382 | flash->mtd.erasesize = flash_info->erase_size; |
| 383 | flash->mtd.writesize = flash_info->page_size; |
Artem Bityutskiy | c4cc625 | 2012-02-03 10:16:50 +0200 | [diff] [blame] | 384 | flash->mtd.writebufsize = flash_info->page_size; |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 385 | flash->mtd.size = flash_info->page_size * flash_info->nr_pages; |
Artem Bityutskiy | 3c3c10b | 2012-01-30 14:58:32 +0200 | [diff] [blame] | 386 | flash->mtd._erase = sst25l_erase; |
| 387 | flash->mtd._read = sst25l_read; |
| 388 | flash->mtd._write = sst25l_write; |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 389 | |
| 390 | dev_info(&spi->dev, "%s (%lld KiB)\n", flash_info->name, |
| 391 | (long long)flash->mtd.size >> 10); |
| 392 | |
Brian Norris | 289c052 | 2011-07-19 10:06:09 -0700 | [diff] [blame] | 393 | pr_debug("mtd .name = %s, .size = 0x%llx (%lldMiB) " |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 394 | ".erasesize = 0x%.8x (%uKiB) .numeraseregions = %d\n", |
| 395 | flash->mtd.name, |
| 396 | (long long)flash->mtd.size, (long long)(flash->mtd.size >> 20), |
| 397 | flash->mtd.erasesize, flash->mtd.erasesize / 1024, |
| 398 | flash->mtd.numeraseregions); |
| 399 | |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 400 | |
Artem Bityutskiy | 42d7fbe | 2012-03-09 19:24:26 +0200 | [diff] [blame] | 401 | ret = mtd_device_parse_register(&flash->mtd, NULL, NULL, |
| 402 | data ? data->parts : NULL, |
| 403 | data ? data->nr_parts : 0); |
Sachin Kamat | b38be28 | 2013-10-08 14:51:34 +0530 | [diff] [blame] | 404 | if (ret) |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 405 | return -ENODEV; |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 406 | |
| 407 | return 0; |
| 408 | } |
| 409 | |
Bill Pemberton | 810b7e0 | 2012-11-19 13:26:04 -0500 | [diff] [blame] | 410 | static int sst25l_remove(struct spi_device *spi) |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 411 | { |
Jingoo Han | 1594908 | 2013-04-06 15:40:30 +0900 | [diff] [blame] | 412 | struct sst25l_flash *flash = spi_get_drvdata(spi); |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 413 | |
Sachin Kamat | b38be28 | 2013-10-08 14:51:34 +0530 | [diff] [blame] | 414 | return mtd_device_unregister(&flash->mtd); |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 415 | } |
| 416 | |
| 417 | static struct spi_driver sst25l_driver = { |
| 418 | .driver = { |
| 419 | .name = "sst25l", |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 420 | .owner = THIS_MODULE, |
| 421 | }, |
| 422 | .probe = sst25l_probe, |
Bill Pemberton | 5153b88 | 2012-11-19 13:21:24 -0500 | [diff] [blame] | 423 | .remove = sst25l_remove, |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 424 | }; |
| 425 | |
Axel Lin | c9d1b75 | 2012-01-27 15:45:20 +0800 | [diff] [blame] | 426 | module_spi_driver(sst25l_driver); |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 427 | |
| 428 | MODULE_DESCRIPTION("MTD SPI driver for SST25L Flash chips"); |
| 429 | MODULE_AUTHOR("Andre Renaud <andre@bluewatersys.com>, " |
Ryan Mallon | 1c5454e | 2011-06-15 14:45:36 +1000 | [diff] [blame] | 430 | "Ryan Mallon"); |
Ryan Mallon | ec77e21 | 2009-09-18 12:51:40 -0700 | [diff] [blame] | 431 | MODULE_LICENSE("GPL"); |