aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/spi/spi-butterfly.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/drivers/spi/spi-butterfly.c b/drivers/spi/spi-butterfly.c
index b1ecea2d76b3..8081f96bd1d5 100644
--- a/drivers/spi/spi-butterfly.c
+++ b/drivers/spi/spi-butterfly.c
@@ -147,8 +147,8 @@ static void butterfly_chipselect(struct spi_device *spi, int value)
147 147
148/* we only needed to implement one mode here, and choose SPI_MODE_0 */ 148/* we only needed to implement one mode here, and choose SPI_MODE_0 */
149 149
150#define spidelay(X) do{}while(0) 150#define spidelay(X) do { } while (0)
151//#define spidelay ndelay 151/* #define spidelay ndelay */
152 152
153#include "spi-bitbang-txrx.h" 153#include "spi-bitbang-txrx.h"
154 154
@@ -171,15 +171,15 @@ static struct mtd_partition partitions[] = { {
171 /* sector 0 = 8 pages * 264 bytes/page (1 block) 171 /* sector 0 = 8 pages * 264 bytes/page (1 block)
172 * sector 1 = 248 pages * 264 bytes/page 172 * sector 1 = 248 pages * 264 bytes/page
173 */ 173 */
174 .name = "bookkeeping", // 66 KB 174 .name = "bookkeeping", /* 66 KB */
175 .offset = 0, 175 .offset = 0,
176 .size = (8 + 248) * 264, 176 .size = (8 + 248) * 264,
177// .mask_flags = MTD_WRITEABLE, 177 /* .mask_flags = MTD_WRITEABLE, */
178}, { 178}, {
179 /* sector 2 = 256 pages * 264 bytes/page 179 /* sector 2 = 256 pages * 264 bytes/page
180 * sectors 3-5 = 512 pages * 264 bytes/page 180 * sectors 3-5 = 512 pages * 264 bytes/page
181 */ 181 */
182 .name = "filesystem", // 462 KB 182 .name = "filesystem", /* 462 KB */
183 .offset = MTDPART_OFS_APPEND, 183 .offset = MTDPART_OFS_APPEND,
184 .size = MTDPART_SIZ_FULL, 184 .size = MTDPART_SIZ_FULL,
185} }; 185} };
@@ -209,7 +209,7 @@ static void butterfly_attach(struct parport *p)
209 * and no way to be selective about what it binds to. 209 * and no way to be selective about what it binds to.
210 */ 210 */
211 211
212 master = spi_alloc_master(dev, sizeof *pp); 212 master = spi_alloc_master(dev, sizeof(*pp));
213 if (!master) { 213 if (!master) {
214 status = -ENOMEM; 214 status = -ENOMEM;
215 goto done; 215 goto done;
@@ -289,7 +289,6 @@ static void butterfly_attach(struct parport *p)
289 pr_debug("%s: dataflash at %s\n", p->name, 289 pr_debug("%s: dataflash at %s\n", p->name,
290 dev_name(&pp->dataflash->dev)); 290 dev_name(&pp->dataflash->dev));
291 291
292 // dev_info(_what?_, ...)
293 pr_info("%s: AVR Butterfly\n", p->name); 292 pr_info("%s: AVR Butterfly\n", p->name);
294 butterfly = pp; 293 butterfly = pp;
295 return; 294 return;