summaryrefslogtreecommitdiff
path: root/drivers/mtd/devices
AgeCommit message (Collapse)AuthorFilesLines
2009-03-20[MTD] we don't need no misc devicesDavid Brownell4-4/+0
Remove <linux/miscdevice.h> from various drivers which don't actually use any of its contents. There are still a number of these left in arch-specific bits of the tree. (Found by diffing results of "grep -rl" for linux/miscdevice.h and for misc_register, examining the differences, and verifying removals with a build test.) Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2009-03-13ps3/block: Replace mtd/ps3vram by block/ps3vramGeert Uytterhoeven3-776/+0
Convert the PS3 Video RAM Storage Driver from an MTD driver to a plain block device driver. The ps3vram driver exposes unused video RAM on the PS3 as a block device suitable for storage or swap. Fast data transfer is achieved using a local cache in system RAM and DMA transfers via the GPU. The new driver is ca. 50% faster for reading, and ca. 10% for writing. Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com> Acked-by: Geoff Levand <geoffrey.levand@am.sony.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2009-03-11mtd_dataflash: fix probing of AT45DB321C chips.Will Newton1-1/+2
Commit 771999b65f79264acde4b855e5d35696eca5e80c ("[MTD] DataFlash: bugfix, binary page sizes now handled") broke support for probing AT45DB321C flash chips. These chips do not support the "page size" status bit, so if we match the JEDEC id return early. [akpm@linux-foundation.org: coding-style fixes] Signed-off-by: Will Newton <will.newton@gmail.com> Cc: David Woodhouse <dwmw2@infradead.org> Acked-by: David Brownell <dbrownell@users.sourceforge.net> Cc: <stable@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-01-19[MTD] slram: Handle negative devlength correctlyRoel Kluin1-4/+10
A negative devlength won't get noticed and clean up: Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2009-01-09Merge git://git.infradead.org/mtd-2.6Linus Torvalds3-33/+38
* git://git.infradead.org/mtd-2.6: (67 commits) [MTD] [MAPS] Fix printk format warning in nettel.c [MTD] [NAND] add cmdline parsing (mtdparts=) support to cafe_nand [MTD] CFI: remove major/minor version check for command set 0x0002 [MTD] [NAND] ndfc driver [MTD] [TESTS] Fix some size_t printk format warnings [MTD] LPDDR Makefile and KConfig [MTD] LPDDR extended physmap driver to support LPDDR flash [MTD] LPDDR added new pfow_base parameter [MTD] LPDDR Command set driver [MTD] LPDDR PFOW definition [MTD] LPDDR QINFO records definitions [MTD] LPDDR qinfo probing. [MTD] [NAND] pxa3xx: convert from ns to clock ticks more accurately [MTD] [NAND] pxa3xx: fix non-page-aligned reads [MTD] [NAND] fix nandsim sched.h references [MTD] [NAND] alauda: use USB API functions rather than constants [MTD] struct device - replace bus_id with dev_name(), dev_set_name() [MTD] fix m25p80 64-bit divisions [MTD] fix dataflash 64-bit divisions [MTD] [NAND] Set the fsl elbc ECCM according the settings in bootloader. ... Fixed up trivial debug conflicts in drivers/mtd/devices/{m25p80.c,mtd_dataflash.c}
2009-01-08mtd/ps3vram: Use _PAGE_NO_CACHE in memory ioremapGeoff Levand1-6/+8
Use _PAGE_NO_CACHE for gpu memory ioremap. Also, add __iomem attribute to gpu memory pointer and change use of memset() to memset_io(). Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2009-01-08mtd/ps3vram: Use msleep in waitsGeoff Levand1-23/+17
Replace the use of udelay() with msleep() in the looping wait routines ps3vram_notifier_wait() and ps3vram_wait_ring(). Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2009-01-08mtd/ps3vram: Use proper kernel typesGeoff Levand1-26/+30
Replace the use of stdint.h types with kernel types in the ps3vram driver. Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2009-01-08mtd/ps3vram: Cleanup ps3vram driver messagesGeoff Levand1-48/+68
Cleanup the ps3vram driver messages. Add a new struct device pointer variable dev to struct ps3vram_priv and use dev_dbg(), pr_dbg(), etc. where appropriate. Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2009-01-08mtd/ps3vram: Remove ps3vram debug routinesGeoff Levand1-29/+0
Remove the ps3vram debug routines ps3vram_dump_ring() and ps3vram_dump_reports(). These routines are not needed. Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2009-01-08mtd/ps3vram: Add modalias support to the ps3vram driverGeert Uytterhoeven1-0/+1
Update ps3vram driver to use the new ps3 three id modalias support. Signed-off-by: Geert Uytterhoeven <Geert.Uytterhoeven@sonycom.com> Signed-off-by: Geoff Levand <geoffrey.levand@am.sony.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2009-01-08mtd/ps3vram: Add ps3vram driver for accessing video RAM as MTDJim Paris3-0/+784
Add ps3vram driver, which exposes unused video RAM on the PS3 as a MTD device suitable for storage or swap. Fast data transfer is achieved using a local cache in system RAM and DMA transfers via the GPU. Signed-off-by: Vivien Chappelier <vivien.chappelier@free.fr> Signed-off-by: Jim Paris <jim@jtan.com> Acked-by: Geoff Levand <geoffrey.levand@am.sony.com> Acked-by: David Woodhouse <David.Woodhouse@intel.com> Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2009-01-07Merge branch 'for-linus' of ↵Linus Torvalds1-1/+1
git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial: (24 commits) trivial: chack -> check typo fix in main Makefile trivial: Add a space (and a comma) to a printk in 8250 driver trivial: Fix misspelling of "firmware" in docs for ncr53c8xx/sym53c8xx trivial: Fix misspelling of "firmware" in powerpc Makefile trivial: Fix misspelling of "firmware" in usb.c trivial: Fix misspelling of "firmware" in qla1280.c trivial: Fix misspelling of "firmware" in a100u2w.c trivial: Fix misspelling of "firmware" in megaraid.c trivial: Fix misspelling of "firmware" in ql4_mbx.c trivial: Fix misspelling of "firmware" in acpi_memhotplug.c trivial: Fix misspelling of "firmware" in ipw2100.c trivial: Fix misspelling of "firmware" in atmel.c trivial: Fix misspelled firmware in Kconfig trivial: fix an -> a typos in documentation and comments trivial: fix then -> than typos in comments and documentation trivial: update Jesper Juhl CREDITS entry with new email trivial: fix singal -> signal typo trivial: Fix incorrect use of "loose" in event.c trivial: printk: fix indentation of new_text_line declaration trivial: rtc-stk17ta8: fix sparse warning ...
2009-01-06mtd: struct device - replace bus_id with dev_name(), dev_set_name()Kay Sievers2-23/+23
CC: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-01-06trivial: fix then -> than typos in comments and documentationFrederik Schwarzer1-1/+1
- (better, more, bigger ...) then -> (...) than Signed-off-by: Frederik Schwarzer <schwarzerf@gmail.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
2008-12-23[MTD] struct device - replace bus_id with dev_name(), dev_set_name()Kay Sievers2-26/+26
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-12-19[MTD] fix m25p80 64-bit divisionsArtem Bityutskiy1-18/+19
MTD has recently been upgraded for 64-bit support, see commit number 69423d99fc182a81f3c5db3eb5c140acc6fc64be in the mtd-2.6.git tree (git://git.infradead.org/mtd-2.6.git) or see this URL: http://git.infradead.org/mtd-2.6.git?a=commit;h=69423d99fc182a81f3c5db3eb5c140acc6fc64be Some variables in MTD data structures which were 32-bit became 64-bit. Namely, the 'size' field in 'struct mtd_info' and the 'addr'/'len' fields in 'struct erase_info'. This means we have to use 'do_div' to divide them. This patch fixes the following linking error: ERROR: "__umoddi3" [drivers/mtd/devices/m25p80.ko] undefined! This patch changes divisions of 64-bit variable so that they use 'do_div'. This patch also change some print placeholders to get rid of gcc warnings. Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-12-19[MTD] fix dataflash 64-bit divisionsArtem Bityutskiy1-9/+15
MTD has recently been upgraded for 64-bit support, see commit number 69423d99fc182a81f3c5db3eb5c140acc6fc64be in the mtd-2.6.git tree (git://git.infradead.org/mtd-2.6.git) or see this URL: http://git.infradead.org/mtd-2.6.git?a=commit;h=69423d99fc182a81f3c5db3eb5c140acc6fc64be Some variables in MTD data structures which were 32-bit became 64-bit. Namely, the 'size' field in 'struct mtd_info' and the 'addr'/'len' fields in 'struct erase_info'. This means we have to use 'do_div' to divide them. This patch fixes the following linking error: ERROR: "__udivdi3" [drivers/mtd/devices/mtd_dataflash.ko] undefined! ERROR: "__umoddi3" [drivers/mtd/devices/mtd_dataflash.ko] undefined! This patch changes divisions of 64-bit variable so that they use 'do_div'. This patch also change some print placeholders to get rid of gcc warnings. Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com> Cc: David Brownell <david-b@pacbell.net> Cc: Nicolas Pitre <nico@cam.org> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-12-10[MTD] Make lart_flash_init, lart_flash_exit staticDmitri Vorobiev1-4/+2
The symbols lart_flash_init, lart_flash_exit are needlessly defined global in drivers/mtd/devices/lart.c, so make them static. Signed-off-by: Dmitri Vorobiev <dmitri.vorobiev@movial.fi> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-12-09Merge git://git.infradead.org/mtd-2.6Linus Torvalds1-12/+16
* git://git.infradead.org/mtd-2.6: [MTD] [NAND] fix OOPS accessing flash operations over STM flash on PXA [MTD] [NAND] drivers/mtd/nand/pasemi_nand.c: Add missing pci_dev_put [MTD] [NAND] fsl_upm: fix build problem with 2.6.28-rc2 [MTD] physmap: fix memory leak on physmap_flash_remove by using devres [MTD] m25p80: chip erase != block erase != sector erase [MTD] m25p80: fix detection of m25p16 flashes [MTD] m25p80: fix detection of SPI parts [MTD] [NAND] OMAP: OneNAND: header file relocation (part 2) [MTD] [NAND] OMAP: OneNAND: header file relocation
2008-11-26[MTD] m25p80: chip erase != block erase != sector eraseChen Gong1-10/+13
This fixes broken terminology added in the "m25p80.c erase enhance" patch, which added a chip erase command but called it "block erase". There are already two block erase commands; blocks are 4KiB or 32KiB. There's also a sector erase (usually 64 KiB). Chip erase typically covers Megabytes. OPCODE_BE ==> OPCODE_CHIP_ERASE erase_block ==> erase_chip [dbrownell@users.sourceforge.net: update sector erase comments too ] Signed-off-by: Chen Gong <clumsycg@gmail.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-11-26[MTD] m25p80: fix detection of m25p16 flashesMike Frysinger1-1/+1
Commit d0e8c47c58575b9131e786edb488fd029eba443e ("m25p80.c extended jedec support") added support for extended ids but seems to break on flashes which don't have an extended id defined. If the table does not have an extid defined, then we should ignore it. Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Michael Hennerich <Michael.Hennerich@analog.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-11-26[MTD] m25p80: fix detection of SPI partsMike Frysinger1-1/+2
Commit d0e8c47c58575b9131e786edb488fd029eba443e ("m25p80.c extended jedec support") added support for extended ids but in the process managed to break detection of all flashes. The ext jedec id check was inserted into an if statement that lacked braces, and it did not add the required braces. As such, the detection routine always returns the first entry in the SPI flash list. Signed-off-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-10-21[PATCH] propagate mode through open_bdev_excl/close_bdev_exclAl Viro1-2/+2
replace open_bdev_excl/close_bdev_excl with variants taking fmode_t. superblock gets the value used to mount it stored in sb->s_mode Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
2008-10-20Revert "[MTD] m25p80.c code cleanup"David Woodhouse1-1/+1
This reverts commit 75d0ee2202b5740e94e913d8a52f91c6557c4c81. Although it seems ObviouslyCorrect™, the spi_write() call uses DMA, while spi_write_then_read() does not. Since our buffer is on the stack, we must use the latter even though we don't actually want to read anything back. Pointed out by David Brownell <david-b@pacbell.net> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-10-14[MTD] m25p80.c extended jedec support (v2)Chen Gong1-2/+2
Include missing parts of previous patch. Signed-off-by: Chen Gong <g.chen@freescale.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-08-11[MTD] m25p80.c extended jedec supportChen Gong1-39/+47
- add extended device information support - add s25sl128 device support Signed-off-by: Chen Gong <g.chen@freescale.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-08-11[MTD] m25p80.c code cleanupChen Gong1-1/+1
code cleanup for m25p80.c Signed-off-by: Chen Gong <g.chen@freescale.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-08-11[MTD] m25p80.c erase enhanceChen Gong1-8/+40
This patch adds an erase_block command to enhance erase operation Signed-off-by: Chen Gong <g.chen@freescale.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-08-07[MTD] make dataflash write-verify be optionalDavid Brownell2-5/+13
This adds a WRITE_VERIFY Kconfig option to the DataFlash driver, closely mirroring the similar NAND and ONENAND options, giving an option to disable some code that's currently always enabled. Removing this step probably saves a millisecond or so per page when writing data, which will add up quickly since these pages are small (the largest is 1 KiB). It doesn't seem to add a lot in terms of reliability, and wouldn't detect errors which crop up when transferring data to the on-chip SRAM buffer. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Acked-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com> Acked-by: Andrew Victor <linux@maxim.org.za> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-08-07[MTD] Compile fix for dataflash OTP supportDavid Brownell1-1/+1
> > linux-next-20080805/drivers/mtd/devices/mtd_dataflash.c: In function 'add_dataflash_otp': > > linux-next-20080805/drivers/mtd/devices/mtd_dataflash.c:670: error: too many arguments to function 'otp_setup' Whoops, sorry ... I see what was going on. My bad. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-08-02[MTD] dataflash OTP supportDavid Brownell2-7/+210
Now that we can tell when we have one of the newer DataFlash chips, optionally expose the 128 bytes of OTP memory they provide. Tested on at45db642 revision B and D chips. Switch mtdchar over to a generic HAVE_MTD_OTP flag instead of adding another #ifdef for each type of chip whose driver has OTP support. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Cc: Bryan Wu <cooloney@kernel.org> Cc: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-07-30[MTD] DataFlash: bugfix, binary page sizes now handledakpm@linux-foundation.org1-47/+83
The wrong version of the "teach dataflash about binary density" patch just got merged (v2 not v3) ... this restores the missing updates: * Fix the cmdlinepart *regression* that caused testing failures (!!) by restoring the original part labels in relevant cases. * Don't reference things that don't exist (!) - An opcode that doesn't even exist for DataFlash - The part is "at45db642" not "at45db641" - ID zero in this JEDEC table * Make the JEDEC probe routine report and handle errors better: - If the SPI calls fail, return the error codes. - Don't depend on ordering of table entries. - Unrecognized ids are different from parts that have no ID. We won't actually know how to handle them correctly; display the ID and ignore the chip. * Move the original block comment about the "legacy" chip ID scheme back next to the code to which it applies ... not next to the new JEDEC query code, which uses an entirely different strategy. * Don't print a guessed erasesize; /proc/mtd has the real value. And add a few more comments. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Cc: Bryan Wu <cooloney@kernel.org> Cc: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-07-25Merge branch 'linux-next' of git://git.infradead.org/~dedekind/ubi-2.6David Woodhouse1-3/+5
2008-07-22MTD: handle pci_name() being constGreg Kroah-Hartman1-3/+5
This changes the MTD core to handle pci_name() now returning a constant string. Cc: David Woodhouse <dwmw2@infradead.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2008-07-11[MTD] [NAND] remove __PPC__ hardcoded address from DiskOnChip driversMilton Miller1-2/+0
Such a hardcoded address can cause a checkstop or machine check if the driver is in the kernel but the address is not acknowledged. Both drivers allow an address to be specified as either a module parameter or config option. Any future powerpc board should either use one of these methods or find the address in the device tree. Signed-off-by: Milton Miller <miltonm@bga.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-07-11[MTD] m25p80: fix bug - ATmel spi flash fails to be copied toMichael Hennerich1-0/+22
Atmel serial flash tends to power up with the protection status bits set. http://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=4089 [michael.hennerich@analog.com: remove duplicate code] Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
2008-07-11Merge branch 'master' of ↵David Woodhouse1-1/+3
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6
2008-06-06[MTD] m25p80.c mutex unlock fixChen Gong1-1/+3
fix a mutex release bug in function m25p80_write. Signed-off-by: Chen Gong <g.chen@freescale.com> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-06-04MTD/JFFS2: remove CVS keywordsAdrian Bunk15-32/+0
Once upon a time, the MTD repository was using CVS. This patch therefore removes all usages of the no longer updated CVS keywords from the MTD code. This also includes code that printed them to the user. Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-06-04[MTD] DataFlash: use proper typesDavid Woodhouse1-16/+16
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-06-04[MTD] DataFlash: fix bug - ATMEL AT45DF321D spi flash card fails to be ↵Michael Hennerich1-5/+112
copied to (v2) - Add support for binary page size DataFlashes. - The driver now prints out pagesize and erasesize. Printout valuable information for creating flash filesystems. Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Cc: David Brownell <david-b@pacbell.net> Signed-off-by: Bryan Wu <cooloney@kernel.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-05-01[MTD][NOR] Add physical address to point() methodJared Hulbert4-25/+41
Adding the ability to get a physical address from point() in addition to virtual address. This physical address is required for XIP of userspace code from flash. Signed-off-by: Jared Hulbert <jaredeh@gmail.com> Reviewed-by: Jörn Engel <joern@logfs.org> Acked-by: Nicolas Pitre <nico@cam.org> Acked-by: Greg Ungerer <gerg@uclinux.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-04-25[MTD] m25p80: Add Support for ATMEL AT25DF641 64-Megabit SPI FlashMichael Hennerich1-0/+1
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <cooloney@kernel.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-04-25[MTD] m25p80: add FAST_READ access support to M25PxxBryan Wu2-10/+28
Signed-off-by: Bryan Wu <cooloney@kernel.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-04-22[MTD] mtdram.c should #include <linux/mtd/mtdram.h>Adrian Bunk1-0/+1
Every file should include the headers containing the externs for its global functions (in this case for mtdram_init_device()). Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-04-22[MTD] Correct phram module param descriptionMark Hindley1-1/+1
Signed-off-by: Mark Hindley <mark@hindley.org.uk> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-04-22[MTD] replace remaining __FUNCTION__ occurrencesHarvey Harrison2-12/+12
__FUNCTION__ is gcc-specific, use __func__ Signed-off-by: Harvey Harrison <harvey.harrison@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-04-22[MTD] block2mtd: logging typo fixesStephane Chazelas1-5/+5
Address a number of small issues mainly regarding the output made by this driver to dmesg: - Some of the blkmtd's had not been changed to block2mtd which caused display problem - the parse_err() macro was displaying "block2mtd: " twice Signed-off-by: Stéphane Chazelas <stephane.chazelas@emerson.com> Acked-by: Jörn Engel <joern@lazybastard.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: David Woodhouse <dwmw2@infradead.org>
2008-03-25mtd: memory corruption in block2mtd.cIngo van Lil1-1/+0
The block2mtd driver (drivers/mtd/devices/block2mtd.c) will kfree an on-stack pointer when handling an invalid argument line (e.g. block2mtd=/dev/loop0,xxx). The kfree was added some time ago when "name" was dynamically allocated. Signed-off-by: Ingo van Lil <inguin@gmx.de> Acked-by: Joern Engel <joern@lazybastard.org> Cc: David Woodhouse <dwmw2@infradead.org> Cc: <stable@kernel.org> Cc: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>