Commit graph android_kernel_sony_sdm845/drivers/mtd
Message SHA1
[MTD] Nuke IVR leftovers
Support for the ITE8172 based boards was deleted a while ago so this is
dead code.

The Kconfig dependency on MIPS was wrong anyway, MIPS is a processor
architecture and nothing else; guesses on systems architecture are likely
to be wrong ...

Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Ralf Baechle   authored and   David Woodhouse   commited 2006-12-11 16:30:26 +00:00
0bf3a9d82a
[MTD] OneNAND: fix oob handling in recent oob patch
There are missing place in recent MTD oob patch

http://git.infradead.org/?p=mtd-2.6.git;a=commitdiff;h=7014568bad55c20b7ee4f439d78c9e875912d51f

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Kyungmin Park   authored and   David Woodhouse   commited 2006-12-11 10:46:20 +00:00
66a1e421b9
[MTD] Fix ssfdc blksize typo
I will not commit even trivial and obvious one-line fixes without building.
I will not commit even trivial and obvious one-line fixes without building.
I will not commit even trivial and obvious one-line fixes without building.
I will not commit even trivial and obvious one-line fixes without building.
Only clever people can get away with that.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-12-11 09:43:38 +00:00
76ab40e465
[MTD] Fix SSFDC build for variable blocksize.
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-12-10 11:48:54 +00:00
db06e2a93f
[MTD] ESB2ROM uses PCI
ESB2ROM uses PCI interface functions.

With CONFIG_PCI=n:
drivers/mtd/maps/esb2rom.c: In function 'esb2rom_init_one':
drivers/mtd/maps/esb2rom.c:167: warning: implicit declaration of function 'pci_dev_get'

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Randy Dunlap   authored and   David Woodhouse   commited 2006-12-10 11:43:21 +00:00
dffbc42b5a
[MTD] of_device-based physmap driver
inlined below is the patch that adds physmap driver for of_device.
It's an MTD part of the two-part support for flash/ROM devices based
on Open Firmware descriptions. The arch part (currently only PowerPC
which is no surprise) was introduced to powerpc folks earlier and
recently the older version of the powerpc part has been included into
the powerpc.git tree
(see http://www.kernel.org/git/?p=linux/kernel/git/paulus/powerpc.git;a=commitdiff;h=28f9ec349ae47c91768b7bc5607db4442c818e11).

 drivers/mtd/maps/Kconfig      |    9 +
 drivers/mtd/maps/Makefile     |    1
 drivers/mtd/maps/physmap_of.c |  255 ++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 265 insertions(+)

Signed-off-by: Vitaly Wool <vwool@ru.mvista.com>
Signed-off-by: Sergey Shtylyov <sshtylyov@ru.mvista.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Vitaly Wool   authored and   David Woodhouse   commited 2006-12-08 13:32:34 +00:00
a2c2fe4b24
[MTD] Support combined RedBoot FIS directory and configuration area
RedBoot supports storing the FIS directory and the RedBoot
configuration area in the same block of flash memory.  This is
not the most common RedBoot configuration, but it is used on
commercially available boards supported by the kernel.

A recent patch to mtd/redboot.c (http://lkml.org/lkml/2006/3/20/410)
which corrected the skipping of deleted table entries has exposed the
latent problem of the kernel redboot parser running off the end of the
FIS directory and interpreting the RedBoot configuration information
as table entries.

This patch terminates the table parsing when the first truly empty
entry is found (table entry deletion only clears the first byte of the
name, so two cleared bytes in a row indicates the end of the table),
thereby supporting the combined redboot FIS directory and RedBoot
configuration information flash layout scenario.

Signed-off-by: Rod Whitby <rod@whitby.id.au>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Rod Whitby   authored and   David Woodhouse   commited 2006-12-08 13:28:26 +00:00
f33665d931
[MTD] NAND: Support for 16-bit bus-width on AT91.
Add support for 16-bit NAND bus-width for the AT91 NAND driver.

The 16-bit NAND is found on the Atmel AT91SAM9260-EK and AT91SAM9261-EK
boards.

Orignal Patch from Patrice Vilchez

Signed-off-by: Andrew Victor <andrew@sanpeople.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Andrew Victor   authored and   David Woodhouse   commited 2006-12-08 13:25:17 +00:00
dd11b8cdf0
[MTD] nandsim: bugfix in page addressing
Number of address bytes for 64-128 MiB NANDs is 4, not 5.

Signed-off-by: Artem Bityutskiy <dedekind@infradead.org>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Artem Bityutskiy   authored and   David Woodhouse   commited 2006-12-08 13:22:54 +00:00
4a0c50c07a
[PATCH] slab: remove SLAB_KERNEL
SLAB_KERNEL is an alias of GFP_KERNEL.

Signed-off-by: Christoph Lameter <clameter@sgi.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>

Christoph Lameter   authored and   Linus Torvalds   commited 2006-12-07 08:39:24 -08:00
e94b176609
[MTD] NAND: use SmartMedia ECC byte order for ndfc
Select MTD_NAND_ECC_SMC (ECC byte order according to the Smart Media
Specification) if MTD_NAND_NDFC is used.
Using the wrong byte order causes fatal, unnoticed data damage.

For further information see:
http://lists.infradead.org/pipermail/linux-mtd/2006-November/016920.html

Signed-off-by: Timo Lindhorst <lindhors@linux.vnet.ibm.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Timo Lindhorst   authored and   David Woodhouse   commited 2006-12-05 18:00:13 +00:00
418b2e56b8
[MTD] redboot partition combined fis / config problem
Can't analyze FIS directory in CYGSEM_REDBOOT_FLASH_COMBINED_FIS_AND_CONFIG
really.

Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Yoshinori Sato   authored and   David Woodhouse   commited 2006-12-01 10:01:50 +00:00
0b47d65408
[MTD] [NAND] Compile fix in rfc_from4.c
Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Mariusz Kozlowski   authored and   David Woodhouse   commited 2006-12-01 09:59:49 +00:00
7dcb483de3
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
David Woodhouse   commited 2006-12-01 09:56:43 +00:00
bd3c97a7c7
[MTD] bugfix: DataFlash is not bit writable
This patch fixes the
"jffs2_flash_writev(): Non-contiguous write to 00825300 with mtd_dataflash" bug.

Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com>
Signed-off-by: Artem Bityutskiy <dedekind@infradead.org>

Haavard Skinnemoen   authored and   Artem Bityutskiy   commited 2006-12-01 10:30:45 +02:00
6c33cafc79
[MTD] Remove trailing whitespace
The newly-added cafe_ecc.c had a lot of it because of the way the lookup
table was auto-generated; clean up the other files too while we're at it.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-11-30 08:17:38 +00:00
c9ac597729
Fix typos in doc and comments
Changes persistant -> persistent. www.dictionary.com does not know
persistant (with an A), but should it be one of those things you can
spell in more than one correct way, let me know.

Signed-off-by: Jan Engelhardt <jengelh@gmx.de>
Signed-off-by: Adrian Bunk <bunk@stusta.de>

Jan Engelhardt   authored and   Adrian Bunk   commited 2006-11-30 05:32:19 +01:00
03a67a46af
Fix misc Kconfig typos
Fix various Kconfig typos.

Signed-off-by: Matt LaPlante <kernel1@cyberdogtech.com>
Acked-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Adrian Bunk <bunk@stusta.de>

Matt LaPlante   authored and   Adrian Bunk   commited 2006-11-30 05:22:59 +01:00
3cb2fccc5f
[MTD] Use EXPORT_SYMBOL_GPL() for exported symbols.
While we're fixing up the newly-added symbol, change the neighbouring ones
too, for consistency and also to reflect the author's interpretation of
the GPL -- which is that _no_ non-GPL modules are permitted. The author
always intended his code to be released under the GPL, and believes that
any new interpretation of 'EXPORT_SYMBOL' as being any different from
'EXPORT_SYMBOL_GPL' is entirely invalid; the GPL requires that _all_
exports have the semantics of the new 'EXPORT_SYMBOL_GPL', which means the
extra four characters are entirely redundant.

But since those four extra characters trigger the check for illegal
modules in a way that just EXPORT_SYMBOL does not, it's useful to change
anyway. This action in no way indicates an admission that there is any
legal distinction between the two states, and in particular does not
indicate that the author believes that non-GPL modules may use symbols
exported with EXPORT_SYMBOL alone.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-11-29 16:33:03 +00:00
dd36f26735
[MTD] return error code from get_mtd_device()
get_mtd_device() returns NULL in case of any failure. Teach it to return an
error code instead. Fix all users as well.

Signed-off-by: Artem Bityutskiy <dedekind@infradead.org>

Artem Bityutskiy   commited 2006-11-29 17:06:38 +02:00
9c74034f8f
[MTD] add get and put methods
This patch adds get_device() and put_device() methods to the MTD description
structure (struct mtd_info). These methods are called by MTD whenever the MTD
device is get or put. They are needed when the underlying driver is something
smarter then just flash chip driver, for example UBI.

Signed-off-by: Artem Bityutskiy <dedekind@infradead.org>

Artem Bityutskiy   commited 2006-11-29 17:04:53 +02:00
9fe912cea3
[MTD] add get_mtd_device_nm() function
This patch adds one more function to the MTD interface to make it possible to
open MTD devices by their names, not only numbers. This is very handy in many
situations. Also, MTD device number depend on load order and may vary, while
names are fixed.

Signed-off-by: Artem Bityutskiy <dedekind@infradead.org>

Artem Bityutskiy   commited 2006-11-29 17:04:31 +02:00
7799308f34
[MTD] NAND: add subpage write support
Many SLC NANDs support up to 4 writes at one NAND page. Add support
of this feature.

Signed-off-by: Artem Bityutskiy <dedekind@infradead.org>

Thomas Gleixner   authored and   Artem Bityutskiy   commited 2006-11-29 17:03:52 +02:00
29072b9607
[MTD] add MTD_BLKDEVS Kconfig option
Add a MTD_BLKDEVS Kconfig option to cleanup the makefile a bit

Signed-off-by: Josh Boyer <jwboyer@linux.vnet.ibm.com>
Signed-off-by: Artem Bityutskiy <dedekind@infradead.org>

Josh Boyer   authored and   Artem Bityutskiy   commited 2006-11-29 16:58:15 +02:00
f6a7ecb18d
[MTD] fix map probe name for cstm_mips_ixx
This patch has fixed name of map probe for cstm_mips_ixx.c

Signed-off-by: Yoichi Yuasa <yoichi_yuasa@tripeaks.co.jp>
Signed-off-by: Artem Bityutskiy <dedekind@infradead.org>

Yoichi Yuasa   authored and   Artem Bityutskiy   commited 2006-11-29 16:57:55 +02:00
eb6cf7bb71
[PATCH] Fix Intel/Sharp command set erase suspend bug
When we sleep and wait for a suspended operation to be resumed, go
back and check until it's ready -- don't just continue after the first
time we're woken. This can cause file system corruption.

Signed-off-by: Joakim Tjernlund <Joakim.Tjernlund@transmode.se>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>

Joakim Tjernlund   authored and   Linus Torvalds   commited 2006-11-28 17:26:50 -08:00
967bf623e9
[MTD] Tidy bitrev usage in rtc_from4.c
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Andrew Morton   authored and   David Woodhouse   commited 2006-11-29 00:19:14 +00:00
ce1060494a
[MTD] [NAND] fix ifdef option in nand_ecc.c
Fix up the config option in the #ifdef statements in nand_ecc.c

Signed-off-by: Timo Lindhorst <lindhors@linux.vnet.ibm.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Timo Lindhorst   authored and   David Woodhouse   commited 2006-11-29 00:11:39 +00:00
fc02919499
[MTD] [NAND] Update CAFÉ driver interrupt handler prototype
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-11-29 00:04:59 +00:00
28bdd4a72d
Merge git://git.infradead.org/~kmpark/onenand-mtd-2.6
David Woodhouse   commited 2006-11-29 00:03:10 +00:00
103e40f633
[MTD] replace kmalloc+memset with kzalloc
Signed-off-by: Yan Burman <yan_952@hotmail.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Burman Yan   authored and   David Woodhouse   commited 2006-11-28 23:47:21 +00:00
95b93a0cd4
[MTD] Fix printk format warning in physmap. (resources again)
Fix printk format warning:
drivers/mtd/maps/physmap.c:93: warning: long long unsigned int format, long unsigned int arg (arg 2)

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Randy Dunlap   authored and   David Woodhouse   commited 2006-11-28 23:40:46 +00:00
998a43e72d
Merge git://git.infradead.org/~dwmw2/cafe-2.6
David Woodhouse   commited 2006-11-28 22:43:10 +00:00
1aaaeabf36
[MTD] [NAND] remove len/ooblen confusion.
As was discussed between Ricard Wanderlöf, David Woodhouse, Artem 
Bityutskiy and me, the current API for reading/writing OOB is confusing. 

The thing that introduces confusion is the need to specify ops.len 
together with ops.ooblen for reads/writes that concern only OOB not data 
area. So, ops.len is overloaded: when ops.datbuf != NULL it serves to 
specify the length of the data read, and when ops.datbuf == NULL, it 
serves to specify the full OOB read length.

The patch inlined below is the slightly updated version of the previous 
patch serving the same purpose, but with the new Artem's comments taken 
into account.

Artem, BTW, thanks a lot for your valuable input!

Signed-off-by: Vitaly Wool <vwool@ru.mvista.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Vitaly Wool   authored and   David Woodhouse   commited 2006-11-28 22:39:03 +00:00
7014568bad
[MTD] Allow variable block sizes in mtd_blkdevs
Currently, mtd_blkdevs enforces a block size of 512, even if the drivers
can seemingly request a different size. This patch fixes mtd_blkdevs so
block sizes other than 512 work correctly.

Signed-off-by: Richard Purdie <rpurdie@openedhand.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Richard Purdie   authored and   David Woodhouse   commited 2006-11-28 22:27:47 +00:00
1918767299
[MTD] [MAPS] Support for BIOS flash chips on the nvidia ck804 southbridge
Add support for accessing BIOS flash chips connected to the NVIDIA ck804 southbridge.

Signed-off-by: Ryan Jackson <rjackson@lnxi.com>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Dave Olsen   authored and   David Woodhouse   commited 2006-11-28 22:25:27 +00:00
90afffc8bd
[MTD] [NAND] Fix endianess bug in ndfc.c
The writel() call accidentally clears all bits in the NDFC_CCR
register (endianess problem). Now __raw_writel() is used instead.

Tested on Bamboo with NAND on chip select 0 and chip select 1.

Signed-off-by: Stefan Roese <sr@denx.de>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Stefan Roese   authored and   David Woodhouse   commited 2006-11-28 22:22:55 +00:00
4010db56c8
[MTD] make drivers/mtd/cmdlinepart.c:mtdpart_setup() static
This patch makes the needlessly global mtdpart_setup() static.

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Adrian Bunk   authored and   David Woodhouse   commited 2006-11-28 22:19:16 +00:00
ddacff1f20
[MTD] [NAND] rtc_from4.c: use lib/bitrev.c
This patch converts drivers/mtd/nand/rtc_from4.c to use the new
lib/bitrev.c

Signed-off-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

Adrian Bunk   authored and   David Woodhouse   commited 2006-11-28 22:18:52 +00:00
1605cd3d9c
[MTD] OneNAND: Single bit error detection
Idea from Jarkko Lavinen

Signed-off-by: Jarkko Lavinen <jarkko.lavinen@nokia.com>
Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>

Kyungmin Park   commited 2006-11-16 12:03:56 +09:00
f4f91ac3c8
[MTD] OneNAND: lock support
Now you can use mtd lock inferface on OneNAND

The idea is from Nemakal, Vijaya, thanks

Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com>

Kyungmin Park   commited 2006-11-16 11:29:39 +09:00
08f782b60a
MTD: OneNAND: interrupt based wait support
We can use the two methods to wait.
  1. polling: read interrupt status register
  2. interrupt: use kernel ineterrupt mechanism

  To use interrupt method, you first connect onenand interrupt pin to your
platform and configure interrupt properly

Signed-off-by: Kyungmin Park <kyungmin.park at samsung.com>

Kyungmin Park   commited 2006-11-16 11:23:48 +09:00
2c22120fbd
[MTD] NAND: Fix ECC settings in CAFÉ controller driver.
We were resetting cafe->ctl2 to zero after an erase (and also during a
write, but it was correctly reset after that). This meant that ECC reads
after an erase were failing. Doh.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-11-01 08:19:20 +08:00
cad40654c3
[MTD] NAND: Add register debugging spew option to CAFÉ driver
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-10-31 12:36:04 +08:00
be8444bdf3
[MTD] NAND: Use register #defines throughout CAFÉ driver, not numbers
Also use cafe_readl() and cafe_writel() abstraction to make code
slightly cleaner -- especially if we want to use it in PIO mode.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-10-31 12:30:11 +08:00
195a253b66
[MTD] NAND: Fix timing calculation in CAFÉ debugging message
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-10-28 17:08:38 +03:00
a020727b16
[PATCH] silence 'make xmldocs' warning by adding missing description of 'raw' in nand_base.c:1485
Add description of 'raw' in comments for
drivers/mtd/nand/nand_base.c::nand_write_page_syndrome() so 'make xmldocs'
will not spew a warning at us.

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Acked-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>

Jesper Juhl   authored and   Linus Torvalds   commited 2006-10-27 15:34:51 -07:00
efbfe96c5d
[MTD] NAND: Remove empty block ECC workaround
They fixed the hardware so that ECC doesn't fail on reading an empty
block.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-10-27 22:12:02 +03:00
63a1423763
[MTD] NAND: Add ECC debugging for CAFÉ
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-10-27 15:40:51 +03:00
7608194c4a
[MTD] CAFÉ NAND: Add 'slowtiming' parameter, default usedma and checkecc on
Signed-off-by: David Woodhouse <dwmw2@infradead.org>

David Woodhouse   commited 2006-10-27 14:50:04 +03:00
b478c775a0