1
0
Fork 0
alistair23-linux/include
Artem Bityutskiy 7d73101921 mtd: fix merge conflict resolution breakage
This patch fixes merge conflict resolution breakage introduced by merge
d3712b9dfc ("Merge tag 'for-linus' of git://github.com/prasad-joshi/logfs_upstream").

The commit changed 'mtd_can_have_bb()' function and made it always
return zero, which is incorrect.  Instead, we need it to return whether
the underlying flash device can have bad eraseblocks or not.  UBI needs
this information because it affects how it handles the underlying flash.
E.g., if the underlying flash is NOR, it cannot have bad blocks and any
write or erase error is fatal, and all we can do is to switch to R/O
mode.  We do not need to reserve a pool of good eraseblocks for bad
eraseblocks handling, and so on.

This patch also removes 'mtd_can_have_bb()' invocations from Logfs to
ensure correct Logfs behavior.

I've tested that with this patch UBI works on top of NOR and NAND
flashes emulated by mtdram and nandsim correspondingly.

This patch is based on patch from Linus Torvalds.

Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Acked-by: Jörn Engel <joern@logfs.org>
Acked-by: Prasad Joshi <prasadjoshi.linux@gmail.com>
Acked-by: Brian Norris <computersforpeace@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2012-02-01 11:10:24 -08:00
..
acpi Merge branches 'atomicio-apei', 'hotplug', 'sony-nvs-nosave' and 'thermal-netlink' into release 2012-01-23 19:47:06 -05:00
asm-generic Merge branch 'for-next' of git://git.infradead.org/users/dhowells/linux-headers 2012-01-14 18:03:30 -08:00
crypto crypto: serpent-sse2 - add lrw support 2011-11-21 16:13:24 +08:00
drm drm: Fix authentication kernel crash 2012-01-25 09:27:45 +00:00
keys keys: add a "logon" key type 2012-01-17 22:39:40 -06:00
linux mtd: fix merge conflict resolution breakage 2012-02-01 11:10:24 -08:00
math-emu
media Merge branch 'v4l_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mchehab/linux-media 2012-01-18 12:53:54 -08:00
misc
mtd mtd: document that MEMWRITE ioctl is NAND-specific 2012-01-09 18:18:36 +00:00
net net/tcp: Fix tcp memory limits initialization when !CONFIG_SYSCTL 2012-01-30 12:41:06 -05:00
pcmcia
rdma rdma/core: Fix sparse warnings 2012-01-04 09:17:45 -08:00
rxrpc
scsi [SCSI] libfc: Declare local functions static 2012-01-16 12:45:48 +04:00
sound Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound 2012-01-12 08:00:30 -08:00
target target: Set additional sense length field in sense data 2011-12-16 06:29:04 +00:00
trace Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/linux-btrfs 2012-01-17 15:49:54 -08:00
video Merge branch 'for-next' of git://git.infradead.org/users/dhowells/linux-headers 2012-01-14 18:03:30 -08:00
xen Merge branch 'for-3.3/drivers' of git://git.kernel.dk/linux-block 2012-01-15 12:48:41 -08:00
Kbuild