Skip to content

Commit

Permalink
mtd: m25p80: set writebufsize
Browse files Browse the repository at this point in the history
Using UBI on m25p80 can give messages like:

    UBI error: io_init: bad write buffer size 0 for 1 min. I/O unit

We need to initialize writebufsize; I think "page_size" is the correct
"bufsize", although I'm not sure. Comments?

Signed-off-by: Brian Norris <[email protected]>
Signed-off-by: Artem Bityutskiy <[email protected]>
Cc: [email protected] [2.6.38+]
Signed-off-by: David Woodhouse <[email protected]>
  • Loading branch information
computersforpeace authored and David Woodhouse committed Mar 26, 2012
1 parent 3ee5014 commit b54f47c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions drivers/mtd/devices/m25p80.c
Original file line number Diff line number Diff line change
Expand Up @@ -932,6 +932,7 @@ static int __devinit m25p_probe(struct spi_device *spi)
ppdata.of_node = spi->dev.of_node;
flash->mtd.dev.parent = &spi->dev;
flash->page_size = info->page_size;
flash->mtd.writebufsize = flash->page_size;

if (info->addr_width)
flash->addr_width = info->addr_width;
Expand Down

0 comments on commit b54f47c

Please sign in to comment.