summaryrefslogtreecommitdiffstats
path: root/at45db.c
Commit message (Collapse)AuthorAgeFilesLines
* Introduce helpers.cStefan Tauner2014-06-121-11/+0
| | | | | | | | | | Move some suitable functions there, add it to the Makefile, but leave the declarations in flash.h for now. Corresponding to flashrom svn r1819. Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> Acked-by: Carl-Daniel Hailfinger <c-d.hailfinger.devel.2006@gmx.net>
* AT45DB: fix read functionsStefan Tauner2014-05-161-4/+8
| | | | | | | | | | | | | | | | | | | | | | This fixes segfaults on reads (implicit reads on writes too), ouch. Thanks to The Raven for reporting the problem and testing my patch, and to Alexander Irenkov for providing a workable fix for it additionally. There were actually two problems: 1) The loop conditions were bogus which could lead to read errors (e.g. on implicit erase verifications). 2) The offset used within the read buffers provided to spi_nbyte_read() and memcpy() were not starting at 0 but the offset of the block within the flash chip (which has nothing to do with read buffer in most cases). This patch works similarly to Alexander's but is intended to be more readable. Corresponding to flashrom svn r1792. Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
* Add 'const' keyword to chip write and other function prototypesMark Marshall2014-05-091-3/+3
| | | | | | | | | | Corresponding to flashrom svn r1789. Inspired by and mostly based on a patch Signed-off-by: Mark Marshall <mark.marshall@omicron.at> Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
* Add support for AT45CS1282Stefan Tauner2013-08-271-0/+41
| | | | | | | | | | | This one is even more strange than the AT45DB chips. Like the AT45DB321C it does not support any power-of-2 page sizes. There is only one asymmetrical eraser and that uses two opcodes. Corresponding to flashrom svn r1725. Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
* Add support for AT45DB321CStefan Tauner2013-08-271-3/+51
| | | | | | | | | | It seems like this model is one-of-a-kind... it shares some properties with the older versions of the AT45DB series as well as with new ones. Corresponding to flashrom svn r1724. Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
* Add support for Atmel AT45DB* chipsAidan Thornton2013-08-271-0/+473
Corresponding to flashrom svn r1723. Signed-off-by: Aidan Thornton <makosoft@gmail.com> Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at> Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
OpenPOWER on IntegriCloud