<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/mtd/ubi/wl.c, branch linux-2.6.36.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.36.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-2.6.36.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2010-08-30T10:32:31Z</updated>
<entry>
<title>UBI: do not oops when erroneous PEB is scheduled for scrubbing</title>
<updated>2010-08-30T10:32:31Z</updated>
<author>
<name>Artem Bityutskiy</name>
</author>
<published>2010-08-29T20:34:44Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=d3f6e6c666c0f68991d785177c4c62fcd1d651f2'/>
<id>urn:sha1:d3f6e6c666c0f68991d785177c4c62fcd1d651f2</id>
<content type='text'>
When an erroneous PEB is scheduling for scrubbing, we end up with the
following oops:

[&lt;c0162404&gt;] (prot_queue_del+0x0/0x50) from [&lt;c01635b4&gt;] (ubi_wl_scrub_peb+0xec/0x13c)
[&lt;c01634c8&gt;] (ubi_wl_scrub_peb+0x0/0x13c) from [&lt;c01603bc&gt;] (ubi_eba_read_leb+0x200/0x428)
[&lt;c01601bc&gt;] (ubi_eba_read_leb+0x0/0x428) from [&lt;c015e3c0&gt;] (ubi_leb_read+0xe8/0x138)
[&lt;c015e2d8&gt;] (ubi_leb_read+0x0/0x138) from [&lt;c00d6918&gt;] (ubifs_start_scan+0x7c/0xf4)
[&lt;c00d689c&gt;] (ubifs_start_scan+0x0/0xf4) from [&lt;c00e3650&gt;] (ubifs_recover_leb+0x3c/0x730)
[&lt;c00e3614&gt;] (ubifs_recover_leb+0x0/0x730) from [&lt;c00e444c&gt;] (ubifs_recover_log_leb+0xc8/0x2dc)
[&lt;c00e4384&gt;] (ubifs_recover_log_leb+0x0/0x2dc) from [&lt;c00d7c20&gt;] (ubifs_replay_journal+0xb90/0x13a4)
[&lt;c00d7090&gt;] (ubifs_replay_journal+0x0/0x13a4) from [&lt;c00cdd68&gt;] (ubifs_fill_super+0xb84/0x1054)
[&lt;c00cd1e4&gt;] (ubifs_fill_super+0x0/0x1054) from [&lt;c00ced04&gt;] (ubifs_get_sb+0xc4/0x2ac)
[&lt;c00cec40&gt;] (ubifs_get_sb+0x0/0x2ac) from [&lt;c007f04c&gt;] (vfs_kern_mount+0x58/0x94)
[&lt;c007eff4&gt;] (vfs_kern_mount+0x0/0x94) from [&lt;c007f0e8&gt;] (do_kern_mount+0x40/0xe8)
[&lt;c007f0a8&gt;] (do_kern_mount+0x0/0xe8) from [&lt;c0095628&gt;] (do_new_mount+0x68/0x8c)
[&lt;c00955c0&gt;] (do_new_mount+0x0/0x8c) from [&lt;c00957a8&gt;] (do_mount+0x15c/0x1b8)
[&lt;c009564c&gt;] (do_mount+0x0/0x1b8) from [&lt;c0095890&gt;] (sys_mount+0x8c/0xd4)
[&lt;c0095804&gt;] (sys_mount+0x0/0xd4) from [&lt;c0023c00&gt;] (ret_fast_syscall+0x0/0x2c)
Kernel panic - not syncing: Fatal exception

The problem is that 'ubi_wl_scrub_peb()' does not expect that PEBs may
be in the erroneous tree, which is a bug. This patch fixes the bug
and adds corresponding check to 'ubi_wl_scrub_peb()'. Now it will simply
ignore erroneous PEBs, instead of causing an oops.

Reported-by: Matthieu CASTET &lt;matthieu.castet@parrot.com&gt;
Signed-off-by: Artem Bityutskiy &lt;Artem.Bityutskiy@nokia.com&gt;
</content>
</entry>
<entry>
<title>UBI: fix s/then/than/ typos</title>
<updated>2010-05-07T05:33:10Z</updated>
<author>
<name>Shinya Kuribayashi</name>
</author>
<published>2010-05-06T10:21:47Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3f5026222e8a16daaa830eec4d72c6745b74407e'/>
<id>urn:sha1:3f5026222e8a16daaa830eec4d72c6745b74407e</id>
<content type='text'>
Signed-off-by: Shinya Kuribayashi &lt;shinya.kuribayashi.px@renesas.com&gt;
Signed-off-by: Artem Bityutskiy &lt;Artem.Bityutskiy@nokia.com&gt;
</content>
</entry>
<entry>
<title>UBI: simplify debugging return codes</title>
<updated>2010-02-01T13:16:37Z</updated>
<author>
<name>Artem Bityutskiy</name>
</author>
<published>2010-01-20T08:28:58Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=adbf05e3ec6ea380ba145b6fa89d9125ed76eb98'/>
<id>urn:sha1:adbf05e3ec6ea380ba145b6fa89d9125ed76eb98</id>
<content type='text'>
UBI debugging functions were a little bit over-engineered and
returned more error codes than needed, and the callers had to
do useless checks. Simplify the return codes.

Impact: only debugging code is affected, which means that for
        non-developers this is a no-op patch.

Signed-off-by: Artem Bityutskiy &lt;Artem.Bityutskiy@nokia.com&gt;
</content>
</entry>
<entry>
<title>UBI: remove bogus debugging checks</title>
<updated>2009-07-05T15:47:05Z</updated>
<author>
<name>Artem Bityutskiy</name>
</author>
<published>2009-06-29T12:58:36Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=1398788fe7b730db10e97dcb9f838603e41922d5'/>
<id>urn:sha1:1398788fe7b730db10e97dcb9f838603e41922d5</id>
<content type='text'>
The 'paranoid_check_empty()' is bogus because, which is easilly
seen on NOR flash, which has long erase cycles, and which may
easilly end-up with half-erased eraseblocks. In this case the
paranoid check fails. I is just wrong to assume that PEBs which
do not have EC headers always contain all 0xFF. Such assumption
should not be made on the I/O level, which is quite low.

Thus, just kill the check.

Signed-off-by: Artem Bityutskiy &lt;Artem.Bityutskiy@nokia.com&gt;
</content>
</entry>
<entry>
<title>UBI: add empty eraseblocks verification</title>
<updated>2009-07-05T15:47:03Z</updated>
<author>
<name>Artem Bityutskiy</name>
</author>
<published>2009-06-28T16:16:55Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=40a71a87fa8e0cb3ec0fca4d152263734b203eb2'/>
<id>urn:sha1:40a71a87fa8e0cb3ec0fca4d152263734b203eb2</id>
<content type='text'>
This patch adds code which makes sure eraseblocks contain all 0xFF
bytes before starting using them. The verification is done only when
debugging checks are enabled.

Signed-off-by: Artem Bityutskiy &lt;Artem.Bityutskiy@nokia.com&gt;
</content>
</entry>
<entry>
<title>UBI: fix multiple spelling typos</title>
<updated>2009-06-10T13:13:27Z</updated>
<author>
<name>Artem Bityutskiy</name>
</author>
<published>2009-06-08T16:28:18Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=815bc5f8fe516f55291aef90f2142073821e7a9c'/>
<id>urn:sha1:815bc5f8fe516f55291aef90f2142073821e7a9c</id>
<content type='text'>
Some of the typos were indicated by Adrian Hunter,
some by 'aspell'.

Signed-off-by: Artem Bityutskiy &lt;Artem.Bityutskiy@nokia.com&gt;
</content>
</entry>
<entry>
<title>UBI: fix kmem_cache_free on error patch</title>
<updated>2009-06-10T13:13:27Z</updated>
<author>
<name>Artem Bityutskiy</name>
</author>
<published>2009-06-08T16:28:18Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=21d08bbcb19d9cdef8ab5b584f25b50d842068e9'/>
<id>urn:sha1:21d08bbcb19d9cdef8ab5b584f25b50d842068e9</id>
<content type='text'>
'kmem_cache_free()' oopeses if NULL is passed, and there is
one error-path place where UBI may call it with NULL object.
This problem was pointed to by Adrian Hunter.

Signed-off-by: Artem Bityutskiy &lt;Artem.Bityutskiy@nokia.com&gt;
</content>
</entry>
<entry>
<title>UBI: print amount of reserved PEBs</title>
<updated>2009-06-09T15:49:51Z</updated>
<author>
<name>Artem Bityutskiy</name>
</author>
<published>2009-06-08T13:52:48Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=52b605d107de72c1d3385a3df972e79fb5befa4c'/>
<id>urn:sha1:52b605d107de72c1d3385a3df972e79fb5befa4c</id>
<content type='text'>
When marking a PEB as bad, print how many PEBs are left reserved.
This is very useful information.

Signed-off-by: Artem Bityutskiy &lt;Artem.Bityutskiy@nokia.com&gt;
</content>
</entry>
<entry>
<title>UBI: improve messages in the WL worker</title>
<updated>2009-06-08T10:05:43Z</updated>
<author>
<name>Artem Bityutskiy</name>
</author>
<published>2009-06-08T09:49:08Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=9c259a52fa6ab46841a6094434cd0d752e854180'/>
<id>urn:sha1:9c259a52fa6ab46841a6094434cd0d752e854180</id>
<content type='text'>
Print not only the PEB number, but also the LEB number and volume id,
which is very useful for bug hunting.

Signed-off-by: Artem Bityutskiy &lt;Artem.Bityutskiy@nokia.com&gt;
</content>
</entry>
<entry>
<title>UBI: do not switch to R/O mode on read errors</title>
<updated>2009-06-02T10:53:35Z</updated>
<author>
<name>Artem Bityutskiy</name>
</author>
<published>2009-05-24T11:13:34Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=b86a2c56e512f46d140a4bcb4e35e8a7d4a99a4b'/>
<id>urn:sha1:b86a2c56e512f46d140a4bcb4e35e8a7d4a99a4b</id>
<content type='text'>
This patch improves UBI errors handling. ATM UBI switches to
R/O mode when the WL worker fails to read the source PEB.
This means that the upper layers (e.g., UBIFS) has no
chances to unmap the erroneous PEB and fix the error.
This patch changes this behaviour and makes UBI put PEBs
like this into a separate RB-tree, thus preventing the
WL worker from hitting the same read errors again and
again.

But there is a 10% limit on a maximum amount of PEBs like this.
If there are too much of them, UBI switches to R/O mode.

Additionally, this patch teaches UBI not to panic and
switch to R/O mode if after a PEB has been copied, the
target LEB cannot be read back. Instead, now UBI cancels
the operation and schedules the target PEB for torturing.

The error paths has been tested by ingecting errors
into 'ubi_eba_copy_leb()'.

Signed-off-by: Artem Bityutskiy &lt;Artem.Bityutskiy@nokia.com&gt;
</content>
</entry>
</feed>
