<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/fs/jffs2, branch v3.2.55</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>jffs2: Fix lock acquisition order bug in jffs2_write_begin</title>
<updated>2012-12-06T11:20:22+00:00</updated>
<author>
<name>Thomas Betker</name>
<email>thomas.betker@freenet.de</email>
</author>
<published>2012-10-17T20:59:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=e3bb00e3b611c48b83730c880d8406c35de5bb4b'/>
<id>e3bb00e3b611c48b83730c880d8406c35de5bb4b</id>
<content type='text'>
commit 5ffd3412ae5536a4c57469cb8ea31887121dcb2e upstream.

jffs2_write_begin() first acquires the page lock, then f-&gt;sem. This
causes an AB-BA deadlock with jffs2_garbage_collect_live(), which first
acquires f-&gt;sem, then the page lock:

jffs2_garbage_collect_live
    mutex_lock(&amp;f-&gt;sem)                         (A)
    jffs2_garbage_collect_dnode
        jffs2_gc_fetch_page
            read_cache_page_async
                do_read_cache_page
                    lock_page(page)             (B)

jffs2_write_begin
    grab_cache_page_write_begin
        find_lock_page
            lock_page(page)                     (B)
    mutex_lock(&amp;f-&gt;sem)                         (A)

We fix this by restructuring jffs2_write_begin() to take f-&gt;sem before
the page lock. However, we make sure that f-&gt;sem is not held when
calling jffs2_reserve_space(), as this is not permitted by the locking
rules.

The deadlock above was observed multiple times on an SoC with a dual
ARMv7 (Cortex-A9), running the long-term 3.4.11 kernel; it occurred
when using scp to copy files from a host system to the ARM target
system. The fix was heavily tested on the same target system.

Signed-off-by: Thomas Betker &lt;thomas.betker@rohde-schwarz.com&gt;
Acked-by: Joakim Tjernlund &lt;Joakim.Tjernlund@transmode.se&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@linux.intel.com&gt;
[bwh: Backported to 3.2:
 - Adjust context
 - Use D1(printk(KERN_DEBUG ...)) instead of jffs2_dbg(1, ...)]
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 5ffd3412ae5536a4c57469cb8ea31887121dcb2e upstream.

jffs2_write_begin() first acquires the page lock, then f-&gt;sem. This
causes an AB-BA deadlock with jffs2_garbage_collect_live(), which first
acquires f-&gt;sem, then the page lock:

jffs2_garbage_collect_live
    mutex_lock(&amp;f-&gt;sem)                         (A)
    jffs2_garbage_collect_dnode
        jffs2_gc_fetch_page
            read_cache_page_async
                do_read_cache_page
                    lock_page(page)             (B)

jffs2_write_begin
    grab_cache_page_write_begin
        find_lock_page
            lock_page(page)                     (B)
    mutex_lock(&amp;f-&gt;sem)                         (A)

We fix this by restructuring jffs2_write_begin() to take f-&gt;sem before
the page lock. However, we make sure that f-&gt;sem is not held when
calling jffs2_reserve_space(), as this is not permitted by the locking
rules.

The deadlock above was observed multiple times on an SoC with a dual
ARMv7 (Cortex-A9), running the long-term 3.4.11 kernel; it occurred
when using scp to copy files from a host system to the ARM target
system. The fix was heavily tested on the same target system.

Signed-off-by: Thomas Betker &lt;thomas.betker@rohde-schwarz.com&gt;
Acked-by: Joakim Tjernlund &lt;Joakim.Tjernlund@transmode.se&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@linux.intel.com&gt;
[bwh: Backported to 3.2:
 - Adjust context
 - Use D1(printk(KERN_DEBUG ...)) instead of jffs2_dbg(1, ...)]
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>JFFS2: don't fail on bitflips in OOB</title>
<updated>2012-10-17T02:49:15+00:00</updated>
<author>
<name>Brian Norris</name>
<email>computersforpeace@gmail.com</email>
</author>
<published>2012-08-31T22:01:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f4c8c2f05a24536e4d883d6f3783c78aa6e773ff'/>
<id>f4c8c2f05a24536e4d883d6f3783c78aa6e773ff</id>
<content type='text'>
commit 74d83beaa229aac7d126ac1ed9414658ff1a89d2 upstream.

JFFS2 was designed without thought for OOB bitflips, it seems, but they
can occur and will be reported to JFFS2 via mtd_read_oob()[1]. We don't
want to fail on these transactions, since the data was corrected.

[1] Few drivers report bitflips for OOB-only transactions. With such
    drivers, this patch should have no effect.

Signed-off-by: Brian Norris &lt;computersforpeace@gmail.com&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@linux.intel.com&gt;
Signed-off-by: David Woodhouse &lt;David.Woodhouse@intel.com&gt;
[bwh: Backported to 3.2: adjust context]
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 74d83beaa229aac7d126ac1ed9414658ff1a89d2 upstream.

JFFS2 was designed without thought for OOB bitflips, it seems, but they
can occur and will be reported to JFFS2 via mtd_read_oob()[1]. We don't
want to fail on these transactions, since the data was corrected.

[1] Few drivers report bitflips for OOB-only transactions. With such
    drivers, this patch should have no effect.

Signed-off-by: Brian Norris &lt;computersforpeace@gmail.com&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@linux.intel.com&gt;
Signed-off-by: David Woodhouse &lt;David.Woodhouse@intel.com&gt;
[bwh: Backported to 3.2: adjust context]
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>jffs2: Fix lock acquisition order bug in gc path</title>
<updated>2012-05-20T21:56:41+00:00</updated>
<author>
<name>Josh Cartwright</name>
<email>joshc@linux.com</email>
</author>
<published>2012-03-29T23:34:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=5a6cc206dfa8de733e848590b43d30706216733c'/>
<id>5a6cc206dfa8de733e848590b43d30706216733c</id>
<content type='text'>
commit 226bb7df3d22bcf4a1c0fe8206c80cc427498eae upstream.

The locking policy is such that the erase_complete_block spinlock is
nested within the alloc_sem mutex.  This fixes a case in which the
acquisition order was erroneously reversed.  This issue was caught by
the following lockdep splat:

   =======================================================
   [ INFO: possible circular locking dependency detected ]
   3.0.5 #1
   -------------------------------------------------------
   jffs2_gcd_mtd6/299 is trying to acquire lock:
    (&amp;c-&gt;alloc_sem){+.+.+.}, at: [&lt;c01f7714&gt;] jffs2_garbage_collect_pass+0x314/0x890

   but task is already holding lock:
    (&amp;(&amp;c-&gt;erase_completion_lock)-&gt;rlock){+.+...}, at: [&lt;c01f7708&gt;] jffs2_garbage_collect_pass+0x308/0x890

   which lock already depends on the new lock.

   the existing dependency chain (in reverse order) is:

   -&gt; #1 (&amp;(&amp;c-&gt;erase_completion_lock)-&gt;rlock){+.+...}:
          [&lt;c008bec4&gt;] validate_chain+0xe6c/0x10bc
          [&lt;c008c660&gt;] __lock_acquire+0x54c/0xba4
          [&lt;c008d240&gt;] lock_acquire+0xa4/0x114
          [&lt;c046780c&gt;] _raw_spin_lock+0x3c/0x4c
          [&lt;c01f744c&gt;] jffs2_garbage_collect_pass+0x4c/0x890
          [&lt;c01f937c&gt;] jffs2_garbage_collect_thread+0x1b4/0x1cc
          [&lt;c0071a68&gt;] kthread+0x98/0xa0
          [&lt;c000f264&gt;] kernel_thread_exit+0x0/0x8

   -&gt; #0 (&amp;c-&gt;alloc_sem){+.+.+.}:
          [&lt;c008ad2c&gt;] print_circular_bug+0x70/0x2c4
          [&lt;c008c08c&gt;] validate_chain+0x1034/0x10bc
          [&lt;c008c660&gt;] __lock_acquire+0x54c/0xba4
          [&lt;c008d240&gt;] lock_acquire+0xa4/0x114
          [&lt;c0466628&gt;] mutex_lock_nested+0x74/0x33c
          [&lt;c01f7714&gt;] jffs2_garbage_collect_pass+0x314/0x890
          [&lt;c01f937c&gt;] jffs2_garbage_collect_thread+0x1b4/0x1cc
          [&lt;c0071a68&gt;] kthread+0x98/0xa0
          [&lt;c000f264&gt;] kernel_thread_exit+0x0/0x8

   other info that might help us debug this:

    Possible unsafe locking scenario:

          CPU0                    CPU1
          ----                    ----
     lock(&amp;(&amp;c-&gt;erase_completion_lock)-&gt;rlock);
                                  lock(&amp;c-&gt;alloc_sem);
                                  lock(&amp;(&amp;c-&gt;erase_completion_lock)-&gt;rlock);
     lock(&amp;c-&gt;alloc_sem);

    *** DEADLOCK ***

   1 lock held by jffs2_gcd_mtd6/299:
    #0:  (&amp;(&amp;c-&gt;erase_completion_lock)-&gt;rlock){+.+...}, at: [&lt;c01f7708&gt;] jffs2_garbage_collect_pass+0x308/0x890

   stack backtrace:
   [&lt;c00155dc&gt;] (unwind_backtrace+0x0/0x100) from [&lt;c0463dc0&gt;] (dump_stack+0x20/0x24)
   [&lt;c0463dc0&gt;] (dump_stack+0x20/0x24) from [&lt;c008ae84&gt;] (print_circular_bug+0x1c8/0x2c4)
   [&lt;c008ae84&gt;] (print_circular_bug+0x1c8/0x2c4) from [&lt;c008c08c&gt;] (validate_chain+0x1034/0x10bc)
   [&lt;c008c08c&gt;] (validate_chain+0x1034/0x10bc) from [&lt;c008c660&gt;] (__lock_acquire+0x54c/0xba4)
   [&lt;c008c660&gt;] (__lock_acquire+0x54c/0xba4) from [&lt;c008d240&gt;] (lock_acquire+0xa4/0x114)
   [&lt;c008d240&gt;] (lock_acquire+0xa4/0x114) from [&lt;c0466628&gt;] (mutex_lock_nested+0x74/0x33c)
   [&lt;c0466628&gt;] (mutex_lock_nested+0x74/0x33c) from [&lt;c01f7714&gt;] (jffs2_garbage_collect_pass+0x314/0x890)
   [&lt;c01f7714&gt;] (jffs2_garbage_collect_pass+0x314/0x890) from [&lt;c01f937c&gt;] (jffs2_garbage_collect_thread+0x1b4/0x1cc)
   [&lt;c01f937c&gt;] (jffs2_garbage_collect_thread+0x1b4/0x1cc) from [&lt;c0071a68&gt;] (kthread+0x98/0xa0)
   [&lt;c0071a68&gt;] (kthread+0x98/0xa0) from [&lt;c000f264&gt;] (kernel_thread_exit+0x0/0x8)

This was introduce in '81cfc9f jffs2: Fix serious write stall due to erase'.

Signed-off-by: Josh Cartwright &lt;joshc@linux.com&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@linux.intel.com&gt;
Signed-off-by: David Woodhouse &lt;David.Woodhouse@intel.com&gt;
[bwh: Backported to 3.2: adjust context]
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 226bb7df3d22bcf4a1c0fe8206c80cc427498eae upstream.

The locking policy is such that the erase_complete_block spinlock is
nested within the alloc_sem mutex.  This fixes a case in which the
acquisition order was erroneously reversed.  This issue was caught by
the following lockdep splat:

   =======================================================
   [ INFO: possible circular locking dependency detected ]
   3.0.5 #1
   -------------------------------------------------------
   jffs2_gcd_mtd6/299 is trying to acquire lock:
    (&amp;c-&gt;alloc_sem){+.+.+.}, at: [&lt;c01f7714&gt;] jffs2_garbage_collect_pass+0x314/0x890

   but task is already holding lock:
    (&amp;(&amp;c-&gt;erase_completion_lock)-&gt;rlock){+.+...}, at: [&lt;c01f7708&gt;] jffs2_garbage_collect_pass+0x308/0x890

   which lock already depends on the new lock.

   the existing dependency chain (in reverse order) is:

   -&gt; #1 (&amp;(&amp;c-&gt;erase_completion_lock)-&gt;rlock){+.+...}:
          [&lt;c008bec4&gt;] validate_chain+0xe6c/0x10bc
          [&lt;c008c660&gt;] __lock_acquire+0x54c/0xba4
          [&lt;c008d240&gt;] lock_acquire+0xa4/0x114
          [&lt;c046780c&gt;] _raw_spin_lock+0x3c/0x4c
          [&lt;c01f744c&gt;] jffs2_garbage_collect_pass+0x4c/0x890
          [&lt;c01f937c&gt;] jffs2_garbage_collect_thread+0x1b4/0x1cc
          [&lt;c0071a68&gt;] kthread+0x98/0xa0
          [&lt;c000f264&gt;] kernel_thread_exit+0x0/0x8

   -&gt; #0 (&amp;c-&gt;alloc_sem){+.+.+.}:
          [&lt;c008ad2c&gt;] print_circular_bug+0x70/0x2c4
          [&lt;c008c08c&gt;] validate_chain+0x1034/0x10bc
          [&lt;c008c660&gt;] __lock_acquire+0x54c/0xba4
          [&lt;c008d240&gt;] lock_acquire+0xa4/0x114
          [&lt;c0466628&gt;] mutex_lock_nested+0x74/0x33c
          [&lt;c01f7714&gt;] jffs2_garbage_collect_pass+0x314/0x890
          [&lt;c01f937c&gt;] jffs2_garbage_collect_thread+0x1b4/0x1cc
          [&lt;c0071a68&gt;] kthread+0x98/0xa0
          [&lt;c000f264&gt;] kernel_thread_exit+0x0/0x8

   other info that might help us debug this:

    Possible unsafe locking scenario:

          CPU0                    CPU1
          ----                    ----
     lock(&amp;(&amp;c-&gt;erase_completion_lock)-&gt;rlock);
                                  lock(&amp;c-&gt;alloc_sem);
                                  lock(&amp;(&amp;c-&gt;erase_completion_lock)-&gt;rlock);
     lock(&amp;c-&gt;alloc_sem);

    *** DEADLOCK ***

   1 lock held by jffs2_gcd_mtd6/299:
    #0:  (&amp;(&amp;c-&gt;erase_completion_lock)-&gt;rlock){+.+...}, at: [&lt;c01f7708&gt;] jffs2_garbage_collect_pass+0x308/0x890

   stack backtrace:
   [&lt;c00155dc&gt;] (unwind_backtrace+0x0/0x100) from [&lt;c0463dc0&gt;] (dump_stack+0x20/0x24)
   [&lt;c0463dc0&gt;] (dump_stack+0x20/0x24) from [&lt;c008ae84&gt;] (print_circular_bug+0x1c8/0x2c4)
   [&lt;c008ae84&gt;] (print_circular_bug+0x1c8/0x2c4) from [&lt;c008c08c&gt;] (validate_chain+0x1034/0x10bc)
   [&lt;c008c08c&gt;] (validate_chain+0x1034/0x10bc) from [&lt;c008c660&gt;] (__lock_acquire+0x54c/0xba4)
   [&lt;c008c660&gt;] (__lock_acquire+0x54c/0xba4) from [&lt;c008d240&gt;] (lock_acquire+0xa4/0x114)
   [&lt;c008d240&gt;] (lock_acquire+0xa4/0x114) from [&lt;c0466628&gt;] (mutex_lock_nested+0x74/0x33c)
   [&lt;c0466628&gt;] (mutex_lock_nested+0x74/0x33c) from [&lt;c01f7714&gt;] (jffs2_garbage_collect_pass+0x314/0x890)
   [&lt;c01f7714&gt;] (jffs2_garbage_collect_pass+0x314/0x890) from [&lt;c01f937c&gt;] (jffs2_garbage_collect_thread+0x1b4/0x1cc)
   [&lt;c01f937c&gt;] (jffs2_garbage_collect_thread+0x1b4/0x1cc) from [&lt;c0071a68&gt;] (kthread+0x98/0xa0)
   [&lt;c0071a68&gt;] (kthread+0x98/0xa0) from [&lt;c000f264&gt;] (kernel_thread_exit+0x0/0x8)

This was introduce in '81cfc9f jffs2: Fix serious write stall due to erase'.

Signed-off-by: Josh Cartwright &lt;joshc@linux.com&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@linux.intel.com&gt;
Signed-off-by: David Woodhouse &lt;David.Woodhouse@intel.com&gt;
[bwh: Backported to 3.2: adjust context]
Signed-off-by: Ben Hutchings &lt;ben@decadent.org.uk&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge git://git.infradead.org/mtd-2.6</title>
<updated>2011-11-07T17:11:16+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2011-11-07T17:11:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=e0d65113a70f1dc514e625cc4e7a7485a4bf72df'/>
<id>e0d65113a70f1dc514e625cc4e7a7485a4bf72df</id>
<content type='text'>
* git://git.infradead.org/mtd-2.6: (226 commits)
  mtd: tests: annotate as DANGEROUS in Kconfig
  mtd: tests: don't use mtd0 as a default
  mtd: clean up usage of MTD_DOCPROBE_ADDRESS
  jffs2: add compr=lzo and compr=zlib options
  jffs2: implement mount option parsing and compression overriding
  mtd: nand: initialize ops.mode
  mtd: provide an alias for the redboot module name
  mtd: m25p80: don't probe device which has status of 'disabled'
  mtd: nand_h1900 never worked
  mtd: Add DiskOnChip G3 support
  mtd: m25p80: add EON flash EN25Q32B into spi flash id table
  mtd: mark block device queue as non-rotational
  mtd: r852: make r852_pm_ops static
  mtd: m25p80: add support for at25df321a spi data flash
  mtd: mxc_nand: preset_v1_v2: unlock all NAND flash blocks
  mtd: nand: switch `check_pattern()' to standard `memcmp()'
  mtd: nand: invalidate cache on unaligned reads
  mtd: nand: do not scan bad blocks with NAND_BBT_NO_OOB set
  mtd: nand: wait to set BBT version
  mtd: nand: scrub BBT on ECC errors
  ...

Fix up trivial conflicts:
 - arch/arm/mach-at91/board-usb-a9260.c
	Merged into board-usb-a926x.c
 - drivers/mtd/maps/lantiq-flash.c
	add_mtd_partitions -&gt; mtd_device_register vs changed to use
	mtd_device_parse_register.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* git://git.infradead.org/mtd-2.6: (226 commits)
  mtd: tests: annotate as DANGEROUS in Kconfig
  mtd: tests: don't use mtd0 as a default
  mtd: clean up usage of MTD_DOCPROBE_ADDRESS
  jffs2: add compr=lzo and compr=zlib options
  jffs2: implement mount option parsing and compression overriding
  mtd: nand: initialize ops.mode
  mtd: provide an alias for the redboot module name
  mtd: m25p80: don't probe device which has status of 'disabled'
  mtd: nand_h1900 never worked
  mtd: Add DiskOnChip G3 support
  mtd: m25p80: add EON flash EN25Q32B into spi flash id table
  mtd: mark block device queue as non-rotational
  mtd: r852: make r852_pm_ops static
  mtd: m25p80: add support for at25df321a spi data flash
  mtd: mxc_nand: preset_v1_v2: unlock all NAND flash blocks
  mtd: nand: switch `check_pattern()' to standard `memcmp()'
  mtd: nand: invalidate cache on unaligned reads
  mtd: nand: do not scan bad blocks with NAND_BBT_NO_OOB set
  mtd: nand: wait to set BBT version
  mtd: nand: scrub BBT on ECC errors
  ...

Fix up trivial conflicts:
 - arch/arm/mach-at91/board-usb-a9260.c
	Merged into board-usb-a926x.c
 - drivers/mtd/maps/lantiq-flash.c
	add_mtd_partitions -&gt; mtd_device_register vs changed to use
	mtd_device_parse_register.
</pre>
</div>
</content>
</entry>
<entry>
<title>filesystems: add set_nlink()</title>
<updated>2011-11-02T11:53:43+00:00</updated>
<author>
<name>Miklos Szeredi</name>
<email>mszeredi@suse.cz</email>
</author>
<published>2011-10-28T12:13:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=bfe8684869601dacfcb2cd69ef8cfd9045f62170'/>
<id>bfe8684869601dacfcb2cd69ef8cfd9045f62170</id>
<content type='text'>
Replace remaining direct i_nlink updates with a new set_nlink()
updater function.

Signed-off-by: Miklos Szeredi &lt;mszeredi@suse.cz&gt;
Tested-by: Toshiyuki Okajima &lt;toshi.okajima@jp.fujitsu.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Replace remaining direct i_nlink updates with a new set_nlink()
updater function.

Signed-off-by: Miklos Szeredi &lt;mszeredi@suse.cz&gt;
Tested-by: Toshiyuki Okajima &lt;toshi.okajima@jp.fujitsu.com&gt;
Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>jffs2: add compr=lzo and compr=zlib options</title>
<updated>2011-10-19T14:22:21+00:00</updated>
<author>
<name>Andres Salomon</name>
<email>dilinger@queued.net</email>
</author>
<published>2011-10-17T01:15:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=123005f3ccfa58637ad6e1a8b9f7f3f861ca65f4'/>
<id>123005f3ccfa58637ad6e1a8b9f7f3f861ca65f4</id>
<content type='text'>
..to allow forcing of either compression scheme.  This will override
compiled-in defaults.  jffs2_compress is reworked a bit, as the lzo/zlib
override shares lots of code w/ the PRIORITY mode.

v2: update show_options accordingly.

Signed-off-by: Andres Salomon &lt;dilinger@queued.net&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
..to allow forcing of either compression scheme.  This will override
compiled-in defaults.  jffs2_compress is reworked a bit, as the lzo/zlib
override shares lots of code w/ the PRIORITY mode.

v2: update show_options accordingly.

Signed-off-by: Andres Salomon &lt;dilinger@queued.net&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>jffs2: implement mount option parsing and compression overriding</title>
<updated>2011-10-19T14:22:20+00:00</updated>
<author>
<name>Andres Salomon</name>
<email>dilinger@queued.net</email>
</author>
<published>2011-10-17T01:15:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=92abc475d8de1c29373f6d96ed63d8ecaa199d25'/>
<id>92abc475d8de1c29373f6d96ed63d8ecaa199d25</id>
<content type='text'>
Currently jffs2 has compile-time constants (and .config options)
controlling whether or not the various compression/decompression
drivers are built in and enabled.  This is fine for embedded
systems, but it clashes with distribution kernels.  Distro kernels
tend to turn on everything; this causes OpenFirmware to fall
over, as it understands ZLIB-compressed inodes.  Booting a kernel
that has LZO compression enabled, writing to the boot partition,
and then rebooting causes OFW to fail to read the kernel from
the filesystem.  This is because LZO compression has priority
when writing new data to jffs2, if LZO is enabled.

This patch adds mount option parsing, and a single supported
option ("compr=none").  This adds the flexibility of being
able to specify which compressor overrides on a per-superblock
basis.  For now, we can simply disable compression;
additional flexibility coming soon.

v2: kill some printks, and implement show_options as suggested
by Artem Bityutskiy.

Signed-off-by: Andres Salomon &lt;dilinger@queued.net&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently jffs2 has compile-time constants (and .config options)
controlling whether or not the various compression/decompression
drivers are built in and enabled.  This is fine for embedded
systems, but it clashes with distribution kernels.  Distro kernels
tend to turn on everything; this causes OpenFirmware to fall
over, as it understands ZLIB-compressed inodes.  Booting a kernel
that has LZO compression enabled, writing to the boot partition,
and then rebooting causes OFW to fail to read the kernel from
the filesystem.  This is because LZO compression has priority
when writing new data to jffs2, if LZO is enabled.

This patch adds mount option parsing, and a single supported
option ("compr=none").  This adds the flexibility of being
able to specify which compressor overrides on a per-superblock
basis.  For now, we can simply disable compression;
additional flexibility coming soon.

v2: kill some printks, and implement show_options as suggested
by Artem Bityutskiy.

Signed-off-by: Andres Salomon &lt;dilinger@queued.net&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>mtd: rename MTD_OOB_* to MTD_OPS_*</title>
<updated>2011-09-11T12:28:59+00:00</updated>
<author>
<name>Brian Norris</name>
<email>computersforpeace@gmail.com</email>
</author>
<published>2011-08-31T01:45:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=0612b9ddc2eeda014dd805c87c752b342d8f80f0'/>
<id>0612b9ddc2eeda014dd805c87c752b342d8f80f0</id>
<content type='text'>
These modes are not necessarily for OOB only. Particularly, MTD_OOB_RAW
affected operations on in-band page data as well. To clarify these
options and to emphasize that their effect is applied per-operation, we
change the primary prefix to MTD_OPS_.

Signed-off-by: Brian Norris &lt;computersforpeace@gmail.com&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@intel.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
These modes are not necessarily for OOB only. Particularly, MTD_OOB_RAW
affected operations on in-band page data as well. To clarify these
options and to emphasize that their effect is applied per-operation, we
change the primary prefix to MTD_OPS_.

Signed-off-by: Brian Norris &lt;computersforpeace@gmail.com&gt;
Signed-off-by: Artem Bityutskiy &lt;artem.bityutskiy@intel.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>jffs2: use mutex_is_locked() in __jffs2_flush_wbuf()</title>
<updated>2011-09-11T12:02:14+00:00</updated>
<author>
<name>Alexey Khoroshilov</name>
<email>khoroshilov@ispras.ru</email>
</author>
<published>2011-06-27T20:21:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=51b11e3630672b7ce8793ecf13e5759656edf38a'/>
<id>51b11e3630672b7ce8793ecf13e5759656edf38a</id>
<content type='text'>
Use a helper to test if a mutex is held instead of a hack with
mutex_trylock().

Signed-off-by: Alexey Khoroshilov &lt;khoroshilov@ispras.ru&gt;
Signed-off-by: Artem Bityutskiy &lt;dedekind1@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use a helper to test if a mutex is held instead of a hack with
mutex_trylock().

Signed-off-by: Alexey Khoroshilov &lt;khoroshilov@ispras.ru&gt;
Signed-off-by: Artem Bityutskiy &lt;dedekind1@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>jffs2: Avoid unneeded 'if' before kfree</title>
<updated>2011-09-11T12:02:10+00:00</updated>
<author>
<name>Jesper Juhl</name>
<email>jj@chaosbits.net</email>
</author>
<published>2011-06-13T20:16:44+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=e8a0e41266e9c207ad8ac158cee9547ef1bc90ac'/>
<id>e8a0e41266e9c207ad8ac158cee9547ef1bc90ac</id>
<content type='text'>
kfree() deals gracefully with NULL pointers, so it's pointless to test for
one prior to calling it.
This removes such a test from jffs2_scan_medium().

Signed-off-by: Jesper Juhl &lt;jj@chaosbits.net&gt;
Signed-off-by: Artem Bityutskiy &lt;dedekind1@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
kfree() deals gracefully with NULL pointers, so it's pointless to test for
one prior to calling it.
This removes such a test from jffs2_scan_medium().

Signed-off-by: Jesper Juhl &lt;jj@chaosbits.net&gt;
Signed-off-by: Artem Bityutskiy &lt;dedekind1@gmail.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
