linux-next.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* next-20090310: ext4 hangs
@ 2009-03-10 12:17 Alexander Beregalov
  2009-03-10 12:46 ` Theodore Tso
  0 siblings, 1 reply; 24+ messages in thread
From: Alexander Beregalov @ 2009-03-10 12:17 UTC (permalink / raw)
  To: linux-next, linux-ext4, LKML

Hi

It is similar to http://lkml.org/lkml/2009/2/6/304,
http://bugzilla.kernel.org/show_bug.cgi?id=12579


I run dbench on ext4 on loop on ext3 on sparc.
The kernel is 2.6.29-rc7-next-20090310
e2fsprogs -1.41.4

ioctl32(mkfs.ext4:1668): Unknown cmd fd(3) cmd(40041272){t:12;sz:4}
arg(ffb2ce60) on /testfs
ioctl32(mkfs.ext4:1668): Unknown cmd fd(3) cmd(20001260){t:12;sz:0}
arg(ffb2ce6c) on /testfs
ioctl32(mkfs.ext4:1668): Unknown cmd fd(3) cmd(401c0204){t:02;sz:28}
arg(ffb2ce44) on /testfs
ioctl32(mkfs.ext4:1668): Unknown cmd fd(3) cmd(20001268){t:12;sz:0}
arg(ffb2d564) on /testfs
ioctl32(mkfs.ext4:1668): Unknown cmd fd(3) cmd(2000125e){t:12;sz:0}
arg(ffb2ce6c) on /testfs
EXT4-fs: barriers enabled
EXT4 FS on loop0, internal journal on loop0:8
EXT4-fs: delayed allocation enabled
EXT4-fs: file extents enabled
EXT4-fs: mballoc enabled
EXT4-fs: mounted filesystem loop0 with ordered data mode
kjournald2 starting: pid 1672, dev loop0:8, commit interval 5 seconds
JBD: barrier-based sync failed on loop0:8 - disabling barriers
INFO: task kjournald2:1672 blocked for more than 120 seconds.
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
kjournald2    D 0000000000557a0c     0  1672      2
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [0000000000557a0c] jbd2_journal_commit_transaction+0x208/0x1718
 [000000000055d758] kjournald2+0x14c/0x318
 [0000000000465d34] kthread+0x48/0x7c
 [000000000042b364] kernel_thread+0x3c/0x54
 [0000000000465c88] kthreadd+0xc8/0x12c
INFO: lockdep is turned off.
INFO: task dbench:1674 blocked for more than 120 seconds.
"echo 0 > /proc/sys/kernel/hung_task_timeout_secs" disables this message.
dbench        D 000000000055716c     0  1674   1673
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055716c] start_this_handle+0x374/0x508
 [0000000000557500] jbd2_journal_start+0xbc/0x11c
 [000000000053a438] ext4_journal_start_sb+0x5c/0x84
 [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
 [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
 [00000000004c7714] touch_atime+0x160/0x178
 [00000000004c2a3c] vfs_readdir+0x88/0xb0
 [00000000004eab90] compat_sys_getdents+0x3c/0x8c
 [0000000000406154] linux_sparc_syscall32+0x34/0x40

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-10 12:17 next-20090310: ext4 hangs Alexander Beregalov
@ 2009-03-10 12:46 ` Theodore Tso
  2009-03-10 12:54   ` Alexander Beregalov
  2009-03-10 14:18   ` Alexander Beregalov
  0 siblings, 2 replies; 24+ messages in thread
From: Theodore Tso @ 2009-03-10 12:46 UTC (permalink / raw)
  To: Alexander Beregalov; +Cc: linux-next, linux-ext4, LKML

On Tue, Mar 10, 2009 at 03:17:51PM +0300, Alexander Beregalov wrote:
> Hi
> 
> It is similar to http://lkml.org/lkml/2009/2/6/304,
> http://bugzilla.kernel.org/show_bug.cgi?id=12579
> 
> I run dbench on ext4 on loop on ext3 on sparc.
> The kernel is 2.6.29-rc7-next-20090310
> e2fsprogs -1.41.4

Thanks for reporting this; does it show up on stock 2.6.29-rc7?  And
any chance you can enable LOCKDEP?  Finally, how many CPU's do you
have on your machine?

Thanks again,

						- Ted

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-10 12:46 ` Theodore Tso
@ 2009-03-10 12:54   ` Alexander Beregalov
  2009-03-10 14:18   ` Alexander Beregalov
  1 sibling, 0 replies; 24+ messages in thread
From: Alexander Beregalov @ 2009-03-10 12:54 UTC (permalink / raw)
  To: Theodore Tso, Alexander Beregalov, linux-next, linux-ext4, LKML

2009/3/10 Theodore Tso <tytso@mit.edu>:
> On Tue, Mar 10, 2009 at 03:17:51PM +0300, Alexander Beregalov wrote:
>> Hi
>>
>> It is similar to http://lkml.org/lkml/2009/2/6/304,
>> http://bugzilla.kernel.org/show_bug.cgi?id=12579
>>
>> I run dbench on ext4 on loop on ext3 on sparc.
>> The kernel is 2.6.29-rc7-next-20090310
>> e2fsprogs -1.41.4
>
> Thanks for reporting this; does it show up on stock 2.6.29-rc7?  And
> any chance you can enable LOCKDEP?  Finally, how many CPU's do you
> have on your machine?

I will try it with current -git.
LOCkDEP is enabled already.
CONFIG_LOCKDEP_SUPPORT=y
CONFIG_LOCKDEP=y
CONFIG_DEBUG_LOCKDEP=y

It is UP system.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-10 12:46 ` Theodore Tso
  2009-03-10 12:54   ` Alexander Beregalov
@ 2009-03-10 14:18   ` Alexander Beregalov
  2009-03-10 15:47     ` Theodore Tso
  1 sibling, 1 reply; 24+ messages in thread
From: Alexander Beregalov @ 2009-03-10 14:18 UTC (permalink / raw)
  To: Theodore Tso, linux-next, linux-ext4, LKML

2009/3/10 Theodore Tso <tytso@mit.edu>:
> On Tue, Mar 10, 2009 at 03:17:51PM +0300, Alexander Beregalov wrote:
>> Hi
>>
>> It is similar to http://lkml.org/lkml/2009/2/6/304,
>> http://bugzilla.kernel.org/show_bug.cgi?id=12579
>>
>> I run dbench on ext4 on loop on ext3 on sparc.
>> The kernel is 2.6.29-rc7-next-20090310
>> e2fsprogs -1.41.4
>
> Thanks for reporting this; does it show up on stock 2.6.29-rc7?
No, I can not reproduce it.
It is a slow system, I would not like to bisect it, only if it is the
last possibility.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-10 14:18   ` Alexander Beregalov
@ 2009-03-10 15:47     ` Theodore Tso
  2009-03-11 16:07       ` Alexander Beregalov
  0 siblings, 1 reply; 24+ messages in thread
From: Theodore Tso @ 2009-03-10 15:47 UTC (permalink / raw)
  To: Alexander Beregalov; +Cc: linux-next, linux-ext4, LKML

On Tue, Mar 10, 2009 at 05:18:55PM +0300, Alexander Beregalov wrote:
> > Thanks for reporting this; does it show up on stock 2.6.29-rc7?
> No, I can not reproduce it.
> It is a slow system, I would not like to bisect it, only if it is the
> last possibility.

Just to be clear; you weren't able to reproduce it on stock 2.6.29-rc7
---- does it reproduce easily on linux-next?

Next question --- does the system hang completely, or just the dbench
process (and probably any process that tries touching the filesystem
that's hung up)?  Do you have a serial console, or someone of
recording all of the dumps coming from sysrq-t?  The two stack traces
you gave weren't the ones causing the problem, but rather the ones
waiting for the journal lock.  

I don't think is related to BZ #12579, although some of the symptoms
look superficially the same.

							- Ted

P.S.  What are your dbench parameters, and how big is your filesystem,
so I can try to reproduce it on my side?  And how long do you
typically need to run before this triggers?  Thanks!

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-10 15:47     ` Theodore Tso
@ 2009-03-11 16:07       ` Alexander Beregalov
  2009-03-25 15:11         ` Jan Kara
  0 siblings, 1 reply; 24+ messages in thread
From: Alexander Beregalov @ 2009-03-11 16:07 UTC (permalink / raw)
  To: Theodore Tso, Alexander Beregalov, linux-next, linux-ext4, LKML

2009/3/10 Theodore Tso <tytso@mit.edu>:
> On Tue, Mar 10, 2009 at 05:18:55PM +0300, Alexander Beregalov wrote:
>> > Thanks for reporting this; does it show up on stock 2.6.29-rc7?
>> No, I can not reproduce it.
>> It is a slow system, I would not like to bisect it, only if it is the
>> last possibility.
>
> Just to be clear; you weren't able to reproduce it on stock 2.6.29-rc7
> ---- does it reproduce easily on linux-next?
Right.
But now I am not sure 2.6.29-rc7 is not affected, I will try to
reproduce it again.

>
> Next question --- does the system hang completely, or just the dbench
> process (and probably any process that tries touching the filesystem
System is responsible.
> that's hung up)?  Do you have a serial console, or someone of
> recording all of the dumps coming from sysrq-t?  The two stack traces
I can read dmesg.
> you gave weren't the ones causing the problem, but rather the ones
> waiting for the journal lock.

SysRq : Show State

<..>

kjournald2    D 0000000000557a0c     0  1547      2
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [0000000000557a0c] jbd2_journal_commit_transaction+0x208/0x1718
 [000000000055d758] kjournald2+0x14c/0x318
 [0000000000465d34] kthread+0x48/0x7c
 [000000000042b364] kernel_thread+0x3c/0x54
 [0000000000465c88] kthreadd+0xc8/0x12c
pdflush       D 000000000055716c     0  2021      2
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055716c] start_this_handle+0x374/0x508
 [0000000000557500] jbd2_journal_start+0xbc/0x11c
 [000000000053a438] ext4_journal_start_sb+0x5c/0x84
 [000000000052dd84] ext4_da_writepages+0x1a8/0x404
 [0000000000490ec0] do_writepages+0x40/0x78
 [00000000004d0ff8] __writeback_single_inode+0x198/0x330
 [00000000004d15d8] generic_sync_sb_inodes+0x238/0x3c4
 [00000000004d1984] writeback_inodes+0xb0/0x114
 [00000000004915c0] background_writeout+0xc8/0x114
 [0000000000492004] pdflush+0x128/0x1e0
 [0000000000465d34] kthread+0x48/0x7c
 [000000000042b364] kernel_thread+0x3c/0x54
 [0000000000465c88] kthreadd+0xc8/0x12c
dbench        D 000000000055716c     0  2024      1
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055716c] start_this_handle+0x374/0x508
 [0000000000557500] jbd2_journal_start+0xbc/0x11c
 [000000000053a438] ext4_journal_start_sb+0x5c/0x84
 [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
 [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
 [00000000004c7714] touch_atime+0x160/0x178
 [00000000004c2a3c] vfs_readdir+0x88/0xb0
 [00000000004eab90] compat_sys_getdents+0x3c/0x8c
 [0000000000406154] linux_sparc_syscall32+0x34/0x40
dbench        D 000000000055716c     0  2025      1
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055716c] start_this_handle+0x374/0x508
 [0000000000557500] jbd2_journal_start+0xbc/0x11c
 [000000000053a438] ext4_journal_start_sb+0x5c/0x84
 [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
 [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
 [00000000004c7714] touch_atime+0x160/0x178
 [00000000004c2a3c] vfs_readdir+0x88/0xb0
 [00000000004eab90] compat_sys_getdents+0x3c/0x8c
 [0000000000406154] linux_sparc_syscall32+0x34/0x40
dbench        D 000000000055716c     0  2026      1
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055716c] start_this_handle+0x374/0x508
 [0000000000557500] jbd2_journal_start+0xbc/0x11c
 [000000000053a438] ext4_journal_start_sb+0x5c/0x84
 [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
 [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
 [00000000004c7714] touch_atime+0x160/0x178
 [000000000048b56c] generic_file_aio_read+0x578/0x620
 [00000000004b5254] do_sync_read+0x90/0xe0
 [00000000004b5c40] vfs_read+0x7c/0x11c
 [00000000004b5d30] SyS_pread64+0x50/0x7c
 [000000000043f778] sys32_pread64+0x20/0x34
 [0000000000406154] linux_sparc_syscall32+0x34/0x40
dbench        D 000000000055716c     0  2027      1
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055716c] start_this_handle+0x374/0x508
 [0000000000557500] jbd2_journal_start+0xbc/0x11c
 [000000000053a438] ext4_journal_start_sb+0x5c/0x84
 [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
 [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
 [00000000004c757c] file_update_time+0xe0/0x118
 [000000000048aef4] __generic_file_aio_write_nolock+0x280/0x380
 [000000000048b930] generic_file_aio_write+0x58/0xc8
 [0000000000526274] ext4_file_write+0xa8/0x15c
 [00000000004b5174] do_sync_write+0x90/0xe0
 [00000000004b5a40] vfs_write+0x7c/0x11c
 [00000000004b5b30] SyS_pwrite64+0x50/0x7c
 [000000000043f744] sys32_pwrite64+0x20/0x34
 [0000000000406154] linux_sparc_syscall32+0x34/0x40
dbench        D 000000000055716c     0  2028      1
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055716c] start_this_handle+0x374/0x508
 [0000000000557500] jbd2_journal_start+0xbc/0x11c
 [000000000053a438] ext4_journal_start_sb+0x5c/0x84
 [000000000052b958] ext4_da_write_begin+0x98/0x1a0
 [000000000048a8dc] generic_file_buffered_write+0xe4/0x2b8
 [000000000048afd0] __generic_file_aio_write_nolock+0x35c/0x380
 [000000000048b930] generic_file_aio_write+0x58/0xc8
 [0000000000526274] ext4_file_write+0xa8/0x15c
 [00000000004b5174] do_sync_write+0x90/0xe0
 [00000000004b5a40] vfs_write+0x7c/0x11c
 [00000000004b5b30] SyS_pwrite64+0x50/0x7c
 [000000000043f744] sys32_pwrite64+0x20/0x34
 [0000000000406154] linux_sparc_syscall32+0x34/0x40
dbench        D 000000000055c010     0  2029      1
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055c010] jbd2_journal_release_jbd_inode+0x94/0xd8
 [0000000000535bb4] ext4_clear_inode+0x2c/0x3c
 [00000000004c7b1c] clear_inode+0xac/0x124
 [0000000000527e48] ext4_free_inode+0x7c/0x3d4
 [000000000052f884] ext4_delete_inode+0x218/0x29c
 [00000000004c86b4] generic_delete_inode+0x8c/0x124
 [00000000004c876c] generic_drop_inode+0x20/0x19c
 [00000000004c77a4] iput+0x78/0x88
 [00000000004c0200] do_unlinkat+0xf8/0x154
 [00000000004c0270] SyS_unlink+0x14/0x24
 [0000000000406154] linux_sparc_syscall32+0x34/0x40
dbench        D 000000000055cf84     0  2030      1
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055cf84] jbd2_log_wait_commit+0x144/0x1a8
 [0000000000555cdc] jbd2_journal_stop+0x32c/0x37c
 [0000000000557594] jbd2_journal_force_commit+0x34/0x48
 [0000000000536d14] ext4_force_commit+0x30/0x50
 [00000000005296b8] ext4_write_inode+0x80/0xa0
 [00000000004d1044] __writeback_single_inode+0x1e4/0x330
 [00000000004d11b0] sync_inode+0x20/0x40
 [00000000005263ec] ext4_sync_file+0xc4/0x118
 [00000000004d46f0] vfs_fsync+0x6c/0xa0
 [00000000004d474c] do_fsync+0x28/0x44
 [00000000004d47a4] SyS_fsync+0x14/0x28
 [0000000000406154] linux_sparc_syscall32+0x34/0x40
dbench        D 000000000055716c     0  2031      1
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055716c] start_this_handle+0x374/0x508
 [0000000000557500] jbd2_journal_start+0xbc/0x11c
 [000000000053a438] ext4_journal_start_sb+0x5c/0x84
 [000000000052b958] ext4_da_write_begin+0x98/0x1a0
 [000000000048a8dc] generic_file_buffered_write+0xe4/0x2b8
 [000000000048afd0] __generic_file_aio_write_nolock+0x35c/0x380
 [000000000048b930] generic_file_aio_write+0x58/0xc8
 [0000000000526274] ext4_file_write+0xa8/0x15c
 [00000000004b5174] do_sync_write+0x90/0xe0
 [00000000004b5a40] vfs_write+0x7c/0x11c
 [00000000004b5b30] SyS_pwrite64+0x50/0x7c
 [000000000043f744] sys32_pwrite64+0x20/0x34
 [0000000000406154] linux_sparc_syscall32+0x34/0x40
dbench        D 000000000055716c     0  2032      1
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055716c] start_this_handle+0x374/0x508
 [0000000000557500] jbd2_journal_start+0xbc/0x11c
 [000000000053a438] ext4_journal_start_sb+0x5c/0x84
 [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
 [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
 [00000000004c7714] touch_atime+0x160/0x178
 [00000000004c2a3c] vfs_readdir+0x88/0xb0
 [00000000004eab90] compat_sys_getdents+0x3c/0x8c
 [0000000000406154] linux_sparc_syscall32+0x34/0x40
dbench        D 000000000055716c     0  2033      1
Call Trace:
 [0000000000768bcc] schedule+0x18/0x40
 [000000000055716c] start_this_handle+0x374/0x508
 [0000000000557500] jbd2_journal_start+0xbc/0x11c
 [000000000053a438] ext4_journal_start_sb+0x5c/0x84
 [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
 [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
 [00000000004c7714] touch_atime+0x160/0x178
 [000000000048b56c] generic_file_aio_read+0x578/0x620
 [00000000004b5254] do_sync_read+0x90/0xe0
 [00000000004b5c40] vfs_read+0x7c/0x11c
 [00000000004b5d30] SyS_pread64+0x50/0x7c
 [000000000043f778] sys32_pread64+0x20/0x34
 [0000000000406154] linux_sparc_syscall32+0x34/0x40


>
> I don't think is related to BZ #12579, although some of the symptoms
> look superficially the same.
>
>                                                        - Ted
>
> P.S.  What are your dbench parameters, and how big is your filesystem,
> so I can try to reproduce it on my side?  And how long do you
> typically need to run before this triggers?  Thanks!

It is 2G filesystem, I run
`dbench -c /usr/share/dbench/client.txt 10` or 5 clients.

Yesterday it happened when I run it for the first time, but today I
run it 10 times before I got the deadlock.

So, I think I need to try it on 2.6.29-rc7 again.
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-11 16:07       ` Alexander Beregalov
@ 2009-03-25 15:11         ` Jan Kara
  2009-03-25 15:15           ` Jan Kara
  0 siblings, 1 reply; 24+ messages in thread
From: Jan Kara @ 2009-03-25 15:11 UTC (permalink / raw)
  To: Alexander Beregalov; +Cc: Theodore Tso, linux-next, linux-ext4, LKML

> 2009/3/10 Theodore Tso <tytso@mit.edu>:
> > On Tue, Mar 10, 2009 at 05:18:55PM +0300, Alexander Beregalov wrote:
> >> > Thanks for reporting this; does it show up on stock 2.6.29-rc7?
> >> No, I can not reproduce it.
> >> It is a slow system, I would not like to bisect it, only if it is the
> >> last possibility.
> >
> > Just to be clear; you weren't able to reproduce it on stock 2.6.29-rc7
> > ---- does it reproduce easily on linux-next?
> Right.
> But now I am not sure 2.6.29-rc7 is not affected, I will try to
> reproduce it again.
> 
> >
> > Next question --- does the system hang completely, or just the dbench
> > process (and probably any process that tries touching the filesystem
> System is responsible.
> > that's hung up)?  Do you have a serial console, or someone of
> > recording all of the dumps coming from sysrq-t?  The two stack traces
> I can read dmesg.
> > you gave weren't the ones causing the problem, but rather the ones
> > waiting for the journal lock.
> 
> SysRq : Show State
> 
> <..>
> 
> kjournald2    D 0000000000557a0c     0  1547      2
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [0000000000557a0c] jbd2_journal_commit_transaction+0x208/0x1718
>  [000000000055d758] kjournald2+0x14c/0x318
>  [0000000000465d34] kthread+0x48/0x7c
>  [000000000042b364] kernel_thread+0x3c/0x54
>  [0000000000465c88] kthreadd+0xc8/0x12c
> pdflush       D 000000000055716c     0  2021      2
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [000000000055716c] start_this_handle+0x374/0x508
>  [0000000000557500] jbd2_journal_start+0xbc/0x11c
>  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
>  [000000000052dd84] ext4_da_writepages+0x1a8/0x404
>  [0000000000490ec0] do_writepages+0x40/0x78
>  [00000000004d0ff8] __writeback_single_inode+0x198/0x330
>  [00000000004d15d8] generic_sync_sb_inodes+0x238/0x3c4
>  [00000000004d1984] writeback_inodes+0xb0/0x114
>  [00000000004915c0] background_writeout+0xc8/0x114
>  [0000000000492004] pdflush+0x128/0x1e0
>  [0000000000465d34] kthread+0x48/0x7c
>  [000000000042b364] kernel_thread+0x3c/0x54
>  [0000000000465c88] kthreadd+0xc8/0x12c
> dbench        D 000000000055716c     0  2024      1
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [000000000055716c] start_this_handle+0x374/0x508
>  [0000000000557500] jbd2_journal_start+0xbc/0x11c
>  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
>  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
>  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
>  [00000000004c7714] touch_atime+0x160/0x178
>  [00000000004c2a3c] vfs_readdir+0x88/0xb0
>  [00000000004eab90] compat_sys_getdents+0x3c/0x8c
>  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> dbench        D 000000000055716c     0  2025      1
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [000000000055716c] start_this_handle+0x374/0x508
>  [0000000000557500] jbd2_journal_start+0xbc/0x11c
>  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
>  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
>  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
>  [00000000004c7714] touch_atime+0x160/0x178
>  [00000000004c2a3c] vfs_readdir+0x88/0xb0
>  [00000000004eab90] compat_sys_getdents+0x3c/0x8c
>  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> dbench        D 000000000055716c     0  2026      1
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [000000000055716c] start_this_handle+0x374/0x508
>  [0000000000557500] jbd2_journal_start+0xbc/0x11c
>  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
>  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
>  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
>  [00000000004c7714] touch_atime+0x160/0x178
>  [000000000048b56c] generic_file_aio_read+0x578/0x620
>  [00000000004b5254] do_sync_read+0x90/0xe0
>  [00000000004b5c40] vfs_read+0x7c/0x11c
>  [00000000004b5d30] SyS_pread64+0x50/0x7c
>  [000000000043f778] sys32_pread64+0x20/0x34
>  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> dbench        D 000000000055716c     0  2027      1
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [000000000055716c] start_this_handle+0x374/0x508
>  [0000000000557500] jbd2_journal_start+0xbc/0x11c
>  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
>  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
>  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
>  [00000000004c757c] file_update_time+0xe0/0x118
>  [000000000048aef4] __generic_file_aio_write_nolock+0x280/0x380
>  [000000000048b930] generic_file_aio_write+0x58/0xc8
>  [0000000000526274] ext4_file_write+0xa8/0x15c
>  [00000000004b5174] do_sync_write+0x90/0xe0
>  [00000000004b5a40] vfs_write+0x7c/0x11c
>  [00000000004b5b30] SyS_pwrite64+0x50/0x7c
>  [000000000043f744] sys32_pwrite64+0x20/0x34
>  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> dbench        D 000000000055716c     0  2028      1
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [000000000055716c] start_this_handle+0x374/0x508
>  [0000000000557500] jbd2_journal_start+0xbc/0x11c
>  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
>  [000000000052b958] ext4_da_write_begin+0x98/0x1a0
>  [000000000048a8dc] generic_file_buffered_write+0xe4/0x2b8
>  [000000000048afd0] __generic_file_aio_write_nolock+0x35c/0x380
>  [000000000048b930] generic_file_aio_write+0x58/0xc8
>  [0000000000526274] ext4_file_write+0xa8/0x15c
>  [00000000004b5174] do_sync_write+0x90/0xe0
>  [00000000004b5a40] vfs_write+0x7c/0x11c
>  [00000000004b5b30] SyS_pwrite64+0x50/0x7c
>  [000000000043f744] sys32_pwrite64+0x20/0x34
>  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> dbench        D 000000000055c010     0  2029      1
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [000000000055c010] jbd2_journal_release_jbd_inode+0x94/0xd8
>  [0000000000535bb4] ext4_clear_inode+0x2c/0x3c
>  [00000000004c7b1c] clear_inode+0xac/0x124
>  [0000000000527e48] ext4_free_inode+0x7c/0x3d4
>  [000000000052f884] ext4_delete_inode+0x218/0x29c
>  [00000000004c86b4] generic_delete_inode+0x8c/0x124
>  [00000000004c876c] generic_drop_inode+0x20/0x19c
>  [00000000004c77a4] iput+0x78/0x88
>  [00000000004c0200] do_unlinkat+0xf8/0x154
>  [00000000004c0270] SyS_unlink+0x14/0x24
>  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> dbench        D 000000000055cf84     0  2030      1
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [000000000055cf84] jbd2_log_wait_commit+0x144/0x1a8
>  [0000000000555cdc] jbd2_journal_stop+0x32c/0x37c
>  [0000000000557594] jbd2_journal_force_commit+0x34/0x48
>  [0000000000536d14] ext4_force_commit+0x30/0x50
>  [00000000005296b8] ext4_write_inode+0x80/0xa0
>  [00000000004d1044] __writeback_single_inode+0x1e4/0x330
>  [00000000004d11b0] sync_inode+0x20/0x40
>  [00000000005263ec] ext4_sync_file+0xc4/0x118
>  [00000000004d46f0] vfs_fsync+0x6c/0xa0
>  [00000000004d474c] do_fsync+0x28/0x44
>  [00000000004d47a4] SyS_fsync+0x14/0x28
>  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> dbench        D 000000000055716c     0  2031      1
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [000000000055716c] start_this_handle+0x374/0x508
>  [0000000000557500] jbd2_journal_start+0xbc/0x11c
>  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
>  [000000000052b958] ext4_da_write_begin+0x98/0x1a0
>  [000000000048a8dc] generic_file_buffered_write+0xe4/0x2b8
>  [000000000048afd0] __generic_file_aio_write_nolock+0x35c/0x380
>  [000000000048b930] generic_file_aio_write+0x58/0xc8
>  [0000000000526274] ext4_file_write+0xa8/0x15c
>  [00000000004b5174] do_sync_write+0x90/0xe0
>  [00000000004b5a40] vfs_write+0x7c/0x11c
>  [00000000004b5b30] SyS_pwrite64+0x50/0x7c
>  [000000000043f744] sys32_pwrite64+0x20/0x34
>  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> dbench        D 000000000055716c     0  2032      1
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [000000000055716c] start_this_handle+0x374/0x508
>  [0000000000557500] jbd2_journal_start+0xbc/0x11c
>  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
>  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
>  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
>  [00000000004c7714] touch_atime+0x160/0x178
>  [00000000004c2a3c] vfs_readdir+0x88/0xb0
>  [00000000004eab90] compat_sys_getdents+0x3c/0x8c
>  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> dbench        D 000000000055716c     0  2033      1
> Call Trace:
>  [0000000000768bcc] schedule+0x18/0x40
>  [000000000055716c] start_this_handle+0x374/0x508
>  [0000000000557500] jbd2_journal_start+0xbc/0x11c
>  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
>  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
>  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
>  [00000000004c7714] touch_atime+0x160/0x178
>  [000000000048b56c] generic_file_aio_read+0x578/0x620
>  [00000000004b5254] do_sync_read+0x90/0xe0
>  [00000000004b5c40] vfs_read+0x7c/0x11c
>  [00000000004b5d30] SyS_pread64+0x50/0x7c
>  [000000000043f778] sys32_pread64+0x20/0x34
>  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> 
> 
> >
> > I don't think is related to BZ #12579, although some of the symptoms
> > look superficially the same.
> >
> >                                                        - Ted
> >
> > P.S.  What are your dbench parameters, and how big is your filesystem,
> > so I can try to reproduce it on my side?  And how long do you
> > typically need to run before this triggers?  Thanks!
> 
> It is 2G filesystem, I run
> `dbench -c /usr/share/dbench/client.txt 10` or 5 clients.
> 
> Yesterday it happened when I run it for the first time, but today I
> run it 10 times before I got the deadlock.
> 
> So, I think I need to try it on 2.6.29-rc7 again.
  I've looked into this. Obviously, what's happenning is that we delete
an inode and jbd2_journal_release_jbd_inode() finds inode is just under
writeout in transaction commit and thus it waits. But it gets never woken
up and because it has a handle from the transaction, every one eventually
blocks on waiting for a transaction to finish.
  But I don't really see how that can happen. The code is really
straightforward and everything happens under j_list_lock... Strange.

									Honza
-- 
Jan Kara <jack@suse.cz>
SuSE CR Labs

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-25 15:11         ` Jan Kara
@ 2009-03-25 15:15           ` Jan Kara
  2009-03-25 15:18             ` Alexander Beregalov
  0 siblings, 1 reply; 24+ messages in thread
From: Jan Kara @ 2009-03-25 15:15 UTC (permalink / raw)
  To: Alexander Beregalov; +Cc: Theodore Tso, linux-next, linux-ext4, LKML

> > 2009/3/10 Theodore Tso <tytso@mit.edu>:
> > > On Tue, Mar 10, 2009 at 05:18:55PM +0300, Alexander Beregalov wrote:
> > >> > Thanks for reporting this; does it show up on stock 2.6.29-rc7?
> > >> No, I can not reproduce it.
> > >> It is a slow system, I would not like to bisect it, only if it is the
> > >> last possibility.
> > >
> > > Just to be clear; you weren't able to reproduce it on stock 2.6.29-rc7
> > > ---- does it reproduce easily on linux-next?
> > Right.
> > But now I am not sure 2.6.29-rc7 is not affected, I will try to
> > reproduce it again.
> > 
> > >
> > > Next question --- does the system hang completely, or just the dbench
> > > process (and probably any process that tries touching the filesystem
> > System is responsible.
> > > that's hung up)?  Do you have a serial console, or someone of
> > > recording all of the dumps coming from sysrq-t?  The two stack traces
> > I can read dmesg.
> > > you gave weren't the ones causing the problem, but rather the ones
> > > waiting for the journal lock.
> > 
> > SysRq : Show State
> > 
> > <..>
> > 
> > kjournald2    D 0000000000557a0c     0  1547      2
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [0000000000557a0c] jbd2_journal_commit_transaction+0x208/0x1718
> >  [000000000055d758] kjournald2+0x14c/0x318
> >  [0000000000465d34] kthread+0x48/0x7c
> >  [000000000042b364] kernel_thread+0x3c/0x54
> >  [0000000000465c88] kthreadd+0xc8/0x12c
> > pdflush       D 000000000055716c     0  2021      2
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [000000000055716c] start_this_handle+0x374/0x508
> >  [0000000000557500] jbd2_journal_start+0xbc/0x11c
> >  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
> >  [000000000052dd84] ext4_da_writepages+0x1a8/0x404
> >  [0000000000490ec0] do_writepages+0x40/0x78
> >  [00000000004d0ff8] __writeback_single_inode+0x198/0x330
> >  [00000000004d15d8] generic_sync_sb_inodes+0x238/0x3c4
> >  [00000000004d1984] writeback_inodes+0xb0/0x114
> >  [00000000004915c0] background_writeout+0xc8/0x114
> >  [0000000000492004] pdflush+0x128/0x1e0
> >  [0000000000465d34] kthread+0x48/0x7c
> >  [000000000042b364] kernel_thread+0x3c/0x54
> >  [0000000000465c88] kthreadd+0xc8/0x12c
> > dbench        D 000000000055716c     0  2024      1
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [000000000055716c] start_this_handle+0x374/0x508
> >  [0000000000557500] jbd2_journal_start+0xbc/0x11c
> >  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
> >  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
> >  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
> >  [00000000004c7714] touch_atime+0x160/0x178
> >  [00000000004c2a3c] vfs_readdir+0x88/0xb0
> >  [00000000004eab90] compat_sys_getdents+0x3c/0x8c
> >  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> > dbench        D 000000000055716c     0  2025      1
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [000000000055716c] start_this_handle+0x374/0x508
> >  [0000000000557500] jbd2_journal_start+0xbc/0x11c
> >  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
> >  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
> >  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
> >  [00000000004c7714] touch_atime+0x160/0x178
> >  [00000000004c2a3c] vfs_readdir+0x88/0xb0
> >  [00000000004eab90] compat_sys_getdents+0x3c/0x8c
> >  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> > dbench        D 000000000055716c     0  2026      1
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [000000000055716c] start_this_handle+0x374/0x508
> >  [0000000000557500] jbd2_journal_start+0xbc/0x11c
> >  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
> >  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
> >  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
> >  [00000000004c7714] touch_atime+0x160/0x178
> >  [000000000048b56c] generic_file_aio_read+0x578/0x620
> >  [00000000004b5254] do_sync_read+0x90/0xe0
> >  [00000000004b5c40] vfs_read+0x7c/0x11c
> >  [00000000004b5d30] SyS_pread64+0x50/0x7c
> >  [000000000043f778] sys32_pread64+0x20/0x34
> >  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> > dbench        D 000000000055716c     0  2027      1
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [000000000055716c] start_this_handle+0x374/0x508
> >  [0000000000557500] jbd2_journal_start+0xbc/0x11c
> >  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
> >  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
> >  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
> >  [00000000004c757c] file_update_time+0xe0/0x118
> >  [000000000048aef4] __generic_file_aio_write_nolock+0x280/0x380
> >  [000000000048b930] generic_file_aio_write+0x58/0xc8
> >  [0000000000526274] ext4_file_write+0xa8/0x15c
> >  [00000000004b5174] do_sync_write+0x90/0xe0
> >  [00000000004b5a40] vfs_write+0x7c/0x11c
> >  [00000000004b5b30] SyS_pwrite64+0x50/0x7c
> >  [000000000043f744] sys32_pwrite64+0x20/0x34
> >  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> > dbench        D 000000000055716c     0  2028      1
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [000000000055716c] start_this_handle+0x374/0x508
> >  [0000000000557500] jbd2_journal_start+0xbc/0x11c
> >  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
> >  [000000000052b958] ext4_da_write_begin+0x98/0x1a0
> >  [000000000048a8dc] generic_file_buffered_write+0xe4/0x2b8
> >  [000000000048afd0] __generic_file_aio_write_nolock+0x35c/0x380
> >  [000000000048b930] generic_file_aio_write+0x58/0xc8
> >  [0000000000526274] ext4_file_write+0xa8/0x15c
> >  [00000000004b5174] do_sync_write+0x90/0xe0
> >  [00000000004b5a40] vfs_write+0x7c/0x11c
> >  [00000000004b5b30] SyS_pwrite64+0x50/0x7c
> >  [000000000043f744] sys32_pwrite64+0x20/0x34
> >  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> > dbench        D 000000000055c010     0  2029      1
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [000000000055c010] jbd2_journal_release_jbd_inode+0x94/0xd8
> >  [0000000000535bb4] ext4_clear_inode+0x2c/0x3c
> >  [00000000004c7b1c] clear_inode+0xac/0x124
> >  [0000000000527e48] ext4_free_inode+0x7c/0x3d4
> >  [000000000052f884] ext4_delete_inode+0x218/0x29c
> >  [00000000004c86b4] generic_delete_inode+0x8c/0x124
> >  [00000000004c876c] generic_drop_inode+0x20/0x19c
> >  [00000000004c77a4] iput+0x78/0x88
> >  [00000000004c0200] do_unlinkat+0xf8/0x154
> >  [00000000004c0270] SyS_unlink+0x14/0x24
> >  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> > dbench        D 000000000055cf84     0  2030      1
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [000000000055cf84] jbd2_log_wait_commit+0x144/0x1a8
> >  [0000000000555cdc] jbd2_journal_stop+0x32c/0x37c
> >  [0000000000557594] jbd2_journal_force_commit+0x34/0x48
> >  [0000000000536d14] ext4_force_commit+0x30/0x50
> >  [00000000005296b8] ext4_write_inode+0x80/0xa0
> >  [00000000004d1044] __writeback_single_inode+0x1e4/0x330
> >  [00000000004d11b0] sync_inode+0x20/0x40
> >  [00000000005263ec] ext4_sync_file+0xc4/0x118
> >  [00000000004d46f0] vfs_fsync+0x6c/0xa0
> >  [00000000004d474c] do_fsync+0x28/0x44
> >  [00000000004d47a4] SyS_fsync+0x14/0x28
> >  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> > dbench        D 000000000055716c     0  2031      1
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [000000000055716c] start_this_handle+0x374/0x508
> >  [0000000000557500] jbd2_journal_start+0xbc/0x11c
> >  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
> >  [000000000052b958] ext4_da_write_begin+0x98/0x1a0
> >  [000000000048a8dc] generic_file_buffered_write+0xe4/0x2b8
> >  [000000000048afd0] __generic_file_aio_write_nolock+0x35c/0x380
> >  [000000000048b930] generic_file_aio_write+0x58/0xc8
> >  [0000000000526274] ext4_file_write+0xa8/0x15c
> >  [00000000004b5174] do_sync_write+0x90/0xe0
> >  [00000000004b5a40] vfs_write+0x7c/0x11c
> >  [00000000004b5b30] SyS_pwrite64+0x50/0x7c
> >  [000000000043f744] sys32_pwrite64+0x20/0x34
> >  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> > dbench        D 000000000055716c     0  2032      1
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [000000000055716c] start_this_handle+0x374/0x508
> >  [0000000000557500] jbd2_journal_start+0xbc/0x11c
> >  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
> >  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
> >  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
> >  [00000000004c7714] touch_atime+0x160/0x178
> >  [00000000004c2a3c] vfs_readdir+0x88/0xb0
> >  [00000000004eab90] compat_sys_getdents+0x3c/0x8c
> >  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> > dbench        D 000000000055716c     0  2033      1
> > Call Trace:
> >  [0000000000768bcc] schedule+0x18/0x40
> >  [000000000055716c] start_this_handle+0x374/0x508
> >  [0000000000557500] jbd2_journal_start+0xbc/0x11c
> >  [000000000053a438] ext4_journal_start_sb+0x5c/0x84
> >  [000000000052a9b8] ext4_dirty_inode+0xd4/0xf0
> >  [00000000004d1a14] __mark_inode_dirty+0x2c/0x188
> >  [00000000004c7714] touch_atime+0x160/0x178
> >  [000000000048b56c] generic_file_aio_read+0x578/0x620
> >  [00000000004b5254] do_sync_read+0x90/0xe0
> >  [00000000004b5c40] vfs_read+0x7c/0x11c
> >  [00000000004b5d30] SyS_pread64+0x50/0x7c
> >  [000000000043f778] sys32_pread64+0x20/0x34
> >  [0000000000406154] linux_sparc_syscall32+0x34/0x40
> > 
> > 
> > >
> > > I don't think is related to BZ #12579, although some of the symptoms
> > > look superficially the same.
> > >
> > >                                                        - Ted
> > >
> > > P.S.  What are your dbench parameters, and how big is your filesystem,
> > > so I can try to reproduce it on my side?  And how long do you
> > > typically need to run before this triggers?  Thanks!
> > 
> > It is 2G filesystem, I run
> > `dbench -c /usr/share/dbench/client.txt 10` or 5 clients.
> > 
> > Yesterday it happened when I run it for the first time, but today I
> > run it 10 times before I got the deadlock.
> > 
> > So, I think I need to try it on 2.6.29-rc7 again.
>   I've looked into this. Obviously, what's happenning is that we delete
> an inode and jbd2_journal_release_jbd_inode() finds inode is just under
> writeout in transaction commit and thus it waits. But it gets never woken
> up and because it has a handle from the transaction, every one eventually
> blocks on waiting for a transaction to finish.
>   But I don't really see how that can happen. The code is really
> straightforward and everything happens under j_list_lock... Strange.
  BTW: Is the system SMP?

								Honza
-- 
Jan Kara <jack@suse.cz>
SuSE CR Labs
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-25 15:15           ` Jan Kara
@ 2009-03-25 15:18             ` Alexander Beregalov
  2009-03-25 15:22               ` Jan Kara
  0 siblings, 1 reply; 24+ messages in thread
From: Alexander Beregalov @ 2009-03-25 15:18 UTC (permalink / raw)
  To: Jan Kara; +Cc: Theodore Tso, linux-next, linux-ext4, LKML

2009/3/25 Jan Kara <jack@suse.cz>:
>> > So, I think I need to try it on 2.6.29-rc7 again.
>>   I've looked into this. Obviously, what's happenning is that we delete
>> an inode and jbd2_journal_release_jbd_inode() finds inode is just under
>> writeout in transaction commit and thus it waits. But it gets never woken
>> up and because it has a handle from the transaction, every one eventually
>> blocks on waiting for a transaction to finish.
>>   But I don't really see how that can happen. The code is really
>> straightforward and everything happens under j_list_lock... Strange.
>  BTW: Is the system SMP?
No, it is UP system.

The bug exists even in 2.6.29, I posted it with a new topic.
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-25 15:18             ` Alexander Beregalov
@ 2009-03-25 15:22               ` Jan Kara
  2009-03-25 15:29                 ` Alexander Beregalov
  0 siblings, 1 reply; 24+ messages in thread
From: Jan Kara @ 2009-03-25 15:22 UTC (permalink / raw)
  To: Alexander Beregalov; +Cc: Theodore Tso, linux-next, linux-ext4, LKML

On Wed 25-03-09 18:18:43, Alexander Beregalov wrote:
> 2009/3/25 Jan Kara <jack@suse.cz>:
> >> > So, I think I need to try it on 2.6.29-rc7 again.
> >>   I've looked into this. Obviously, what's happenning is that we delete
> >> an inode and jbd2_journal_release_jbd_inode() finds inode is just under
> >> writeout in transaction commit and thus it waits. But it gets never woken
> >> up and because it has a handle from the transaction, every one eventually
> >> blocks on waiting for a transaction to finish.
> >>   But I don't really see how that can happen. The code is really
> >> straightforward and everything happens under j_list_lock... Strange.
> >  BTW: Is the system SMP?
> No, it is UP system.
  Even stranger. And do you have CONFIG_PREEMPT set?

> The bug exists even in 2.6.29, I posted it with a new topic.
  OK, I've sort-of expected this.

									Honza
-- 
Jan Kara <jack@suse.cz>
SUSE Labs, CR

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-25 15:22               ` Jan Kara
@ 2009-03-25 15:29                 ` Alexander Beregalov
  2009-03-25 16:15                   ` Jan Kara
  0 siblings, 1 reply; 24+ messages in thread
From: Alexander Beregalov @ 2009-03-25 15:29 UTC (permalink / raw)
  To: Jan Kara; +Cc: Theodore Tso, linux-next, linux-ext4, LKML

[-- Attachment #1: Type: text/plain, Size: 1158 bytes --]

2009/3/25 Jan Kara <jack@suse.cz>:
> On Wed 25-03-09 18:18:43, Alexander Beregalov wrote:
>> 2009/3/25 Jan Kara <jack@suse.cz>:
>> >> > So, I think I need to try it on 2.6.29-rc7 again.
>> >>   I've looked into this. Obviously, what's happenning is that we delete
>> >> an inode and jbd2_journal_release_jbd_inode() finds inode is just under
>> >> writeout in transaction commit and thus it waits. But it gets never woken
>> >> up and because it has a handle from the transaction, every one eventually
>> >> blocks on waiting for a transaction to finish.
>> >>   But I don't really see how that can happen. The code is really
>> >> straightforward and everything happens under j_list_lock... Strange.
>> >  BTW: Is the system SMP?
>> No, it is UP system.
>  Even stranger. And do you have CONFIG_PREEMPT set?
>
>> The bug exists even in 2.6.29, I posted it with a new topic.
>  OK, I've sort-of expected this.

CONFIG_PREEMPT_RCU=y
CONFIG_PREEMPT_RCU_TRACE=y
# CONFIG_PREEMPT_NONE is not set
# CONFIG_PREEMPT_VOLUNTARY is not set
CONFIG_PREEMPT=y
CONFIG_DEBUG_PREEMPT=y
# CONFIG_PREEMPT_TRACER is not set

config is attached.

[-- Attachment #2: sparc-config --]
[-- Type: application/octet-stream, Size: 25765 bytes --]

#
# Automatically generated make config: don't edit
# Linux kernel version: 2.6.29-rc7
# Tue Mar 24 17:45:01 2009
#
CONFIG_64BIT=y
CONFIG_SPARC=y
# CONFIG_SPARC32 is not set
CONFIG_SPARC64=y
CONFIG_ARCH_DEFCONFIG="arch/sparc/configs/sparc64_defconfig"
CONFIG_BITS=64
CONFIG_GENERIC_TIME=y
CONFIG_GENERIC_CMOS_UPDATE=y
CONFIG_GENERIC_CLOCKEVENTS=y
CONFIG_IOMMU_HELPER=y
CONFIG_QUICKLIST=y
CONFIG_STACKTRACE_SUPPORT=y
CONFIG_LOCKDEP_SUPPORT=y
CONFIG_HAVE_LATENCYTOP_SUPPORT=y
CONFIG_AUDIT_ARCH=y
CONFIG_HAVE_SETUP_PER_CPU_AREA=y
CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y
CONFIG_MMU=y
CONFIG_ARCH_NO_VIRT_TO_BUS=y
CONFIG_OF=y
CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config"

#
# General setup
#
CONFIG_EXPERIMENTAL=y
CONFIG_BROKEN_ON_SMP=y
CONFIG_LOCK_KERNEL=y
CONFIG_INIT_ENV_ARG_LIMIT=32
CONFIG_LOCALVERSION=""
CONFIG_LOCALVERSION_AUTO=y
CONFIG_SWAP=y
CONFIG_SYSVIPC=y
CONFIG_SYSVIPC_SYSCTL=y
CONFIG_POSIX_MQUEUE=y
# CONFIG_BSD_PROCESS_ACCT is not set
# CONFIG_TASKSTATS is not set
# CONFIG_AUDIT is not set

#
# RCU Subsystem
#
# CONFIG_CLASSIC_RCU is not set
# CONFIG_TREE_RCU is not set
CONFIG_PREEMPT_RCU=y
CONFIG_RCU_TRACE=y
# CONFIG_TREE_RCU_TRACE is not set
CONFIG_PREEMPT_RCU_TRACE=y
CONFIG_IKCONFIG=y
CONFIG_IKCONFIG_PROC=y
CONFIG_LOG_BUF_SHIFT=18
# CONFIG_GROUP_SCHED is not set
# CONFIG_CGROUPS is not set
# CONFIG_SYSFS_DEPRECATED_V2 is not set
CONFIG_RELAY=y
CONFIG_NAMESPACES=y
# CONFIG_UTS_NS is not set
# CONFIG_IPC_NS is not set
# CONFIG_USER_NS is not set
# CONFIG_PID_NS is not set
# CONFIG_NET_NS is not set
# CONFIG_BLK_DEV_INITRD is not set
CONFIG_CC_OPTIMIZE_FOR_SIZE=y
CONFIG_SYSCTL=y
# CONFIG_EMBEDDED is not set
CONFIG_UID16=y
CONFIG_SYSCTL_SYSCALL=y
CONFIG_KALLSYMS=y
CONFIG_KALLSYMS_ALL=y
# CONFIG_KALLSYMS_EXTRA_PASS is not set
CONFIG_HOTPLUG=y
CONFIG_PRINTK=y
CONFIG_BUG=y
CONFIG_ELF_CORE=y
CONFIG_COMPAT_BRK=y
CONFIG_BASE_FULL=y
CONFIG_FUTEX=y
CONFIG_ANON_INODES=y
CONFIG_EPOLL=y
CONFIG_SIGNALFD=y
CONFIG_TIMERFD=y
CONFIG_EVENTFD=y
CONFIG_SHMEM=y
CONFIG_AIO=y
CONFIG_VM_EVENT_COUNTERS=y
CONFIG_PCI_QUIRKS=y
CONFIG_SLUB_DEBUG=y
# CONFIG_SLAB is not set
CONFIG_SLUB=y
# CONFIG_SLOB is not set
# CONFIG_PROFILING is not set
CONFIG_HAVE_OPROFILE=y
CONFIG_KPROBES=y
CONFIG_HAVE_SYSCALL_WRAPPERS=y
CONFIG_KRETPROBES=y
CONFIG_HAVE_KPROBES=y
CONFIG_HAVE_KRETPROBES=y
CONFIG_HAVE_ARCH_TRACEHOOK=y
# CONFIG_HAVE_GENERIC_DMA_COHERENT is not set
CONFIG_SLABINFO=y
CONFIG_RT_MUTEXES=y
CONFIG_BASE_SMALL=0
CONFIG_MODULES=y
# CONFIG_MODULE_FORCE_LOAD is not set
CONFIG_MODULE_UNLOAD=y
CONFIG_MODULE_FORCE_UNLOAD=y
# CONFIG_MODVERSIONS is not set
# CONFIG_MODULE_SRCVERSION_ALL is not set
CONFIG_BLOCK=y
# CONFIG_BLK_DEV_IO_TRACE is not set
# CONFIG_BLK_DEV_BSG is not set
# CONFIG_BLK_DEV_INTEGRITY is not set
CONFIG_BLOCK_COMPAT=y

#
# IO Schedulers
#
CONFIG_IOSCHED_NOOP=y
# CONFIG_IOSCHED_AS is not set
# CONFIG_IOSCHED_DEADLINE is not set
CONFIG_IOSCHED_CFQ=y
# CONFIG_DEFAULT_AS is not set
# CONFIG_DEFAULT_DEADLINE is not set
CONFIG_DEFAULT_CFQ=y
# CONFIG_DEFAULT_NOOP is not set
CONFIG_DEFAULT_IOSCHED="cfq"
# CONFIG_FREEZER is not set

#
# Processor type and features
#
# CONFIG_SMP is not set
CONFIG_HZ_100=y
# CONFIG_HZ_250 is not set
# CONFIG_HZ_300 is not set
# CONFIG_HZ_1000 is not set
CONFIG_HZ=100
# CONFIG_SCHED_HRTICK is not set
CONFIG_RWSEM_XCHGADD_ALGORITHM=y
CONFIG_GENERIC_FIND_NEXT_BIT=y
CONFIG_GENERIC_HWEIGHT=y
CONFIG_GENERIC_CALIBRATE_DELAY=y
CONFIG_ARCH_MAY_HAVE_PC_FDC=y
CONFIG_SPARC64_PAGE_SIZE_8KB=y
# CONFIG_SPARC64_PAGE_SIZE_64KB is not set
CONFIG_SECCOMP=y
CONFIG_GENERIC_HARDIRQS=y
CONFIG_TICK_ONESHOT=y
CONFIG_NO_HZ=y
# CONFIG_HIGH_RES_TIMERS is not set
CONFIG_GENERIC_CLOCKEVENTS_BUILD=y
# CONFIG_CPU_FREQ is not set
# CONFIG_US3_MC is not set
CONFIG_ARCH_POPULATES_NODE_MAP=y
CONFIG_ARCH_SELECT_MEMORY_MODEL=y
CONFIG_ARCH_SPARSEMEM_ENABLE=y
CONFIG_ARCH_SPARSEMEM_DEFAULT=y
CONFIG_SELECT_MEMORY_MODEL=y
# CONFIG_FLATMEM_MANUAL is not set
# CONFIG_DISCONTIGMEM_MANUAL is not set
CONFIG_SPARSEMEM_MANUAL=y
CONFIG_SPARSEMEM=y
CONFIG_HAVE_MEMORY_PRESENT=y
CONFIG_SPARSEMEM_EXTREME=y
CONFIG_SPARSEMEM_VMEMMAP_ENABLE=y
CONFIG_SPARSEMEM_VMEMMAP=y
CONFIG_PAGEFLAGS_EXTENDED=y
CONFIG_SPLIT_PTLOCK_CPUS=4
CONFIG_PHYS_ADDR_T_64BIT=y
CONFIG_ZONE_DMA_FLAG=0
CONFIG_NR_QUICK=1
CONFIG_UNEVICTABLE_LRU=y
# CONFIG_PREEMPT_NONE is not set
# CONFIG_PREEMPT_VOLUNTARY is not set
CONFIG_PREEMPT=y
# CONFIG_CMDLINE_BOOL is not set

#
# Bus options (PCI etc.)
#
CONFIG_SBUS=y
CONFIG_SBUSCHAR=y
# CONFIG_SUN_LDOMS is not set
CONFIG_PCI=y
CONFIG_PCI_DOMAINS=y
CONFIG_PCI_SYSCALL=y
CONFIG_ARCH_SUPPORTS_MSI=y
CONFIG_PCI_MSI=y
# CONFIG_PCI_LEGACY is not set
CONFIG_PCI_DEBUG=y
# CONFIG_PCI_STUB is not set
# CONFIG_PCCARD is not set
CONFIG_SUN_OPENPROMFS=y
CONFIG_SPARC64_PCI=y

#
# Executable file formats
#
CONFIG_BINFMT_ELF=y
CONFIG_COMPAT_BINFMT_ELF=y
# CONFIG_CORE_DUMP_DEFAULT_ELF_HEADERS is not set
# CONFIG_HAVE_AOUT is not set
# CONFIG_BINFMT_MISC is not set
CONFIG_COMPAT=y
CONFIG_SYSVIPC_COMPAT=y
CONFIG_NET=y

#
# Networking options
#
CONFIG_COMPAT_NET_DEV_OPS=y
CONFIG_PACKET=y
CONFIG_PACKET_MMAP=y
CONFIG_UNIX=y
# CONFIG_NET_KEY is not set
CONFIG_INET=y
# CONFIG_IP_MULTICAST is not set
# CONFIG_IP_ADVANCED_ROUTER is not set
CONFIG_IP_FIB_HASH=y
# CONFIG_IP_PNP is not set
# CONFIG_NET_IPIP is not set
# CONFIG_NET_IPGRE is not set
# CONFIG_ARPD is not set
# CONFIG_SYN_COOKIES is not set
# CONFIG_INET_AH is not set
# CONFIG_INET_ESP is not set
# CONFIG_INET_IPCOMP is not set
# CONFIG_INET_XFRM_TUNNEL is not set
# CONFIG_INET_TUNNEL is not set
# CONFIG_INET_XFRM_MODE_TRANSPORT is not set
# CONFIG_INET_XFRM_MODE_TUNNEL is not set
# CONFIG_INET_XFRM_MODE_BEET is not set
# CONFIG_INET_LRO is not set
# CONFIG_INET_DIAG is not set
# CONFIG_TCP_CONG_ADVANCED is not set
CONFIG_TCP_CONG_CUBIC=y
CONFIG_DEFAULT_TCP_CONG="cubic"
# CONFIG_TCP_MD5SIG is not set
# CONFIG_IPV6 is not set
# CONFIG_NETWORK_SECMARK is not set
# CONFIG_NETFILTER is not set
# CONFIG_IP_DCCP is not set
# CONFIG_IP_SCTP is not set
# CONFIG_TIPC is not set
# CONFIG_ATM is not set
# CONFIG_BRIDGE is not set
# CONFIG_NET_DSA is not set
# CONFIG_VLAN_8021Q is not set
# CONFIG_DECNET is not set
# CONFIG_LLC2 is not set
# CONFIG_IPX is not set
# CONFIG_ATALK is not set
# CONFIG_X25 is not set
# CONFIG_LAPB is not set
# CONFIG_ECONET is not set
# CONFIG_WAN_ROUTER is not set
# CONFIG_NET_SCHED is not set
# CONFIG_DCB is not set

#
# Network testing
#
# CONFIG_NET_PKTGEN is not set
# CONFIG_NET_TCPPROBE is not set
# CONFIG_HAMRADIO is not set
# CONFIG_CAN is not set
# CONFIG_IRDA is not set
# CONFIG_BT is not set
# CONFIG_AF_RXRPC is not set
# CONFIG_PHONET is not set
# CONFIG_WIRELESS is not set
# CONFIG_WIMAX is not set
# CONFIG_RFKILL is not set
# CONFIG_NET_9P is not set

#
# Device Drivers
#

#
# Generic Driver Options
#
CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
CONFIG_STANDALONE=y
# CONFIG_PREVENT_FIRMWARE_BUILD is not set
CONFIG_FW_LOADER=y
# CONFIG_FIRMWARE_IN_KERNEL is not set
CONFIG_EXTRA_FIRMWARE=""
CONFIG_DEBUG_DRIVER=y
CONFIG_DEBUG_DEVRES=y
# CONFIG_SYS_HYPERVISOR is not set
CONFIG_CONNECTOR=y
CONFIG_PROC_EVENTS=y
# CONFIG_MTD is not set
CONFIG_OF_DEVICE=y
# CONFIG_PARPORT is not set
CONFIG_BLK_DEV=y
# CONFIG_BLK_DEV_FD is not set
# CONFIG_BLK_CPQ_CISS_DA is not set
# CONFIG_BLK_DEV_DAC960 is not set
# CONFIG_BLK_DEV_UMEM is not set
# CONFIG_BLK_DEV_COW_COMMON is not set
CONFIG_BLK_DEV_LOOP=y
# CONFIG_BLK_DEV_CRYPTOLOOP is not set
# CONFIG_BLK_DEV_NBD is not set
# CONFIG_BLK_DEV_SX8 is not set
# CONFIG_BLK_DEV_RAM is not set
# CONFIG_CDROM_PKTCDVD is not set
# CONFIG_ATA_OVER_ETH is not set
# CONFIG_BLK_DEV_HD is not set
# CONFIG_MISC_DEVICES is not set
CONFIG_HAVE_IDE=y
# CONFIG_IDE is not set

#
# SCSI device support
#
# CONFIG_RAID_ATTRS is not set
CONFIG_SCSI=y
CONFIG_SCSI_DMA=y
# CONFIG_SCSI_TGT is not set
# CONFIG_SCSI_NETLINK is not set
CONFIG_SCSI_PROC_FS=y

#
# SCSI support type (disk, tape, CD-ROM)
#
CONFIG_BLK_DEV_SD=y
# CONFIG_CHR_DEV_ST is not set
# CONFIG_CHR_DEV_OSST is not set
CONFIG_BLK_DEV_SR=y
CONFIG_BLK_DEV_SR_VENDOR=y
CONFIG_CHR_DEV_SG=y
# CONFIG_CHR_DEV_SCH is not set

#
# Some SCSI devices (e.g. CD jukebox) support multiple LUNs
#
# CONFIG_SCSI_MULTI_LUN is not set
# CONFIG_SCSI_CONSTANTS is not set
# CONFIG_SCSI_LOGGING is not set
# CONFIG_SCSI_SCAN_ASYNC is not set
CONFIG_SCSI_WAIT_SCAN=m

#
# SCSI Transports
#
# CONFIG_SCSI_SPI_ATTRS is not set
# CONFIG_SCSI_FC_ATTRS is not set
# CONFIG_SCSI_ISCSI_ATTRS is not set
# CONFIG_SCSI_SAS_LIBSAS is not set
# CONFIG_SCSI_SRP_ATTRS is not set
# CONFIG_SCSI_LOWLEVEL is not set
# CONFIG_SCSI_DH is not set
CONFIG_ATA=y
# CONFIG_ATA_NONSTANDARD is not set
CONFIG_SATA_PMP=y
# CONFIG_SATA_AHCI is not set
# CONFIG_SATA_SIL24 is not set
CONFIG_ATA_SFF=y
# CONFIG_SATA_SVW is not set
# CONFIG_ATA_PIIX is not set
# CONFIG_SATA_MV is not set
# CONFIG_SATA_NV is not set
# CONFIG_PDC_ADMA is not set
# CONFIG_SATA_QSTOR is not set
# CONFIG_SATA_PROMISE is not set
# CONFIG_SATA_SX4 is not set
# CONFIG_SATA_SIL is not set
# CONFIG_SATA_SIS is not set
# CONFIG_SATA_ULI is not set
# CONFIG_SATA_VIA is not set
# CONFIG_SATA_VITESSE is not set
# CONFIG_SATA_INIC162X is not set
# CONFIG_PATA_ALI is not set
# CONFIG_PATA_AMD is not set
# CONFIG_PATA_ARTOP is not set
# CONFIG_PATA_ATIIXP is not set
# CONFIG_PATA_CMD640_PCI is not set
CONFIG_PATA_CMD64X=y
# CONFIG_PATA_CS5520 is not set
# CONFIG_PATA_CS5530 is not set
# CONFIG_PATA_CYPRESS is not set
# CONFIG_PATA_EFAR is not set
# CONFIG_ATA_GENERIC is not set
# CONFIG_PATA_HPT366 is not set
# CONFIG_PATA_HPT37X is not set
# CONFIG_PATA_HPT3X2N is not set
# CONFIG_PATA_HPT3X3 is not set
# CONFIG_PATA_IT821X is not set
# CONFIG_PATA_IT8213 is not set
# CONFIG_PATA_JMICRON is not set
# CONFIG_PATA_TRIFLEX is not set
# CONFIG_PATA_MARVELL is not set
# CONFIG_PATA_MPIIX is not set
# CONFIG_PATA_OLDPIIX is not set
# CONFIG_PATA_NETCELL is not set
# CONFIG_PATA_NINJA32 is not set
# CONFIG_PATA_NS87410 is not set
# CONFIG_PATA_NS87415 is not set
# CONFIG_PATA_OPTI is not set
# CONFIG_PATA_OPTIDMA is not set
# CONFIG_PATA_PDC_OLD is not set
# CONFIG_PATA_RADISYS is not set
# CONFIG_PATA_RZ1000 is not set
# CONFIG_PATA_SC1200 is not set
# CONFIG_PATA_SERVERWORKS is not set
# CONFIG_PATA_PDC2027X is not set
# CONFIG_PATA_SIL680 is not set
# CONFIG_PATA_SIS is not set
# CONFIG_PATA_VIA is not set
# CONFIG_PATA_WINBOND is not set
# CONFIG_PATA_SCH is not set
# CONFIG_MD is not set
# CONFIG_FUSION is not set

#
# IEEE 1394 (FireWire) support
#

#
# Enable only one of the two stacks, unless you know what you are doing
#
# CONFIG_FIREWIRE is not set
# CONFIG_IEEE1394 is not set
# CONFIG_I2O is not set
CONFIG_NETDEVICES=y
# CONFIG_DUMMY is not set
# CONFIG_BONDING is not set
# CONFIG_MACVLAN is not set
# CONFIG_EQUALIZER is not set
# CONFIG_TUN is not set
# CONFIG_VETH is not set
# CONFIG_ARCNET is not set
# CONFIG_PHYLIB is not set
CONFIG_NET_ETHERNET=y
# CONFIG_MII is not set
# CONFIG_SUNLANCE is not set
CONFIG_HAPPYMEAL=y
# CONFIG_SUNBMAC is not set
# CONFIG_SUNQE is not set
# CONFIG_SUNGEM is not set
# CONFIG_CASSINI is not set
# CONFIG_NET_VENDOR_3COM is not set
# CONFIG_DNET is not set
# CONFIG_NET_TULIP is not set
# CONFIG_HP100 is not set
# CONFIG_IBM_NEW_EMAC_ZMII is not set
# CONFIG_IBM_NEW_EMAC_RGMII is not set
# CONFIG_IBM_NEW_EMAC_TAH is not set
# CONFIG_IBM_NEW_EMAC_EMAC4 is not set
# CONFIG_IBM_NEW_EMAC_NO_FLOW_CTRL is not set
# CONFIG_IBM_NEW_EMAC_MAL_CLR_ICINTSTAT is not set
# CONFIG_IBM_NEW_EMAC_MAL_COMMON_ERR is not set
# CONFIG_NET_PCI is not set
# CONFIG_B44 is not set
# CONFIG_ATL2 is not set
# CONFIG_NETDEV_1000 is not set
# CONFIG_NETDEV_10000 is not set
# CONFIG_TR is not set

#
# Wireless LAN
#
# CONFIG_WLAN_PRE80211 is not set
# CONFIG_WLAN_80211 is not set
# CONFIG_IWLWIFI_LEDS is not set

#
# Enable WiMAX (Networking options) to see the WiMAX drivers
#
# CONFIG_WAN is not set
# CONFIG_FDDI is not set
# CONFIG_HIPPI is not set
# CONFIG_PPP is not set
# CONFIG_SLIP is not set
# CONFIG_NET_FC is not set
CONFIG_NETCONSOLE=y
CONFIG_NETCONSOLE_DYNAMIC=y
CONFIG_NETPOLL=y
CONFIG_NETPOLL_TRAP=y
CONFIG_NET_POLL_CONTROLLER=y
# CONFIG_ISDN is not set
# CONFIG_PHONE is not set

#
# Input device support
#
CONFIG_INPUT=y
# CONFIG_INPUT_FF_MEMLESS is not set
# CONFIG_INPUT_POLLDEV is not set

#
# Userland interfaces
#
CONFIG_INPUT_MOUSEDEV=y
CONFIG_INPUT_MOUSEDEV_PSAUX=y
CONFIG_INPUT_MOUSEDEV_SCREEN_X=1024
CONFIG_INPUT_MOUSEDEV_SCREEN_Y=768
# CONFIG_INPUT_JOYDEV is not set
CONFIG_INPUT_EVDEV=y
# CONFIG_INPUT_EVBUG is not set

#
# Input Device Drivers
#
CONFIG_INPUT_KEYBOARD=y
# CONFIG_KEYBOARD_ATKBD is not set
CONFIG_KEYBOARD_SUNKBD=y
# CONFIG_KEYBOARD_LKKBD is not set
# CONFIG_KEYBOARD_XTKBD is not set
# CONFIG_KEYBOARD_NEWTON is not set
# CONFIG_KEYBOARD_STOWAWAY is not set
# CONFIG_INPUT_MOUSE is not set
# CONFIG_INPUT_JOYSTICK is not set
# CONFIG_INPUT_TABLET is not set
# CONFIG_INPUT_TOUCHSCREEN is not set
# CONFIG_INPUT_MISC is not set

#
# Hardware I/O ports
#
CONFIG_SERIO=y
# CONFIG_SERIO_I8042 is not set
# CONFIG_SERIO_SERPORT is not set
# CONFIG_SERIO_PCIPS2 is not set
# CONFIG_SERIO_RAW is not set
# CONFIG_GAMEPORT is not set

#
# Character devices
#
CONFIG_VT=y
CONFIG_CONSOLE_TRANSLATIONS=y
CONFIG_VT_CONSOLE=y
CONFIG_HW_CONSOLE=y
# CONFIG_VT_HW_CONSOLE_BINDING is not set
CONFIG_DEVKMEM=y
# CONFIG_SERIAL_NONSTANDARD is not set
# CONFIG_NOZOMI is not set

#
# Serial drivers
#
# CONFIG_SERIAL_8250 is not set

#
# Non-8250 serial port support
#
CONFIG_SERIAL_SUNCORE=y
# CONFIG_SERIAL_SUNZILOG is not set
CONFIG_SERIAL_SUNSU=y
CONFIG_SERIAL_SUNSU_CONSOLE=y
# CONFIG_SERIAL_SUNSAB is not set
# CONFIG_SERIAL_SUNHV is not set
CONFIG_SERIAL_CORE=y
CONFIG_SERIAL_CORE_CONSOLE=y
# CONFIG_SERIAL_JSM is not set
CONFIG_UNIX98_PTYS=y
# CONFIG_DEVPTS_MULTIPLE_INSTANCES is not set
# CONFIG_LEGACY_PTYS is not set
# CONFIG_IPMI_HANDLER is not set
# CONFIG_HW_RANDOM is not set
# CONFIG_R3964 is not set
# CONFIG_APPLICOM is not set
# CONFIG_RAW_DRIVER is not set
# CONFIG_TCG_TPM is not set
CONFIG_DEVPORT=y
# CONFIG_I2C is not set
# CONFIG_SPI is not set
CONFIG_ARCH_WANT_OPTIONAL_GPIOLIB=y
# CONFIG_GPIOLIB is not set
# CONFIG_W1 is not set
# CONFIG_POWER_SUPPLY is not set
# CONFIG_HWMON is not set
# CONFIG_THERMAL is not set
# CONFIG_THERMAL_HWMON is not set
# CONFIG_WATCHDOG is not set
CONFIG_SSB_POSSIBLE=y

#
# Sonics Silicon Backplane
#
# CONFIG_SSB is not set

#
# Multifunction device drivers
#
# CONFIG_MFD_CORE is not set
# CONFIG_MFD_SM501 is not set
# CONFIG_HTC_PASIC3 is not set
# CONFIG_MFD_TMIO is not set
# CONFIG_REGULATOR is not set

#
# Multimedia devices
#

#
# Multimedia core support
#
# CONFIG_VIDEO_DEV is not set
# CONFIG_DVB_CORE is not set
# CONFIG_VIDEO_MEDIA is not set

#
# Multimedia drivers
#
# CONFIG_DAB is not set

#
# Graphics support
#
# CONFIG_DRM is not set
# CONFIG_VGASTATE is not set
# CONFIG_VIDEO_OUTPUT_CONTROL is not set
CONFIG_FB=y
# CONFIG_FIRMWARE_EDID is not set
# CONFIG_FB_DDC is not set
# CONFIG_FB_BOOT_VESA_SUPPORT is not set
CONFIG_FB_CFB_FILLRECT=y
CONFIG_FB_CFB_COPYAREA=y
CONFIG_FB_CFB_IMAGEBLIT=y
# CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set
# CONFIG_FB_SYS_FILLRECT is not set
# CONFIG_FB_SYS_COPYAREA is not set
# CONFIG_FB_SYS_IMAGEBLIT is not set
# CONFIG_FB_FOREIGN_ENDIAN is not set
# CONFIG_FB_SYS_FOPS is not set
# CONFIG_FB_SVGALIB is not set
# CONFIG_FB_MACMODES is not set
# CONFIG_FB_BACKLIGHT is not set
CONFIG_FB_MODE_HELPERS=y
CONFIG_FB_TILEBLITTING=y

#
# Frame buffer hardware drivers
#
# CONFIG_FB_CIRRUS is not set
# CONFIG_FB_PM2 is not set
# CONFIG_FB_ASILIANT is not set
# CONFIG_FB_IMSTT is not set
# CONFIG_FB_UVESA is not set
CONFIG_FB_SBUS=y
# CONFIG_FB_BW2 is not set
# CONFIG_FB_CG3 is not set
# CONFIG_FB_CG6 is not set
CONFIG_FB_FFB=y
# CONFIG_FB_TCX is not set
# CONFIG_FB_CG14 is not set
# CONFIG_FB_P9100 is not set
# CONFIG_FB_LEO is not set
# CONFIG_FB_XVR500 is not set
# CONFIG_FB_XVR2500 is not set
# CONFIG_FB_S1D13XXX is not set
# CONFIG_FB_NVIDIA is not set
# CONFIG_FB_RIVA is not set
# CONFIG_FB_MATROX is not set
# CONFIG_FB_RADEON is not set
# CONFIG_FB_ATY128 is not set
CONFIG_FB_ATY=y
CONFIG_FB_ATY_CT=y
# CONFIG_FB_ATY_GENERIC_LCD is not set
# CONFIG_FB_ATY_GX is not set
# CONFIG_FB_ATY_BACKLIGHT is not set
# CONFIG_FB_S3 is not set
# CONFIG_FB_SAVAGE is not set
# CONFIG_FB_SIS is not set
# CONFIG_FB_VIA is not set
# CONFIG_FB_NEOMAGIC is not set
# CONFIG_FB_KYRO is not set
# CONFIG_FB_3DFX is not set
# CONFIG_FB_VOODOO1 is not set
# CONFIG_FB_VT8623 is not set
# CONFIG_FB_TRIDENT is not set
# CONFIG_FB_ARK is not set
# CONFIG_FB_PM3 is not set
# CONFIG_FB_CARMINE is not set
# CONFIG_FB_VIRTUAL is not set
# CONFIG_FB_METRONOME is not set
# CONFIG_FB_MB862XX is not set
# CONFIG_BACKLIGHT_LCD_SUPPORT is not set

#
# Display device support
#
# CONFIG_DISPLAY_SUPPORT is not set

#
# Console display driver support
#
CONFIG_PROM_CONSOLE=y
CONFIG_DUMMY_CONSOLE=y
CONFIG_FRAMEBUFFER_CONSOLE=y
CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY=y
# CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set
CONFIG_FONTS=y
# CONFIG_FONT_8x8 is not set
# CONFIG_FONT_8x16 is not set
# CONFIG_FONT_6x11 is not set
# CONFIG_FONT_7x14 is not set
# CONFIG_FONT_PEARL_8x8 is not set
# CONFIG_FONT_ACORN_8x8 is not set
CONFIG_FONT_SUN8x16=y
# CONFIG_FONT_SUN12x22 is not set
# CONFIG_FONT_10x18 is not set
CONFIG_LOGO=y
# CONFIG_LOGO_LINUX_MONO is not set
# CONFIG_LOGO_LINUX_VGA16 is not set
# CONFIG_LOGO_LINUX_CLUT224 is not set
CONFIG_LOGO_SUN_CLUT224=y
# CONFIG_SOUND is not set
# CONFIG_HID_SUPPORT is not set
# CONFIG_USB_SUPPORT is not set
# CONFIG_UWB is not set
# CONFIG_MMC is not set
# CONFIG_MEMSTICK is not set
# CONFIG_NEW_LEDS is not set
# CONFIG_ACCESSIBILITY is not set
# CONFIG_INFINIBAND is not set
CONFIG_RTC_LIB=y
CONFIG_RTC_CLASS=y
CONFIG_RTC_HCTOSYS=y
CONFIG_RTC_HCTOSYS_DEVICE="rtc0"
# CONFIG_RTC_DEBUG is not set

#
# RTC interfaces
#
CONFIG_RTC_INTF_SYSFS=y
CONFIG_RTC_INTF_PROC=y
CONFIG_RTC_INTF_DEV=y
# CONFIG_RTC_INTF_DEV_UIE_EMUL is not set
# CONFIG_RTC_DRV_TEST is not set

#
# SPI RTC drivers
#

#
# Platform RTC drivers
#
CONFIG_RTC_DRV_CMOS=y
# CONFIG_RTC_DRV_DS1286 is not set
# CONFIG_RTC_DRV_DS1511 is not set
# CONFIG_RTC_DRV_DS1553 is not set
# CONFIG_RTC_DRV_DS1742 is not set
# CONFIG_RTC_DRV_STK17TA8 is not set
# CONFIG_RTC_DRV_M48T86 is not set
# CONFIG_RTC_DRV_M48T35 is not set
CONFIG_RTC_DRV_M48T59=y
CONFIG_RTC_DRV_BQ4802=y
# CONFIG_RTC_DRV_V3020 is not set

#
# on-CPU RTC drivers
#
CONFIG_RTC_DRV_SUN4V=y
CONFIG_RTC_DRV_STARFIRE=y
# CONFIG_DMADEVICES is not set
# CONFIG_UIO is not set
CONFIG_STAGING=y
# CONFIG_STAGING_EXCLUDE_BUILD is not set
# CONFIG_ME4000 is not set
# CONFIG_MEILHAUS is not set
# CONFIG_ECHO is not set
# CONFIG_BENET is not set
# CONFIG_COMEDI is not set
# CONFIG_ALTERA_PCIE_CHDMA is not set

#
# Android
#
# CONFIG_ANDROID is not set
# CONFIG_ANDROID_BINDER_IPC is not set
# CONFIG_ANDROID_LOGGER is not set
# CONFIG_ANDROID_RAM_CONSOLE is not set
# CONFIG_ANDROID_LOW_MEMORY_KILLER is not set

#
# Misc Linux/SPARC drivers
#
CONFIG_SUN_OPENPROMIO=y
# CONFIG_OBP_FLASH is not set
# CONFIG_TADPOLE_TS102_UCTRL is not set
# CONFIG_BBC_I2C is not set
# CONFIG_ENVCTRL is not set
# CONFIG_DISPLAY7SEG is not set

#
# File systems
#
CONFIG_EXT2_FS=y
# CONFIG_EXT2_FS_XATTR is not set
# CONFIG_EXT2_FS_XIP is not set
CONFIG_EXT3_FS=y
# CONFIG_EXT3_FS_XATTR is not set
CONFIG_EXT4_FS=y
CONFIG_EXT4DEV_COMPAT=y
# CONFIG_EXT4_FS_XATTR is not set
CONFIG_JBD=y
CONFIG_JBD_DEBUG=y
CONFIG_JBD2=y
CONFIG_JBD2_DEBUG=y
# CONFIG_REISERFS_FS is not set
# CONFIG_JFS_FS is not set
# CONFIG_FS_POSIX_ACL is not set
CONFIG_FILE_LOCKING=y
# CONFIG_XFS_FS is not set
# CONFIG_GFS2_FS is not set
# CONFIG_OCFS2_FS is not set
CONFIG_BTRFS_FS=y
# CONFIG_BTRFS_FS_POSIX_ACL is not set
CONFIG_DNOTIFY=y
CONFIG_INOTIFY=y
CONFIG_INOTIFY_USER=y
# CONFIG_QUOTA is not set
# CONFIG_AUTOFS_FS is not set
# CONFIG_AUTOFS4_FS is not set
# CONFIG_FUSE_FS is not set

#
# CD-ROM/DVD Filesystems
#
# CONFIG_ISO9660_FS is not set
# CONFIG_UDF_FS is not set

#
# DOS/FAT/NT Filesystems
#
# CONFIG_MSDOS_FS is not set
# CONFIG_VFAT_FS is not set
# CONFIG_NTFS_FS is not set

#
# Pseudo filesystems
#
CONFIG_PROC_FS=y
CONFIG_PROC_KCORE=y
CONFIG_PROC_SYSCTL=y
CONFIG_PROC_PAGE_MONITOR=y
CONFIG_SYSFS=y
CONFIG_TMPFS=y
# CONFIG_TMPFS_POSIX_ACL is not set
# CONFIG_HUGETLBFS is not set
# CONFIG_HUGETLB_PAGE is not set
CONFIG_CONFIGFS_FS=y
# CONFIG_MISC_FILESYSTEMS is not set
CONFIG_NETWORK_FILESYSTEMS=y
CONFIG_NFS_FS=y
CONFIG_NFS_V3=y
# CONFIG_NFS_V3_ACL is not set
# CONFIG_NFS_V4 is not set
CONFIG_NFSD=y
CONFIG_NFSD_V3=y
# CONFIG_NFSD_V3_ACL is not set
# CONFIG_NFSD_V4 is not set
CONFIG_LOCKD=y
CONFIG_LOCKD_V4=y
CONFIG_EXPORTFS=y
CONFIG_NFS_COMMON=y
CONFIG_SUNRPC=y
# CONFIG_SUNRPC_REGISTER_V4 is not set
# CONFIG_RPCSEC_GSS_KRB5 is not set
# CONFIG_RPCSEC_GSS_SPKM3 is not set
# CONFIG_SMB_FS is not set
# CONFIG_CIFS is not set
# CONFIG_NCP_FS is not set
# CONFIG_CODA_FS is not set
# CONFIG_AFS_FS is not set

#
# Partition Types
#
# CONFIG_PARTITION_ADVANCED is not set
CONFIG_MSDOS_PARTITION=y
CONFIG_SUN_PARTITION=y
# CONFIG_NLS is not set
# CONFIG_DLM is not set

#
# Kernel hacking
#
CONFIG_TRACE_IRQFLAGS_SUPPORT=y
CONFIG_PRINTK_TIME=y
CONFIG_ENABLE_WARN_DEPRECATED=y
CONFIG_ENABLE_MUST_CHECK=y
CONFIG_FRAME_WARN=2048
CONFIG_MAGIC_SYSRQ=y
# CONFIG_UNUSED_SYMBOLS is not set
CONFIG_DEBUG_FS=y
# CONFIG_HEADERS_CHECK is not set
CONFIG_DEBUG_KERNEL=y
CONFIG_DEBUG_SHIRQ=y
CONFIG_DETECT_SOFTLOCKUP=y
# CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC is not set
CONFIG_BOOTPARAM_SOFTLOCKUP_PANIC_VALUE=0
# CONFIG_SCHED_DEBUG is not set
# CONFIG_SCHEDSTATS is not set
# CONFIG_TIMER_STATS is not set
# CONFIG_DEBUG_OBJECTS is not set
# CONFIG_SLUB_DEBUG_ON is not set
# CONFIG_SLUB_STATS is not set
CONFIG_DEBUG_PREEMPT=y
CONFIG_DEBUG_RT_MUTEXES=y
CONFIG_DEBUG_PI_LIST=y
# CONFIG_RT_MUTEX_TESTER is not set
CONFIG_DEBUG_SPINLOCK=y
CONFIG_DEBUG_MUTEXES=y
CONFIG_DEBUG_LOCK_ALLOC=y
CONFIG_PROVE_LOCKING=y
CONFIG_LOCKDEP=y
# CONFIG_LOCK_STAT is not set
CONFIG_DEBUG_LOCKDEP=y
CONFIG_TRACE_IRQFLAGS=y
CONFIG_DEBUG_SPINLOCK_SLEEP=y
CONFIG_DEBUG_LOCKING_API_SELFTESTS=y
CONFIG_STACKTRACE=y
# CONFIG_DEBUG_KOBJECT is not set
CONFIG_DEBUG_BUGVERBOSE=y
CONFIG_DEBUG_INFO=y
CONFIG_DEBUG_VM=y
# CONFIG_DEBUG_WRITECOUNT is not set
CONFIG_DEBUG_MEMORY_INIT=y
CONFIG_DEBUG_LIST=y
CONFIG_DEBUG_SG=y
# CONFIG_DEBUG_NOTIFIERS is not set
CONFIG_FRAME_POINTER=y
# CONFIG_BOOT_PRINTK_DELAY is not set
# CONFIG_RCU_TORTURE_TEST is not set
CONFIG_KPROBES_SANITY_TEST=y
# CONFIG_BACKTRACE_SELF_TEST is not set
# CONFIG_DEBUG_BLOCK_EXT_DEVT is not set
# CONFIG_LKDTM is not set
# CONFIG_FAULT_INJECTION is not set
# CONFIG_LATENCYTOP is not set
CONFIG_SYSCTL_SYSCALL_CHECK=y
CONFIG_HAVE_FUNCTION_TRACER=y

#
# Tracers
#
# CONFIG_FUNCTION_TRACER is not set
# CONFIG_IRQSOFF_TRACER is not set
# CONFIG_PREEMPT_TRACER is not set
# CONFIG_SCHED_TRACER is not set
# CONFIG_CONTEXT_SWITCH_TRACER is not set
# CONFIG_BOOT_TRACER is not set
# CONFIG_TRACE_BRANCH_PROFILING is not set
# CONFIG_STACK_TRACER is not set
CONFIG_DYNAMIC_PRINTK_DEBUG=y
# CONFIG_SAMPLES is not set
CONFIG_HAVE_ARCH_KGDB=y
# CONFIG_KGDB is not set
# CONFIG_DEBUG_STACK_USAGE is not set
CONFIG_DEBUG_DCFLUSH=y
CONFIG_STACK_DEBUG=y
CONFIG_DEBUG_PAGEALLOC=y
CONFIG_MCOUNT=y

#
# Security options
#
# CONFIG_KEYS is not set
# CONFIG_SECURITY is not set
# CONFIG_SECURITYFS is not set
# CONFIG_SECURITY_FILE_CAPABILITIES is not set
CONFIG_CRYPTO=y

#
# Crypto core or helper
#
# CONFIG_CRYPTO_FIPS is not set
CONFIG_CRYPTO_ALGAPI=y
CONFIG_CRYPTO_ALGAPI2=y
CONFIG_CRYPTO_AEAD2=y
CONFIG_CRYPTO_BLKCIPHER2=y
CONFIG_CRYPTO_HASH=y
CONFIG_CRYPTO_HASH2=y
CONFIG_CRYPTO_RNG2=y
CONFIG_CRYPTO_MANAGER=y
CONFIG_CRYPTO_MANAGER2=y
# CONFIG_CRYPTO_GF128MUL is not set
# CONFIG_CRYPTO_NULL is not set
# CONFIG_CRYPTO_CRYPTD is not set
# CONFIG_CRYPTO_AUTHENC is not set
# CONFIG_CRYPTO_TEST is not set

#
# Authenticated Encryption with Associated Data
#
# CONFIG_CRYPTO_CCM is not set
# CONFIG_CRYPTO_GCM is not set
# CONFIG_CRYPTO_SEQIV is not set

#
# Block modes
#
# CONFIG_CRYPTO_CBC is not set
# CONFIG_CRYPTO_CTR is not set
# CONFIG_CRYPTO_CTS is not set
# CONFIG_CRYPTO_ECB is not set
# CONFIG_CRYPTO_LRW is not set
# CONFIG_CRYPTO_PCBC is not set
# CONFIG_CRYPTO_XTS is not set

#
# Hash modes
#
CONFIG_CRYPTO_HMAC=y
# CONFIG_CRYPTO_XCBC is not set

#
# Digest
#
CONFIG_CRYPTO_CRC32C=y
# CONFIG_CRYPTO_MD4 is not set
# CONFIG_CRYPTO_MD5 is not set
# CONFIG_CRYPTO_MICHAEL_MIC is not set
# CONFIG_CRYPTO_RMD128 is not set
# CONFIG_CRYPTO_RMD160 is not set
# CONFIG_CRYPTO_RMD256 is not set
# CONFIG_CRYPTO_RMD320 is not set
# CONFIG_CRYPTO_SHA1 is not set
# CONFIG_CRYPTO_SHA256 is not set
# CONFIG_CRYPTO_SHA512 is not set
# CONFIG_CRYPTO_TGR192 is not set
# CONFIG_CRYPTO_WP512 is not set

#
# Ciphers
#
# CONFIG_CRYPTO_AES is not set
# CONFIG_CRYPTO_ANUBIS is not set
# CONFIG_CRYPTO_ARC4 is not set
# CONFIG_CRYPTO_BLOWFISH is not set
# CONFIG_CRYPTO_CAMELLIA is not set
# CONFIG_CRYPTO_CAST5 is not set
# CONFIG_CRYPTO_CAST6 is not set
# CONFIG_CRYPTO_DES is not set
# CONFIG_CRYPTO_FCRYPT is not set
# CONFIG_CRYPTO_KHAZAD is not set
# CONFIG_CRYPTO_SALSA20 is not set
# CONFIG_CRYPTO_SEED is not set
# CONFIG_CRYPTO_SERPENT is not set
# CONFIG_CRYPTO_TEA is not set
# CONFIG_CRYPTO_TWOFISH is not set

#
# Compression
#
# CONFIG_CRYPTO_DEFLATE is not set
# CONFIG_CRYPTO_LZO is not set

#
# Random Number Generation
#
# CONFIG_CRYPTO_ANSI_CPRNG is not set
# CONFIG_CRYPTO_HW is not set

#
# Library routines
#
CONFIG_BITREVERSE=y
CONFIG_GENERIC_FIND_LAST_BIT=y
# CONFIG_CRC_CCITT is not set
CONFIG_CRC16=y
CONFIG_CRC_T10DIF=y
# CONFIG_CRC_ITU_T is not set
CONFIG_CRC32=y
# CONFIG_CRC7 is not set
CONFIG_LIBCRC32C=y
CONFIG_ZLIB_INFLATE=y
CONFIG_ZLIB_DEFLATE=y
CONFIG_PLIST=y
CONFIG_HAS_IOMEM=y
CONFIG_HAS_IOPORT=y
CONFIG_HAS_DMA=y
CONFIG_HAVE_LMB=y

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-25 15:29                 ` Alexander Beregalov
@ 2009-03-25 16:15                   ` Jan Kara
  2009-03-25 17:07                     ` Alexander Beregalov
  0 siblings, 1 reply; 24+ messages in thread
From: Jan Kara @ 2009-03-25 16:15 UTC (permalink / raw)
  To: Alexander Beregalov; +Cc: Theodore Tso, linux-next, linux-ext4, LKML

On Wed 25-03-09 18:29:10, Alexander Beregalov wrote:
> 2009/3/25 Jan Kara <jack@suse.cz>:
> > On Wed 25-03-09 18:18:43, Alexander Beregalov wrote:
> >> 2009/3/25 Jan Kara <jack@suse.cz>:
> >> >> > So, I think I need to try it on 2.6.29-rc7 again.
> >> >>   I've looked into this. Obviously, what's happenning is that we delete
> >> >> an inode and jbd2_journal_release_jbd_inode() finds inode is just under
> >> >> writeout in transaction commit and thus it waits. But it gets never woken
> >> >> up and because it has a handle from the transaction, every one eventually
> >> >> blocks on waiting for a transaction to finish.
> >> >>   But I don't really see how that can happen. The code is really
> >> >> straightforward and everything happens under j_list_lock... Strange.
> >> >  BTW: Is the system SMP?
> >> No, it is UP system.
> >  Even stranger. And do you have CONFIG_PREEMPT set?
> >
> >> The bug exists even in 2.6.29, I posted it with a new topic.
> >  OK, I've sort-of expected this.
> 
> CONFIG_PREEMPT_RCU=y
> CONFIG_PREEMPT_RCU_TRACE=y
> # CONFIG_PREEMPT_NONE is not set
> # CONFIG_PREEMPT_VOLUNTARY is not set
> CONFIG_PREEMPT=y
> CONFIG_DEBUG_PREEMPT=y
> # CONFIG_PREEMPT_TRACER is not set
> 
> config is attached.
  Thanks for the data. I still don't see how the wakeup can get lost. The
process even cannot be preempted when we are in the section protected by
j_list_lock... Can you send me a disassembly of functions
jbd2_journal_release_jbd_inode() and journal_submit_data_buffers() so that
I can see whether the compiler has not reordered something unexpectedly?
Thanks.

								Honza
-- 
Jan Kara <jack@suse.cz>
SUSE Labs, CR
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-25 16:15                   ` Jan Kara
@ 2009-03-25 17:07                     ` Alexander Beregalov
  2009-03-25 19:43                       ` Jan Kara
  0 siblings, 1 reply; 24+ messages in thread
From: Alexander Beregalov @ 2009-03-25 17:07 UTC (permalink / raw)
  To: Jan Kara; +Cc: Theodore Tso, linux-next, linux-ext4, LKML

[-- Attachment #1: Type: text/plain, Size: 13792 bytes --]

2009/3/25 Jan Kara <jack@suse.cz>:
> On Wed 25-03-09 18:29:10, Alexander Beregalov wrote:
>> 2009/3/25 Jan Kara <jack@suse.cz>:
>> > On Wed 25-03-09 18:18:43, Alexander Beregalov wrote:
>> >> 2009/3/25 Jan Kara <jack@suse.cz>:
>> >> >> > So, I think I need to try it on 2.6.29-rc7 again.
>> >> >>   I've looked into this. Obviously, what's happenning is that we delete
>> >> >> an inode and jbd2_journal_release_jbd_inode() finds inode is just under
>> >> >> writeout in transaction commit and thus it waits. But it gets never woken
>> >> >> up and because it has a handle from the transaction, every one eventually
>> >> >> blocks on waiting for a transaction to finish.
>> >> >>   But I don't really see how that can happen. The code is really
>> >> >> straightforward and everything happens under j_list_lock... Strange.
>> >> >  BTW: Is the system SMP?
>> >> No, it is UP system.
>> >  Even stranger. And do you have CONFIG_PREEMPT set?
>> >
>> >> The bug exists even in 2.6.29, I posted it with a new topic.
>> >  OK, I've sort-of expected this.
>>
>> CONFIG_PREEMPT_RCU=y
>> CONFIG_PREEMPT_RCU_TRACE=y
>> # CONFIG_PREEMPT_NONE is not set
>> # CONFIG_PREEMPT_VOLUNTARY is not set
>> CONFIG_PREEMPT=y
>> CONFIG_DEBUG_PREEMPT=y
>> # CONFIG_PREEMPT_TRACER is not set
>>
>> config is attached.
>  Thanks for the data. I still don't see how the wakeup can get lost. The
> process even cannot be preempted when we are in the section protected by
> j_list_lock... Can you send me a disassembly of functions
> jbd2_journal_release_jbd_inode() and journal_submit_data_buffers() so that
> I can see whether the compiler has not reordered something unexpectedly?

void jbd2_journal_release_jbd_inode(journal_t *journal,
                                    struct jbd2_inode *jinode)
{
     6d8:       9d e3 bf 00     save  %sp, -256, %sp
     6dc:       11 00 00 00     sethi  %hi(0), %o0
     6e0:       40 00 00 00     call  6e0 <jbd2_journal_release_jbd_inode+0x8>
     6e4:       90 12 20 00     mov  %o0, %o0   ! 0 <jbd2_history_skip_empty>
        int writeout = 0;

        if (!journal)
     6e8:       02 c6 00 30     brz,pn   %i0, 7a8
<jbd2_journal_release_jbd_inode+0xd0>
     6ec:       03 00 00 00     sethi  %hi(0), %g1
                return;
restart:
        spin_lock(&journal->j_list_lock);
     6f0:       b0 06 25 70     add  %i0, 0x570, %i0
        /* Is commit writing out inode - we have to wait */
        if (jinode->i_flags & JI_COMMIT_RUNNING) {
                wait_queue_head_t *wq;
                DEFINE_WAIT_BIT(wait, &jinode->i_flags, __JI_COMMIT_RUNNING);
     6f4:       aa 10 60 00     mov  %g1, %l5
     6f8:       a2 06 60 28     add  %i1, 0x28, %l1
     6fc:       a8 07 a7 b7     add  %fp, 0x7b7, %l4
     700:       a6 07 a7 df     add  %fp, 0x7df, %l3
                wq = bit_waitqueue(&jinode->i_flags, __JI_COMMIT_RUNNING);
                prepare_to_wait(wq, &wait.wait, TASK_UNINTERRUPTIBLE);
     704:       a4 07 a7 c7     add  %fp, 0x7c7, %l2
        int writeout = 0;

        if (!journal)
                return;
restart:
        spin_lock(&journal->j_list_lock);
     708:       40 00 00 00     call  708 <jbd2_journal_release_jbd_inode+0x30>
     70c:       90 10 00 18     mov  %i0, %o0
        /* Is commit writing out inode - we have to wait */
        if (jinode->i_flags & JI_COMMIT_RUNNING) {
     710:       c2 06 60 28     ld  [ %i1 + 0x28 ], %g1
                wait_queue_head_t *wq;
                DEFINE_WAIT_BIT(wait, &jinode->i_flags, __JI_COMMIT_RUNNING);
     714:       94 10 20 38     mov  0x38, %o2
     718:       90 10 00 14     mov  %l4, %o0
     71c:       92 10 20 00     clr  %o1
        if (!journal)
                return;
restart:
        spin_lock(&journal->j_list_lock);
        /* Is commit writing out inode - we have to wait */
        if (jinode->i_flags & JI_COMMIT_RUNNING) {
     720:       80 88 60 01     btst  1, %g1
     724:       02 60 00 19     be,pn   %xcc, 788
<jbd2_journal_release_jbd_inode+0xb0>
     728:       a0 10 00 04     mov  %g4, %l0
                wait_queue_head_t *wq;
                DEFINE_WAIT_BIT(wait, &jinode->i_flags, __JI_COMMIT_RUNNING);
     72c:       40 00 00 00     call  72c <jbd2_journal_release_jbd_inode+0x54>
     730:       01 00 00 00     nop
                wq = bit_waitqueue(&jinode->i_flags, __JI_COMMIT_RUNNING);
     734:       90 10 00 11     mov  %l1, %o0
     738:       92 10 20 00     clr  %o1
restart:
        spin_lock(&journal->j_list_lock);
        /* Is commit writing out inode - we have to wait */
        if (jinode->i_flags & JI_COMMIT_RUNNING) {
                wait_queue_head_t *wq;
                DEFINE_WAIT_BIT(wait, &jinode->i_flags, __JI_COMMIT_RUNNING);
     73c:       e0 77 a7 cf     stx  %l0, [ %fp + 0x7cf ]
     740:       e2 77 a7 b7     stx  %l1, [ %fp + 0x7b7 ]
     744:       ea 77 a7 d7     stx  %l5, [ %fp + 0x7d7 ]
     748:       e6 77 a7 df     stx  %l3, [ %fp + 0x7df ]
                wq = bit_waitqueue(&jinode->i_flags, __JI_COMMIT_RUNNING);
     74c:       40 00 00 00     call  74c <jbd2_journal_release_jbd_inode+0x74>
     750:       e6 77 a7 e7     stx  %l3, [ %fp + 0x7e7 ]
                prepare_to_wait(wq, &wait.wait, TASK_UNINTERRUPTIBLE);
     754:       92 10 00 12     mov  %l2, %o1
     758:       94 10 20 02     mov  2, %o2
     75c:       40 00 00 00     call  75c <jbd2_journal_release_jbd_inode+0x84>
     760:       a0 10 00 08     mov  %o0, %l0
                spin_unlock(&journal->j_list_lock);
     764:       40 00 00 00     call  764 <jbd2_journal_release_jbd_inode+0x8c>
     768:       90 10 00 18     mov  %i0, %o0
                schedule();
     76c:       40 00 00 00     call  76c <jbd2_journal_release_jbd_inode+0x94>
     770:       01 00 00 00     nop
                finish_wait(wq, &wait.wait);
     774:       90 10 00 10     mov  %l0, %o0
     778:       40 00 00 00     call  778 <jbd2_journal_release_jbd_inode+0xa0>
     77c:       92 10 00 12     mov  %l2, %o1
     780:       10 6f ff e2     b  %xcc, 708
<jbd2_journal_release_jbd_inode+0x30>
     784:       01 00 00 00     nop
        }

        /* Do we need to wait for data writeback? */
        if (journal->j_committing_transaction == jinode->i_transaction)
                writeout = 1;
        if (jinode->i_transaction) {
     788:       c2 5e 40 00     ldx  [ %i1 ], %g1
     78c:       02 c0 40 05     brz,pn   %g1, 7a0
<jbd2_journal_release_jbd_inode+0xc8>
     790:       01 00 00 00     nop
                list_del(&jinode->i_list);
     794:       40 00 00 00     call  794 <jbd2_journal_release_jbd_inode+0xbc>
     798:       90 06 60 10     add  %i1, 0x10, %o0
                jinode->i_transaction = NULL;
     79c:       c0 76 40 00     clrx  [ %i1 ]
        }
        spin_unlock(&journal->j_list_lock);
     7a0:       40 00 00 00     call  7a0 <jbd2_journal_release_jbd_inode+0xc8>
     7a4:       90 10 00 18     mov  %i0, %o0
     7a8:       81 cf e0 08     rett  %i7 + 8
     7ac:       01 00 00 00     nop

====
By default gcc inlines journal_submit_data_buffers()
Here is -fno-inline version. Default version is in attach.
====

static int journal_submit_data_buffers(journal_t *journal,
                transaction_t *commit_transaction)
{
      9c:       9d e3 bf 40     save  %sp, -192, %sp
      a0:       11 00 00 00     sethi  %hi(0), %o0
        struct jbd2_inode *jinode;
        int err, ret = 0;
        struct address_space *mapping;

        spin_lock(&journal->j_list_lock);
      a4:       a4 06 25 70     add  %i0, 0x570, %l2
 * our inode list. We use JI_COMMIT_RUNNING flag to protect inode we currently
 * operate on from being released while we write out pages.
 */
static int journal_submit_data_buffers(journal_t *journal,
                transaction_t *commit_transaction)
{
      a8:       90 12 20 00     mov  %o0, %o0
      ac:       40 00 00 00     call  ac <journal_submit_data_buffers+0x10>
      b0:       b0 10 20 00     clr  %i0
        struct jbd2_inode *jinode;
        int err, ret = 0;
        struct address_space *mapping;

        spin_lock(&journal->j_list_lock);
        list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
      b4:       a6 06 60 60     add  %i1, 0x60, %l3
{
        struct jbd2_inode *jinode;
        int err, ret = 0;
        struct address_space *mapping;

        spin_lock(&journal->j_list_lock);
      b8:       40 00 00 00     call  b8 <journal_submit_data_buffers+0x1c>
      bc:       90 10 00 12     mov  %l2, %o0
        list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
      c0:       10 68 00 1d     b  %xcc, 134 <journal_submit_data_buffers+0x98>
      c4:       c2 5e 60 60     ldx  [ %i1 + 0x60 ], %g1
                mapping = jinode->i_vfs_inode->i_mapping;
                jinode->i_flags |= JI_COMMIT_RUNNING;
                spin_unlock(&journal->j_list_lock);
      c8:       90 10 00 12     mov  %l2, %o0
        struct address_space *mapping;

        spin_lock(&journal->j_list_lock);
        list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
                mapping = jinode->i_vfs_inode->i_mapping;
                jinode->i_flags |= JI_COMMIT_RUNNING;
      cc:       c2 04 60 28     ld  [ %l1 + 0x28 ], %g1
        int err, ret = 0;
        struct address_space *mapping;

        spin_lock(&journal->j_list_lock);
        list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
                mapping = jinode->i_vfs_inode->i_mapping;
      d0:       e0 58 a1 e0     ldx  [ %g2 + 0x1e0 ], %l0
                jinode->i_flags |= JI_COMMIT_RUNNING;
      d4:       82 10 60 01     or  %g1, 1, %g1
                spin_unlock(&journal->j_list_lock);
      d8:       40 00 00 00     call  d8 <journal_submit_data_buffers+0x3c>
      dc:       c2 24 60 28     st  %g1, [ %l1 + 0x28 ]
                 * submit the inode data buffers. We use writepage
                 * instead of writepages. Because writepages can do
                 * block allocation  with delalloc. We need to write
                 * only allocated blocks here.
                 */
                err = journal_submit_inode_data_buffers(mapping);
      e0:       7f ff ff d3     call  2c <journal_submit_inode_data_buffers>
      e4:       90 10 00 10     mov  %l0, %o0
                if (!ret)
      e8:       80 a6 20 00     cmp  %i0, 0
      ec:       b1 64 40 08     move  %icc, %o0, %i0
                        ret = err;
                spin_lock(&journal->j_list_lock);
      f0:       40 00 00 00     call  f0 <journal_submit_data_buffers+0x54>
      f4:       90 10 00 12     mov  %l2, %o0
                J_ASSERT(jinode->i_transaction == commit_transaction);
      f8:       c2 5c 40 00     ldx  [ %l1 ], %g1
      fc:       80 a0 40 19     cmp  %g1, %i1
     100:       22 68 00 07     be,a   %xcc, 11c
<journal_submit_data_buffers+0x80>
     104:       c2 04 60 28     ld  [ %l1 + 0x28 ], %g1
     108:       11 00 00 00     sethi  %hi(0), %o0
     10c:       92 10 21 04     mov  0x104, %o1
     110:       40 00 00 00     call  110 <journal_submit_data_buffers+0x74>
     114:       90 12 20 00     mov  %o0, %o0
     118:       91 d0 20 05     ta  5
                jinode->i_flags &= ~JI_COMMIT_RUNNING;
                wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
     11c:       90 04 60 28     add  %l1, 0x28, %o0
     120:       92 10 20 00     clr  %o1
                err = journal_submit_inode_data_buffers(mapping);
                if (!ret)
                        ret = err;
                spin_lock(&journal->j_list_lock);
                J_ASSERT(jinode->i_transaction == commit_transaction);
                jinode->i_flags &= ~JI_COMMIT_RUNNING;
     124:       82 08 7f fe     and  %g1, -2, %g1
                wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
     128:       40 00 00 00     call  128 <journal_submit_data_buffers+0x8c>
     12c:       c2 24 60 28     st  %g1, [ %l1 + 0x28 ]
        struct jbd2_inode *jinode;
        int err, ret = 0;
        struct address_space *mapping;

        spin_lock(&journal->j_list_lock);
        list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
     130:       c2 5c 60 10     ldx  [ %l1 + 0x10 ], %g1
     134:       a2 00 7f f0     add  %g1, -16, %l1
         * prefetches into the prefetch-cache which only is accessible
         * by floating point operations in UltraSPARC-III and later.
         * By contrast, "#one_write" prefetches into the L2 cache
         * in shared state.
         */
        __asm__ __volatile__("prefetch [%0], #one_write"
     138:       c2 5c 60 10     ldx  [ %l1 + 0x10 ], %g1
     13c:       c7 68 40 00     prefetch  [ %g1 ], #one_write
     140:       82 04 60 10     add  %l1, 0x10, %g1
     144:       80 a4 c0 01     cmp  %l3, %g1
     148:       32 6f ff e0     bne,a   %xcc, c8
<journal_submit_data_buffers+0x2c>
     14c:       c4 5c 60 20     ldx  [ %l1 + 0x20 ], %g2
                spin_lock(&journal->j_list_lock);
                J_ASSERT(jinode->i_transaction == commit_transaction);
                wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
        }
        spin_unlock(&journal->j_list_lock);
     150:       90 10 00 12     mov  %l2, %o0
     154:       40 00 00 00     call  154 <journal_submit_data_buffers+0xb8>
     158:       b1 3e 20 00     sra  %i0, 0, %i0
        return ret;
}
     15c:       81 cf e0 08     rett  %i7 + 8
     160:       01 00 00 00     nop

[-- Attachment #2: jbd2-commit-noinline.out --]
[-- Type: application/octet-stream, Size: 151910 bytes --]


fs/jbd2/commit.o:     file format elf64-sparc


Disassembly of section .text:

0000000000000000 <write_tag_block>:
	return checksum;
}

static void write_tag_block(int tag_bytes, journal_block_tag_t *tag,
				   unsigned long long block)
{
       0:	9d e3 bf 40 	save  %sp, -192, %sp
       4:	11 00 00 00 	sethi  %hi(0), %o0
       8:	40 00 00 00 	call  8 <write_tag_block+0x8>
       c:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>
	tag->t_blocknr = cpu_to_be32(block & (u32)~0);
	if (tag_bytes > JBD2_TAG_SIZE32)
      10:	80 a6 20 08 	cmp  %i0, 8
      14:	08 40 00 04 	bleu,pn   %icc, 24 <write_tag_block+0x24>
      18:	f4 26 40 00 	st  %i2, [ %i1 ]
		tag->t_blocknr_high = cpu_to_be32((block >> 31) >> 1);
      1c:	83 36 b0 20 	srlx  %i2, 0x20, %g1
      20:	c2 26 60 08 	st  %g1, [ %i1 + 8 ]
      24:	81 cf e0 08 	rett  %i7 + 8
      28:	01 00 00 00 	nop 

000000000000002c <journal_submit_inode_data_buffers>:
 * We don't do block allocation here even for delalloc. We don't
 * use writepages() because with dealyed allocation we may be doing
 * block allocation in writepages().
 */
static int journal_submit_inode_data_buffers(struct address_space *mapping)
{
      2c:	9d e3 bf 00 	save  %sp, -256, %sp
      30:	11 00 00 00 	sethi  %hi(0), %o0
		.sync_mode =  WB_SYNC_ALL,
		.nr_to_write = mapping->nrpages * 2,
		.range_start = 0,
		.range_end = i_size_read(mapping->host),
		.for_writepages = 1,
	};
      34:	a2 07 a7 af 	add  %fp, 0x7af, %l1
 * We don't do block allocation here even for delalloc. We don't
 * use writepages() because with dealyed allocation we may be doing
 * block allocation in writepages().
 */
static int journal_submit_inode_data_buffers(struct address_space *mapping)
{
      38:	40 00 00 00 	call  38 <journal_submit_inode_data_buffers+0xc>
      3c:	90 12 20 00 	mov  %o0, %o0
	preempt_disable();
	i_size = inode->i_size;
	preempt_enable();
	return i_size;
#else
	return inode->i_size;
      40:	c2 5e 00 00 	ldx  [ %i0 ], %g1
		.sync_mode =  WB_SYNC_ALL,
		.nr_to_write = mapping->nrpages * 2,
		.range_start = 0,
		.range_end = i_size_read(mapping->host),
		.for_writepages = 1,
	};
      44:	94 10 20 40 	mov  0x40, %o2
      48:	92 10 20 00 	clr  %o1
      4c:	90 10 00 11 	mov  %l1, %o0
      50:	e0 5e 20 a8 	ldx  [ %i0 + 0xa8 ], %l0
      54:	40 00 00 00 	call  54 <journal_submit_inode_data_buffers+0x28>
      58:	e4 58 60 68 	ldx  [ %g1 + 0x68 ], %l2
      5c:	a1 2c 30 01 	sllx  %l0, 1, %l0
      60:	82 10 20 01 	mov  1, %g1
      64:	c4 5f a7 e7 	ldx  [ %fp + 0x7e7 ], %g2

	ret = generic_writepages(mapping, &wbc);
      68:	90 10 00 18 	mov  %i0, %o0
		.sync_mode =  WB_SYNC_ALL,
		.nr_to_write = mapping->nrpages * 2,
		.range_start = 0,
		.range_end = i_size_read(mapping->host),
		.for_writepages = 1,
	};
      6c:	c2 27 a7 b7 	st  %g1, [ %fp + 0x7b7 ]
      70:	82 10 20 01 	mov  1, %g1

	ret = generic_writepages(mapping, &wbc);
      74:	92 10 00 11 	mov  %l1, %o1
		.sync_mode =  WB_SYNC_ALL,
		.nr_to_write = mapping->nrpages * 2,
		.range_start = 0,
		.range_end = i_size_read(mapping->host),
		.for_writepages = 1,
	};
      78:	83 28 70 3b 	sllx  %g1, 0x3b, %g1
      7c:	e0 77 a7 c7 	stx  %l0, [ %fp + 0x7c7 ]
      80:	84 10 80 01 	or  %g2, %g1, %g2
      84:	e4 77 a7 df 	stx  %l2, [ %fp + 0x7df ]

	ret = generic_writepages(mapping, &wbc);
      88:	40 00 00 00 	call  88 <journal_submit_inode_data_buffers+0x5c>
      8c:	c4 77 a7 e7 	stx  %g2, [ %fp + 0x7e7 ]
	return ret;
}
      90:	b1 3a 20 00 	sra  %o0, 0, %i0
      94:	81 cf e0 08 	rett  %i7 + 8
      98:	01 00 00 00 	nop 

000000000000009c <journal_submit_data_buffers>:
 * our inode list. We use JI_COMMIT_RUNNING flag to protect inode we currently
 * operate on from being released while we write out pages.
 */
static int journal_submit_data_buffers(journal_t *journal,
		transaction_t *commit_transaction)
{
      9c:	9d e3 bf 40 	save  %sp, -192, %sp
      a0:	11 00 00 00 	sethi  %hi(0), %o0
	struct jbd2_inode *jinode;
	int err, ret = 0;
	struct address_space *mapping;

	spin_lock(&journal->j_list_lock);
      a4:	a4 06 25 70 	add  %i0, 0x570, %l2
 * our inode list. We use JI_COMMIT_RUNNING flag to protect inode we currently
 * operate on from being released while we write out pages.
 */
static int journal_submit_data_buffers(journal_t *journal,
		transaction_t *commit_transaction)
{
      a8:	90 12 20 00 	mov  %o0, %o0
      ac:	40 00 00 00 	call  ac <journal_submit_data_buffers+0x10>
      b0:	b0 10 20 00 	clr  %i0
	struct jbd2_inode *jinode;
	int err, ret = 0;
	struct address_space *mapping;

	spin_lock(&journal->j_list_lock);
	list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
      b4:	a6 06 60 60 	add  %i1, 0x60, %l3
{
	struct jbd2_inode *jinode;
	int err, ret = 0;
	struct address_space *mapping;

	spin_lock(&journal->j_list_lock);
      b8:	40 00 00 00 	call  b8 <journal_submit_data_buffers+0x1c>
      bc:	90 10 00 12 	mov  %l2, %o0
	list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
      c0:	10 68 00 1d 	b  %xcc, 134 <journal_submit_data_buffers+0x98>
      c4:	c2 5e 60 60 	ldx  [ %i1 + 0x60 ], %g1
		mapping = jinode->i_vfs_inode->i_mapping;
		jinode->i_flags |= JI_COMMIT_RUNNING;
		spin_unlock(&journal->j_list_lock);
      c8:	90 10 00 12 	mov  %l2, %o0
	struct address_space *mapping;

	spin_lock(&journal->j_list_lock);
	list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
		mapping = jinode->i_vfs_inode->i_mapping;
		jinode->i_flags |= JI_COMMIT_RUNNING;
      cc:	c2 04 60 28 	ld  [ %l1 + 0x28 ], %g1
	int err, ret = 0;
	struct address_space *mapping;

	spin_lock(&journal->j_list_lock);
	list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
		mapping = jinode->i_vfs_inode->i_mapping;
      d0:	e0 58 a1 e0 	ldx  [ %g2 + 0x1e0 ], %l0
		jinode->i_flags |= JI_COMMIT_RUNNING;
      d4:	82 10 60 01 	or  %g1, 1, %g1
		spin_unlock(&journal->j_list_lock);
      d8:	40 00 00 00 	call  d8 <journal_submit_data_buffers+0x3c>
      dc:	c2 24 60 28 	st  %g1, [ %l1 + 0x28 ]
		 * submit the inode data buffers. We use writepage
		 * instead of writepages. Because writepages can do
		 * block allocation  with delalloc. We need to write
		 * only allocated blocks here.
		 */
		err = journal_submit_inode_data_buffers(mapping);
      e0:	7f ff ff d3 	call  2c <journal_submit_inode_data_buffers>
      e4:	90 10 00 10 	mov  %l0, %o0
		if (!ret)
      e8:	80 a6 20 00 	cmp  %i0, 0
      ec:	b1 64 40 08 	move  %icc, %o0, %i0
			ret = err;
		spin_lock(&journal->j_list_lock);
      f0:	40 00 00 00 	call  f0 <journal_submit_data_buffers+0x54>
      f4:	90 10 00 12 	mov  %l2, %o0
		J_ASSERT(jinode->i_transaction == commit_transaction);
      f8:	c2 5c 40 00 	ldx  [ %l1 ], %g1
      fc:	80 a0 40 19 	cmp  %g1, %i1
     100:	22 68 00 07 	be,a   %xcc, 11c <journal_submit_data_buffers+0x80>
     104:	c2 04 60 28 	ld  [ %l1 + 0x28 ], %g1
     108:	11 00 00 00 	sethi  %hi(0), %o0
     10c:	92 10 21 04 	mov  0x104, %o1
     110:	40 00 00 00 	call  110 <journal_submit_data_buffers+0x74>
     114:	90 12 20 00 	mov  %o0, %o0
     118:	91 d0 20 05 	ta  5
		jinode->i_flags &= ~JI_COMMIT_RUNNING;
		wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
     11c:	90 04 60 28 	add  %l1, 0x28, %o0
     120:	92 10 20 00 	clr  %o1
		err = journal_submit_inode_data_buffers(mapping);
		if (!ret)
			ret = err;
		spin_lock(&journal->j_list_lock);
		J_ASSERT(jinode->i_transaction == commit_transaction);
		jinode->i_flags &= ~JI_COMMIT_RUNNING;
     124:	82 08 7f fe 	and  %g1, -2, %g1
		wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
     128:	40 00 00 00 	call  128 <journal_submit_data_buffers+0x8c>
     12c:	c2 24 60 28 	st  %g1, [ %l1 + 0x28 ]
	struct jbd2_inode *jinode;
	int err, ret = 0;
	struct address_space *mapping;

	spin_lock(&journal->j_list_lock);
	list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
     130:	c2 5c 60 10 	ldx  [ %l1 + 0x10 ], %g1
     134:	a2 00 7f f0 	add  %g1, -16, %l1
	 * prefetches into the prefetch-cache which only is accessible
	 * by floating point operations in UltraSPARC-III and later.
	 * By contrast, "#one_write" prefetches into the L2 cache
	 * in shared state.
	 */
	__asm__ __volatile__("prefetch [%0], #one_write"
     138:	c2 5c 60 10 	ldx  [ %l1 + 0x10 ], %g1
     13c:	c7 68 40 00 	prefetch  [ %g1 ], #one_write
     140:	82 04 60 10 	add  %l1, 0x10, %g1
     144:	80 a4 c0 01 	cmp  %l3, %g1
     148:	32 6f ff e0 	bne,a   %xcc, c8 <journal_submit_data_buffers+0x2c>
     14c:	c4 5c 60 20 	ldx  [ %l1 + 0x20 ], %g2
		spin_lock(&journal->j_list_lock);
		J_ASSERT(jinode->i_transaction == commit_transaction);
		jinode->i_flags &= ~JI_COMMIT_RUNNING;
		wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
	}
	spin_unlock(&journal->j_list_lock);
     150:	90 10 00 12 	mov  %l2, %o0
     154:	40 00 00 00 	call  154 <journal_submit_data_buffers+0xb8>
     158:	b1 3e 20 00 	sra  %i0, 0, %i0
	return ret;
}
     15c:	81 cf e0 08 	rett  %i7 + 8
     160:	01 00 00 00 	nop 

0000000000000164 <jbd2_checksum_data>:

	return ret;
}

static __u32 jbd2_checksum_data(__u32 crc32_sum, struct buffer_head *bh)
{
     164:	9d e3 bf 40 	save  %sp, -192, %sp
     168:	11 00 00 00 	sethi  %hi(0), %o0
     16c:	40 00 00 00 	call  16c <jbd2_checksum_data+0x8>
     170:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>
 * no other way to make the pagefault handlers do this. So we do
 * disable preemption but we don't necessarily care about that.
 */
static inline void pagefault_disable(void)
{
	inc_preempt_count();
     174:	90 10 20 01 	mov  1, %o0
     178:	40 00 00 00 	call  178 <jbd2_checksum_data+0x14>
     17c:	e0 5e 60 10 	ldx  [ %i1 + 0x10 ], %l0
	struct page *page = bh->b_page;
	char *addr;
	__u32 checksum;

	addr = kmap_atomic(page, KM_USER0);
	checksum = crc32_be(crc32_sum,
     180:	82 10 3f ff 	mov  -1, %g1
     184:	d2 5e 60 28 	ldx  [ %i1 + 0x28 ], %o1
     188:	90 10 00 18 	mov  %i0, %o0
     18c:	c4 5c 20 38 	ldx  [ %l0 + 0x38 ], %g2
     190:	83 30 70 33 	srlx  %g1, 0x33, %g1
     194:	92 0a 40 01 	and  %o1, %g1, %o1
     198:	d4 5e 60 20 	ldx  [ %i1 + 0x20 ], %o2
     19c:	40 00 00 00 	call  19c <jbd2_checksum_data+0x38>
     1a0:	92 00 80 09 	add  %g2, %o1, %o1
     1a4:	b0 10 00 08 	mov  %o0, %i0
	/*
	 * make sure to issue those last loads/stores before enabling
	 * the pagefault handler again.
	 */
	barrier();
	dec_preempt_count();
     1a8:	40 00 00 00 	call  1a8 <jbd2_checksum_data+0x44>
     1ac:	90 10 20 01 	mov  1, %o0
 * @nr: bit number to test
 * @addr: Address to start counting from
 */
static inline int test_bit(int nr, const volatile unsigned long *addr)
{
	return 1UL & (addr[BIT_WORD(nr)] >> (nr & (BITS_PER_LONG-1)));
     1b0:	c2 59 a0 08 	ldx  [ %g6 + 8 ], %g1
	/*
	 * make sure we do..
	 */
	barrier();
	preempt_check_resched();
     1b4:	82 08 60 08 	and  %g1, 8, %g1
     1b8:	02 c8 40 04 	brz  %g1, 1c8 <jbd2_checksum_data+0x64>
     1bc:	01 00 00 00 	nop 
     1c0:	40 00 00 00 	call  1c0 <jbd2_checksum_data+0x5c>
     1c4:	01 00 00 00 	nop 
		(void *)(addr + offset_in_page(bh->b_data)), bh->b_size);
	kunmap_atomic(addr, KM_USER0);

	return checksum;
}
     1c8:	81 cf e0 08 	rett  %i7 + 8
     1cc:	91 32 20 00 	srl  %o0, 0, %o0

00000000000001d0 <journal_finish_inode_data_buffers>:
 * transaction if needed.
 *
 */
static int journal_finish_inode_data_buffers(journal_t *journal,
		transaction_t *commit_transaction)
{
     1d0:	9d e3 bf 40 	save  %sp, -192, %sp
     1d4:	11 00 00 00 	sethi  %hi(0), %o0
	struct jbd2_inode *jinode, *next_i;
	int err, ret = 0;

	/* For locking, see the comment in journal_submit_data_buffers() */
	spin_lock(&journal->j_list_lock);
     1d8:	a4 06 25 70 	add  %i0, 0x570, %l2
 * transaction if needed.
 *
 */
static int journal_finish_inode_data_buffers(journal_t *journal,
		transaction_t *commit_transaction)
{
     1dc:	90 12 20 00 	mov  %o0, %o0
     1e0:	40 00 00 00 	call  1e0 <journal_finish_inode_data_buffers+0x10>
     1e4:	b0 10 20 00 	clr  %i0
	struct jbd2_inode *jinode, *next_i;
	int err, ret = 0;

	/* For locking, see the comment in journal_submit_data_buffers() */
	spin_lock(&journal->j_list_lock);
	list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
     1e8:	a6 06 60 60 	add  %i1, 0x60, %l3
{
	struct jbd2_inode *jinode, *next_i;
	int err, ret = 0;

	/* For locking, see the comment in journal_submit_data_buffers() */
	spin_lock(&journal->j_list_lock);
     1ec:	40 00 00 00 	call  1ec <journal_finish_inode_data_buffers+0x1c>
     1f0:	90 10 00 12 	mov  %l2, %o0
	list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
     1f4:	10 68 00 1c 	b  %xcc, 264 <journal_finish_inode_data_buffers+0x94>
     1f8:	c2 5e 60 60 	ldx  [ %i1 + 0x60 ], %g1
		jinode->i_flags |= JI_COMMIT_RUNNING;
     1fc:	c2 04 20 28 	ld  [ %l0 + 0x28 ], %g1
     200:	82 10 60 01 	or  %g1, 1, %g1
		spin_unlock(&journal->j_list_lock);
     204:	40 00 00 00 	call  204 <journal_finish_inode_data_buffers+0x34>
     208:	c2 24 20 28 	st  %g1, [ %l0 + 0x28 ]
		err = filemap_fdatawait(jinode->i_vfs_inode->i_mapping);
     20c:	c2 5c 20 20 	ldx  [ %l0 + 0x20 ], %g1
     210:	40 00 00 00 	call  210 <journal_finish_inode_data_buffers+0x40>
     214:	d0 58 61 e0 	ldx  [ %g1 + 0x1e0 ], %o0
		if (err) {
     218:	80 a2 20 00 	cmp  %o0, 0
     21c:	02 48 00 09 	be  %icc, 240 <journal_finish_inode_data_buffers+0x70>
     220:	a2 10 00 08 	mov  %o0, %l1
			/*
			 * Because AS_EIO is cleared by
			 * wait_on_page_writeback_range(), set it again so
			 * that user process can get -EIO from fsync().
			 */
			set_bit(AS_EIO,
     224:	c2 5c 20 20 	ldx  [ %l0 + 0x20 ], %g1
     228:	90 10 20 15 	mov  0x15, %o0
     22c:	d2 58 61 e0 	ldx  [ %g1 + 0x1e0 ], %o1
     230:	40 00 00 00 	call  230 <journal_finish_inode_data_buffers+0x60>
     234:	92 02 60 c0 	add  %o1, 0xc0, %o1
				&jinode->i_vfs_inode->i_mapping->flags);

			if (!ret)
     238:	80 a6 20 00 	cmp  %i0, 0
     23c:	b1 64 40 11 	move  %icc, %l1, %i0
				ret = err;
		}
		spin_lock(&journal->j_list_lock);
     240:	40 00 00 00 	call  240 <journal_finish_inode_data_buffers+0x70>
     244:	90 10 00 12 	mov  %l2, %o0
		jinode->i_flags &= ~JI_COMMIT_RUNNING;
     248:	c2 04 20 28 	ld  [ %l0 + 0x28 ], %g1
		wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
     24c:	90 04 20 28 	add  %l0, 0x28, %o0
     250:	92 10 20 00 	clr  %o1

			if (!ret)
				ret = err;
		}
		spin_lock(&journal->j_list_lock);
		jinode->i_flags &= ~JI_COMMIT_RUNNING;
     254:	82 08 7f fe 	and  %g1, -2, %g1
		wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
     258:	40 00 00 00 	call  258 <journal_finish_inode_data_buffers+0x88>
     25c:	c2 24 20 28 	st  %g1, [ %l0 + 0x28 ]
	struct jbd2_inode *jinode, *next_i;
	int err, ret = 0;

	/* For locking, see the comment in journal_submit_data_buffers() */
	spin_lock(&journal->j_list_lock);
	list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
     260:	c2 5c 20 10 	ldx  [ %l0 + 0x10 ], %g1
     264:	a0 00 7f f0 	add  %g1, -16, %l0
     268:	c2 5c 20 10 	ldx  [ %l0 + 0x10 ], %g1
     26c:	c7 68 40 00 	prefetch  [ %g1 ], #one_write
     270:	82 04 20 10 	add  %l0, 0x10, %g1
     274:	80 a4 c0 01 	cmp  %l3, %g1
     278:	12 6f ff e1 	bne  %xcc, 1fc <journal_finish_inode_data_buffers+0x2c>
     27c:	90 10 00 12 	mov  %l2, %o0
		jinode->i_flags &= ~JI_COMMIT_RUNNING;
		wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
	}

	/* Now refile inode to proper lists */
	list_for_each_entry_safe(jinode, next_i,
     280:	c2 5e 60 60 	ldx  [ %i1 + 0x60 ], %g1
     284:	b2 00 7f f0 	add  %g1, -16, %i1
     288:	10 68 00 11 	b  %xcc, 2cc <journal_finish_inode_data_buffers+0xfc>
     28c:	c2 5e 60 10 	ldx  [ %i1 + 0x10 ], %g1
				 &commit_transaction->t_inode_list, i_list) {
		list_del(&jinode->i_list);
     290:	40 00 00 00 	call  290 <journal_finish_inode_data_buffers+0xc0>
     294:	01 00 00 00 	nop 
		if (jinode->i_next_transaction) {
     298:	c2 5e 60 08 	ldx  [ %i1 + 8 ], %g1
 * Insert a new entry after the specified head.
 * This is good for implementing stacks.
 */
static inline void list_add(struct list_head *new, struct list_head *head)
{
	__list_add(new, head, head->next);
     29c:	90 10 00 10 	mov  %l0, %o0
     2a0:	02 c0 40 08 	brz,pn   %g1, 2c0 <journal_finish_inode_data_buffers+0xf0>
     2a4:	92 00 60 60 	add  %g1, 0x60, %o1
			jinode->i_transaction = jinode->i_next_transaction;
			jinode->i_next_transaction = NULL;
     2a8:	c0 76 60 08 	clrx  [ %i1 + 8 ]
	/* Now refile inode to proper lists */
	list_for_each_entry_safe(jinode, next_i,
				 &commit_transaction->t_inode_list, i_list) {
		list_del(&jinode->i_list);
		if (jinode->i_next_transaction) {
			jinode->i_transaction = jinode->i_next_transaction;
     2ac:	c2 76 40 00 	stx  %g1, [ %i1 ]
     2b0:	40 00 00 00 	call  2b0 <journal_finish_inode_data_buffers+0xe0>
     2b4:	d4 58 60 60 	ldx  [ %g1 + 0x60 ], %o2
		jinode->i_flags &= ~JI_COMMIT_RUNNING;
		wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
	}

	/* Now refile inode to proper lists */
	list_for_each_entry_safe(jinode, next_i,
     2b8:	10 68 00 04 	b  %xcc, 2c8 <journal_finish_inode_data_buffers+0xf8>
     2bc:	c2 5c 60 10 	ldx  [ %l1 + 0x10 ], %g1
			jinode->i_transaction = jinode->i_next_transaction;
			jinode->i_next_transaction = NULL;
			list_add(&jinode->i_list,
				&jinode->i_transaction->t_inode_list);
		} else {
			jinode->i_transaction = NULL;
     2c0:	c0 76 40 00 	clrx  [ %i1 ]
		jinode->i_flags &= ~JI_COMMIT_RUNNING;
		wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
	}

	/* Now refile inode to proper lists */
	list_for_each_entry_safe(jinode, next_i,
     2c4:	c2 5c 60 10 	ldx  [ %l1 + 0x10 ], %g1
     2c8:	b2 10 00 11 	mov  %l1, %i1
     2cc:	a0 06 60 10 	add  %i1, 0x10, %l0
     2d0:	a2 00 7f f0 	add  %g1, -16, %l1
     2d4:	80 a4 00 13 	cmp  %l0, %l3
     2d8:	12 6f ff ee 	bne  %xcc, 290 <journal_finish_inode_data_buffers+0xc0>
     2dc:	90 10 00 10 	mov  %l0, %o0
				&jinode->i_transaction->t_inode_list);
		} else {
			jinode->i_transaction = NULL;
		}
	}
	spin_unlock(&journal->j_list_lock);
     2e0:	90 10 00 12 	mov  %l2, %o0
     2e4:	40 00 00 00 	call  2e4 <journal_finish_inode_data_buffers+0x114>
     2e8:	b1 3e 20 00 	sra  %i0, 0, %i0

	return ret;
}
     2ec:	81 cf e0 08 	rett  %i7 + 8
     2f0:	01 00 00 00 	nop 

00000000000002f4 <journal_submit_commit_record>:
 */
static int journal_submit_commit_record(journal_t *journal,
					transaction_t *commit_transaction,
					struct buffer_head **cbh,
					__u32 crc32_sum)
{
     2f4:	9d e3 bf 20 	save  %sp, -224, %sp
     2f8:	11 00 00 00 	sethi  %hi(0), %o0
     2fc:	a4 10 00 18 	mov  %i0, %l2
     300:	40 00 00 00 	call  300 <journal_submit_commit_record+0xc>
     304:	90 12 20 00 	mov  %o0, %o0
	struct journal_head *descriptor;
	struct commit_header *tmp;
	struct buffer_head *bh;
	int ret;
	int barrier_done = 0;
	struct timespec now = current_kernel_time();
     308:	40 00 00 00 	call  308 <journal_submit_commit_record+0x14>
     30c:	01 00 00 00 	nop 

	if (is_journal_aborted(journal))
     310:	c2 5e 00 00 	ldx  [ %i0 ], %g1
     314:	b0 10 20 00 	clr  %i0
	struct journal_head *descriptor;
	struct commit_header *tmp;
	struct buffer_head *bh;
	int ret;
	int barrier_done = 0;
	struct timespec now = current_kernel_time();
     318:	d0 77 a7 df 	stx  %o0, [ %fp + 0x7df ]
     31c:	d2 77 a7 e7 	stx  %o1, [ %fp + 0x7e7 ]

	if (is_journal_aborted(journal))
     320:	80 88 60 02 	btst  2, %g1
	struct journal_head *descriptor;
	struct commit_header *tmp;
	struct buffer_head *bh;
	int ret;
	int barrier_done = 0;
	struct timespec now = current_kernel_time();
     324:	d0 77 a7 cf 	stx  %o0, [ %fp + 0x7cf ]

	if (is_journal_aborted(journal))
     328:	12 68 00 78 	bne  %xcc, 508 <journal_submit_commit_record+0x214>
     32c:	d2 77 a7 d7 	stx  %o1, [ %fp + 0x7d7 ]
		return 0;

	descriptor = jbd2_journal_get_descriptor_buffer(journal);
     330:	90 10 00 12 	mov  %l2, %o0
     334:	40 00 00 00 	call  334 <journal_submit_commit_record+0x40>
     338:	b0 10 20 01 	mov  1, %i0
	if (!descriptor)
     33c:	02 c2 00 73 	brz,pn   %o0, 508 <journal_submit_commit_record+0x214>
     340:	03 30 0e ce 	sethi  %hi(0xc03b3800), %g1
TAS_BUFFER_FNS(RevokeValid, revokevalid)
BUFFER_FNS(Freed, freed)

static inline struct buffer_head *jh2bh(struct journal_head *jh)
{
	return jh->b_bh;
     344:	e2 5a 00 00 	ldx  [ %o0 ], %l1
		return 1;

	bh = jh2bh(descriptor);

	tmp = (struct commit_header *)bh->b_data;
	tmp->h_magic = cpu_to_be32(JBD2_MAGIC_NUMBER);
     348:	82 10 61 98 	or  %g1, 0x198, %g1
	if (!descriptor)
		return 1;

	bh = jh2bh(descriptor);

	tmp = (struct commit_header *)bh->b_data;
     34c:	c4 5c 60 28 	ldx  [ %l1 + 0x28 ], %g2
	tmp->h_magic = cpu_to_be32(JBD2_MAGIC_NUMBER);
     350:	c2 20 80 00 	st  %g1, [ %g2 ]
	tmp->h_blocktype = cpu_to_be32(JBD2_COMMIT_BLOCK);
     354:	82 10 20 02 	mov  2, %g1
     358:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]
	tmp->h_sequence = cpu_to_be32(commit_transaction->t_tid);
     35c:	c2 06 60 08 	ld  [ %i1 + 8 ], %g1
     360:	c2 20 a0 08 	st  %g1, [ %g2 + 8 ]
	tmp->h_commit_sec = cpu_to_be64(now.tv_sec);
     364:	c2 5f a7 df 	ldx  [ %fp + 0x7df ], %g1
     368:	c2 70 a0 30 	stx  %g1, [ %g2 + 0x30 ]
	tmp->h_commit_nsec = cpu_to_be32(now.tv_nsec);
     36c:	c2 5f a7 e7 	ldx  [ %fp + 0x7e7 ], %g1
     370:	c2 20 a0 38 	st  %g1, [ %g2 + 0x38 ]

	if (JBD2_HAS_COMPAT_FEATURE(journal,
     374:	c2 04 a0 20 	ld  [ %l2 + 0x20 ], %g1
     378:	80 a0 60 01 	cmp  %g1, 1
     37c:	04 40 00 0c 	ble,pn   %icc, 3ac <journal_submit_commit_record+0xb8>
     380:	11 00 00 00 	sethi  %hi(0), %o0
     384:	c2 5c a0 18 	ldx  [ %l2 + 0x18 ], %g1
     388:	c2 00 60 24 	ld  [ %g1 + 0x24 ], %g1
     38c:	80 88 60 01 	btst  1, %g1
     390:	02 68 00 07 	be  %xcc, 3ac <journal_submit_commit_record+0xb8>
     394:	01 00 00 00 	nop 
				    JBD2_FEATURE_COMPAT_CHECKSUM)) {
		tmp->h_chksum_type 	= JBD2_CRC32_CHKSUM;
     398:	82 10 20 01 	mov  1, %g1	! 1 <write_tag_block+0x1>
		tmp->h_chksum_size 	= JBD2_CRC32_CHKSUM_SIZE;
		tmp->h_chksum[0] 	= cpu_to_be32(crc32_sum);
     39c:	f6 20 a0 10 	st  %i3, [ %g2 + 0x10 ]
	tmp->h_commit_sec = cpu_to_be64(now.tv_sec);
	tmp->h_commit_nsec = cpu_to_be32(now.tv_nsec);

	if (JBD2_HAS_COMPAT_FEATURE(journal,
				    JBD2_FEATURE_COMPAT_CHECKSUM)) {
		tmp->h_chksum_type 	= JBD2_CRC32_CHKSUM;
     3a0:	c2 28 a0 0c 	stb  %g1, [ %g2 + 0xc ]
		tmp->h_chksum_size 	= JBD2_CRC32_CHKSUM_SIZE;
     3a4:	82 10 20 04 	mov  4, %g1
     3a8:	c2 28 a0 0d 	stb  %g1, [ %g2 + 0xd ]
	return likely(!test_and_set_bit_lock(BH_Lock, &bh->b_state));
}

static inline void lock_buffer(struct buffer_head *bh)
{
	might_sleep();
     3ac:	92 10 21 4b 	mov  0x14b, %o1
     3b0:	40 00 00 00 	call  3b0 <journal_submit_commit_record+0xbc>
     3b4:	90 12 20 00 	mov  %o0, %o0
		__wait_on_buffer(bh);
}

static inline int trylock_buffer(struct buffer_head *bh)
{
	return likely(!test_and_set_bit_lock(BH_Lock, &bh->b_state));
     3b8:	90 10 20 02 	mov  2, %o0
     3bc:	40 00 00 00 	call  3bc <journal_submit_commit_record+0xc8>
     3c0:	92 10 00 11 	mov  %l1, %o1
}

static inline void lock_buffer(struct buffer_head *bh)
{
	might_sleep();
	if (!trylock_buffer(bh))
     3c4:	80 a2 20 00 	cmp  %o0, 0
     3c8:	02 48 00 05 	be  %icc, 3dc <journal_submit_commit_record+0xe8>
     3cc:	90 10 20 01 	mov  1, %o0
		__lock_buffer(bh);
     3d0:	40 00 00 00 	call  3d0 <journal_submit_commit_record+0xdc>
     3d4:	90 10 00 11 	mov  %l1, %o0
 * Emit the buffer bitops functions.   Note that there are also functions
 * of the form "mark_buffer_foo()".  These are higher-level functions which
 * do something in addition to setting a b_state bit.
 */
BUFFER_FNS(Uptodate, uptodate)
BUFFER_FNS(Dirty, dirty)
     3d8:	90 10 20 01 	mov  1, %o0
     3dc:	40 00 00 00 	call  3dc <journal_submit_commit_record+0xe8>
     3e0:	92 10 00 11 	mov  %l1, %o1
/*
 * Emit the buffer bitops functions.   Note that there are also functions
 * of the form "mark_buffer_foo()".  These are higher-level functions which
 * do something in addition to setting a b_state bit.
 */
BUFFER_FNS(Uptodate, uptodate)
     3e4:	90 10 20 00 	clr  %o0
     3e8:	40 00 00 00 	call  3e8 <journal_submit_commit_record+0xf4>
     3ec:	92 10 00 11 	mov  %l1, %o1

	JBUFFER_TRACE(descriptor, "submit commit block");
	lock_buffer(bh);
	clear_buffer_dirty(bh);
	set_buffer_uptodate(bh);
	bh->b_end_io = journal_end_buffer_io_sync;
     3f0:	03 00 00 00 	sethi  %hi(0), %g1
     3f4:	82 10 60 00 	mov  %g1, %g1	! 0 <write_tag_block>
     3f8:	c2 74 60 38 	stx  %g1, [ %l1 + 0x38 ]

	if (journal->j_flags & JBD2_BARRIER &&
     3fc:	c2 5c 80 00 	ldx  [ %l2 ], %g1
     400:	82 08 60 20 	and  %g1, 0x20, %g1
     404:	02 c8 40 0f 	brz  %g1, 440 <journal_submit_commit_record+0x14c>
     408:	a0 10 20 00 	clr  %l0
     40c:	c2 04 a0 20 	ld  [ %l2 + 0x20 ], %g1
     410:	80 a0 60 01 	cmp  %g1, 1
     414:	04 40 00 08 	ble,pn   %icc, 434 <journal_submit_commit_record+0x140>
     418:	90 10 20 0c 	mov  0xc, %o0
     41c:	c2 5c a0 18 	ldx  [ %l2 + 0x18 ], %g1
     420:	c2 00 60 28 	ld  [ %g1 + 0x28 ], %g1
     424:	80 88 60 04 	btst  4, %g1
     428:	12 68 00 07 	bne  %xcc, 444 <journal_submit_commit_record+0x150>
     42c:	90 10 20 19 	mov  0x19, %o0
BUFFER_FNS(Async_Read, async_read)
BUFFER_FNS(Async_Write, async_write)
BUFFER_FNS(Delay, delay)
BUFFER_FNS(Boundary, boundary)
BUFFER_FNS(Write_EIO, write_io_error)
BUFFER_FNS(Ordered, ordered)
     430:	90 10 20 0c 	mov  0xc, %o0
     434:	40 00 00 00 	call  434 <journal_submit_commit_record+0x140>
     438:	92 10 00 11 	mov  %l1, %o1
     43c:	a0 10 20 01 	mov  1, %l0
		!JBD2_HAS_INCOMPAT_FEATURE(journal,
					 JBD2_FEATURE_INCOMPAT_ASYNC_COMMIT)) {
		set_buffer_ordered(bh);
		barrier_done = 1;
	}
	ret = submit_bh(WRITE_SYNC, bh);
     440:	90 10 20 19 	mov  0x19, %o0
     444:	40 00 00 00 	call  444 <journal_submit_commit_record+0x150>
     448:	92 10 00 11 	mov  %l1, %o1
	if (barrier_done)
     44c:	80 a4 20 00 	cmp  %l0, 0
     450:	02 48 00 05 	be  %icc, 464 <journal_submit_commit_record+0x170>
     454:	b0 10 00 08 	mov  %o0, %i0
     458:	90 10 20 0c 	mov  0xc, %o0
     45c:	40 00 00 00 	call  45c <journal_submit_commit_record+0x168>
     460:	92 10 00 11 	mov  %l1, %o1
	/* is it possible for another commit to fail at roughly
	 * the same time as this one?  If so, we don't want to
	 * trust the barrier flag in the super, but instead want
	 * to remember if we sent a barrier request
	 */
	if (ret == -EOPNOTSUPP && barrier_done) {
     464:	82 1e 3f d3 	xor  %i0, -45, %g1
     468:	80 a0 00 01 	cmp  %g0, %g1
     46c:	82 60 3f ff 	subc  %g0, -1, %g1
     470:	80 88 40 10 	btst  %g1, %l0
     474:	22 48 00 25 	be,a   %icc, 508 <journal_submit_commit_record+0x214>
     478:	e2 76 80 00 	stx  %l1, [ %i2 ]
		printk(KERN_WARNING
     47c:	11 00 00 00 	sethi  %hi(0), %o0
     480:	92 04 a5 28 	add  %l2, 0x528, %o1
     484:	90 12 20 00 	mov  %o0, %o0
     488:	40 00 00 00 	call  488 <journal_submit_commit_record+0x194>
     48c:	a0 04 a0 28 	add  %l2, 0x28, %l0
		       "JBD: barrier-based sync failed on %s - "
		       "disabling barriers\n", journal->j_devname);
		spin_lock(&journal->j_state_lock);
     490:	40 00 00 00 	call  490 <journal_submit_commit_record+0x19c>
     494:	90 10 00 10 	mov  %l0, %o0
		journal->j_flags &= ~JBD2_BARRIER;
     498:	c2 5c 80 00 	ldx  [ %l2 ], %g1
		spin_unlock(&journal->j_state_lock);
     49c:	90 10 00 10 	mov  %l0, %o0
	if (ret == -EOPNOTSUPP && barrier_done) {
		printk(KERN_WARNING
		       "JBD: barrier-based sync failed on %s - "
		       "disabling barriers\n", journal->j_devname);
		spin_lock(&journal->j_state_lock);
		journal->j_flags &= ~JBD2_BARRIER;
     4a0:	82 08 7f df 	and  %g1, -33, %g1
		spin_unlock(&journal->j_state_lock);
     4a4:	40 00 00 00 	call  4a4 <journal_submit_commit_record+0x1b0>
     4a8:	c2 74 80 00 	stx  %g1, [ %l2 ]
	return likely(!test_and_set_bit_lock(BH_Lock, &bh->b_state));
}

static inline void lock_buffer(struct buffer_head *bh)
{
	might_sleep();
     4ac:	11 00 00 00 	sethi  %hi(0), %o0
     4b0:	92 10 21 4b 	mov  0x14b, %o1
     4b4:	40 00 00 00 	call  4b4 <journal_submit_commit_record+0x1c0>
     4b8:	90 12 20 00 	mov  %o0, %o0
		__wait_on_buffer(bh);
}

static inline int trylock_buffer(struct buffer_head *bh)
{
	return likely(!test_and_set_bit_lock(BH_Lock, &bh->b_state));
     4bc:	90 10 20 02 	mov  2, %o0
     4c0:	40 00 00 00 	call  4c0 <journal_submit_commit_record+0x1cc>
     4c4:	92 10 00 11 	mov  %l1, %o1
}

static inline void lock_buffer(struct buffer_head *bh)
{
	might_sleep();
	if (!trylock_buffer(bh))
     4c8:	80 a2 20 00 	cmp  %o0, 0
     4cc:	02 48 00 05 	be  %icc, 4e0 <journal_submit_commit_record+0x1ec>
     4d0:	90 10 20 00 	clr  %o0
		__lock_buffer(bh);
     4d4:	40 00 00 00 	call  4d4 <journal_submit_commit_record+0x1e0>
     4d8:	90 10 00 11 	mov  %l1, %o0
/*
 * Emit the buffer bitops functions.   Note that there are also functions
 * of the form "mark_buffer_foo()".  These are higher-level functions which
 * do something in addition to setting a b_state bit.
 */
BUFFER_FNS(Uptodate, uptodate)
     4dc:	90 10 20 00 	clr  %o0
     4e0:	40 00 00 00 	call  4e0 <journal_submit_commit_record+0x1ec>
     4e4:	92 10 00 11 	mov  %l1, %o1
BUFFER_FNS(Dirty, dirty)
     4e8:	90 10 20 01 	mov  1, %o0
     4ec:	40 00 00 00 	call  4ec <journal_submit_commit_record+0x1f8>
     4f0:	92 10 00 11 	mov  %l1, %o1

		/* And try again, without the barrier */
		lock_buffer(bh);
		set_buffer_uptodate(bh);
		clear_buffer_dirty(bh);
		ret = submit_bh(WRITE_SYNC, bh);
     4f4:	90 10 20 19 	mov  0x19, %o0
     4f8:	40 00 00 00 	call  4f8 <journal_submit_commit_record+0x204>
     4fc:	92 10 00 11 	mov  %l1, %o1
     500:	b0 10 00 08 	mov  %o0, %i0
	}
	*cbh = bh;
     504:	e2 76 80 00 	stx  %l1, [ %i2 ]
	return ret;
}
     508:	81 cf e0 08 	rett  %i7 + 8
     50c:	91 3a 20 00 	sra  %o0, 0, %o0

0000000000000510 <journal_end_buffer_io_sync>:

/*
 * Default IO end handler for temporary BJ_IO buffer_heads.
 */
static void journal_end_buffer_io_sync(struct buffer_head *bh, int uptodate)
{
     510:	9d e3 bf 40 	save  %sp, -192, %sp
     514:	11 00 00 00 	sethi  %hi(0), %o0
     518:	40 00 00 00 	call  518 <journal_end_buffer_io_sync+0x8>
     51c:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>
	BUFFER_TRACE(bh, "");
	if (uptodate)
     520:	02 ce 40 06 	brz  %i1, 538 <journal_end_buffer_io_sync+0x28>
     524:	90 10 20 00 	clr  %o0
/*
 * Emit the buffer bitops functions.   Note that there are also functions
 * of the form "mark_buffer_foo()".  These are higher-level functions which
 * do something in addition to setting a b_state bit.
 */
BUFFER_FNS(Uptodate, uptodate)
     528:	40 00 00 00 	call  528 <journal_end_buffer_io_sync+0x18>
     52c:	92 10 00 18 	mov  %i0, %o1
     530:	10 68 00 04 	b  %xcc, 540 <journal_end_buffer_io_sync+0x30>
     534:	01 00 00 00 	nop 
		set_buffer_uptodate(bh);
	else
		clear_buffer_uptodate(bh);
	unlock_buffer(bh);
     538:	40 00 00 00 	call  538 <journal_end_buffer_io_sync+0x28>
     53c:	92 10 00 18 	mov  %i0, %o1
     540:	40 00 00 00 	call  540 <journal_end_buffer_io_sync+0x30>
     544:	90 10 00 18 	mov  %i0, %o0
}
     548:	81 cf e0 08 	rett  %i7 + 8
     54c:	01 00 00 00 	nop 

0000000000000550 <journal_wait_on_commit_record>:
 * This function along with journal_submit_commit_record
 * allows to write the commit record asynchronously.
 */
static int journal_wait_on_commit_record(journal_t *journal,
					 struct buffer_head *bh)
{
     550:	9d e3 bf 40 	save  %sp, -192, %sp
     554:	11 00 00 00 	sethi  %hi(0), %o0
     558:	a0 10 00 18 	mov  %i0, %l0
     55c:	90 12 20 00 	mov  %o0, %o0
     560:	40 00 00 00 	call  560 <journal_wait_on_commit_record+0x10>
     564:	a4 06 25 28 	add  %i0, 0x528, %l2
	wait_on_buffer(bh);
	if (buffer_eopnotsupp(bh) && (journal->j_flags & JBD2_BARRIER)) {
		printk(KERN_WARNING
		       "JBD2: wait_on_commit_record: sync failed on %s - "
		       "disabling barriers\n", journal->j_devname);
		spin_lock(&journal->j_state_lock);
     568:	a2 06 20 28 	add  %i0, 0x28, %l1
	int ret = 0;

retry:
	clear_buffer_dirty(bh);
	wait_on_buffer(bh);
	if (buffer_eopnotsupp(bh) && (journal->j_flags & JBD2_BARRIER)) {
     56c:	29 00 00 08 	sethi  %hi(0x2000), %l4
 * __wait_on_buffer() just to trip a debug check.  Because debug code in inline
 * functions is bloaty.
 */
static inline void wait_on_buffer(struct buffer_head *bh)
{
	might_sleep();
     570:	03 00 00 00 	sethi  %hi(0), %g1
     574:	a6 10 60 00 	mov  %g1, %l3	! 0 <write_tag_block>
		printk(KERN_WARNING
     578:	03 00 00 00 	sethi  %hi(0), %g1
     57c:	ac 10 60 00 	mov  %g1, %l6	! 0 <write_tag_block>
		spin_unlock(&journal->j_state_lock);

		lock_buffer(bh);
		clear_buffer_dirty(bh);
		set_buffer_uptodate(bh);
		bh->b_end_io = journal_end_buffer_io_sync;
     580:	03 00 00 00 	sethi  %hi(0), %g1
     584:	aa 10 60 00 	mov  %g1, %l5	! 0 <write_tag_block>
 * Emit the buffer bitops functions.   Note that there are also functions
 * of the form "mark_buffer_foo()".  These are higher-level functions which
 * do something in addition to setting a b_state bit.
 */
BUFFER_FNS(Uptodate, uptodate)
BUFFER_FNS(Dirty, dirty)
     588:	92 10 00 19 	mov  %i1, %o1
     58c:	40 00 00 00 	call  58c <journal_wait_on_commit_record+0x3c>
     590:	90 10 20 01 	mov  1, %o0
 * __wait_on_buffer() just to trip a debug check.  Because debug code in inline
 * functions is bloaty.
 */
static inline void wait_on_buffer(struct buffer_head *bh)
{
	might_sleep();
     594:	90 10 00 13 	mov  %l3, %o0
     598:	40 00 00 00 	call  598 <journal_wait_on_commit_record+0x48>
     59c:	92 10 21 3f 	mov  0x13f, %o1
     5a0:	c2 5e 40 00 	ldx  [ %i1 ], %g1
	if (buffer_locked(bh) || atomic_read(&bh->b_count) == 0)
     5a4:	82 08 60 04 	and  %g1, 4, %g1
     5a8:	0a c0 40 06 	brnz,pn   %g1, 5c0 <journal_wait_on_commit_record+0x70>
     5ac:	90 10 00 19 	mov  %i1, %o0
     5b0:	c2 06 60 60 	ld  [ %i1 + 0x60 ], %g1
     5b4:	80 a0 60 00 	cmp  %g1, 0
     5b8:	12 48 00 04 	bne  %icc, 5c8 <journal_wait_on_commit_record+0x78>
     5bc:	01 00 00 00 	nop 
		__wait_on_buffer(bh);
     5c0:	40 00 00 00 	call  5c0 <journal_wait_on_commit_record+0x70>
     5c4:	01 00 00 00 	nop 
     5c8:	c2 5e 40 00 	ldx  [ %i1 ], %g1
	int ret = 0;

retry:
	clear_buffer_dirty(bh);
	wait_on_buffer(bh);
	if (buffer_eopnotsupp(bh) && (journal->j_flags & JBD2_BARRIER)) {
     5cc:	82 08 40 14 	and  %g1, %l4, %g1
     5d0:	02 c0 40 2b 	brz,pn   %g1, 67c <journal_wait_on_commit_record+0x12c>
     5d4:	01 00 00 00 	nop 
     5d8:	c2 5c 00 00 	ldx  [ %l0 ], %g1
     5dc:	82 08 60 20 	and  %g1, 0x20, %g1
     5e0:	02 c8 40 27 	brz  %g1, 67c <journal_wait_on_commit_record+0x12c>
     5e4:	92 10 00 12 	mov  %l2, %o1
		printk(KERN_WARNING
     5e8:	40 00 00 00 	call  5e8 <journal_wait_on_commit_record+0x98>
     5ec:	90 10 00 16 	mov  %l6, %o0
		       "JBD2: wait_on_commit_record: sync failed on %s - "
		       "disabling barriers\n", journal->j_devname);
		spin_lock(&journal->j_state_lock);
     5f0:	40 00 00 00 	call  5f0 <journal_wait_on_commit_record+0xa0>
     5f4:	90 10 00 11 	mov  %l1, %o0
		journal->j_flags &= ~JBD2_BARRIER;
     5f8:	c2 5c 00 00 	ldx  [ %l0 ], %g1
		spin_unlock(&journal->j_state_lock);
     5fc:	90 10 00 11 	mov  %l1, %o0
	if (buffer_eopnotsupp(bh) && (journal->j_flags & JBD2_BARRIER)) {
		printk(KERN_WARNING
		       "JBD2: wait_on_commit_record: sync failed on %s - "
		       "disabling barriers\n", journal->j_devname);
		spin_lock(&journal->j_state_lock);
		journal->j_flags &= ~JBD2_BARRIER;
     600:	82 08 7f df 	and  %g1, -33, %g1
		spin_unlock(&journal->j_state_lock);
     604:	40 00 00 00 	call  604 <journal_wait_on_commit_record+0xb4>
     608:	c2 74 00 00 	stx  %g1, [ %l0 ]
	return likely(!test_and_set_bit_lock(BH_Lock, &bh->b_state));
}

static inline void lock_buffer(struct buffer_head *bh)
{
	might_sleep();
     60c:	90 10 00 13 	mov  %l3, %o0
     610:	40 00 00 00 	call  610 <journal_wait_on_commit_record+0xc0>
     614:	92 10 21 4b 	mov  0x14b, %o1
		__wait_on_buffer(bh);
}

static inline int trylock_buffer(struct buffer_head *bh)
{
	return likely(!test_and_set_bit_lock(BH_Lock, &bh->b_state));
     618:	92 10 00 19 	mov  %i1, %o1
     61c:	40 00 00 00 	call  61c <journal_wait_on_commit_record+0xcc>
     620:	90 10 20 02 	mov  2, %o0
}

static inline void lock_buffer(struct buffer_head *bh)
{
	might_sleep();
	if (!trylock_buffer(bh))
     624:	80 a2 20 00 	cmp  %o0, 0
     628:	02 48 00 05 	be  %icc, 63c <journal_wait_on_commit_record+0xec>
     62c:	90 10 20 01 	mov  1, %o0
		__lock_buffer(bh);
     630:	40 00 00 00 	call  630 <journal_wait_on_commit_record+0xe0>
     634:	90 10 00 19 	mov  %i1, %o0
 * Emit the buffer bitops functions.   Note that there are also functions
 * of the form "mark_buffer_foo()".  These are higher-level functions which
 * do something in addition to setting a b_state bit.
 */
BUFFER_FNS(Uptodate, uptodate)
BUFFER_FNS(Dirty, dirty)
     638:	90 10 20 01 	mov  1, %o0
     63c:	40 00 00 00 	call  63c <journal_wait_on_commit_record+0xec>
     640:	92 10 00 19 	mov  %i1, %o1
/*
 * Emit the buffer bitops functions.   Note that there are also functions
 * of the form "mark_buffer_foo()".  These are higher-level functions which
 * do something in addition to setting a b_state bit.
 */
BUFFER_FNS(Uptodate, uptodate)
     644:	90 10 20 00 	clr  %o0
     648:	40 00 00 00 	call  648 <journal_wait_on_commit_record+0xf8>
     64c:	92 10 00 19 	mov  %i1, %o1
		lock_buffer(bh);
		clear_buffer_dirty(bh);
		set_buffer_uptodate(bh);
		bh->b_end_io = journal_end_buffer_io_sync;

		ret = submit_bh(WRITE_SYNC, bh);
     650:	90 10 20 19 	mov  0x19, %o0
		spin_unlock(&journal->j_state_lock);

		lock_buffer(bh);
		clear_buffer_dirty(bh);
		set_buffer_uptodate(bh);
		bh->b_end_io = journal_end_buffer_io_sync;
     654:	ea 76 60 38 	stx  %l5, [ %i1 + 0x38 ]

		ret = submit_bh(WRITE_SYNC, bh);
     658:	40 00 00 00 	call  658 <journal_wait_on_commit_record+0x108>
     65c:	92 10 00 19 	mov  %i1, %o1
		if (ret) {
     660:	b0 92 20 00 	orcc  %o0, 0, %i0
     664:	02 4f ff ca 	be  %icc, 58c <journal_wait_on_commit_record+0x3c>
     668:	92 10 00 19 	mov  %i1, %o1
			unlock_buffer(bh);
     66c:	40 00 00 00 	call  66c <journal_wait_on_commit_record+0x11c>
     670:	90 10 00 19 	mov  %i1, %o0
		ret = -EIO;
	put_bh(bh);            /* One for getblk() */
	jbd2_journal_put_journal_head(bh2jh(bh));

	return ret;
}
     674:	81 cf e0 08 	rett  %i7 + 8
     678:	91 3a 20 00 	sra  %o0, 0, %o0
     67c:	c2 5e 40 00 	ldx  [ %i1 ], %g1
			return ret;
		}
		goto retry;
	}

	if (unlikely(!buffer_uptodate(bh)))
     680:	b0 10 3f fb 	mov  -5, %i0
     684:	80 88 60 01 	btst  1, %g1
     688:	b1 66 70 00 	movne  %xcc, 0, %i0
}

static inline void put_bh(struct buffer_head *bh)
{
        smp_mb__before_atomic_dec();
        atomic_dec(&bh->b_count);
     68c:	90 10 20 01 	mov  1, %o0
     690:	40 00 00 00 	call  690 <journal_wait_on_commit_record+0x140>
     694:	92 06 60 60 	add  %i1, 0x60, %o1
		ret = -EIO;
	put_bh(bh);            /* One for getblk() */
	jbd2_journal_put_journal_head(bh2jh(bh));
     698:	40 00 00 00 	call  698 <journal_wait_on_commit_record+0x148>
     69c:	d0 5e 60 40 	ldx  [ %i1 + 0x40 ], %o0

	return ret;
}
     6a0:	b1 3e 20 00 	sra  %i0, 0, %i0
     6a4:	81 cf e0 08 	rett  %i7 + 8
     6a8:	01 00 00 00 	nop 

00000000000006ac <release_buffer_page>:
 *
 * Called under lock_journal(), and possibly under journal_datalist_lock.  The
 * caller provided us with a ref against the buffer, and we drop that here.
 */
static void release_buffer_page(struct buffer_head *bh)
{
     6ac:	9d e3 bf 40 	save  %sp, -192, %sp
     6b0:	11 00 00 00 	sethi  %hi(0), %o0
     6b4:	40 00 00 00 	call  6b4 <release_buffer_page+0x8>
     6b8:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>
     6bc:	c2 5e 00 00 	ldx  [ %i0 ], %g1
	struct page *page;

	if (buffer_dirty(bh))
     6c0:	82 08 60 02 	and  %g1, 2, %g1
     6c4:	0a c0 40 2c 	brnz,pn   %g1, 774 <release_buffer_page+0xc8>
     6c8:	01 00 00 00 	nop 
		goto nope;
	if (atomic_read(&bh->b_count) != 1)
     6cc:	c2 06 20 60 	ld  [ %i0 + 0x60 ], %g1
     6d0:	80 a0 60 01 	cmp  %g1, 1
     6d4:	12 48 00 28 	bne  %icc, 774 <release_buffer_page+0xc8>
     6d8:	01 00 00 00 	nop 
		goto nope;
	page = bh->b_page;
     6dc:	e0 5e 20 10 	ldx  [ %i0 + 0x10 ], %l0
	if (!page)
     6e0:	02 c4 00 25 	brz,pn   %l0, 774 <release_buffer_page+0xc8>
     6e4:	01 00 00 00 	nop 
		goto nope;
	if (page->mapping)
     6e8:	c2 5c 20 18 	ldx  [ %l0 + 0x18 ], %g1
     6ec:	0a c8 40 22 	brnz  %g1, 774 <release_buffer_page+0xc8>
     6f0:	90 10 20 00 	clr  %o0
	__clear_bit(PG_locked, &page->flags);
}

static inline int trylock_page(struct page *page)
{
	return (likely(!test_and_set_bit_lock(PG_locked, &page->flags)));
     6f4:	40 00 00 00 	call  6f4 <release_buffer_page+0x48>
     6f8:	92 10 00 10 	mov  %l0, %o1
		goto nope;

	/* OK, it's a truncated page */
	if (!trylock_page(page))
     6fc:	80 a2 20 00 	cmp  %o0, 0
     700:	12 48 00 1d 	bne  %icc, 774 <release_buffer_page+0xc8>
     704:	01 00 00 00 	nop 
     708:	c2 5c 00 00 	ldx  [ %l0 ], %g1
#endif
}

static inline struct page *compound_head(struct page *page)
{
	if (unlikely(PageTail(page)))
     70c:	05 00 00 10 	sethi  %hi(0x4000), %g2
     710:	82 08 40 02 	and  %g1, %g2, %g1
     714:	02 c8 40 03 	brz  %g1, 720 <release_buffer_page+0x74>
     718:	92 10 00 10 	mov  %l0, %o1
		return page->first_page;
     71c:	d2 5c 20 10 	ldx  [ %l0 + 0x10 ], %o1
}

static inline void get_page(struct page *page)
{
	page = compound_head(page);
	VM_BUG_ON(atomic_read(&page->_count) == 0);
     720:	c2 02 60 08 	ld  [ %o1 + 8 ], %g1
     724:	80 a0 60 00 	cmp  %g1, 0
     728:	12 48 00 07 	bne  %icc, 744 <release_buffer_page+0x98>
     72c:	92 02 60 08 	add  %o1, 8, %o1
     730:	11 00 00 00 	sethi  %hi(0), %o0
     734:	92 10 21 2e 	mov  0x12e, %o1
     738:	40 00 00 00 	call  738 <release_buffer_page+0x8c>
     73c:	90 12 20 00 	mov  %o0, %o0
     740:	91 d0 20 05 	ta  5
	atomic_inc(&page->_count);
     744:	40 00 00 00 	call  744 <release_buffer_page+0x98>
     748:	90 10 20 01 	mov  1, %o0
		goto nope;

	page_cache_get(page);
	__brelse(bh);
     74c:	40 00 00 00 	call  74c <release_buffer_page+0xa0>
     750:	90 10 00 18 	mov  %i0, %o0
	try_to_free_buffers(page);
     754:	40 00 00 00 	call  754 <release_buffer_page+0xa8>
     758:	90 10 00 10 	mov  %l0, %o0
	unlock_page(page);
     75c:	40 00 00 00 	call  75c <release_buffer_page+0xb0>
     760:	90 10 00 10 	mov  %l0, %o0
	page_cache_release(page);
     764:	40 00 00 00 	call  764 <release_buffer_page+0xb8>
     768:	90 10 00 10 	mov  %l0, %o0
     76c:	81 cf e0 08 	rett  %i7 + 8
     770:	01 00 00 00 	nop 
	return;

nope:
	__brelse(bh);
     774:	40 00 00 00 	call  774 <release_buffer_page+0xc8>
     778:	90 10 00 18 	mov  %i0, %o0
     77c:	81 cf e0 08 	rett  %i7 + 8
     780:	01 00 00 00 	nop 

0000000000000784 <jbd2_journal_commit_transaction>:
 *
 * The primary function for committing a transaction to the log.  This
 * function is called by the journal thread to begin a complete commit.
 */
void jbd2_journal_commit_transaction(journal_t *journal)
{
     784:	9d e3 be 90 	save  %sp, -368, %sp
     788:	11 00 00 00 	sethi  %hi(0), %o0
     78c:	40 00 00 00 	call  78c <jbd2_journal_commit_transaction+0x8>
     790:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>
	struct transaction_stats_s stats;
	transaction_t *commit_transaction;
	struct journal_head *jh, *new_jh, *descriptor;
	struct buffer_head **wbuf = journal->j_wbuf;
     794:	c2 5e 26 58 	ldx  [ %i0 + 0x658 ], %g1
	journal_block_tag_t *tag = NULL;
	int space_left = 0;
	int first_tag = 0;
	int tag_flag;
	int i, to_free = 0;
	int tag_bytes = journal_tag_bytes(journal);
     798:	90 10 00 18 	mov  %i0, %o0
     79c:	40 00 00 00 	call  79c <jbd2_journal_commit_transaction+0x18>
     7a0:	c2 77 a7 4f 	stx  %g1, [ %fp + 0x74f ]
	summarise_journal_usage(journal);
	spin_unlock(&journal->j_list_lock);
#endif

	/* Do we need to erase the effects of a prior jbd2_journal_flush? */
	if (journal->j_flags & JBD2_FLUSHED) {
     7a4:	c2 5e 00 00 	ldx  [ %i0 ], %g1
     7a8:	05 00 00 00 	sethi  %hi(0), %g2
	journal_block_tag_t *tag = NULL;
	int space_left = 0;
	int first_tag = 0;
	int tag_flag;
	int i, to_free = 0;
	int tag_bytes = journal_tag_bytes(journal);
     7ac:	d0 27 a7 5b 	st  %o0, [ %fp + 0x75b ]
	summarise_journal_usage(journal);
	spin_unlock(&journal->j_list_lock);
#endif

	/* Do we need to erase the effects of a prior jbd2_journal_flush? */
	if (journal->j_flags & JBD2_FLUSHED) {
     7b0:	82 08 60 08 	and  %g1, 8, %g1
     7b4:	02 c8 40 16 	brz  %g1, 80c <jbd2_journal_commit_transaction+0x88>
     7b8:	c0 77 a7 d7 	clrx  [ %fp + 0x7d7 ]
		jbd_debug(3, "super block updated\n");
     7bc:	c2 08 a0 00 	ldub  [ %g2 ], %g1
     7c0:	80 a0 60 02 	cmp  %g1, 2
     7c4:	28 48 00 0e 	bleu,a   %icc, 7fc <jbd2_journal_commit_transaction+0x78>
     7c8:	90 10 00 18 	mov  %i0, %o0
     7cc:	11 00 00 00 	sethi  %hi(0), %o0
     7d0:	13 00 00 00 	sethi  %hi(0), %o1
     7d4:	17 00 00 00 	sethi  %hi(0), %o3
     7d8:	90 12 20 00 	mov  %o0, %o0
     7dc:	92 12 60 00 	mov  %o1, %o1
     7e0:	96 12 e0 00 	mov  %o3, %o3
     7e4:	40 00 00 00 	call  7e4 <jbd2_journal_commit_transaction+0x60>
     7e8:	94 10 21 80 	mov  0x180, %o2
     7ec:	11 00 00 00 	sethi  %hi(0), %o0
     7f0:	40 00 00 00 	call  7f0 <jbd2_journal_commit_transaction+0x6c>
     7f4:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>
		jbd2_journal_update_superblock(journal, 1);
     7f8:	90 10 00 18 	mov  %i0, %o0
     7fc:	40 00 00 00 	call  7fc <jbd2_journal_commit_transaction+0x78>
     800:	92 10 20 01 	mov  1, %o1
	} else {
		jbd_debug(3, "superblock not updated\n");
	}

	J_ASSERT(journal->j_running_transaction != NULL);
     804:	10 68 00 12 	b  %xcc, 84c <jbd2_journal_commit_transaction+0xc8>
     808:	e6 5e 20 d8 	ldx  [ %i0 + 0xd8 ], %l3
	/* Do we need to erase the effects of a prior jbd2_journal_flush? */
	if (journal->j_flags & JBD2_FLUSHED) {
		jbd_debug(3, "super block updated\n");
		jbd2_journal_update_superblock(journal, 1);
	} else {
		jbd_debug(3, "superblock not updated\n");
     80c:	c2 08 a0 00 	ldub  [ %g2 ], %g1
     810:	80 a0 60 02 	cmp  %g1, 2
     814:	28 48 00 0e 	bleu,a   %icc, 84c <jbd2_journal_commit_transaction+0xc8>
     818:	e6 5e 20 d8 	ldx  [ %i0 + 0xd8 ], %l3
     81c:	11 00 00 00 	sethi  %hi(0), %o0
     820:	13 00 00 00 	sethi  %hi(0), %o1
     824:	17 00 00 00 	sethi  %hi(0), %o3
     828:	90 12 20 00 	mov  %o0, %o0
     82c:	92 12 60 00 	mov  %o1, %o1
     830:	96 12 e0 00 	mov  %o3, %o3
     834:	40 00 00 00 	call  834 <jbd2_journal_commit_transaction+0xb0>
     838:	94 10 21 83 	mov  0x183, %o2
     83c:	11 00 00 00 	sethi  %hi(0), %o0
     840:	40 00 00 00 	call  840 <jbd2_journal_commit_transaction+0xbc>
     844:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>
	}

	J_ASSERT(journal->j_running_transaction != NULL);
     848:	e6 5e 20 d8 	ldx  [ %i0 + 0xd8 ], %l3
     84c:	02 c4 c0 06 	brz,pn   %l3, 864 <jbd2_journal_commit_transaction+0xe0>
     850:	92 10 21 86 	mov  0x186, %o1
	J_ASSERT(journal->j_committing_transaction == NULL);
     854:	c2 5e 20 e0 	ldx  [ %i0 + 0xe0 ], %g1
     858:	22 c8 40 08 	brz,a   %g1, 878 <jbd2_journal_commit_transaction+0xf4>
     85c:	c2 04 e0 0c 	ld  [ %l3 + 0xc ], %g1
     860:	92 10 21 87 	mov  0x187, %o1
     864:	11 00 00 00 	sethi  %hi(0), %o0
     868:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>
     86c:	40 00 00 00 	call  86c <jbd2_journal_commit_transaction+0xe8>
     870:	01 00 00 00 	nop 
     874:	91 d0 20 05 	ta  5

	commit_transaction = journal->j_running_transaction;
	J_ASSERT(commit_transaction->t_state == T_RUNNING);
     878:	80 a0 60 00 	cmp  %g1, 0
     87c:	12 47 ff fa 	bne,pn   %icc, 864 <jbd2_journal_commit_transaction+0xe0>
     880:	92 10 21 8a 	mov  0x18a, %o1

	trace_mark(jbd2_start_commit, "dev %s transaction %d",
		   journal->j_devname, commit_transaction->t_tid);
	jbd_debug(1, "JBD: starting commit of transaction %d\n",
     884:	03 00 00 00 	sethi  %hi(0), %g1
     888:	c2 08 60 00 	ldub  [ %g1 ], %g1
     88c:	80 a0 60 00 	cmp  %g1, 0
     890:	22 48 00 0f 	be,a   %icc, 8cc <jbd2_journal_commit_transaction+0x148>
     894:	b4 06 20 28 	add  %i0, 0x28, %i2
     898:	13 00 00 00 	sethi  %hi(0), %o1
     89c:	11 00 00 00 	sethi  %hi(0), %o0
     8a0:	17 00 00 00 	sethi  %hi(0), %o3
     8a4:	92 12 60 00 	mov  %o1, %o1
     8a8:	90 12 20 00 	mov  %o0, %o0
     8ac:	96 12 e0 00 	mov  %o3, %o3
     8b0:	40 00 00 00 	call  8b0 <jbd2_journal_commit_transaction+0x12c>
     8b4:	94 10 21 8f 	mov  0x18f, %o2
     8b8:	11 00 00 00 	sethi  %hi(0), %o0
     8bc:	d2 04 e0 08 	ld  [ %l3 + 8 ], %o1
     8c0:	40 00 00 00 	call  8c0 <jbd2_journal_commit_transaction+0x13c>
     8c4:	90 12 20 00 	mov  %o0, %o0
			commit_transaction->t_tid);

	spin_lock(&journal->j_state_lock);
     8c8:	b4 06 20 28 	add  %i0, 0x28, %i2
	stats.u.run.rs_wait = commit_transaction->t_max_wait;
	stats.u.run.rs_locked = jiffies;
	stats.u.run.rs_running = jbd2_time_diff(commit_transaction->t_start,
						stats.u.run.rs_locked);

	spin_lock(&commit_transaction->t_handle_lock);
     8cc:	a2 04 e0 70 	add  %l3, 0x70, %l1
	trace_mark(jbd2_start_commit, "dev %s transaction %d",
		   journal->j_devname, commit_transaction->t_tid);
	jbd_debug(1, "JBD: starting commit of transaction %d\n",
			commit_transaction->t_tid);

	spin_lock(&journal->j_state_lock);
     8d0:	90 10 00 1a 	mov  %i2, %o0
     8d4:	40 00 00 00 	call  8d4 <jbd2_journal_commit_transaction+0x150>
     8d8:	a8 06 22 30 	add  %i0, 0x230, %l4
	stats.u.run.rs_running = jbd2_time_diff(commit_transaction->t_start,
						stats.u.run.rs_locked);

	spin_lock(&commit_transaction->t_handle_lock);
	while (commit_transaction->t_updates) {
		DEFINE_WAIT(wait);
     8dc:	a4 07 a7 af 	add  %fp, 0x7af, %l2
     8e0:	aa 07 a7 c7 	add  %fp, 0x7c7, %l5
		   journal->j_devname, commit_transaction->t_tid);
	jbd_debug(1, "JBD: starting commit of transaction %d\n",
			commit_transaction->t_tid);

	spin_lock(&journal->j_state_lock);
	commit_transaction->t_state = T_LOCKED;
     8e4:	82 10 20 01 	mov  1, %g1
     8e8:	c2 24 e0 0c 	st  %g1, [ %l3 + 0xc ]
	stats.u.run.rs_wait = commit_transaction->t_max_wait;
	stats.u.run.rs_locked = jiffies;
	stats.u.run.rs_running = jbd2_time_diff(commit_transaction->t_start,
						stats.u.run.rs_locked);

	spin_lock(&commit_transaction->t_handle_lock);
     8ec:	90 10 00 11 	mov  %l1, %o0

	spin_lock(&journal->j_state_lock);
	commit_transaction->t_state = T_LOCKED;

	stats.u.run.rs_wait = commit_transaction->t_max_wait;
	stats.u.run.rs_locked = jiffies;
     8f0:	03 00 00 00 	sethi  %hi(0), %g1
			commit_transaction->t_tid);

	spin_lock(&journal->j_state_lock);
	commit_transaction->t_state = T_LOCKED;

	stats.u.run.rs_wait = commit_transaction->t_max_wait;
     8f4:	c4 5c e0 a0 	ldx  [ %l3 + 0xa0 ], %g2
	stats.u.run.rs_locked = jiffies;
     8f8:	c6 58 60 00 	ldx  [ %g1 ], %g3
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;

	return end + (MAX_JIFFY_OFFSET - start);
     8fc:	82 10 3f ff 	mov  -1, %g1
			commit_transaction->t_tid);

	spin_lock(&journal->j_state_lock);
	commit_transaction->t_state = T_LOCKED;

	stats.u.run.rs_wait = commit_transaction->t_max_wait;
     900:	c4 77 a7 6f 	stx  %g2, [ %fp + 0x76f ]
     904:	83 28 70 3e 	sllx  %g1, 0x3e, %g1
	stats.u.run.rs_locked = jiffies;
     908:	c6 77 a7 7f 	stx  %g3, [ %fp + 0x77f ]
     90c:	82 18 7f fe 	xor  %g1, -2, %g1
	stats.u.run.rs_running = jbd2_time_diff(commit_transaction->t_start,
     910:	c4 5c e0 a8 	ldx  [ %l3 + 0xa8 ], %g2
     914:	82 00 c0 01 	add  %g3, %g1, %g1

static inline unsigned long
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;
     918:	80 a0 c0 02 	cmp  %g3, %g2

	return end + (MAX_JIFFY_OFFSET - start);
     91c:	82 20 40 02 	sub  %g1, %g2, %g1

static inline unsigned long
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;
     920:	86 20 c0 02 	sub  %g3, %g2, %g3
     924:	83 67 50 03 	movcc  %xcc, %g3, %g1
						stats.u.run.rs_locked);

	spin_lock(&commit_transaction->t_handle_lock);
     928:	40 00 00 00 	call  928 <jbd2_journal_commit_transaction+0x1a4>
     92c:	c2 77 a7 77 	stx  %g1, [ %fp + 0x777 ]
	while (commit_transaction->t_updates) {
		DEFINE_WAIT(wait);
     930:	03 00 00 00 	sethi  %hi(0), %g1
     934:	10 68 00 1f 	b  %xcc, 9b0 <jbd2_journal_commit_transaction+0x22c>
     938:	ac 10 60 00 	mov  %g1, %l6	! 0 <write_tag_block>
     93c:	94 10 20 28 	mov  0x28, %o2
     940:	90 10 00 12 	mov  %l2, %o0
     944:	40 00 00 00 	call  944 <jbd2_journal_commit_transaction+0x1c0>
     948:	a0 10 00 04 	mov  %g4, %l0

		prepare_to_wait(&journal->j_wait_updates, &wait,
     94c:	90 10 00 14 	mov  %l4, %o0
     950:	92 10 00 12 	mov  %l2, %o1
	stats.u.run.rs_running = jbd2_time_diff(commit_transaction->t_start,
						stats.u.run.rs_locked);

	spin_lock(&commit_transaction->t_handle_lock);
	while (commit_transaction->t_updates) {
		DEFINE_WAIT(wait);
     954:	e0 77 a7 b7 	stx  %l0, [ %fp + 0x7b7 ]

		prepare_to_wait(&journal->j_wait_updates, &wait,
     958:	94 10 20 02 	mov  2, %o2
	stats.u.run.rs_running = jbd2_time_diff(commit_transaction->t_start,
						stats.u.run.rs_locked);

	spin_lock(&commit_transaction->t_handle_lock);
	while (commit_transaction->t_updates) {
		DEFINE_WAIT(wait);
     95c:	ec 77 a7 bf 	stx  %l6, [ %fp + 0x7bf ]
     960:	ea 77 a7 c7 	stx  %l5, [ %fp + 0x7c7 ]

		prepare_to_wait(&journal->j_wait_updates, &wait,
     964:	40 00 00 00 	call  964 <jbd2_journal_commit_transaction+0x1e0>
     968:	ea 77 a7 cf 	stx  %l5, [ %fp + 0x7cf ]
					TASK_UNINTERRUPTIBLE);
		if (commit_transaction->t_updates) {
     96c:	c2 04 e0 d0 	ld  [ %l3 + 0xd0 ], %g1
     970:	80 a0 60 00 	cmp  %g1, 0
     974:	02 48 00 0d 	be  %icc, 9a8 <jbd2_journal_commit_transaction+0x224>
     978:	90 10 00 14 	mov  %l4, %o0
			spin_unlock(&commit_transaction->t_handle_lock);
     97c:	40 00 00 00 	call  97c <jbd2_journal_commit_transaction+0x1f8>
     980:	90 10 00 11 	mov  %l1, %o0
			spin_unlock(&journal->j_state_lock);
     984:	40 00 00 00 	call  984 <jbd2_journal_commit_transaction+0x200>
     988:	90 10 00 1a 	mov  %i2, %o0
			schedule();
     98c:	40 00 00 00 	call  98c <jbd2_journal_commit_transaction+0x208>
     990:	01 00 00 00 	nop 
			spin_lock(&journal->j_state_lock);
     994:	40 00 00 00 	call  994 <jbd2_journal_commit_transaction+0x210>
     998:	90 10 00 1a 	mov  %i2, %o0
			spin_lock(&commit_transaction->t_handle_lock);
     99c:	40 00 00 00 	call  99c <jbd2_journal_commit_transaction+0x218>
     9a0:	90 10 00 11 	mov  %l1, %o0
		}
		finish_wait(&journal->j_wait_updates, &wait);
     9a4:	90 10 00 14 	mov  %l4, %o0
     9a8:	40 00 00 00 	call  9a8 <jbd2_journal_commit_transaction+0x224>
     9ac:	92 10 00 12 	mov  %l2, %o1
	stats.u.run.rs_locked = jiffies;
	stats.u.run.rs_running = jbd2_time_diff(commit_transaction->t_start,
						stats.u.run.rs_locked);

	spin_lock(&commit_transaction->t_handle_lock);
	while (commit_transaction->t_updates) {
     9b0:	c2 04 e0 d0 	ld  [ %l3 + 0xd0 ], %g1
     9b4:	80 a0 60 00 	cmp  %g1, 0
     9b8:	12 4f ff e1 	bne  %icc, 93c <jbd2_journal_commit_transaction+0x1b8>
     9bc:	92 10 20 00 	clr  %o1
			spin_lock(&journal->j_state_lock);
			spin_lock(&commit_transaction->t_handle_lock);
		}
		finish_wait(&journal->j_wait_updates, &wait);
	}
	spin_unlock(&commit_transaction->t_handle_lock);
     9c0:	90 10 00 11 	mov  %l1, %o0
     9c4:	40 00 00 00 	call  9c4 <jbd2_journal_commit_transaction+0x240>
     9c8:	25 00 10 00 	sethi  %hi(0x400000), %l2

	J_ASSERT (commit_transaction->t_outstanding_credits <=
     9cc:	c4 04 e0 d4 	ld  [ %l3 + 0xd4 ], %g2
     9d0:	c2 06 25 d0 	ld  [ %i0 + 0x5d0 ], %g1
     9d4:	80 a0 80 01 	cmp  %g2, %g1
     9d8:	04 48 00 39 	ble  %icc, abc <jbd2_journal_commit_transaction+0x338>
     9dc:	92 10 21 ab 	mov  0x1ab, %o1
	} else {
		jbd_debug(3, "superblock not updated\n");
	}

	J_ASSERT(journal->j_running_transaction != NULL);
	J_ASSERT(journal->j_committing_transaction == NULL);
     9e0:	10 6f ff a2 	b  %xcc, 868 <jbd2_journal_commit_transaction+0xe4>
     9e4:	11 00 00 00 	sethi  %hi(0), %o0
		JBUFFER_TRACE(jh, "reserved, unused: refile");
		/*
		 * A jbd2_journal_get_undo_access()+jbd2_journal_release_buffer() may
		 * leave undo-committed data.
		 */
		if (jh->b_committed_data) {
     9e8:	02 c0 40 32 	brz,pn   %g1, ab0 <jbd2_journal_commit_transaction+0x32c>
     9ec:	90 10 20 01 	mov  1, %o0
	 * the body of the outer loop. If it is contended, then
	 * within the inner loop a non-atomic test is used to
	 * busywait with less bus contention for a good time to
	 * attempt to acquire the lock bit.
	 */
	preempt_disable();
     9f0:	40 00 00 00 	call  9f0 <jbd2_journal_commit_transaction+0x26c>
     9f4:	e0 5c 40 00 	ldx  [ %l1 ], %l0
#if defined(CONFIG_SMP) || defined(CONFIG_DEBUG_SPINLOCK)
	while (unlikely(test_and_set_bit_lock(bitnum, addr))) {
     9f8:	10 68 00 10 	b  %xcc, a38 <jbd2_journal_commit_transaction+0x2b4>
     9fc:	90 10 20 16 	mov  0x16, %o0
		while (test_bit(bitnum, addr)) {
			preempt_enable();
     a00:	40 00 00 00 	call  a00 <jbd2_journal_commit_transaction+0x27c>
     a04:	90 10 20 01 	mov  1, %o0
     a08:	c2 59 a0 08 	ldx  [ %g6 + 8 ], %g1
     a0c:	82 08 60 08 	and  %g1, 8, %g1
     a10:	02 c8 40 04 	brz  %g1, a20 <jbd2_journal_commit_transaction+0x29c>
     a14:	01 00 00 00 	nop 
     a18:	40 00 00 00 	call  a18 <jbd2_journal_commit_transaction+0x294>
     a1c:	01 00 00 00 	nop 
			cpu_relax();
			preempt_disable();
     a20:	40 00 00 00 	call  a20 <jbd2_journal_commit_transaction+0x29c>
     a24:	90 10 20 01 	mov  1, %o0	! 1 <write_tag_block+0x1>
     a28:	c2 5c 00 00 	ldx  [ %l0 ], %g1
	 * attempt to acquire the lock bit.
	 */
	preempt_disable();
#if defined(CONFIG_SMP) || defined(CONFIG_DEBUG_SPINLOCK)
	while (unlikely(test_and_set_bit_lock(bitnum, addr))) {
		while (test_bit(bitnum, addr)) {
     a2c:	82 08 40 12 	and  %g1, %l2, %g1
     a30:	0a f0 7f f4 	brnz,pn   %g1, a00 <jbd2_journal_commit_transaction+0x27c>
     a34:	90 10 20 16 	mov  0x16, %o0
	 * busywait with less bus contention for a good time to
	 * attempt to acquire the lock bit.
	 */
	preempt_disable();
#if defined(CONFIG_SMP) || defined(CONFIG_DEBUG_SPINLOCK)
	while (unlikely(test_and_set_bit_lock(bitnum, addr))) {
     a38:	40 00 00 00 	call  a38 <jbd2_journal_commit_transaction+0x2b4>
     a3c:	92 10 00 10 	mov  %l0, %o1
     a40:	80 a2 20 00 	cmp  %o0, 0
     a44:	12 4f ff f9 	bne  %icc, a28 <jbd2_journal_commit_transaction+0x2a4>
     a48:	92 10 3f ff 	mov  -1, %o1
/* Pure 2^n version of get_order */
static __inline__ __attribute_const__ int get_order(unsigned long size)
{
	int order;

	size = (size - 1) >> (PAGE_SHIFT - 1);
     a4c:	c2 5c 20 20 	ldx  [ %l0 + 0x20 ], %g1
			struct buffer_head *bh = jh2bh(jh);

			jbd_lock_bh_state(bh);
			jbd2_free(jh->b_committed_data, bh->b_size);
     a50:	d0 5c 60 20 	ldx  [ %l1 + 0x20 ], %o0
     a54:	82 00 7f ff 	add  %g1, -1, %g1
     a58:	83 30 70 0c 	srlx  %g1, 0xc, %g1
	order = -1;
	do {
		size >>= 1;
     a5c:	83 30 70 01 	srlx  %g1, 1, %g1
		order++;
	} while (size);
     a60:	0a f8 7f ff 	brnz  %g1, a5c <jbd2_journal_commit_transaction+0x2d8>
     a64:	92 02 60 01 	inc  %o1
	return (void *)__get_free_pages(flags, get_order(size));
}

static inline void jbd2_free(void *ptr, size_t size)
{
	free_pages((unsigned long)ptr, get_order(size));
     a68:	40 00 00 00 	call  a68 <jbd2_journal_commit_transaction+0x2e4>
     a6c:	93 32 60 00 	srl  %o1, 0, %o1
			jh->b_committed_data = NULL;
     a70:	c0 74 60 20 	clrx  [ %l1 + 0x20 ]
     a74:	c2 5c 00 00 	ldx  [ %l0 ], %g1
 *  bit-based spin_unlock()
 */
static inline void bit_spin_unlock(int bitnum, unsigned long *addr)
{
#ifdef CONFIG_DEBUG_SPINLOCK
	BUG_ON(!test_bit(bitnum, addr));
     a78:	82 08 40 12 	and  %g1, %l2, %g1
     a7c:	22 c0 43 2e 	brz,a,pn   %g1, 1734 <jbd2_journal_commit_transaction+0xfb0>
     a80:	11 00 00 00 	sethi  %hi(0), %o0
#endif
#if defined(CONFIG_SMP) || defined(CONFIG_DEBUG_SPINLOCK)
	clear_bit_unlock(bitnum, addr);
     a84:	90 10 20 16 	mov  0x16, %o0
     a88:	40 00 00 00 	call  a88 <jbd2_journal_commit_transaction+0x304>
     a8c:	92 10 00 10 	mov  %l0, %o1
#endif
	preempt_enable();
     a90:	40 00 00 00 	call  a90 <jbd2_journal_commit_transaction+0x30c>
     a94:	90 10 20 01 	mov  1, %o0
     a98:	c2 59 a0 08 	ldx  [ %g6 + 8 ], %g1
     a9c:	82 08 60 08 	and  %g1, 8, %g1
     aa0:	02 c8 40 05 	brz  %g1, ab4 <jbd2_journal_commit_transaction+0x330>
     aa4:	92 10 00 11 	mov  %l1, %o1
     aa8:	40 00 00 00 	call  aa8 <jbd2_journal_commit_transaction+0x324>
     aac:	01 00 00 00 	nop 
			jbd_unlock_bh_state(bh);
		}
		jbd2_journal_refile_buffer(journal, jh);
     ab0:	92 10 00 11 	mov  %l1, %o1
     ab4:	40 00 00 00 	call  ab4 <jbd2_journal_commit_transaction+0x330>
     ab8:	90 10 00 18 	mov  %i0, %o0
	 * we do not require it to remember exactly which old buffers it
	 * has reserved.  This is consistent with the existing behaviour
	 * that multiple jbd2_journal_get_write_access() calls to the same
	 * buffer are perfectly permissable.
	 */
	while (commit_transaction->t_reserved_list) {
     abc:	e2 5c e0 20 	ldx  [ %l3 + 0x20 ], %l1
     ac0:	2a fc 7f ca 	brnz,a   %l1, 9e8 <jbd2_journal_commit_transaction+0x264>
     ac4:	c2 5c 60 20 	ldx  [ %l1 + 0x20 ], %g1
	/*
	 * Now try to drop any written-back buffers from the journal's
	 * checkpoint lists.  We do this *before* commit because it potentially
	 * frees some memory
	 */
	spin_lock(&journal->j_list_lock);
     ac8:	b6 06 25 70 	add  %i0, 0x570, %i3
     acc:	40 00 00 00 	call  acc <jbd2_journal_commit_transaction+0x348>
     ad0:	90 10 00 1b 	mov  %i3, %o0
	__jbd2_journal_clean_checkpoint_list(journal);
     ad4:	40 00 00 00 	call  ad4 <jbd2_journal_commit_transaction+0x350>
     ad8:	90 10 00 18 	mov  %i0, %o0
	spin_unlock(&journal->j_list_lock);
     adc:	40 00 00 00 	call  adc <jbd2_journal_commit_transaction+0x358>
     ae0:	90 10 00 1b 	mov  %i3, %o0

	jbd_debug (3, "JBD: commit phase 1\n");
     ae4:	03 00 00 00 	sethi  %hi(0), %g1
     ae8:	c2 08 60 00 	ldub  [ %g1 ], %g1
     aec:	80 a0 60 02 	cmp  %g1, 2
     af0:	08 48 00 0c 	bleu  %icc, b20 <jbd2_journal_commit_transaction+0x39c>
     af4:	13 00 00 00 	sethi  %hi(0), %o1
     af8:	11 00 00 00 	sethi  %hi(0), %o0
     afc:	17 00 00 00 	sethi  %hi(0), %o3
     b00:	90 12 20 00 	mov  %o0, %o0
     b04:	92 12 60 00 	mov  %o1, %o1
     b08:	96 12 e0 00 	mov  %o3, %o3
     b0c:	40 00 00 00 	call  b0c <jbd2_journal_commit_transaction+0x388>
     b10:	94 10 21 d8 	mov  0x1d8, %o2
     b14:	11 00 00 00 	sethi  %hi(0), %o0
     b18:	40 00 00 00 	call  b18 <jbd2_journal_commit_transaction+0x394>
     b1c:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>

	/*
	 * Switch to a new revoke table.
	 */
	jbd2_journal_switch_revoke_table(journal);
     b20:	40 00 00 00 	call  b20 <jbd2_journal_commit_transaction+0x39c>
     b24:	90 10 00 18 	mov  %i0, %o0

	stats.u.run.rs_flushing = jiffies;
     b28:	03 00 00 00 	sethi  %hi(0), %g1
	stats.u.run.rs_locked = jbd2_time_diff(stats.u.run.rs_locked,
     b2c:	c6 5f a7 7f 	ldx  [ %fp + 0x77f ], %g3
	/*
	 * Switch to a new revoke table.
	 */
	jbd2_journal_switch_revoke_table(journal);

	stats.u.run.rs_flushing = jiffies;
     b30:	c4 58 60 00 	ldx  [ %g1 ], %g2
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;

	return end + (MAX_JIFFY_OFFSET - start);
     b34:	82 10 3f ff 	mov  -1, %g1
     b38:	83 28 70 3e 	sllx  %g1, 0x3e, %g1
     b3c:	82 18 7f fe 	xor  %g1, -2, %g1

static inline unsigned long
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;
     b40:	80 a0 80 03 	cmp  %g2, %g3
     b44:	c4 77 a7 87 	stx  %g2, [ %fp + 0x787 ]

	return end + (MAX_JIFFY_OFFSET - start);
     b48:	82 00 80 01 	add  %g2, %g1, %g1

static inline unsigned long
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;
     b4c:	84 20 80 03 	sub  %g2, %g3, %g2

	return end + (MAX_JIFFY_OFFSET - start);
     b50:	82 20 40 03 	sub  %g1, %g3, %g1

static inline unsigned long
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;
     b54:	83 67 50 02 	movcc  %xcc, %g2, %g1
	stats.u.run.rs_locked = jbd2_time_diff(stats.u.run.rs_locked,
     b58:	c2 77 a7 7f 	stx  %g1, [ %fp + 0x77f ]
					       stats.u.run.rs_flushing);

	commit_transaction->t_state = T_FLUSH;
     b5c:	82 10 20 03 	mov  3, %g1
     b60:	c2 24 e0 0c 	st  %g1, [ %l3 + 0xc ]
	journal->j_committing_transaction = commit_transaction;
     b64:	e6 76 20 e0 	stx  %l3, [ %i0 + 0xe0 ]
	journal->j_running_transaction = NULL;
	start_time = ktime_get();
     b68:	40 00 00 00 	call  b68 <jbd2_journal_commit_transaction+0x3e4>
     b6c:	c0 76 20 d8 	clrx  [ %i0 + 0xd8 ]
	commit_transaction->t_log_start = journal->j_head;
     b70:	c2 5e 24 e8 	ldx  [ %i0 + 0x4e8 ], %g1
	wake_up(&journal->j_wait_transaction_locked);
     b74:	92 10 20 03 	mov  3, %o1
     b78:	94 10 20 01 	mov  1, %o2
					       stats.u.run.rs_flushing);

	commit_transaction->t_state = T_FLUSH;
	journal->j_committing_transaction = commit_transaction;
	journal->j_running_transaction = NULL;
	start_time = ktime_get();
     b7c:	d0 77 a7 3f 	stx  %o0, [ %fp + 0x73f ]
	commit_transaction->t_log_start = journal->j_head;
	wake_up(&journal->j_wait_transaction_locked);
     b80:	96 10 20 00 	clr  %o3
     b84:	90 06 20 f0 	add  %i0, 0xf0, %o0
     b88:	40 00 00 00 	call  b88 <jbd2_journal_commit_transaction+0x404>
     b8c:	c2 74 e0 10 	stx  %g1, [ %l3 + 0x10 ]
	spin_unlock(&journal->j_state_lock);
     b90:	40 00 00 00 	call  b90 <jbd2_journal_commit_transaction+0x40c>
     b94:	90 10 00 1a 	mov  %i2, %o0

	jbd_debug (3, "JBD: commit phase 2\n");
     b98:	03 00 00 00 	sethi  %hi(0), %g1
     b9c:	c2 08 60 00 	ldub  [ %g1 ], %g1
     ba0:	80 a0 60 02 	cmp  %g1, 2
     ba4:	28 48 00 0e 	bleu,a   %icc, bdc <jbd2_journal_commit_transaction+0x458>
     ba8:	90 10 00 18 	mov  %i0, %o0
     bac:	11 00 00 00 	sethi  %hi(0), %o0
     bb0:	13 00 00 00 	sethi  %hi(0), %o1
     bb4:	17 00 00 00 	sethi  %hi(0), %o3
     bb8:	90 12 20 00 	mov  %o0, %o0
     bbc:	92 12 60 00 	mov  %o1, %o1
     bc0:	96 12 e0 00 	mov  %o3, %o3
     bc4:	40 00 00 00 	call  bc4 <jbd2_journal_commit_transaction+0x440>
     bc8:	94 10 21 eb 	mov  0x1eb, %o2
     bcc:	11 00 00 00 	sethi  %hi(0), %o0
     bd0:	40 00 00 00 	call  bd0 <jbd2_journal_commit_transaction+0x44c>
     bd4:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>

	/*
	 * Now start flushing things to disk, in the order they appear
	 * on the transaction lists.  Data blocks go first.
	 */
	err = journal_submit_data_buffers(journal, commit_transaction);
     bd8:	90 10 00 18 	mov  %i0, %o0
     bdc:	7f ff fd 30 	call  9c <journal_submit_data_buffers>
     be0:	92 10 00 13 	mov  %l3, %o1
	if (err)
     be4:	80 a2 20 00 	cmp  %o0, 0
     be8:	22 48 00 06 	be,a   %icc, c00 <jbd2_journal_commit_transaction+0x47c>
     bec:	90 10 00 18 	mov  %i0, %o0
		jbd2_journal_abort(journal, err);
     bf0:	93 3a 20 00 	sra  %o0, 0, %o1
     bf4:	40 00 00 00 	call  bf4 <jbd2_journal_commit_transaction+0x470>
     bf8:	90 10 00 18 	mov  %i0, %o0

	jbd2_journal_write_revoke_records(journal, commit_transaction);
     bfc:	90 10 00 18 	mov  %i0, %o0
     c00:	40 00 00 00 	call  c00 <jbd2_journal_commit_transaction+0x47c>
     c04:	92 10 00 13 	mov  %l3, %o1

	jbd_debug(3, "JBD: commit phase 2\n");
     c08:	03 00 00 00 	sethi  %hi(0), %g1
     c0c:	c2 08 60 00 	ldub  [ %g1 ], %g1
     c10:	80 a0 60 02 	cmp  %g1, 2
     c14:	08 48 00 0c 	bleu  %icc, c44 <jbd2_journal_commit_transaction+0x4c0>
     c18:	11 00 00 00 	sethi  %hi(0), %o0
     c1c:	13 00 00 00 	sethi  %hi(0), %o1
     c20:	17 00 00 00 	sethi  %hi(0), %o3
     c24:	90 12 20 00 	mov  %o0, %o0
     c28:	92 12 60 00 	mov  %o1, %o1
     c2c:	96 12 e0 00 	mov  %o3, %o3
     c30:	40 00 00 00 	call  c30 <jbd2_journal_commit_transaction+0x4ac>
     c34:	94 10 21 f7 	mov  0x1f7, %o2
     c38:	11 00 00 00 	sethi  %hi(0), %o0
     c3c:	40 00 00 00 	call  c3c <jbd2_journal_commit_transaction+0x4b8>
     c40:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>
	/*
	 * Way to go: we have now written out all of the data for a
	 * transaction!  Now comes the tricky part: we need to write out
	 * metadata.  Loop over the transaction's entire buffer list:
	 */
	spin_lock(&journal->j_state_lock);
     c44:	40 00 00 00 	call  c44 <jbd2_journal_commit_transaction+0x4c0>
     c48:	90 10 00 1a 	mov  %i2, %o0
	commit_transaction->t_state = T_COMMIT;
     c4c:	82 10 20 04 	mov  4, %g1
	spin_unlock(&journal->j_state_lock);
     c50:	90 10 00 1a 	mov  %i2, %o0
     c54:	40 00 00 00 	call  c54 <jbd2_journal_commit_transaction+0x4d0>
     c58:	c2 24 e0 0c 	st  %g1, [ %l3 + 0xc ]

	stats.u.run.rs_logging = jiffies;
     c5c:	03 00 00 00 	sethi  %hi(0), %g1
	stats.u.run.rs_flushing = jbd2_time_diff(stats.u.run.rs_flushing,
     c60:	c6 5f a7 87 	ldx  [ %fp + 0x787 ], %g3
	 */
	spin_lock(&journal->j_state_lock);
	commit_transaction->t_state = T_COMMIT;
	spin_unlock(&journal->j_state_lock);

	stats.u.run.rs_logging = jiffies;
     c64:	c4 58 60 00 	ldx  [ %g1 ], %g2

	return end + (MAX_JIFFY_OFFSET - start);
     c68:	82 10 3f ff 	mov  -1, %g1
     c6c:	83 28 70 3e 	sllx  %g1, 0x3e, %g1
     c70:	82 18 7f fe 	xor  %g1, -2, %g1
     c74:	c4 77 a7 8f 	stx  %g2, [ %fp + 0x78f ]

static inline unsigned long
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;
     c78:	80 a0 80 03 	cmp  %g2, %g3

	return end + (MAX_JIFFY_OFFSET - start);
     c7c:	82 00 80 01 	add  %g2, %g1, %g1

static inline unsigned long
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;
     c80:	84 20 80 03 	sub  %g2, %g3, %g2

	return end + (MAX_JIFFY_OFFSET - start);
     c84:	82 20 40 03 	sub  %g1, %g3, %g1

static inline unsigned long
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;
     c88:	83 67 50 02 	movcc  %xcc, %g2, %g1
	stats.u.run.rs_flushing = jbd2_time_diff(stats.u.run.rs_flushing,
     c8c:	c2 77 a7 87 	stx  %g1, [ %fp + 0x787 ]
						 stats.u.run.rs_logging);
	stats.u.run.rs_blocks = commit_transaction->t_outstanding_credits;
     c90:	c2 44 e0 d4 	ldsw  [ %l3 + 0xd4 ], %g1
	stats.u.run.rs_blocks_logged = 0;
     c94:	c0 77 a7 a7 	clrx  [ %fp + 0x7a7 ]
	spin_unlock(&journal->j_state_lock);

	stats.u.run.rs_logging = jiffies;
	stats.u.run.rs_flushing = jbd2_time_diff(stats.u.run.rs_flushing,
						 stats.u.run.rs_logging);
	stats.u.run.rs_blocks = commit_transaction->t_outstanding_credits;
     c98:	c2 77 a7 9f 	stx  %g1, [ %fp + 0x79f ]
	stats.u.run.rs_blocks_logged = 0;

	J_ASSERT(commit_transaction->t_nr_buffers <=
     c9c:	c4 04 e0 18 	ld  [ %l3 + 0x18 ], %g2
     ca0:	c2 04 e0 d4 	ld  [ %l3 + 0xd4 ], %g1
     ca4:	80 a0 80 01 	cmp  %g2, %g1
     ca8:	14 40 00 0a 	bg,pn   %icc, cd0 <jbd2_journal_commit_transaction+0x54c>
     cac:	84 06 25 b8 	add  %i0, 0x5b8, %g2
		tag->t_flags = cpu_to_be32(tag_flag);
		tagp += tag_bytes;
		space_left -= tag_bytes;

		if (first_tag) {
			memcpy (tagp, journal->j_uuid, 16);
     cb0:	ac 10 20 00 	clr  %l6
     cb4:	c4 77 a7 47 	stx  %g2, [ %fp + 0x747 ]
     cb8:	a8 10 20 00 	clr  %l4
     cbc:	aa 10 20 00 	clr  %l5
     cc0:	ae 10 20 00 	clr  %l7
     cc4:	ba 10 20 00 	clr  %i5
     cc8:	10 68 00 f3 	b  %xcc, 1094 <jbd2_journal_commit_transaction+0x910>
     ccc:	b2 10 3f ff 	mov  -1, %i1
	stats.u.run.rs_flushing = jbd2_time_diff(stats.u.run.rs_flushing,
						 stats.u.run.rs_logging);
	stats.u.run.rs_blocks = commit_transaction->t_outstanding_credits;
	stats.u.run.rs_blocks_logged = 0;

	J_ASSERT(commit_transaction->t_nr_buffers <=
     cd0:	10 6f fe e5 	b  %xcc, 864 <jbd2_journal_commit_transaction+0xe0>
     cd4:	92 10 22 09 	mov  0x209, %o1
		jh = commit_transaction->t_buffers;

		/* If we're in abort mode, we just un-journal the buffer and
		   release it. */

		if (is_journal_aborted(journal)) {
     cd8:	80 88 60 02 	btst  2, %g1
     cdc:	02 68 00 14 	be  %xcc, d2c <jbd2_journal_commit_transaction+0x5a8>
     ce0:	01 00 00 00 	nop 
	BH_JBDPrivateStart,	/* First bit available for private use by FS */
};

BUFFER_FNS(JBD, jbd)
BUFFER_FNS(JWrite, jwrite)
BUFFER_FNS(JBDDirty, jbddirty)
     ce4:	d2 5c 80 00 	ldx  [ %l2 ], %o1
     ce8:	40 00 00 00 	call  ce8 <jbd2_journal_commit_transaction+0x564>
     cec:	90 10 20 15 	mov  0x15, %o0
			clear_buffer_jbddirty(jh2bh(jh));
			JBUFFER_TRACE(jh, "journal is aborting: refile");
			jbd2_buffer_abort_trigger(jh,
     cf0:	c4 5c a0 18 	ldx  [ %l2 + 0x18 ], %g2
     cf4:	86 04 a0 60 	add  %l2, 0x60, %g3
     cf8:	82 04 a0 68 	add  %l2, 0x68, %g1
     cfc:	90 10 00 12 	mov  %l2, %o0
     d00:	83 78 84 03 	movre  %g2, %g3, %g1
     d04:	40 00 00 00 	call  d04 <jbd2_journal_commit_transaction+0x580>
     d08:	d2 58 40 00 	ldx  [ %g1 ], %o1
						  jh->b_frozen_data ?
						  jh->b_frozen_triggers :
						  jh->b_triggers);
			jbd2_journal_refile_buffer(journal, jh);
     d0c:	90 10 00 18 	mov  %i0, %o0
     d10:	40 00 00 00 	call  d10 <jbd2_journal_commit_transaction+0x58c>
     d14:	92 10 00 12 	mov  %l2, %o1
			/* If that was the last one, we need to clean up
			 * any descriptor buffers which may have been
			 * already allocated, even if we are now
			 * aborting. */
			if (!commit_transaction->t_buffers)
     d18:	c2 5c e0 28 	ldx  [ %l3 + 0x28 ], %g1
     d1c:	2a c8 40 df 	brnz,a   %g1, 1098 <jbd2_journal_commit_transaction+0x914>
     d20:	e4 5c e0 28 	ldx  [ %l3 + 0x28 ], %l2
                           submitting the IOs.  "tag" still points to
                           the last tag we set up. */

			tag->t_flags |= cpu_to_be32(JBD2_FLAG_LAST_TAG);

start_journal_io:
     d24:	10 68 00 aa 	b  %xcc, fcc <jbd2_journal_commit_transaction+0x848>
     d28:	e4 5f a7 4f 	ldx  [ %fp + 0x74f ], %l2
		}

		/* Make sure we have a descriptor block in which to
		   record the metadata buffer. */

		if (!descriptor) {
     d2c:	0a cd 80 4a 	brnz  %l6, e54 <jbd2_journal_commit_transaction+0x6d0>
     d30:	90 10 00 18 	mov  %i0, %o0
			struct buffer_head *bh;

			J_ASSERT (bufs == 0);
     d34:	80 a5 20 00 	cmp  %l4, 0
     d38:	02 48 00 04 	be  %icc, d48 <jbd2_journal_commit_transaction+0x5c4>
     d3c:	07 00 00 00 	sethi  %hi(0), %g3
     d40:	10 6f fe c9 	b  %xcc, 864 <jbd2_journal_commit_transaction+0xe0>
     d44:	92 10 22 2e 	mov  0x22e, %o1

			jbd_debug(4, "JBD: get descriptor\n");
     d48:	86 10 e0 00 	mov  %g3, %g3
     d4c:	c2 08 c0 00 	ldub  [ %g3 ], %g1
     d50:	80 a0 60 03 	cmp  %g1, 3
     d54:	08 48 00 0c 	bleu  %icc, d84 <jbd2_journal_commit_transaction+0x600>
     d58:	13 00 00 00 	sethi  %hi(0), %o1
     d5c:	11 00 00 00 	sethi  %hi(0), %o0
     d60:	17 00 00 00 	sethi  %hi(0), %o3
     d64:	90 12 20 00 	mov  %o0, %o0
     d68:	92 12 60 00 	mov  %o1, %o1
     d6c:	94 10 22 30 	mov  0x230, %o2
     d70:	40 00 00 00 	call  d70 <jbd2_journal_commit_transaction+0x5ec>
     d74:	96 12 e0 00 	mov  %o3, %o3
     d78:	11 00 00 00 	sethi  %hi(0), %o0
     d7c:	40 00 00 00 	call  d7c <jbd2_journal_commit_transaction+0x5f8>
     d80:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>

			descriptor = jbd2_journal_get_descriptor_buffer(journal);
     d84:	40 00 00 00 	call  d84 <jbd2_journal_commit_transaction+0x600>
     d88:	90 10 00 18 	mov  %i0, %o0
     d8c:	ac 10 00 08 	mov  %o0, %l6
			if (!descriptor) {
				jbd2_journal_abort(journal, -EIO);
     d90:	92 10 3f fb 	mov  -5, %o1
			J_ASSERT (bufs == 0);

			jbd_debug(4, "JBD: get descriptor\n");

			descriptor = jbd2_journal_get_descriptor_buffer(journal);
			if (!descriptor) {
     d94:	02 c5 80 37 	brz,pn   %l6, e70 <jbd2_journal_commit_transaction+0x6ec>
     d98:	90 10 00 18 	mov  %i0, %o0
				jbd2_journal_abort(journal, -EIO);
				continue;
			}

			bh = jh2bh(descriptor);
			jbd_debug(4, "JBD: got buffer %llu (%p)\n",
     d9c:	05 00 00 00 	sethi  %hi(0), %g2
     da0:	84 10 a0 00 	mov  %g2, %g2	! 0 <write_tag_block>
     da4:	c2 08 80 00 	ldub  [ %g2 ], %g1
     da8:	80 a0 60 03 	cmp  %g1, 3
     dac:	08 48 00 0f 	bleu  %icc, de8 <jbd2_journal_commit_transaction+0x664>
     db0:	e0 5d 80 00 	ldx  [ %l6 ], %l0
     db4:	13 00 00 00 	sethi  %hi(0), %o1
     db8:	11 00 00 00 	sethi  %hi(0), %o0
     dbc:	17 00 00 00 	sethi  %hi(0), %o3
     dc0:	92 12 60 00 	mov  %o1, %o1
     dc4:	94 10 22 3a 	mov  0x23a, %o2
     dc8:	90 12 20 00 	mov  %o0, %o0
     dcc:	40 00 00 00 	call  dcc <jbd2_journal_commit_transaction+0x648>
     dd0:	96 12 e0 00 	mov  %o3, %o3
     dd4:	11 00 00 00 	sethi  %hi(0), %o0
     dd8:	d2 5c 20 18 	ldx  [ %l0 + 0x18 ], %o1
     ddc:	d4 5c 20 28 	ldx  [ %l0 + 0x28 ], %o2
     de0:	40 00 00 00 	call  de0 <jbd2_journal_commit_transaction+0x65c>
     de4:	90 12 20 00 	mov  %o0, %o0
				(unsigned long long)bh->b_blocknr, bh->b_data);
			header = (journal_header_t *)&bh->b_data[0];
     de8:	c4 5c 20 28 	ldx  [ %l0 + 0x28 ], %g2
			header->h_magic     = cpu_to_be32(JBD2_MAGIC_NUMBER);
     dec:	07 30 0e ce 	sethi  %hi(0xc03b3800), %g3
			header->h_blocktype = cpu_to_be32(JBD2_DESCRIPTOR_BLOCK);
     df0:	82 10 20 01 	mov  1, %g1

			bh = jh2bh(descriptor);
			jbd_debug(4, "JBD: got buffer %llu (%p)\n",
				(unsigned long long)bh->b_blocknr, bh->b_data);
			header = (journal_header_t *)&bh->b_data[0];
			header->h_magic     = cpu_to_be32(JBD2_MAGIC_NUMBER);
     df4:	86 10 e1 98 	or  %g3, 0x198, %g3
	BH_Unshadow,		/* Dummy bit, for BJ_Shadow wakeup filtering */
	BH_JBDPrivateStart,	/* First bit available for private use by FS */
};

BUFFER_FNS(JBD, jbd)
BUFFER_FNS(JWrite, jwrite)
     df8:	90 10 20 11 	mov  0x11, %o0
     dfc:	c6 20 80 00 	st  %g3, [ %g2 ]
     e00:	92 10 00 10 	mov  %l0, %o1
			wbuf[bufs++] = bh;

			/* Record it so that we can wait for IO
                           completion later */
			BUFFER_TRACE(bh, "ph3: file as descriptor");
			jbd2_journal_file_buffer(descriptor, commit_transaction,
     e04:	a8 10 20 01 	mov  1, %l4
			bh = jh2bh(descriptor);
			jbd_debug(4, "JBD: got buffer %llu (%p)\n",
				(unsigned long long)bh->b_blocknr, bh->b_data);
			header = (journal_header_t *)&bh->b_data[0];
			header->h_magic     = cpu_to_be32(JBD2_MAGIC_NUMBER);
			header->h_blocktype = cpu_to_be32(JBD2_DESCRIPTOR_BLOCK);
     e08:	c2 20 a0 04 	st  %g1, [ %g2 + 4 ]
			wbuf[bufs++] = bh;

			/* Record it so that we can wait for IO
                           completion later */
			BUFFER_TRACE(bh, "ph3: file as descriptor");
			jbd2_journal_file_buffer(descriptor, commit_transaction,
     e0c:	ba 10 20 01 	mov  1, %i5
			jbd_debug(4, "JBD: got buffer %llu (%p)\n",
				(unsigned long long)bh->b_blocknr, bh->b_data);
			header = (journal_header_t *)&bh->b_data[0];
			header->h_magic     = cpu_to_be32(JBD2_MAGIC_NUMBER);
			header->h_blocktype = cpu_to_be32(JBD2_DESCRIPTOR_BLOCK);
			header->h_sequence  = cpu_to_be32(commit_transaction->t_tid);
     e10:	c2 04 e0 08 	ld  [ %l3 + 8 ], %g1
     e14:	c2 20 a0 08 	st  %g1, [ %g2 + 8 ]

			tagp = &bh->b_data[sizeof(journal_header_t)];
     e18:	c2 5c 20 28 	ldx  [ %l0 + 0x28 ], %g1
			space_left = bh->b_size - sizeof(journal_header_t);
     e1c:	c4 5c 20 20 	ldx  [ %l0 + 0x20 ], %g2
			header = (journal_header_t *)&bh->b_data[0];
			header->h_magic     = cpu_to_be32(JBD2_MAGIC_NUMBER);
			header->h_blocktype = cpu_to_be32(JBD2_DESCRIPTOR_BLOCK);
			header->h_sequence  = cpu_to_be32(commit_transaction->t_tid);

			tagp = &bh->b_data[sizeof(journal_header_t)];
     e20:	aa 00 60 0c 	add  %g1, 0xc, %l5
     e24:	40 00 00 00 	call  e24 <jbd2_journal_commit_transaction+0x6a0>
     e28:	ae 00 bf f4 	add  %g2, -12, %l7
 * Emit the buffer bitops functions.   Note that there are also functions
 * of the form "mark_buffer_foo()".  These are higher-level functions which
 * do something in addition to setting a b_state bit.
 */
BUFFER_FNS(Uptodate, uptodate)
BUFFER_FNS(Dirty, dirty)
     e2c:	90 10 20 01 	mov  1, %o0
     e30:	40 00 00 00 	call  e30 <jbd2_journal_commit_transaction+0x6ac>
     e34:	92 10 00 10 	mov  %l0, %o1
			space_left = bh->b_size - sizeof(journal_header_t);
			first_tag = 1;
			set_buffer_jwrite(bh);
			set_buffer_dirty(bh);
			wbuf[bufs++] = bh;
     e38:	c2 5f a7 4f 	ldx  [ %fp + 0x74f ], %g1

			/* Record it so that we can wait for IO
                           completion later */
			BUFFER_TRACE(bh, "ph3: file as descriptor");
			jbd2_journal_file_buffer(descriptor, commit_transaction,
     e3c:	90 10 00 16 	mov  %l6, %o0
     e40:	92 10 00 13 	mov  %l3, %o1
     e44:	94 10 20 05 	mov  5, %o2
     e48:	40 00 00 00 	call  e48 <jbd2_journal_commit_transaction+0x6c4>
     e4c:	e0 70 40 00 	stx  %l0, [ %g1 ]
					BJ_LogCtl);
		}

		/* Where is the buffer to be written? */

		err = jbd2_journal_next_log_block(journal, &blocknr);
     e50:	90 10 00 18 	mov  %i0, %o0
     e54:	40 00 00 00 	call  e54 <jbd2_journal_commit_transaction+0x6d0>
     e58:	92 07 a7 df 	add  %fp, 0x7df, %o1
		/* If the block mapping failed, just abandon the buffer
		   and repeat this loop: we'll fall into the
		   refile-on-abort condition above. */
		if (err) {
     e5c:	80 a2 20 00 	cmp  %o0, 0
     e60:	22 48 00 08 	be,a   %icc, e80 <jbd2_journal_commit_transaction+0x6fc>
     e64:	c2 04 e0 d4 	ld  [ %l3 + 0xd4 ], %g1
			jbd2_journal_abort(journal, err);
     e68:	93 3a 20 00 	sra  %o0, 0, %o1
     e6c:	90 10 00 18 	mov  %i0, %o0
     e70:	40 00 00 00 	call  e70 <jbd2_journal_commit_transaction+0x6ec>
     e74:	01 00 00 00 	nop 
		 commit_transaction->t_outstanding_credits);

	err = 0;
	descriptor = NULL;
	bufs = 0;
	while (commit_transaction->t_buffers) {
     e78:	10 68 00 88 	b  %xcc, 1098 <jbd2_journal_commit_transaction+0x914>
     e7c:	e4 5c e0 28 	ldx  [ %l3 + 0x28 ], %l2
		commit_transaction->t_outstanding_credits--;

		/* Bump b_count to prevent truncate from stumbling over
                   the shadowed buffer!  @@@ This can go if we ever get
                   rid of the BJ_IO/BJ_Shadow pairing of buffers. */
		atomic_inc(&jh2bh(jh)->b_count);
     e80:	90 10 20 01 	mov  1, %o0
		if (flags & 1)
			tag_flag |= JBD2_FLAG_ESCAPE;
		if (!first_tag)
			tag_flag |= JBD2_FLAG_SAME_UUID;

		tag = (journal_block_tag_t *) tagp;
     e84:	b8 10 00 15 	mov  %l5, %i4
		write_tag_block(tag_bytes, tag, jh2bh(jh)->b_blocknr);
		tag->t_flags = cpu_to_be32(tag_flag);
		tagp += tag_bytes;
		space_left -= tag_bytes;
     e88:	c4 07 a7 5b 	ld  [ %fp + 0x75b ], %g2
		/*
		 * start_this_handle() uses t_outstanding_credits to determine
		 * the free space in the log, but this counter is changed
		 * by jbd2_journal_next_log_block() also.
		 */
		commit_transaction->t_outstanding_credits--;
     e8c:	82 00 7f ff 	add  %g1, -1, %g1
			tag_flag |= JBD2_FLAG_ESCAPE;
		if (!first_tag)
			tag_flag |= JBD2_FLAG_SAME_UUID;

		tag = (journal_block_tag_t *) tagp;
		write_tag_block(tag_bytes, tag, jh2bh(jh)->b_blocknr);
     e90:	e2 47 a7 5b 	ldsw  [ %fp + 0x75b ], %l1
		/*
		 * start_this_handle() uses t_outstanding_credits to determine
		 * the free space in the log, but this counter is changed
		 * by jbd2_journal_next_log_block() also.
		 */
		commit_transaction->t_outstanding_credits--;
     e94:	c2 24 e0 d4 	st  %g1, [ %l3 + 0xd4 ]

		tag = (journal_block_tag_t *) tagp;
		write_tag_block(tag_bytes, tag, jh2bh(jh)->b_blocknr);
		tag->t_flags = cpu_to_be32(tag_flag);
		tagp += tag_bytes;
		space_left -= tag_bytes;
     e98:	ae 25 c0 02 	sub  %l7, %g2, %l7
		commit_transaction->t_outstanding_credits--;

		/* Bump b_count to prevent truncate from stumbling over
                   the shadowed buffer!  @@@ This can go if we ever get
                   rid of the BJ_IO/BJ_Shadow pairing of buffers. */
		atomic_inc(&jh2bh(jh)->b_count);
     e9c:	d2 5c 80 00 	ldx  [ %l2 ], %o1
     ea0:	40 00 00 00 	call  ea0 <jbd2_journal_commit_transaction+0x71c>
     ea4:	92 02 60 60 	add  %o1, 0x60, %o1

		/* Make a temporary IO buffer with which to write it out
                   (this will requeue both the metadata buffer and the
                   temporary IO buffer). new_bh goes on BJ_IO*/

		set_bit(BH_JWrite, &jh2bh(jh)->b_state);
     ea8:	d2 5c 80 00 	ldx  [ %l2 ], %o1
     eac:	40 00 00 00 	call  eac <jbd2_journal_commit_transaction+0x728>
     eb0:	90 10 20 11 	mov  0x11, %o0
		 * new_bh->b_transaction to commit_transaction.
		 * We need to clean this up before we release new_bh
		 * (which is of type BJ_IO)
		 */
		JBUFFER_TRACE(jh, "ph3: write metadata");
		flags = jbd2_journal_write_metadata_buffer(commit_transaction,
     eb4:	d6 5f a7 df 	ldx  [ %fp + 0x7df ], %o3
     eb8:	94 07 a7 e7 	add  %fp, 0x7e7, %o2
     ebc:	92 10 00 12 	mov  %l2, %o1
     ec0:	40 00 00 00 	call  ec0 <jbd2_journal_commit_transaction+0x73c>
     ec4:	90 10 00 13 	mov  %l3, %o0
						      jh, &new_jh, blocknr);
		set_bit(BH_JWrite, &jh2bh(new_jh)->b_state);
     ec8:	c2 5f a7 e7 	ldx  [ %fp + 0x7e7 ], %g1
		 * new_bh->b_transaction to commit_transaction.
		 * We need to clean this up before we release new_bh
		 * (which is of type BJ_IO)
		 */
		JBUFFER_TRACE(jh, "ph3: write metadata");
		flags = jbd2_journal_write_metadata_buffer(commit_transaction,
     ecc:	a0 10 00 08 	mov  %o0, %l0
						      jh, &new_jh, blocknr);
		set_bit(BH_JWrite, &jh2bh(new_jh)->b_state);
     ed0:	90 10 20 11 	mov  0x11, %o0
		wbuf[bufs++] = jh2bh(new_jh);
     ed4:	a0 0c 20 01 	and  %l0, 1, %l0
		 * (which is of type BJ_IO)
		 */
		JBUFFER_TRACE(jh, "ph3: write metadata");
		flags = jbd2_journal_write_metadata_buffer(commit_transaction,
						      jh, &new_jh, blocknr);
		set_bit(BH_JWrite, &jh2bh(new_jh)->b_state);
     ed8:	40 00 00 00 	call  ed8 <jbd2_journal_commit_transaction+0x754>
     edc:	d2 58 40 00 	ldx  [ %g1 ], %o1

		tag_flag = 0;
		if (flags & 1)
			tag_flag |= JBD2_FLAG_ESCAPE;
		if (!first_tag)
			tag_flag |= JBD2_FLAG_SAME_UUID;
     ee0:	80 a7 60 00 	cmp  %i5, 0
     ee4:	82 14 20 02 	or  %l0, 2, %g1
		 */
		JBUFFER_TRACE(jh, "ph3: write metadata");
		flags = jbd2_journal_write_metadata_buffer(commit_transaction,
						      jh, &new_jh, blocknr);
		set_bit(BH_JWrite, &jh2bh(new_jh)->b_state);
		wbuf[bufs++] = jh2bh(new_jh);
     ee8:	c6 5f a7 4f 	ldx  [ %fp + 0x74f ], %g3

		tag_flag = 0;
		if (flags & 1)
			tag_flag |= JBD2_FLAG_ESCAPE;
		if (!first_tag)
			tag_flag |= JBD2_FLAG_SAME_UUID;
     eec:	a1 64 40 01 	move  %icc, %g1, %l0
		 */
		JBUFFER_TRACE(jh, "ph3: write metadata");
		flags = jbd2_journal_write_metadata_buffer(commit_transaction,
						      jh, &new_jh, blocknr);
		set_bit(BH_JWrite, &jh2bh(new_jh)->b_state);
		wbuf[bufs++] = jh2bh(new_jh);
     ef0:	85 3d 20 00 	sra  %l4, 0, %g2
			tag_flag |= JBD2_FLAG_ESCAPE;
		if (!first_tag)
			tag_flag |= JBD2_FLAG_SAME_UUID;

		tag = (journal_block_tag_t *) tagp;
		write_tag_block(tag_bytes, tag, jh2bh(jh)->b_blocknr);
     ef4:	92 10 00 15 	mov  %l5, %o1
		 */
		JBUFFER_TRACE(jh, "ph3: write metadata");
		flags = jbd2_journal_write_metadata_buffer(commit_transaction,
						      jh, &new_jh, blocknr);
		set_bit(BH_JWrite, &jh2bh(new_jh)->b_state);
		wbuf[bufs++] = jh2bh(new_jh);
     ef8:	c2 5f a7 e7 	ldx  [ %fp + 0x7e7 ], %g1
     efc:	85 28 b0 03 	sllx  %g2, 3, %g2
			tag_flag |= JBD2_FLAG_ESCAPE;
		if (!first_tag)
			tag_flag |= JBD2_FLAG_SAME_UUID;

		tag = (journal_block_tag_t *) tagp;
		write_tag_block(tag_bytes, tag, jh2bh(jh)->b_blocknr);
     f00:	90 10 00 11 	mov  %l1, %o0
		 */
		JBUFFER_TRACE(jh, "ph3: write metadata");
		flags = jbd2_journal_write_metadata_buffer(commit_transaction,
						      jh, &new_jh, blocknr);
		set_bit(BH_JWrite, &jh2bh(new_jh)->b_state);
		wbuf[bufs++] = jh2bh(new_jh);
     f04:	a8 05 20 01 	inc  %l4
     f08:	c2 58 40 00 	ldx  [ %g1 ], %g1
     f0c:	c2 70 c0 02 	stx  %g1, [ %g3 + %g2 ]
			tag_flag |= JBD2_FLAG_ESCAPE;
		if (!first_tag)
			tag_flag |= JBD2_FLAG_SAME_UUID;

		tag = (journal_block_tag_t *) tagp;
		write_tag_block(tag_bytes, tag, jh2bh(jh)->b_blocknr);
     f10:	c2 5c 80 00 	ldx  [ %l2 ], %g1
     f14:	7f ff fc 3b 	call  0 <write_tag_block>
     f18:	d4 58 60 18 	ldx  [ %g1 + 0x18 ], %o2
		tag->t_flags = cpu_to_be32(tag_flag);
     f1c:	e0 25 60 04 	st  %l0, [ %l5 + 4 ]
		tagp += tag_bytes;
		space_left -= tag_bytes;

		if (first_tag) {
     f20:	80 a7 60 00 	cmp  %i5, 0
     f24:	02 48 00 08 	be  %icc, f44 <jbd2_journal_commit_transaction+0x7c0>
     f28:	aa 05 40 11 	add  %l5, %l1, %l5
			memcpy (tagp, journal->j_uuid, 16);
     f2c:	d2 5f a7 47 	ldx  [ %fp + 0x747 ], %o1
     f30:	90 10 00 15 	mov  %l5, %o0
     f34:	94 10 20 10 	mov  0x10, %o2
			tagp += 16;
     f38:	aa 05 60 10 	add  %l5, 0x10, %l5
		tag->t_flags = cpu_to_be32(tag_flag);
		tagp += tag_bytes;
		space_left -= tag_bytes;

		if (first_tag) {
			memcpy (tagp, journal->j_uuid, 16);
     f3c:	40 00 00 00 	call  f3c <jbd2_journal_commit_transaction+0x7b8>
     f40:	ae 05 ff f0 	add  %l7, -16, %l7
		}

		/* If there's no more to do, or if the descriptor is full,
		   let the IO rip! */

		if (bufs == journal->j_wbufsize ||
     f44:	c2 06 26 60 	ld  [ %i0 + 0x660 ], %g1
     f48:	80 a5 00 01 	cmp  %l4, %g1
     f4c:	02 40 00 0a 	be,pn   %icc, f74 <jbd2_journal_commit_transaction+0x7f0>
     f50:	07 00 00 00 	sethi  %hi(0), %g3
     f54:	c2 5c e0 28 	ldx  [ %l3 + 0x28 ], %g1
     f58:	02 c0 40 07 	brz,pn   %g1, f74 <jbd2_journal_commit_transaction+0x7f0>
     f5c:	c4 07 a7 5b 	ld  [ %fp + 0x75b ], %g2
     f60:	82 00 a0 10 	add  %g2, 0x10, %g1
     f64:	80 a5 c0 01 	cmp  %l7, %g1
     f68:	16 48 00 4b 	bge  %icc, 1094 <jbd2_journal_commit_transaction+0x910>
     f6c:	ba 10 20 00 	clr  %i5
		    commit_transaction->t_buffers == NULL ||
		    space_left < tag_bytes + 16) {

			jbd_debug(4, "JBD: Submit %d IOs\n", bufs);
     f70:	07 00 00 00 	sethi  %hi(0), %g3
     f74:	86 10 e0 00 	mov  %g3, %g3	! 0 <write_tag_block>
     f78:	c2 08 c0 00 	ldub  [ %g3 ], %g1
     f7c:	80 a0 60 03 	cmp  %g1, 3
     f80:	28 48 00 0f 	bleu,a   %icc, fbc <jbd2_journal_commit_transaction+0x838>
     f84:	c2 07 20 04 	ld  [ %i4 + 4 ], %g1
     f88:	13 00 00 00 	sethi  %hi(0), %o1
     f8c:	11 00 00 00 	sethi  %hi(0), %o0
     f90:	17 00 00 00 	sethi  %hi(0), %o3
     f94:	92 12 60 00 	mov  %o1, %o1
     f98:	90 12 20 00 	mov  %o0, %o0
     f9c:	94 10 22 93 	mov  0x293, %o2
     fa0:	40 00 00 00 	call  fa0 <jbd2_journal_commit_transaction+0x81c>
     fa4:	96 12 e0 00 	mov  %o3, %o3
     fa8:	11 00 00 00 	sethi  %hi(0), %o0
     fac:	93 3d 20 00 	sra  %l4, 0, %o1
     fb0:	40 00 00 00 	call  fb0 <jbd2_journal_commit_transaction+0x82c>
     fb4:	90 12 20 00 	mov  %o0, %o0

			/* Write an end-of-descriptor marker before
                           submitting the IOs.  "tag" still points to
                           the last tag we set up. */

			tag->t_flags |= cpu_to_be32(JBD2_FLAG_LAST_TAG);
     fb8:	c2 07 20 04 	ld  [ %i4 + 4 ], %g1
     fbc:	ba 10 20 00 	clr  %i5
     fc0:	82 10 60 08 	or  %g1, 8, %g1
     fc4:	c2 27 20 04 	st  %g1, [ %i4 + 4 ]

start_journal_io:
     fc8:	e4 5f a7 4f 	ldx  [ %fp + 0x74f ], %l2
     fcc:	10 68 00 28 	b  %xcc, 106c <jbd2_journal_commit_transaction+0x8e8>
     fd0:	a2 10 20 00 	clr  %l1
			for (i = 0; i < bufs; i++) {
				struct buffer_head *bh = wbuf[i];
				/*
				 * Compute checksum.
				 */
				if (JBD2_HAS_COMPAT_FEATURE(journal,
     fd4:	80 a0 60 01 	cmp  %g1, 1
     fd8:	04 40 00 0b 	ble,pn   %icc, 1004 <jbd2_journal_commit_transaction+0x880>
     fdc:	e0 5c 80 00 	ldx  [ %l2 ], %l0
     fe0:	c2 5e 20 18 	ldx  [ %i0 + 0x18 ], %g1
     fe4:	c2 00 60 24 	ld  [ %g1 + 0x24 ], %g1
     fe8:	80 88 60 01 	btst  1, %g1
     fec:	22 68 00 07 	be,a   %xcc, 1008 <jbd2_journal_commit_transaction+0x884>
     ff0:	11 00 00 00 	sethi  %hi(0), %o0
					JBD2_FEATURE_COMPAT_CHECKSUM)) {
					crc32_sum =
     ff4:	91 36 60 00 	srl  %i1, 0, %o0
     ff8:	7f ff fc 5b 	call  164 <jbd2_checksum_data>
     ffc:	92 10 00 10 	mov  %l0, %o1
    1000:	b2 10 00 08 	mov  %o0, %i1
	return likely(!test_and_set_bit_lock(BH_Lock, &bh->b_state));
}

static inline void lock_buffer(struct buffer_head *bh)
{
	might_sleep();
    1004:	11 00 00 00 	sethi  %hi(0), %o0
    1008:	92 10 21 4b 	mov  0x14b, %o1
    100c:	40 00 00 00 	call  100c <jbd2_journal_commit_transaction+0x888>
    1010:	90 12 20 00 	mov  %o0, %o0
		__wait_on_buffer(bh);
}

static inline int trylock_buffer(struct buffer_head *bh)
{
	return likely(!test_and_set_bit_lock(BH_Lock, &bh->b_state));
    1014:	90 10 20 02 	mov  2, %o0
    1018:	40 00 00 00 	call  1018 <jbd2_journal_commit_transaction+0x894>
    101c:	92 10 00 10 	mov  %l0, %o1
}

static inline void lock_buffer(struct buffer_head *bh)
{
	might_sleep();
	if (!trylock_buffer(bh))
    1020:	80 a2 20 00 	cmp  %o0, 0
    1024:	02 48 00 05 	be  %icc, 1038 <jbd2_journal_commit_transaction+0x8b4>
    1028:	90 10 20 01 	mov  1, %o0
		__lock_buffer(bh);
    102c:	40 00 00 00 	call  102c <jbd2_journal_commit_transaction+0x8a8>
    1030:	90 10 00 10 	mov  %l0, %o0
 * Emit the buffer bitops functions.   Note that there are also functions
 * of the form "mark_buffer_foo()".  These are higher-level functions which
 * do something in addition to setting a b_state bit.
 */
BUFFER_FNS(Uptodate, uptodate)
BUFFER_FNS(Dirty, dirty)
    1034:	90 10 20 01 	mov  1, %o0
    1038:	40 00 00 00 	call  1038 <jbd2_journal_commit_transaction+0x8b4>
    103c:	92 10 00 10 	mov  %l0, %o1
                           the last tag we set up. */

			tag->t_flags |= cpu_to_be32(JBD2_FLAG_LAST_TAG);

start_journal_io:
			for (i = 0; i < bufs; i++) {
    1040:	a2 04 60 01 	inc  %l1
    1044:	a4 04 a0 08 	add  %l2, 8, %l2
/*
 * Emit the buffer bitops functions.   Note that there are also functions
 * of the form "mark_buffer_foo()".  These are higher-level functions which
 * do something in addition to setting a b_state bit.
 */
BUFFER_FNS(Uptodate, uptodate)
    1048:	90 10 20 00 	clr  %o0
    104c:	40 00 00 00 	call  104c <jbd2_journal_commit_transaction+0x8c8>
    1050:	92 10 00 10 	mov  %l0, %o1
				}

				lock_buffer(bh);
				clear_buffer_dirty(bh);
				set_buffer_uptodate(bh);
				bh->b_end_io = journal_end_buffer_io_sync;
    1054:	03 00 00 00 	sethi  %hi(0), %g1
				submit_bh(WRITE, bh);
    1058:	92 10 00 10 	mov  %l0, %o1
				}

				lock_buffer(bh);
				clear_buffer_dirty(bh);
				set_buffer_uptodate(bh);
				bh->b_end_io = journal_end_buffer_io_sync;
    105c:	82 10 60 00 	mov  %g1, %g1
				submit_bh(WRITE, bh);
    1060:	90 10 20 01 	mov  1, %o0
    1064:	40 00 00 00 	call  1064 <jbd2_journal_commit_transaction+0x8e0>
    1068:	c2 74 20 38 	stx  %g1, [ %l0 + 0x38 ]
                           the last tag we set up. */

			tag->t_flags |= cpu_to_be32(JBD2_FLAG_LAST_TAG);

start_journal_io:
			for (i = 0; i < bufs; i++) {
    106c:	80 a4 40 14 	cmp  %l1, %l4
    1070:	26 4f ff d9 	bl,a   %icc, fd4 <jbd2_journal_commit_transaction+0x850>
    1074:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1
	return 0;
}
#else
static inline int cond_resched(void)
{
	return _cond_resched();
    1078:	40 00 00 00 	call  1078 <jbd2_journal_commit_transaction+0x8f4>
    107c:	ac 10 20 00 	clr  %l6
				set_buffer_uptodate(bh);
				bh->b_end_io = journal_end_buffer_io_sync;
				submit_bh(WRITE, bh);
			}
			cond_resched();
			stats.u.run.rs_blocks_logged += bufs;
    1080:	c2 5f a7 a7 	ldx  [ %fp + 0x7a7 ], %g1
    1084:	85 3d 20 00 	sra  %l4, 0, %g2
    1088:	a8 10 20 00 	clr  %l4
    108c:	82 00 40 02 	add  %g1, %g2, %g1
    1090:	c2 77 a7 a7 	stx  %g1, [ %fp + 0x7a7 ]
		 commit_transaction->t_outstanding_credits);

	err = 0;
	descriptor = NULL;
	bufs = 0;
	while (commit_transaction->t_buffers) {
    1094:	e4 5c e0 28 	ldx  [ %l3 + 0x28 ], %l2
    1098:	2a fc bf 10 	brnz,a   %l2, cd8 <jbd2_journal_commit_transaction+0x554>
    109c:	c2 5e 00 00 	ldx  [ %i0 ], %g1
		}
	}

	/* Done it all: now write the commit record asynchronously. */

	if (JBD2_HAS_INCOMPAT_FEATURE(journal,
    10a0:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1
    10a4:	80 a0 60 01 	cmp  %g1, 1
    10a8:	04 40 00 10 	ble,pn   %icc, 10e8 <jbd2_journal_commit_transaction+0x964>
    10ac:	90 10 00 18 	mov  %i0, %o0
    10b0:	c2 5e 20 18 	ldx  [ %i0 + 0x18 ], %g1
    10b4:	c2 00 60 28 	ld  [ %g1 + 0x28 ], %g1
    10b8:	80 88 60 04 	btst  4, %g1
    10bc:	02 68 00 0b 	be  %xcc, 10e8 <jbd2_journal_commit_transaction+0x964>
    10c0:	92 10 00 13 	mov  %l3, %o1
		JBD2_FEATURE_INCOMPAT_ASYNC_COMMIT)) {
		err = journal_submit_commit_record(journal, commit_transaction,
    10c4:	94 07 a7 d7 	add  %fp, 0x7d7, %o2
    10c8:	7f ff fc 8b 	call  2f4 <journal_submit_commit_record>
    10cc:	97 36 60 00 	srl  %i1, 0, %o3
						 &cbh, crc32_sum);
		if (err)
    10d0:	80 a2 20 00 	cmp  %o0, 0
    10d4:	02 48 00 05 	be  %icc, 10e8 <jbd2_journal_commit_transaction+0x964>
    10d8:	90 10 00 18 	mov  %i0, %o0
			__jbd2_journal_abort_hard(journal);
    10dc:	40 00 00 00 	call  10dc <jbd2_journal_commit_transaction+0x958>
    10e0:	90 10 00 18 	mov  %i0, %o0
	 * and !ASYNC commit. If commit is ASYNC, we need to wait only after
	 * the commit block went to disk (which happens above). If commit is
	 * SYNC, we need to wait for data buffers before we start writing
	 * commit block, which happens below in such setting.
	 */
	err = journal_finish_inode_data_buffers(journal, commit_transaction);
    10e4:	90 10 00 18 	mov  %i0, %o0
    10e8:	7f ff fc 3a 	call  1d0 <journal_finish_inode_data_buffers>
    10ec:	92 10 00 13 	mov  %l3, %o1
	if (err) {
    10f0:	a4 92 20 00 	orcc  %o0, 0, %l2
    10f4:	02 48 00 0f 	be  %icc, 1130 <jbd2_journal_commit_transaction+0x9ac>
    10f8:	03 00 00 00 	sethi  %hi(0), %g1
		printk(KERN_WARNING
    10fc:	11 00 00 00 	sethi  %hi(0), %o0
    1100:	92 06 25 28 	add  %i0, 0x528, %o1
    1104:	40 00 00 00 	call  1104 <jbd2_journal_commit_transaction+0x980>
    1108:	90 12 20 00 	mov  %o0, %o0
			"JBD2: Detected IO errors while flushing file data "
		       "on %s\n", journal->j_devname);
		if (journal->j_flags & JBD2_ABORT_ON_SYNCDATA_ERR)
    110c:	c2 5e 00 00 	ldx  [ %i0 ], %g1
    1110:	82 08 60 40 	and  %g1, 0x40, %g1
    1114:	22 c8 40 06 	brz,a   %g1, 112c <jbd2_journal_commit_transaction+0x9a8>
    1118:	a4 10 20 00 	clr  %l2
			jbd2_journal_abort(journal, err);
    111c:	93 3c a0 00 	sra  %l2, 0, %o1
    1120:	40 00 00 00 	call  1120 <jbd2_journal_commit_transaction+0x99c>
    1124:	90 10 00 18 	mov  %i0, %o0
    1128:	a4 10 20 00 	clr  %l2
	   Wait for the buffers in reverse order.  That way we are
	   less likely to be woken up until all IOs have completed, and
	   so we incur less scheduling load.
	*/

	jbd_debug(3, "JBD: commit phase 3\n");
    112c:	03 00 00 00 	sethi  %hi(0), %g1
    1130:	c2 08 60 00 	ldub  [ %g1 ], %g1
    1134:	80 a0 60 02 	cmp  %g1, 2
    1138:	28 48 00 50 	bleu,a   %icc, 1278 <jbd2_journal_commit_transaction+0xaf4>
    113c:	03 00 00 00 	sethi  %hi(0), %g1
    1140:	11 00 00 00 	sethi  %hi(0), %o0
    1144:	13 00 00 00 	sethi  %hi(0), %o1
    1148:	17 00 00 00 	sethi  %hi(0), %o3
    114c:	92 12 60 00 	mov  %o1, %o1
    1150:	96 12 e0 00 	mov  %o3, %o3
    1154:	94 10 22 dd 	mov  0x2dd, %o2
    1158:	40 00 00 00 	call  1158 <jbd2_journal_commit_transaction+0x9d4>
    115c:	90 12 20 00 	mov  %o0, %o0
    1160:	11 00 00 00 	sethi  %hi(0), %o0
    1164:	40 00 00 00 	call  1164 <jbd2_journal_commit_transaction+0x9e0>
    1168:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>
 * __wait_on_buffer() just to trip a debug check.  Because debug code in inline
 * functions is bloaty.
 */
static inline void wait_on_buffer(struct buffer_head *bh)
{
	might_sleep();
    116c:	10 68 00 43 	b  %xcc, 1278 <jbd2_journal_commit_transaction+0xaf4>
    1170:	03 00 00 00 	sethi  %hi(0), %g1
TAS_BUFFER_FNS(RevokeValid, revokevalid)
BUFFER_FNS(Freed, freed)

static inline struct buffer_head *jh2bh(struct journal_head *jh)
{
	return jh->b_bh;
    1174:	e0 5c 40 00 	ldx  [ %l1 ], %l0
    1178:	c2 5c 00 00 	ldx  [ %l0 ], %g1
	while (commit_transaction->t_iobuf_list != NULL) {
		struct buffer_head *bh;

		jh = commit_transaction->t_iobuf_list->b_tprev;
		bh = jh2bh(jh);
		if (buffer_locked(bh)) {
    117c:	82 08 60 04 	and  %g1, 4, %g1
    1180:	02 c8 40 10 	brz  %g1, 11c0 <jbd2_journal_commit_transaction+0xa3c>
    1184:	90 10 00 14 	mov  %l4, %o0
    1188:	40 00 00 00 	call  1188 <jbd2_journal_commit_transaction+0xa04>
    118c:	92 10 21 3f 	mov  0x13f, %o1
    1190:	c2 5c 00 00 	ldx  [ %l0 ], %g1
	if (buffer_locked(bh) || atomic_read(&bh->b_count) == 0)
    1194:	82 08 60 04 	and  %g1, 4, %g1
    1198:	0a c0 40 06 	brnz,pn   %g1, 11b0 <jbd2_journal_commit_transaction+0xa2c>
    119c:	01 00 00 00 	nop 
    11a0:	c2 04 20 60 	ld  [ %l0 + 0x60 ], %g1
    11a4:	80 a0 60 00 	cmp  %g1, 0
    11a8:	32 48 00 37 	bne,a   %icc, 1284 <jbd2_journal_commit_transaction+0xb00>
    11ac:	d0 5c e0 48 	ldx  [ %l3 + 0x48 ], %o0
		__wait_on_buffer(bh);
    11b0:	40 00 00 00 	call  11b0 <jbd2_journal_commit_transaction+0xa2c>
    11b4:	90 10 00 10 	mov  %l0, %o0
	/*
	 * akpm: these are BJ_IO, and j_list_lock is not needed.
	 * See __journal_try_to_free_buffer.
	 */
wait_for_iobuf:
	while (commit_transaction->t_iobuf_list != NULL) {
    11b8:	10 68 00 33 	b  %xcc, 1284 <jbd2_journal_commit_transaction+0xb00>
    11bc:	d0 5c e0 48 	ldx  [ %l3 + 0x48 ], %o0
    11c0:	40 00 00 00 	call  11c0 <jbd2_journal_commit_transaction+0xa3c>
    11c4:	01 00 00 00 	nop 
		bh = jh2bh(jh);
		if (buffer_locked(bh)) {
			wait_on_buffer(bh);
			goto wait_for_iobuf;
		}
		if (cond_resched())
    11c8:	80 a2 20 00 	cmp  %o0, 0
    11cc:	32 48 00 2e 	bne,a   %icc, 1284 <jbd2_journal_commit_transaction+0xb00>
    11d0:	d0 5c e0 48 	ldx  [ %l3 + 0x48 ], %o0
    11d4:	c2 5c 00 00 	ldx  [ %l0 ], %g1
	BH_Unshadow,		/* Dummy bit, for BJ_Shadow wakeup filtering */
	BH_JBDPrivateStart,	/* First bit available for private use by FS */
};

BUFFER_FNS(JBD, jbd)
BUFFER_FNS(JWrite, jwrite)
    11d8:	90 10 20 11 	mov  0x11, %o0
    11dc:	92 10 00 10 	mov  %l0, %o1
			goto wait_for_iobuf;

		if (unlikely(!buffer_uptodate(bh)))
    11e0:	80 88 60 01 	btst  1, %g1
    11e4:	40 00 00 00 	call  11e4 <jbd2_journal_commit_transaction+0xa60>
    11e8:	a5 64 77 fb 	move  %xcc, -5, %l2
			err = -EIO;

		clear_buffer_jwrite(bh);

		JBUFFER_TRACE(jh, "ph4: unfile after journal write");
		jbd2_journal_unfile_buffer(journal, jh);
    11ec:	92 10 00 11 	mov  %l1, %o1
    11f0:	40 00 00 00 	call  11f0 <jbd2_journal_commit_transaction+0xa6c>
    11f4:	90 10 00 18 	mov  %i0, %o0
		/*
		 * ->t_iobuf_list should contain only dummy buffer_heads
		 * which were created by jbd2_journal_write_metadata_buffer().
		 */
		BUFFER_TRACE(bh, "dumping temporary bh");
		jbd2_journal_put_journal_head(jh);
    11f8:	40 00 00 00 	call  11f8 <jbd2_journal_commit_transaction+0xa74>
    11fc:	90 10 00 11 	mov  %l1, %o0
		__brelse(bh);
    1200:	40 00 00 00 	call  1200 <jbd2_journal_commit_transaction+0xa7c>
    1204:	90 10 00 10 	mov  %l0, %o0
		J_ASSERT_BH(bh, atomic_read(&bh->b_count) == 0);
    1208:	c2 04 20 60 	ld  [ %l0 + 0x60 ], %g1
    120c:	80 a0 60 00 	cmp  %g1, 0
    1210:	12 47 fd 95 	bne,pn   %icc, 864 <jbd2_journal_commit_transaction+0xe0>
    1214:	92 10 22 ff 	mov  0x2ff, %o1
		free_buffer_head(bh);
    1218:	40 00 00 00 	call  1218 <jbd2_journal_commit_transaction+0xa94>
    121c:	90 10 00 10 	mov  %l0, %o0

		/* We also have to unlock and free the corresponding
                   shadowed buffer */
		jh = commit_transaction->t_shadow_list->b_tprev;
    1220:	c2 5c e0 50 	ldx  [ %l3 + 0x50 ], %g1
		bh = jh2bh(jh);
		clear_bit(BH_JWrite, &bh->b_state);
    1224:	90 10 20 11 	mov  0x11, %o0
		J_ASSERT_BH(bh, atomic_read(&bh->b_count) == 0);
		free_buffer_head(bh);

		/* We also have to unlock and free the corresponding
                   shadowed buffer */
		jh = commit_transaction->t_shadow_list->b_tprev;
    1228:	e2 58 60 40 	ldx  [ %g1 + 0x40 ], %l1
TAS_BUFFER_FNS(RevokeValid, revokevalid)
BUFFER_FNS(Freed, freed)

static inline struct buffer_head *jh2bh(struct journal_head *jh)
{
	return jh->b_bh;
    122c:	e0 5c 40 00 	ldx  [ %l1 ], %l0
		bh = jh2bh(jh);
		clear_bit(BH_JWrite, &bh->b_state);
    1230:	40 00 00 00 	call  1230 <jbd2_journal_commit_transaction+0xaac>
    1234:	92 10 00 10 	mov  %l0, %o1
    1238:	c2 5c 00 00 	ldx  [ %l0 ], %g1
		J_ASSERT_BH(bh, buffer_jbddirty(bh));
    123c:	82 08 40 15 	and  %g1, %l5, %g1
    1240:	0a c8 40 04 	brnz  %g1, 1250 <jbd2_journal_commit_transaction+0xacc>
    1244:	90 10 00 11 	mov  %l1, %o0
    1248:	10 6f fd 87 	b  %xcc, 864 <jbd2_journal_commit_transaction+0xe0>
    124c:	92 10 23 07 	mov  0x307, %o1
		/* The metadata is now released for reuse, but we need
                   to remember it against this transaction so that when
                   we finally commit, we can do any checkpointing
                   required. */
		JBUFFER_TRACE(jh, "file as BJ_Forget");
		jbd2_journal_file_buffer(jh, commit_transaction, BJ_Forget);
    1250:	92 10 00 13 	mov  %l3, %o1
    1254:	40 00 00 00 	call  1254 <jbd2_journal_commit_transaction+0xad0>
    1258:	94 10 20 02 	mov  2, %o2
		/* Wake up any transactions which were waiting for this
		   IO to complete */
		wake_up_bit(&bh->b_state, BH_Unshadow);
    125c:	90 10 00 10 	mov  %l0, %o0
    1260:	40 00 00 00 	call  1260 <jbd2_journal_commit_transaction+0xadc>
    1264:	92 10 20 18 	mov  0x18, %o1
		JBUFFER_TRACE(jh, "brelse shadowed buffer");
		__brelse(bh);
    1268:	40 00 00 00 	call  1268 <jbd2_journal_commit_transaction+0xae4>
    126c:	90 10 00 10 	mov  %l0, %o0
	/*
	 * akpm: these are BJ_IO, and j_list_lock is not needed.
	 * See __journal_try_to_free_buffer.
	 */
wait_for_iobuf:
	while (commit_transaction->t_iobuf_list != NULL) {
    1270:	10 68 00 05 	b  %xcc, 1284 <jbd2_journal_commit_transaction+0xb00>
    1274:	d0 5c e0 48 	ldx  [ %l3 + 0x48 ], %o0
		/* We also have to unlock and free the corresponding
                   shadowed buffer */
		jh = commit_transaction->t_shadow_list->b_tprev;
		bh = jh2bh(jh);
		clear_bit(BH_JWrite, &bh->b_state);
		J_ASSERT_BH(bh, buffer_jbddirty(bh));
    1278:	2b 00 08 00 	sethi  %hi(0x200000), %l5
 * __wait_on_buffer() just to trip a debug check.  Because debug code in inline
 * functions is bloaty.
 */
static inline void wait_on_buffer(struct buffer_head *bh)
{
	might_sleep();
    127c:	a8 10 60 00 	mov  %g1, %l4
	/*
	 * akpm: these are BJ_IO, and j_list_lock is not needed.
	 * See __journal_try_to_free_buffer.
	 */
wait_for_iobuf:
	while (commit_transaction->t_iobuf_list != NULL) {
    1280:	d0 5c e0 48 	ldx  [ %l3 + 0x48 ], %o0
    1284:	2a fa 3f bc 	brnz,a   %o0, 1174 <jbd2_journal_commit_transaction+0x9f0>
    1288:	e2 5a 20 40 	ldx  [ %o0 + 0x40 ], %l1
		wake_up_bit(&bh->b_state, BH_Unshadow);
		JBUFFER_TRACE(jh, "brelse shadowed buffer");
		__brelse(bh);
	}

	J_ASSERT (commit_transaction->t_shadow_list == NULL);
    128c:	c2 5c e0 50 	ldx  [ %l3 + 0x50 ], %g1
    1290:	0a f0 7d 75 	brnz,pn   %g1, 864 <jbd2_journal_commit_transaction+0xe0>
    1294:	92 10 23 16 	mov  0x316, %o1

	jbd_debug(3, "JBD: commit phase 4\n");
    1298:	03 00 00 00 	sethi  %hi(0), %g1
    129c:	c2 08 60 00 	ldub  [ %g1 ], %g1
    12a0:	80 a0 60 02 	cmp  %g1, 2
    12a4:	28 48 00 36 	bleu,a   %icc, 137c <jbd2_journal_commit_transaction+0xbf8>
    12a8:	03 00 00 00 	sethi  %hi(0), %g1
    12ac:	11 00 00 00 	sethi  %hi(0), %o0
    12b0:	13 00 00 00 	sethi  %hi(0), %o1
    12b4:	17 00 00 00 	sethi  %hi(0), %o3
    12b8:	92 12 60 00 	mov  %o1, %o1
    12bc:	96 12 e0 00 	mov  %o3, %o3
    12c0:	94 10 23 18 	mov  0x318, %o2
    12c4:	40 00 00 00 	call  12c4 <jbd2_journal_commit_transaction+0xb40>
    12c8:	90 12 20 00 	mov  %o0, %o0
    12cc:	11 00 00 00 	sethi  %hi(0), %o0
    12d0:	40 00 00 00 	call  12d0 <jbd2_journal_commit_transaction+0xb4c>
    12d4:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>
    12d8:	10 68 00 29 	b  %xcc, 137c <jbd2_journal_commit_transaction+0xbf8>
    12dc:	03 00 00 00 	sethi  %hi(0), %g1
    12e0:	e0 5c 40 00 	ldx  [ %l1 ], %l0
    12e4:	c2 5c 00 00 	ldx  [ %l0 ], %g1
	while (commit_transaction->t_log_list != NULL) {
		struct buffer_head *bh;

		jh = commit_transaction->t_log_list->b_tprev;
		bh = jh2bh(jh);
		if (buffer_locked(bh)) {
    12e8:	82 08 60 04 	and  %g1, 4, %g1
    12ec:	02 c8 40 10 	brz  %g1, 132c <jbd2_journal_commit_transaction+0xba8>
    12f0:	90 10 00 14 	mov  %l4, %o0
    12f4:	40 00 00 00 	call  12f4 <jbd2_journal_commit_transaction+0xb70>
    12f8:	92 10 21 3f 	mov  0x13f, %o1
    12fc:	c2 5c 00 00 	ldx  [ %l0 ], %g1
	if (buffer_locked(bh) || atomic_read(&bh->b_count) == 0)
    1300:	82 08 60 04 	and  %g1, 4, %g1
    1304:	0a c0 40 06 	brnz,pn   %g1, 131c <jbd2_journal_commit_transaction+0xb98>
    1308:	01 00 00 00 	nop 
    130c:	c2 04 20 60 	ld  [ %l0 + 0x60 ], %g1
    1310:	80 a0 60 00 	cmp  %g1, 0
    1314:	32 48 00 1c 	bne,a   %icc, 1384 <jbd2_journal_commit_transaction+0xc00>
    1318:	d0 5c e0 58 	ldx  [ %l3 + 0x58 ], %o0
		__wait_on_buffer(bh);
    131c:	40 00 00 00 	call  131c <jbd2_journal_commit_transaction+0xb98>
    1320:	90 10 00 10 	mov  %l0, %o0

	jbd_debug(3, "JBD: commit phase 4\n");

	/* Here we wait for the revoke record and descriptor record buffers */
 wait_for_ctlbuf:
	while (commit_transaction->t_log_list != NULL) {
    1324:	10 68 00 18 	b  %xcc, 1384 <jbd2_journal_commit_transaction+0xc00>
    1328:	d0 5c e0 58 	ldx  [ %l3 + 0x58 ], %o0
    132c:	40 00 00 00 	call  132c <jbd2_journal_commit_transaction+0xba8>
    1330:	01 00 00 00 	nop 
		bh = jh2bh(jh);
		if (buffer_locked(bh)) {
			wait_on_buffer(bh);
			goto wait_for_ctlbuf;
		}
		if (cond_resched())
    1334:	80 a2 20 00 	cmp  %o0, 0
    1338:	32 48 00 13 	bne,a   %icc, 1384 <jbd2_journal_commit_transaction+0xc00>
    133c:	d0 5c e0 58 	ldx  [ %l3 + 0x58 ], %o0
    1340:	c2 5c 00 00 	ldx  [ %l0 ], %g1
	BH_Unshadow,		/* Dummy bit, for BJ_Shadow wakeup filtering */
	BH_JBDPrivateStart,	/* First bit available for private use by FS */
};

BUFFER_FNS(JBD, jbd)
BUFFER_FNS(JWrite, jwrite)
    1344:	92 10 00 10 	mov  %l0, %o1
    1348:	90 10 20 11 	mov  0x11, %o0
			goto wait_for_ctlbuf;

		if (unlikely(!buffer_uptodate(bh)))
    134c:	80 88 60 01 	btst  1, %g1
    1350:	40 00 00 00 	call  1350 <jbd2_journal_commit_transaction+0xbcc>
    1354:	a5 64 77 fb 	move  %xcc, -5, %l2
			err = -EIO;

		BUFFER_TRACE(bh, "ph5: control buffer writeout done: unfile");
		clear_buffer_jwrite(bh);
		jbd2_journal_unfile_buffer(journal, jh);
    1358:	90 10 00 18 	mov  %i0, %o0
    135c:	40 00 00 00 	call  135c <jbd2_journal_commit_transaction+0xbd8>
    1360:	92 10 00 11 	mov  %l1, %o1
		jbd2_journal_put_journal_head(jh);
    1364:	40 00 00 00 	call  1364 <jbd2_journal_commit_transaction+0xbe0>
    1368:	90 10 00 11 	mov  %l1, %o0
		__brelse(bh);		/* One for getblk */
    136c:	40 00 00 00 	call  136c <jbd2_journal_commit_transaction+0xbe8>
    1370:	90 10 00 10 	mov  %l0, %o0

	jbd_debug(3, "JBD: commit phase 4\n");

	/* Here we wait for the revoke record and descriptor record buffers */
 wait_for_ctlbuf:
	while (commit_transaction->t_log_list != NULL) {
    1374:	10 68 00 04 	b  %xcc, 1384 <jbd2_journal_commit_transaction+0xc00>
    1378:	d0 5c e0 58 	ldx  [ %l3 + 0x58 ], %o0
 * __wait_on_buffer() just to trip a debug check.  Because debug code in inline
 * functions is bloaty.
 */
static inline void wait_on_buffer(struct buffer_head *bh)
{
	might_sleep();
    137c:	a8 10 60 00 	mov  %g1, %l4
    1380:	d0 5c e0 58 	ldx  [ %l3 + 0x58 ], %o0
    1384:	2a fa 3f d7 	brnz,a   %o0, 12e0 <jbd2_journal_commit_transaction+0xb5c>
    1388:	e2 5a 20 40 	ldx  [ %o0 + 0x40 ], %l1
		jbd2_journal_put_journal_head(jh);
		__brelse(bh);		/* One for getblk */
		/* AKPM: bforget here */
	}

	if (err)
    138c:	80 a4 a0 00 	cmp  %l2, 0
    1390:	02 48 00 06 	be  %icc, 13a8 <jbd2_journal_commit_transaction+0xc24>
    1394:	03 00 00 00 	sethi  %hi(0), %g1
		jbd2_journal_abort(journal, err);
    1398:	90 10 00 18 	mov  %i0, %o0
    139c:	40 00 00 00 	call  139c <jbd2_journal_commit_transaction+0xc18>
    13a0:	93 3c a0 00 	sra  %l2, 0, %o1

	jbd_debug(3, "JBD: commit phase 5\n");
    13a4:	03 00 00 00 	sethi  %hi(0), %g1
    13a8:	c2 08 60 00 	ldub  [ %g1 ], %g1
    13ac:	80 a0 60 02 	cmp  %g1, 2
    13b0:	28 48 00 0e 	bleu,a   %icc, 13e8 <jbd2_journal_commit_transaction+0xc64>
    13b4:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1
    13b8:	11 00 00 00 	sethi  %hi(0), %o0
    13bc:	13 00 00 00 	sethi  %hi(0), %o1
    13c0:	17 00 00 00 	sethi  %hi(0), %o3
    13c4:	90 12 20 00 	mov  %o0, %o0
    13c8:	92 12 60 00 	mov  %o1, %o1
    13cc:	96 12 e0 00 	mov  %o3, %o3
    13d0:	40 00 00 00 	call  13d0 <jbd2_journal_commit_transaction+0xc4c>
    13d4:	94 10 23 36 	mov  0x336, %o2
    13d8:	11 00 00 00 	sethi  %hi(0), %o0
    13dc:	40 00 00 00 	call  13dc <jbd2_journal_commit_transaction+0xc58>
    13e0:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>

	if (!JBD2_HAS_INCOMPAT_FEATURE(journal,
    13e4:	c2 06 20 20 	ld  [ %i0 + 0x20 ], %g1
    13e8:	80 a0 60 01 	cmp  %g1, 1
    13ec:	04 40 00 08 	ble,pn   %icc, 140c <jbd2_journal_commit_transaction+0xc88>
    13f0:	97 36 60 00 	srl  %i1, 0, %o3
    13f4:	c2 5e 20 18 	ldx  [ %i0 + 0x18 ], %g1
    13f8:	c2 00 60 28 	ld  [ %g1 + 0x28 ], %g1
    13fc:	80 88 60 04 	btst  4, %g1
    1400:	12 68 00 0e 	bne  %xcc, 1438 <jbd2_journal_commit_transaction+0xcb4>
    1404:	80 a4 a0 00 	cmp  %l2, 0
		JBD2_FEATURE_INCOMPAT_ASYNC_COMMIT)) {
		err = journal_submit_commit_record(journal, commit_transaction,
    1408:	97 36 60 00 	srl  %i1, 0, %o3
    140c:	90 10 00 18 	mov  %i0, %o0
    1410:	92 10 00 13 	mov  %l3, %o1
    1414:	7f ff fb b8 	call  2f4 <journal_submit_commit_record>
    1418:	94 07 a7 d7 	add  %fp, 0x7d7, %o2
						&cbh, crc32_sum);
		if (err)
    141c:	a4 92 20 00 	orcc  %o0, 0, %l2
    1420:	22 48 00 09 	be,a   %icc, 1444 <jbd2_journal_commit_transaction+0xcc0>
    1424:	c2 5e 00 00 	ldx  [ %i0 ], %g1
			__jbd2_journal_abort_hard(journal);
    1428:	40 00 00 00 	call  1428 <jbd2_journal_commit_transaction+0xca4>
    142c:	90 10 00 18 	mov  %i0, %o0
	}
	if (!err && !is_journal_aborted(journal))
		err = journal_wait_on_commit_record(journal, cbh);

	if (err)
		jbd2_journal_abort(journal, err);
    1430:	10 68 00 0f 	b  %xcc, 146c <jbd2_journal_commit_transaction+0xce8>
    1434:	93 3c a0 00 	sra  %l2, 0, %o1
		err = journal_submit_commit_record(journal, commit_transaction,
						&cbh, crc32_sum);
		if (err)
			__jbd2_journal_abort_hard(journal);
	}
	if (!err && !is_journal_aborted(journal))
    1438:	12 48 00 0d 	bne  %icc, 146c <jbd2_journal_commit_transaction+0xce8>
    143c:	93 3c a0 00 	sra  %l2, 0, %o1
    1440:	c2 5e 00 00 	ldx  [ %i0 ], %g1
    1444:	80 88 60 02 	btst  2, %g1
    1448:	12 68 00 0c 	bne  %xcc, 1478 <jbd2_journal_commit_transaction+0xcf4>
    144c:	03 00 00 00 	sethi  %hi(0), %g1
		err = journal_wait_on_commit_record(journal, cbh);
    1450:	d2 5f a7 d7 	ldx  [ %fp + 0x7d7 ], %o1
    1454:	7f ff fc 3f 	call  550 <journal_wait_on_commit_record>
    1458:	90 10 00 18 	mov  %i0, %o0

	if (err)
    145c:	a4 92 20 00 	orcc  %o0, 0, %l2
    1460:	02 48 00 06 	be  %icc, 1478 <jbd2_journal_commit_transaction+0xcf4>
    1464:	03 00 00 00 	sethi  %hi(0), %g1
		jbd2_journal_abort(journal, err);
    1468:	93 3c a0 00 	sra  %l2, 0, %o1
    146c:	40 00 00 00 	call  146c <jbd2_journal_commit_transaction+0xce8>
    1470:	90 10 00 18 	mov  %i0, %o0
	/* End of a transaction!  Finally, we can do checkpoint
           processing: any buffers committed as a result of this
           transaction can be removed from any checkpoint list it was on
           before. */

	jbd_debug(3, "JBD: commit phase 6\n");
    1474:	03 00 00 00 	sethi  %hi(0), %g1
    1478:	c2 08 60 00 	ldub  [ %g1 ], %g1
    147c:	80 a0 60 02 	cmp  %g1, 2
    1480:	28 48 00 0e 	bleu,a   %icc, 14b8 <jbd2_journal_commit_transaction+0xd34>
    1484:	c4 5c e0 60 	ldx  [ %l3 + 0x60 ], %g2
    1488:	11 00 00 00 	sethi  %hi(0), %o0
    148c:	13 00 00 00 	sethi  %hi(0), %o1
    1490:	17 00 00 00 	sethi  %hi(0), %o3
    1494:	90 12 20 00 	mov  %o0, %o0
    1498:	92 12 60 00 	mov  %o1, %o1
    149c:	96 12 e0 00 	mov  %o3, %o3
    14a0:	40 00 00 00 	call  14a0 <jbd2_journal_commit_transaction+0xd1c>
    14a4:	94 10 23 4a 	mov  0x34a, %o2
    14a8:	11 00 00 00 	sethi  %hi(0), %o0
    14ac:	40 00 00 00 	call  14ac <jbd2_journal_commit_transaction+0xd28>
    14b0:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>

	J_ASSERT(list_empty(&commit_transaction->t_inode_list));
    14b4:	c4 5c e0 60 	ldx  [ %l3 + 0x60 ], %g2
    14b8:	82 04 e0 60 	add  %l3, 0x60, %g1
    14bc:	80 a0 80 01 	cmp  %g2, %g1
    14c0:	12 67 fc e9 	bne,pn   %xcc, 864 <jbd2_journal_commit_transaction+0xe0>
    14c4:	92 10 23 4c 	mov  0x34c, %o1
	J_ASSERT(commit_transaction->t_buffers == NULL);
    14c8:	c2 5c e0 28 	ldx  [ %l3 + 0x28 ], %g1
    14cc:	0a f0 7c e6 	brnz,pn   %g1, 864 <jbd2_journal_commit_transaction+0xe0>
    14d0:	92 10 23 4d 	mov  0x34d, %o1
	J_ASSERT(commit_transaction->t_checkpoint_list == NULL);
    14d4:	c2 5c e0 38 	ldx  [ %l3 + 0x38 ], %g1
    14d8:	0a f0 7c e3 	brnz,pn   %g1, 864 <jbd2_journal_commit_transaction+0xe0>
    14dc:	92 10 23 4e 	mov  0x34e, %o1
	J_ASSERT(commit_transaction->t_iobuf_list == NULL);
    14e0:	c2 5c e0 48 	ldx  [ %l3 + 0x48 ], %g1
    14e4:	0a f0 7c e0 	brnz,pn   %g1, 864 <jbd2_journal_commit_transaction+0xe0>
    14e8:	92 10 23 4f 	mov  0x34f, %o1
	J_ASSERT(commit_transaction->t_shadow_list == NULL);
    14ec:	c2 5c e0 50 	ldx  [ %l3 + 0x50 ], %g1
    14f0:	0a f0 7c dd 	brnz,pn   %g1, 864 <jbd2_journal_commit_transaction+0xe0>
    14f4:	92 10 23 50 	mov  0x350, %o1
	J_ASSERT(commit_transaction->t_log_list == NULL);
    14f8:	c2 5c e0 58 	ldx  [ %l3 + 0x58 ], %g1
	 * attempt to acquire the lock bit.
	 */
	preempt_disable();
#if defined(CONFIG_SMP) || defined(CONFIG_DEBUG_SPINLOCK)
	while (unlikely(test_and_set_bit_lock(bitnum, addr))) {
		while (test_bit(bitnum, addr)) {
    14fc:	25 00 10 00 	sethi  %hi(0x400000), %l2
		 * that buffer in the future now that the last use has
		 * been committed.  That's not only a performance gain,
		 * it also stops aliasing problems if the buffer is left
		 * behind for writeback and gets reallocated for another
		 * use in a different page. */
		if (buffer_freed(bh)) {
    1500:	2b 00 01 00 	sethi  %hi(0x40000), %l5
			clear_buffer_freed(bh);
			clear_buffer_jbddirty(bh);
		}

		if (buffer_jbddirty(bh)) {
    1504:	29 00 08 00 	sethi  %hi(0x200000), %l4
	J_ASSERT(list_empty(&commit_transaction->t_inode_list));
	J_ASSERT(commit_transaction->t_buffers == NULL);
	J_ASSERT(commit_transaction->t_checkpoint_list == NULL);
	J_ASSERT(commit_transaction->t_iobuf_list == NULL);
	J_ASSERT(commit_transaction->t_shadow_list == NULL);
	J_ASSERT(commit_transaction->t_log_list == NULL);
    1508:	0a f0 7c d7 	brnz,pn   %g1, 864 <jbd2_journal_commit_transaction+0xe0>
    150c:	92 10 23 51 	mov  0x351, %o1
restart_loop:
	/*
	 * As there are other places (journal_unmap_buffer()) adding buffers
	 * to this list we have to be careful and hold the j_list_lock.
	 */
	spin_lock(&journal->j_list_lock);
    1510:	40 00 00 00 	call  1510 <jbd2_journal_commit_transaction+0xd8c>
    1514:	90 10 00 1b 	mov  %i3, %o0
	while (commit_transaction->t_forget) {
    1518:	10 68 00 98 	b  %xcc, 1778 <jbd2_journal_commit_transaction+0xff4>
    151c:	e0 5c e0 30 	ldx  [ %l3 + 0x30 ], %l0
		transaction_t *cp_transaction;
		struct buffer_head *bh;

		jh = commit_transaction->t_forget;
		spin_unlock(&journal->j_list_lock);
    1520:	40 00 00 00 	call  1520 <jbd2_journal_commit_transaction+0xd9c>
    1524:	90 10 00 1b 	mov  %i3, %o0
	 * the body of the outer loop. If it is contended, then
	 * within the inner loop a non-atomic test is used to
	 * busywait with less bus contention for a good time to
	 * attempt to acquire the lock bit.
	 */
	preempt_disable();
    1528:	90 10 20 01 	mov  1, %o0
    152c:	40 00 00 00 	call  152c <jbd2_journal_commit_transaction+0xda8>
    1530:	e2 5c 00 00 	ldx  [ %l0 ], %l1
#if defined(CONFIG_SMP) || defined(CONFIG_DEBUG_SPINLOCK)
	while (unlikely(test_and_set_bit_lock(bitnum, addr))) {
    1534:	10 68 00 10 	b  %xcc, 1574 <jbd2_journal_commit_transaction+0xdf0>
    1538:	90 10 20 16 	mov  0x16, %o0
		while (test_bit(bitnum, addr)) {
			preempt_enable();
    153c:	40 00 00 00 	call  153c <jbd2_journal_commit_transaction+0xdb8>
    1540:	90 10 20 01 	mov  1, %o0
    1544:	c2 59 a0 08 	ldx  [ %g6 + 8 ], %g1
    1548:	82 08 60 08 	and  %g1, 8, %g1
    154c:	02 c8 40 04 	brz  %g1, 155c <jbd2_journal_commit_transaction+0xdd8>
    1550:	01 00 00 00 	nop 
    1554:	40 00 00 00 	call  1554 <jbd2_journal_commit_transaction+0xdd0>
    1558:	01 00 00 00 	nop 
			cpu_relax();
			preempt_disable();
    155c:	40 00 00 00 	call  155c <jbd2_journal_commit_transaction+0xdd8>
    1560:	90 10 20 01 	mov  1, %o0	! 1 <write_tag_block+0x1>
    1564:	c2 5c 40 00 	ldx  [ %l1 ], %g1
	 * attempt to acquire the lock bit.
	 */
	preempt_disable();
#if defined(CONFIG_SMP) || defined(CONFIG_DEBUG_SPINLOCK)
	while (unlikely(test_and_set_bit_lock(bitnum, addr))) {
		while (test_bit(bitnum, addr)) {
    1568:	82 08 40 12 	and  %g1, %l2, %g1
    156c:	0a f0 7f f4 	brnz,pn   %g1, 153c <jbd2_journal_commit_transaction+0xdb8>
    1570:	90 10 20 16 	mov  0x16, %o0
	 * busywait with less bus contention for a good time to
	 * attempt to acquire the lock bit.
	 */
	preempt_disable();
#if defined(CONFIG_SMP) || defined(CONFIG_DEBUG_SPINLOCK)
	while (unlikely(test_and_set_bit_lock(bitnum, addr))) {
    1574:	40 00 00 00 	call  1574 <jbd2_journal_commit_transaction+0xdf0>
    1578:	92 10 00 11 	mov  %l1, %o1
    157c:	80 a2 20 00 	cmp  %o0, 0
    1580:	12 4f ff f9 	bne  %icc, 1564 <jbd2_journal_commit_transaction+0xde0>
    1584:	01 00 00 00 	nop 
		bh = jh2bh(jh);
		jbd_lock_bh_state(bh);
		J_ASSERT_JH(jh,	jh->b_transaction == commit_transaction ||
    1588:	c4 5c 20 28 	ldx  [ %l0 + 0x28 ], %g2
    158c:	80 a0 80 13 	cmp  %g2, %l3
    1590:	22 68 00 08 	be,a   %xcc, 15b0 <jbd2_journal_commit_transaction+0xe2c>
    1594:	d0 5c 20 20 	ldx  [ %l0 + 0x20 ], %o0
    1598:	c2 5e 20 d8 	ldx  [ %i0 + 0xd8 ], %g1
    159c:	80 a0 80 01 	cmp  %g2, %g1
    15a0:	22 68 00 04 	be,a   %xcc, 15b0 <jbd2_journal_commit_transaction+0xe2c>
    15a4:	d0 5c 20 20 	ldx  [ %l0 + 0x20 ], %o0
    15a8:	10 6f fc af 	b  %xcc, 864 <jbd2_journal_commit_transaction+0xe0>
    15ac:	92 10 23 62 	mov  0x362, %o1
		 * Otherwise, we can just throw away the frozen data now.
		 *
		 * We also know that the frozen data has already fired
		 * its triggers if they exist, so we can clear that too.
		 */
		if (jh->b_committed_data) {
    15b0:	02 c2 00 0f 	brz,pn   %o0, 15ec <jbd2_journal_commit_transaction+0xe68>
    15b4:	92 10 3f ff 	mov  -1, %o1
/* Pure 2^n version of get_order */
static __inline__ __attribute_const__ int get_order(unsigned long size)
{
	int order;

	size = (size - 1) >> (PAGE_SHIFT - 1);
    15b8:	c2 5c 60 20 	ldx  [ %l1 + 0x20 ], %g1
    15bc:	82 00 7f ff 	add  %g1, -1, %g1
    15c0:	83 30 70 0c 	srlx  %g1, 0xc, %g1
	order = -1;
	do {
		size >>= 1;
    15c4:	83 30 70 01 	srlx  %g1, 1, %g1
		order++;
	} while (size);
    15c8:	0a f8 7f ff 	brnz  %g1, 15c4 <jbd2_journal_commit_transaction+0xe40>
    15cc:	92 02 60 01 	inc  %o1
	return (void *)__get_free_pages(flags, get_order(size));
}

static inline void jbd2_free(void *ptr, size_t size)
{
	free_pages((unsigned long)ptr, get_order(size));
    15d0:	40 00 00 00 	call  15d0 <jbd2_journal_commit_transaction+0xe4c>
    15d4:	93 32 60 00 	srl  %o1, 0, %o1
			jbd2_free(jh->b_committed_data, bh->b_size);
			jh->b_committed_data = NULL;
			if (jh->b_frozen_data) {
    15d8:	c2 5c 20 18 	ldx  [ %l0 + 0x18 ], %g1
    15dc:	02 c0 40 11 	brz,pn   %g1, 1620 <jbd2_journal_commit_transaction+0xe9c>
    15e0:	c0 74 20 20 	clrx  [ %l0 + 0x20 ]
				jh->b_committed_data = jh->b_frozen_data;
    15e4:	10 68 00 0d 	b  %xcc, 1618 <jbd2_journal_commit_transaction+0xe94>
    15e8:	c2 74 20 20 	stx  %g1, [ %l0 + 0x20 ]
				jh->b_frozen_data = NULL;
				jh->b_frozen_triggers = NULL;
			}
		} else if (jh->b_frozen_data) {
    15ec:	d0 5c 20 18 	ldx  [ %l0 + 0x18 ], %o0
    15f0:	02 c2 00 0c 	brz,pn   %o0, 1620 <jbd2_journal_commit_transaction+0xe9c>
    15f4:	01 00 00 00 	nop 
/* Pure 2^n version of get_order */
static __inline__ __attribute_const__ int get_order(unsigned long size)
{
	int order;

	size = (size - 1) >> (PAGE_SHIFT - 1);
    15f8:	c2 5c 60 20 	ldx  [ %l1 + 0x20 ], %g1
    15fc:	82 00 7f ff 	add  %g1, -1, %g1
    1600:	83 30 70 0c 	srlx  %g1, 0xc, %g1
	order = -1;
	do {
		size >>= 1;
    1604:	83 30 70 01 	srlx  %g1, 1, %g1
		order++;
	} while (size);
    1608:	0a f8 7f ff 	brnz  %g1, 1604 <jbd2_journal_commit_transaction+0xe80>
    160c:	92 02 60 01 	inc  %o1
    1610:	40 00 00 00 	call  1610 <jbd2_journal_commit_transaction+0xe8c>
    1614:	93 32 60 00 	srl  %o1, 0, %o1
			jbd2_free(jh->b_frozen_data, bh->b_size);
			jh->b_frozen_data = NULL;
    1618:	c0 74 20 18 	clrx  [ %l0 + 0x18 ]
			jh->b_frozen_triggers = NULL;
    161c:	c0 74 20 68 	clrx  [ %l0 + 0x68 ]
		}

		spin_lock(&journal->j_list_lock);
    1620:	40 00 00 00 	call  1620 <jbd2_journal_commit_transaction+0xe9c>
    1624:	90 10 00 1b 	mov  %i3, %o0
		cp_transaction = jh->b_cp_transaction;
    1628:	c4 5c 20 48 	ldx  [ %l0 + 0x48 ], %g2
		if (cp_transaction) {
    162c:	02 c0 80 06 	brz,pn   %g2, 1644 <jbd2_journal_commit_transaction+0xec0>
    1630:	90 10 00 10 	mov  %l0, %o0
			JBUFFER_TRACE(jh, "remove from old cp transaction");
			cp_transaction->t_chp_stats.cs_dropped++;
    1634:	c2 58 a0 c8 	ldx  [ %g2 + 0xc8 ], %g1
    1638:	82 00 60 01 	inc  %g1
			__jbd2_journal_remove_checkpoint(jh);
    163c:	40 00 00 00 	call  163c <jbd2_journal_commit_transaction+0xeb8>
    1640:	c2 70 a0 c8 	stx  %g1, [ %g2 + 0xc8 ]
    1644:	c2 5c 40 00 	ldx  [ %l1 ], %g1
		 * that buffer in the future now that the last use has
		 * been committed.  That's not only a performance gain,
		 * it also stops aliasing problems if the buffer is left
		 * behind for writeback and gets reallocated for another
		 * use in a different page. */
		if (buffer_freed(bh)) {
    1648:	82 08 40 15 	and  %g1, %l5, %g1
    164c:	02 c8 40 07 	brz  %g1, 1668 <jbd2_journal_commit_transaction+0xee4>
    1650:	90 10 20 12 	mov  0x12, %o0
TAS_BUFFER_FNS(JBDDirty, jbddirty)
BUFFER_FNS(Revoked, revoked)
TAS_BUFFER_FNS(Revoked, revoked)
BUFFER_FNS(RevokeValid, revokevalid)
TAS_BUFFER_FNS(RevokeValid, revokevalid)
BUFFER_FNS(Freed, freed)
    1654:	40 00 00 00 	call  1654 <jbd2_journal_commit_transaction+0xed0>
    1658:	92 10 00 11 	mov  %l1, %o1
	BH_JBDPrivateStart,	/* First bit available for private use by FS */
};

BUFFER_FNS(JBD, jbd)
BUFFER_FNS(JWrite, jwrite)
BUFFER_FNS(JBDDirty, jbddirty)
    165c:	90 10 20 15 	mov  0x15, %o0
    1660:	40 00 00 00 	call  1660 <jbd2_journal_commit_transaction+0xedc>
    1664:	92 10 00 11 	mov  %l1, %o1
    1668:	c2 5c 40 00 	ldx  [ %l1 ], %g1
			clear_buffer_freed(bh);
			clear_buffer_jbddirty(bh);
		}

		if (buffer_jbddirty(bh)) {
    166c:	82 08 40 14 	and  %g1, %l4, %g1
    1670:	02 c8 40 0e 	brz  %g1, 16a8 <jbd2_journal_commit_transaction+0xf24>
    1674:	90 10 00 10 	mov  %l0, %o0
			JBUFFER_TRACE(jh, "add to new checkpointing trans");
			__jbd2_journal_insert_checkpoint(jh, commit_transaction);
    1678:	40 00 00 00 	call  1678 <jbd2_journal_commit_transaction+0xef4>
    167c:	92 10 00 13 	mov  %l3, %o1
			if (is_journal_aborted(journal))
    1680:	c2 5e 00 00 	ldx  [ %i0 ], %g1
    1684:	80 88 60 02 	btst  2, %g1
    1688:	02 68 00 04 	be  %xcc, 1698 <jbd2_journal_commit_transaction+0xf14>
    168c:	90 10 20 15 	mov  0x15, %o0
    1690:	40 00 00 00 	call  1690 <jbd2_journal_commit_transaction+0xf0c>
    1694:	92 10 00 11 	mov  %l1, %o1
				clear_buffer_jbddirty(bh);
			JBUFFER_TRACE(jh, "refile for checkpoint writeback");
			__jbd2_journal_refile_buffer(jh);
    1698:	40 00 00 00 	call  1698 <jbd2_journal_commit_transaction+0xf14>
    169c:	90 10 00 10 	mov  %l0, %o0
    16a0:	10 68 00 20 	b  %xcc, 1720 <jbd2_journal_commit_transaction+0xf9c>
    16a4:	01 00 00 00 	nop 
    16a8:	c2 5c 40 00 	ldx  [ %l1 ], %g1
			jbd_unlock_bh_state(bh);
		} else {
			J_ASSERT_BH(bh, !buffer_dirty(bh));
    16ac:	82 08 60 02 	and  %g1, 2, %g1
    16b0:	0a f0 7c 6d 	brnz,pn   %g1, 864 <jbd2_journal_commit_transaction+0xe0>
    16b4:	92 10 23 a3 	mov  0x3a3, %o1
			 * transaction has committed. *BUT* it could be
			 * reallocated once we have written all the data to
			 * disk and before we process the buffer on BJ_Forget
			 * list. */
			JBUFFER_TRACE(jh, "refile or unfile freed buffer");
			__jbd2_journal_refile_buffer(jh);
    16b8:	40 00 00 00 	call  16b8 <jbd2_journal_commit_transaction+0xf34>
    16bc:	90 10 00 10 	mov  %l0, %o0
			if (!jh->b_transaction) {
    16c0:	c2 5c 20 28 	ldx  [ %l0 + 0x28 ], %g1
    16c4:	0a c8 40 17 	brnz  %g1, 1720 <jbd2_journal_commit_transaction+0xf9c>
    16c8:	01 00 00 00 	nop 
    16cc:	c2 5c 40 00 	ldx  [ %l1 ], %g1
 *  bit-based spin_unlock()
 */
static inline void bit_spin_unlock(int bitnum, unsigned long *addr)
{
#ifdef CONFIG_DEBUG_SPINLOCK
	BUG_ON(!test_bit(bitnum, addr));
    16d0:	82 08 40 12 	and  %g1, %l2, %g1
    16d4:	22 c0 40 18 	brz,a,pn   %g1, 1734 <jbd2_journal_commit_transaction+0xfb0>
    16d8:	11 00 00 00 	sethi  %hi(0), %o0
#endif
#if defined(CONFIG_SMP) || defined(CONFIG_DEBUG_SPINLOCK)
	clear_bit_unlock(bitnum, addr);
    16dc:	90 10 20 16 	mov  0x16, %o0
    16e0:	40 00 00 00 	call  16e0 <jbd2_journal_commit_transaction+0xf5c>
    16e4:	92 10 00 11 	mov  %l1, %o1
#endif
	preempt_enable();
    16e8:	40 00 00 00 	call  16e8 <jbd2_journal_commit_transaction+0xf64>
    16ec:	90 10 20 01 	mov  1, %o0
    16f0:	c2 59 a0 08 	ldx  [ %g6 + 8 ], %g1
    16f4:	82 08 60 08 	and  %g1, 8, %g1
    16f8:	02 c8 40 04 	brz  %g1, 1708 <jbd2_journal_commit_transaction+0xf84>
    16fc:	01 00 00 00 	nop 
    1700:	40 00 00 00 	call  1700 <jbd2_journal_commit_transaction+0xf7c>
    1704:	01 00 00 00 	nop 
				jbd_unlock_bh_state(bh);
				 /* needs a brelse */
				jbd2_journal_remove_journal_head(bh);
    1708:	40 00 00 00 	call  1708 <jbd2_journal_commit_transaction+0xf84>
    170c:	90 10 00 11 	mov  %l1, %o0
				release_buffer_page(bh);
    1710:	7f ff fb e7 	call  6ac <release_buffer_page>
    1714:	90 10 00 11 	mov  %l1, %o0
    1718:	10 68 00 15 	b  %xcc, 176c <jbd2_journal_commit_transaction+0xfe8>
    171c:	01 00 00 00 	nop 
    1720:	c2 5c 40 00 	ldx  [ %l1 ], %g1
 *  bit-based spin_unlock()
 */
static inline void bit_spin_unlock(int bitnum, unsigned long *addr)
{
#ifdef CONFIG_DEBUG_SPINLOCK
	BUG_ON(!test_bit(bitnum, addr));
    1724:	82 08 40 12 	and  %g1, %l2, %g1
    1728:	0a c8 40 06 	brnz  %g1, 1740 <jbd2_journal_commit_transaction+0xfbc>
    172c:	01 00 00 00 	nop 
    1730:	11 00 00 00 	sethi  %hi(0), %o0
    1734:	92 10 20 36 	mov  0x36, %o1
    1738:	10 6f fc 4d 	b  %xcc, 86c <jbd2_journal_commit_transaction+0xe8>
    173c:	90 12 20 00 	mov  %o0, %o0
#endif
#if defined(CONFIG_SMP) || defined(CONFIG_DEBUG_SPINLOCK)
	clear_bit_unlock(bitnum, addr);
    1740:	90 10 20 16 	mov  0x16, %o0
    1744:	40 00 00 00 	call  1744 <jbd2_journal_commit_transaction+0xfc0>
    1748:	92 10 00 11 	mov  %l1, %o1
#endif
	preempt_enable();
    174c:	40 00 00 00 	call  174c <jbd2_journal_commit_transaction+0xfc8>
    1750:	90 10 20 01 	mov  1, %o0
    1754:	c2 59 a0 08 	ldx  [ %g6 + 8 ], %g1
    1758:	82 08 60 08 	and  %g1, 8, %g1
    175c:	02 c8 40 04 	brz  %g1, 176c <jbd2_journal_commit_transaction+0xfe8>
    1760:	01 00 00 00 	nop 
    1764:	40 00 00 00 	call  1764 <jbd2_journal_commit_transaction+0xfe0>
    1768:	01 00 00 00 	nop 
			} else
				jbd_unlock_bh_state(bh);
		}
		cond_resched_lock(&journal->j_list_lock);
    176c:	40 00 00 00 	call  176c <jbd2_journal_commit_transaction+0xfe8>
    1770:	90 10 00 1b 	mov  %i3, %o0
	/*
	 * As there are other places (journal_unmap_buffer()) adding buffers
	 * to this list we have to be careful and hold the j_list_lock.
	 */
	spin_lock(&journal->j_list_lock);
	while (commit_transaction->t_forget) {
    1774:	e0 5c e0 30 	ldx  [ %l3 + 0x30 ], %l0
    1778:	0a fc 3f 6a 	brnz  %l0, 1520 <jbd2_journal_commit_transaction+0xd9c>
    177c:	01 00 00 00 	nop 
			} else
				jbd_unlock_bh_state(bh);
		}
		cond_resched_lock(&journal->j_list_lock);
	}
	spin_unlock(&journal->j_list_lock);
    1780:	40 00 00 00 	call  1780 <jbd2_journal_commit_transaction+0xffc>
    1784:	90 10 00 1b 	mov  %i3, %o0
	 * This is a bit sleazy.  We use j_list_lock to protect transition
	 * of a transaction into T_FINISHED state and calling
	 * __jbd2_journal_drop_transaction(). Otherwise we could race with
	 * other checkpointing code processing the transaction...
	 */
	spin_lock(&journal->j_state_lock);
    1788:	40 00 00 00 	call  1788 <jbd2_journal_commit_transaction+0x1004>
    178c:	90 10 00 1a 	mov  %i2, %o0
	spin_lock(&journal->j_list_lock);
    1790:	40 00 00 00 	call  1790 <jbd2_journal_commit_transaction+0x100c>
    1794:	90 10 00 1b 	mov  %i3, %o0
	/*
	 * Now recheck if some buffers did not get attached to the transaction
	 * while the lock was dropped...
	 */
	if (commit_transaction->t_forget) {
    1798:	c2 5c e0 30 	ldx  [ %l3 + 0x30 ], %g1
    179c:	02 c0 40 08 	brz,pn   %g1, 17bc <jbd2_journal_commit_transaction+0x1038>
    17a0:	03 00 00 00 	sethi  %hi(0), %g1
		spin_unlock(&journal->j_list_lock);
    17a4:	40 00 00 00 	call  17a4 <jbd2_journal_commit_transaction+0x1020>
    17a8:	90 10 00 1b 	mov  %i3, %o0
		spin_unlock(&journal->j_state_lock);
    17ac:	40 00 00 00 	call  17ac <jbd2_journal_commit_transaction+0x1028>
    17b0:	90 10 00 1a 	mov  %i2, %o0
    17b4:	10 6f ff 57 	b  %xcc, 1510 <jbd2_journal_commit_transaction+0xd8c>
    17b8:	01 00 00 00 	nop 
		goto restart_loop;
	}

	/* Done with this transaction! */

	jbd_debug(3, "JBD: commit phase 7\n");
    17bc:	c2 08 60 00 	ldub  [ %g1 ], %g1
    17c0:	80 a0 60 02 	cmp  %g1, 2
    17c4:	28 48 00 0e 	bleu,a   %icc, 17fc <jbd2_journal_commit_transaction+0x1078>
    17c8:	c2 04 e0 0c 	ld  [ %l3 + 0xc ], %g1
    17cc:	11 00 00 00 	sethi  %hi(0), %o0
    17d0:	13 00 00 00 	sethi  %hi(0), %o1
    17d4:	17 00 00 00 	sethi  %hi(0), %o3
    17d8:	90 12 20 00 	mov  %o0, %o0
    17dc:	92 12 60 00 	mov  %o1, %o1
    17e0:	96 12 e0 00 	mov  %o3, %o3
    17e4:	40 00 00 00 	call  17e4 <jbd2_journal_commit_transaction+0x1060>
    17e8:	94 10 23 cc 	mov  0x3cc, %o2
    17ec:	11 00 00 00 	sethi  %hi(0), %o0
    17f0:	40 00 00 00 	call  17f0 <jbd2_journal_commit_transaction+0x106c>
    17f4:	90 12 20 00 	mov  %o0, %o0	! 0 <write_tag_block>

	J_ASSERT(commit_transaction->t_state == T_COMMIT);
    17f8:	c2 04 e0 0c 	ld  [ %l3 + 0xc ], %g1
    17fc:	80 a0 60 04 	cmp  %g1, 4
    1800:	12 47 fc 19 	bne,pn   %icc, 864 <jbd2_journal_commit_transaction+0xe0>
    1804:	92 10 23 ce 	mov  0x3ce, %o1

	commit_transaction->t_start = jiffies;
    1808:	03 00 00 00 	sethi  %hi(0), %g1
						commit_transaction->t_start);

	/*
	 * File the transaction for history
	 */
	stats.ts_type = JBD2_STATS_RUN;
    180c:	84 10 20 01 	mov  1, %g2

	jbd_debug(3, "JBD: commit phase 7\n");

	J_ASSERT(commit_transaction->t_state == T_COMMIT);

	commit_transaction->t_start = jiffies;
    1810:	ce 58 60 00 	ldx  [ %g1 ], %g7
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;

	return end + (MAX_JIFFY_OFFSET - start);
    1814:	82 10 3f ff 	mov  -1, %g1
	 * File the transaction for history
	 */
	stats.ts_type = JBD2_STATS_RUN;
	stats.ts_tid = commit_transaction->t_tid;
	stats.u.run.rs_handle_count = commit_transaction->t_handle_count;
	spin_lock(&journal->j_history_lock);
    1818:	a0 06 26 90 	add  %i0, 0x690, %l0
    181c:	83 28 70 3e 	sllx  %g1, 0x3e, %g1
    1820:	90 10 00 10 	mov  %l0, %o0

	jbd_debug(3, "JBD: commit phase 7\n");

	J_ASSERT(commit_transaction->t_state == T_COMMIT);

	commit_transaction->t_start = jiffies;
    1824:	ce 74 e0 a8 	stx  %g7, [ %l3 + 0xa8 ]
    1828:	82 18 7f fe 	xor  %g1, -2, %g1
	stats.u.run.rs_logging = jbd2_time_diff(stats.u.run.rs_logging,
    182c:	c6 5f a7 8f 	ldx  [ %fp + 0x78f ], %g3
    1830:	82 01 c0 01 	add  %g7, %g1, %g1
						commit_transaction->t_start);

	/*
	 * File the transaction for history
	 */
	stats.ts_type = JBD2_STATS_RUN;
    1834:	c4 27 a7 5f 	st  %g2, [ %fp + 0x75f ]

static inline unsigned long
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;
    1838:	80 a1 c0 03 	cmp  %g7, %g3

	return end + (MAX_JIFFY_OFFSET - start);
    183c:	82 20 40 03 	sub  %g1, %g3, %g1

static inline unsigned long
jbd2_time_diff(unsigned long start, unsigned long end)
{
	if (end >= start)
		return end - start;
    1840:	8e 21 c0 03 	sub  %g7, %g3, %g7
    1844:	83 67 50 07 	movcc  %xcc, %g7, %g1
	jbd_debug(3, "JBD: commit phase 7\n");

	J_ASSERT(commit_transaction->t_state == T_COMMIT);

	commit_transaction->t_start = jiffies;
	stats.u.run.rs_logging = jbd2_time_diff(stats.u.run.rs_logging,
    1848:	c2 77 a7 8f 	stx  %g1, [ %fp + 0x78f ]

	/*
	 * File the transaction for history
	 */
	stats.ts_type = JBD2_STATS_RUN;
	stats.ts_tid = commit_transaction->t_tid;
    184c:	c2 04 e0 08 	ld  [ %l3 + 8 ], %g1
    1850:	c2 77 a7 67 	stx  %g1, [ %fp + 0x767 ]
	stats.u.run.rs_handle_count = commit_transaction->t_handle_count;
    1854:	c2 44 e0 f8 	ldsw  [ %l3 + 0xf8 ], %g1
	spin_lock(&journal->j_history_lock);
    1858:	40 00 00 00 	call  1858 <jbd2_journal_commit_transaction+0x10d4>
    185c:	c2 77 a7 97 	stx  %g1, [ %fp + 0x797 ]
	memcpy(journal->j_history + journal->j_history_cur, &stats,
    1860:	d0 06 26 8c 	ld  [ %i0 + 0x68c ], %o0
    1864:	92 07 a7 5f 	add  %fp, 0x75f, %o1
    1868:	94 10 20 50 	mov  0x50, %o2
    186c:	c2 5e 26 80 	ldx  [ %i0 + 0x680 ], %g1
    1870:	90 5a 20 50 	smul  %o0, 0x50, %o0
    1874:	40 00 00 00 	call  1874 <jbd2_journal_commit_transaction+0x10f0>
    1878:	90 00 40 08 	add  %g1, %o0, %o0
			sizeof(stats));
	if (++journal->j_history_cur == journal->j_history_max)
    187c:	c2 06 26 8c 	ld  [ %i0 + 0x68c ], %g1
    1880:	c4 06 26 88 	ld  [ %i0 + 0x688 ], %g2
    1884:	82 00 60 01 	inc  %g1
    1888:	80 a0 40 02 	cmp  %g1, %g2
    188c:	12 48 00 03 	bne  %icc, 1898 <jbd2_journal_commit_transaction+0x1114>
    1890:	c2 26 26 8c 	st  %g1, [ %i0 + 0x68c ]
		journal->j_history_cur = 0;
    1894:	c0 26 26 8c 	clr  [ %i0 + 0x68c ]

	/*
	 * Calculate overall stats
	 */
	journal->j_stats.ts_tid++;
	journal->j_stats.u.run.rs_wait += stats.u.run.rs_wait;
    1898:	d2 5e 26 d8 	ldx  [ %i0 + 0x6d8 ], %o1
	journal->j_stats.u.run.rs_flushing += stats.u.run.rs_flushing;
	journal->j_stats.u.run.rs_logging += stats.u.run.rs_logging;
	journal->j_stats.u.run.rs_handle_count += stats.u.run.rs_handle_count;
	journal->j_stats.u.run.rs_blocks += stats.u.run.rs_blocks;
	journal->j_stats.u.run.rs_blocks_logged += stats.u.run.rs_blocks_logged;
	spin_unlock(&journal->j_history_lock);
    189c:	90 10 00 10 	mov  %l0, %o0

	/*
	 * Calculate overall stats
	 */
	journal->j_stats.ts_tid++;
	journal->j_stats.u.run.rs_wait += stats.u.run.rs_wait;
    18a0:	c2 5f a7 6f 	ldx  [ %fp + 0x76f ], %g1
	journal->j_stats.u.run.rs_running += stats.u.run.rs_running;
    18a4:	de 5e 26 e0 	ldx  [ %i0 + 0x6e0 ], %o7

	/*
	 * Calculate overall stats
	 */
	journal->j_stats.ts_tid++;
	journal->j_stats.u.run.rs_wait += stats.u.run.rs_wait;
    18a8:	92 02 40 01 	add  %o1, %g1, %o1
	journal->j_stats.u.run.rs_running += stats.u.run.rs_running;
    18ac:	c2 5f a7 77 	ldx  [ %fp + 0x777 ], %g1
	journal->j_stats.u.run.rs_locked += stats.u.run.rs_locked;
    18b0:	c6 5e 26 e8 	ldx  [ %i0 + 0x6e8 ], %g3
	/*
	 * Calculate overall stats
	 */
	journal->j_stats.ts_tid++;
	journal->j_stats.u.run.rs_wait += stats.u.run.rs_wait;
	journal->j_stats.u.run.rs_running += stats.u.run.rs_running;
    18b4:	9e 03 c0 01 	add  %o7, %g1, %o7
	journal->j_stats.u.run.rs_locked += stats.u.run.rs_locked;
    18b8:	c2 5f a7 7f 	ldx  [ %fp + 0x77f ], %g1
	journal->j_stats.u.run.rs_flushing += stats.u.run.rs_flushing;
    18bc:	ce 5e 26 f0 	ldx  [ %i0 + 0x6f0 ], %g7
	 * Calculate overall stats
	 */
	journal->j_stats.ts_tid++;
	journal->j_stats.u.run.rs_wait += stats.u.run.rs_wait;
	journal->j_stats.u.run.rs_running += stats.u.run.rs_running;
	journal->j_stats.u.run.rs_locked += stats.u.run.rs_locked;
    18c0:	86 00 c0 01 	add  %g3, %g1, %g3
	journal->j_stats.u.run.rs_flushing += stats.u.run.rs_flushing;
    18c4:	c2 5f a7 87 	ldx  [ %fp + 0x787 ], %g1
	journal->j_stats.u.run.rs_logging += stats.u.run.rs_logging;
    18c8:	da 5e 26 f8 	ldx  [ %i0 + 0x6f8 ], %o5
	 */
	journal->j_stats.ts_tid++;
	journal->j_stats.u.run.rs_wait += stats.u.run.rs_wait;
	journal->j_stats.u.run.rs_running += stats.u.run.rs_running;
	journal->j_stats.u.run.rs_locked += stats.u.run.rs_locked;
	journal->j_stats.u.run.rs_flushing += stats.u.run.rs_flushing;
    18cc:	8e 01 c0 01 	add  %g7, %g1, %g7
	journal->j_stats.u.run.rs_logging += stats.u.run.rs_logging;
    18d0:	c2 5f a7 8f 	ldx  [ %fp + 0x78f ], %g1
	journal->j_stats.u.run.rs_handle_count += stats.u.run.rs_handle_count;
    18d4:	d8 5e 27 00 	ldx  [ %i0 + 0x700 ], %o4
	journal->j_stats.ts_tid++;
	journal->j_stats.u.run.rs_wait += stats.u.run.rs_wait;
	journal->j_stats.u.run.rs_running += stats.u.run.rs_running;
	journal->j_stats.u.run.rs_locked += stats.u.run.rs_locked;
	journal->j_stats.u.run.rs_flushing += stats.u.run.rs_flushing;
	journal->j_stats.u.run.rs_logging += stats.u.run.rs_logging;
    18d8:	9a 03 40 01 	add  %o5, %g1, %o5
	journal->j_stats.u.run.rs_handle_count += stats.u.run.rs_handle_count;
    18dc:	c2 5f a7 97 	ldx  [ %fp + 0x797 ], %g1
	journal->j_stats.u.run.rs_blocks += stats.u.run.rs_blocks;
    18e0:	d6 5e 27 08 	ldx  [ %i0 + 0x708 ], %o3
	journal->j_stats.u.run.rs_wait += stats.u.run.rs_wait;
	journal->j_stats.u.run.rs_running += stats.u.run.rs_running;
	journal->j_stats.u.run.rs_locked += stats.u.run.rs_locked;
	journal->j_stats.u.run.rs_flushing += stats.u.run.rs_flushing;
	journal->j_stats.u.run.rs_logging += stats.u.run.rs_logging;
	journal->j_stats.u.run.rs_handle_count += stats.u.run.rs_handle_count;
    18e4:	98 03 00 01 	add  %o4, %g1, %o4
	journal->j_stats.u.run.rs_blocks += stats.u.run.rs_blocks;
    18e8:	c2 5f a7 9f 	ldx  [ %fp + 0x79f ], %g1
		journal->j_history_cur = 0;

	/*
	 * Calculate overall stats
	 */
	journal->j_stats.ts_tid++;
    18ec:	c4 5e 26 d0 	ldx  [ %i0 + 0x6d0 ], %g2
	journal->j_stats.u.run.rs_locked += stats.u.run.rs_locked;
	journal->j_stats.u.run.rs_flushing += stats.u.run.rs_flushing;
	journal->j_stats.u.run.rs_logging += stats.u.run.rs_logging;
	journal->j_stats.u.run.rs_handle_count += stats.u.run.rs_handle_count;
	journal->j_stats.u.run.rs_blocks += stats.u.run.rs_blocks;
	journal->j_stats.u.run.rs_blocks_logged += stats.u.run.rs_blocks_logged;
    18f0:	d4 5e 27 10 	ldx  [ %i0 + 0x710 ], %o2
	journal->j_stats.u.run.rs_running += stats.u.run.rs_running;
	journal->j_stats.u.run.rs_locked += stats.u.run.rs_locked;
	journal->j_stats.u.run.rs_flushing += stats.u.run.rs_flushing;
	journal->j_stats.u.run.rs_logging += stats.u.run.rs_logging;
	journal->j_stats.u.run.rs_handle_count += stats.u.run.rs_handle_count;
	journal->j_stats.u.run.rs_blocks += stats.u.run.rs_blocks;
    18f4:	96 02 c0 01 	add  %o3, %g1, %o3
	journal->j_stats.u.run.rs_blocks_logged += stats.u.run.rs_blocks_logged;
    18f8:	c2 5f a7 a7 	ldx  [ %fp + 0x7a7 ], %g1
		journal->j_history_cur = 0;

	/*
	 * Calculate overall stats
	 */
	journal->j_stats.ts_tid++;
    18fc:	84 00 a0 01 	inc  %g2
	journal->j_stats.u.run.rs_wait += stats.u.run.rs_wait;
    1900:	d2 76 26 d8 	stx  %o1, [ %i0 + 0x6d8 ]
	journal->j_stats.u.run.rs_locked += stats.u.run.rs_locked;
	journal->j_stats.u.run.rs_flushing += stats.u.run.rs_flushing;
	journal->j_stats.u.run.rs_logging += stats.u.run.rs_logging;
	journal->j_stats.u.run.rs_handle_count += stats.u.run.rs_handle_count;
	journal->j_stats.u.run.rs_blocks += stats.u.run.rs_blocks;
	journal->j_stats.u.run.rs_blocks_logged += stats.u.run.rs_blocks_logged;
    1904:	94 02 80 01 	add  %o2, %g1, %o2
		journal->j_history_cur = 0;

	/*
	 * Calculate overall stats
	 */
	journal->j_stats.ts_tid++;
    1908:	c4 76 26 d0 	stx  %g2, [ %i0 + 0x6d0 ]
	journal->j_stats.u.run.rs_wait += stats.u.run.rs_wait;
	journal->j_stats.u.run.rs_running += stats.u.run.rs_running;
    190c:	de 76 26 e0 	stx  %o7, [ %i0 + 0x6e0 ]
	journal->j_stats.u.run.rs_locked += stats.u.run.rs_locked;
    1910:	c6 76 26 e8 	stx  %g3, [ %i0 + 0x6e8 ]
	journal->j_stats.u.run.rs_flushing += stats.u.run.rs_flushing;
    1914:	ce 76 26 f0 	stx  %g7, [ %i0 + 0x6f0 ]
	journal->j_stats.u.run.rs_logging += stats.u.run.rs_logging;
    1918:	da 76 26 f8 	stx  %o5, [ %i0 + 0x6f8 ]
	journal->j_stats.u.run.rs_handle_count += stats.u.run.rs_handle_count;
    191c:	d8 76 27 00 	stx  %o4, [ %i0 + 0x700 ]
	journal->j_stats.u.run.rs_blocks += stats.u.run.rs_blocks;
    1920:	d6 76 27 08 	stx  %o3, [ %i0 + 0x708 ]
	journal->j_stats.u.run.rs_blocks_logged += stats.u.run.rs_blocks_logged;
	spin_unlock(&journal->j_history_lock);
    1924:	40 00 00 00 	call  1924 <jbd2_journal_commit_transaction+0x11a0>
    1928:	d4 76 27 10 	stx  %o2, [ %i0 + 0x710 ]

	commit_transaction->t_state = T_FINISHED;
    192c:	82 10 20 05 	mov  5, %g1
    1930:	c2 24 e0 0c 	st  %g1, [ %l3 + 0xc ]
	J_ASSERT(commit_transaction == journal->j_committing_transaction);
    1934:	e0 5e 20 e0 	ldx  [ %i0 + 0xe0 ], %l0
    1938:	80 a4 c0 10 	cmp  %l3, %l0
    193c:	12 67 fb ca 	bne,pn   %xcc, 864 <jbd2_journal_commit_transaction+0xe0>
    1940:	92 10 23 ef 	mov  0x3ef, %o1
	journal->j_commit_sequence = commit_transaction->t_tid;
    1944:	c2 04 e0 08 	ld  [ %l3 + 8 ], %g1
	journal->j_committing_transaction = NULL;
    1948:	c0 76 20 e0 	clrx  [ %i0 + 0xe0 ]
	commit_time = ktime_to_ns(ktime_sub(ktime_get(), start_time));
    194c:	40 00 00 00 	call  194c <jbd2_journal_commit_transaction+0x11c8>
    1950:	c2 26 25 b0 	st  %g1, [ %i0 + 0x5b0 ]
    1954:	c6 5f a7 3f 	ldx  [ %fp + 0x73f ], %g3

	/*
	 * weight the commit time higher than the average time so we don't
	 * react too strongly to vast changes in the commit time
	 */
	if (likely(journal->j_average_commit_time))
    1958:	c4 5e 26 68 	ldx  [ %i0 + 0x668 ], %g2
    195c:	02 c0 80 08 	brz,pn   %g2, 197c <jbd2_journal_commit_transaction+0x11f8>
    1960:	90 22 00 03 	sub  %o0, %g3, %o0
		journal->j_average_commit_time = (commit_time +
    1964:	83 28 b0 01 	sllx  %g2, 1, %g1
    1968:	82 00 40 02 	add  %g1, %g2, %g1
    196c:	82 02 00 01 	add  %o0, %g1, %g1
    1970:	83 30 70 02 	srlx  %g1, 2, %g1
    1974:	10 68 00 03 	b  %xcc, 1980 <jbd2_journal_commit_transaction+0x11fc>
    1978:	c2 76 26 68 	stx  %g1, [ %i0 + 0x668 ]
				journal->j_average_commit_time*3) / 4;
	else
		journal->j_average_commit_time = commit_time;
    197c:	d0 76 26 68 	stx  %o0, [ %i0 + 0x668 ]
	spin_unlock(&journal->j_state_lock);
    1980:	40 00 00 00 	call  1980 <jbd2_journal_commit_transaction+0x11fc>
    1984:	90 10 00 1a 	mov  %i2, %o0

	if (commit_transaction->t_checkpoint_list == NULL &&
    1988:	c2 5c e0 38 	ldx  [ %l3 + 0x38 ], %g1
    198c:	2a c8 40 0a 	brnz,a   %g1, 19b4 <jbd2_journal_commit_transaction+0x1230>
    1990:	c4 5e 20 e8 	ldx  [ %i0 + 0xe8 ], %g2
    1994:	c2 5c 20 40 	ldx  [ %l0 + 0x40 ], %g1
    1998:	2a c8 40 07 	brnz,a   %g1, 19b4 <jbd2_journal_commit_transaction+0x1230>
    199c:	c4 5e 20 e8 	ldx  [ %i0 + 0xe8 ], %g2
	    commit_transaction->t_checkpoint_io_list == NULL) {
		__jbd2_journal_drop_transaction(journal, commit_transaction);
    19a0:	90 10 00 18 	mov  %i0, %o0
    19a4:	40 00 00 00 	call  19a4 <jbd2_journal_commit_transaction+0x1220>
    19a8:	92 10 00 10 	mov  %l0, %o1
    19ac:	10 68 00 0f 	b  %xcc, 19e8 <jbd2_journal_commit_transaction+0x1264>
    19b0:	a2 10 20 01 	mov  1, %l1
		to_free = 1;
	} else {
		if (journal->j_checkpoint_transactions == NULL) {
    19b4:	2a c8 80 07 	brnz,a   %g2, 19d0 <jbd2_journal_commit_transaction+0x124c>
    19b8:	c2 58 a0 e0 	ldx  [ %g2 + 0xe0 ], %g1
			journal->j_checkpoint_transactions = commit_transaction;
    19bc:	e0 76 20 e8 	stx  %l0, [ %i0 + 0xe8 ]
			commit_transaction->t_cpnext = commit_transaction;
			commit_transaction->t_cpprev = commit_transaction;
    19c0:	a2 10 20 00 	clr  %l1
		__jbd2_journal_drop_transaction(journal, commit_transaction);
		to_free = 1;
	} else {
		if (journal->j_checkpoint_transactions == NULL) {
			journal->j_checkpoint_transactions = commit_transaction;
			commit_transaction->t_cpnext = commit_transaction;
    19c4:	e0 74 20 d8 	stx  %l0, [ %l0 + 0xd8 ]
			commit_transaction->t_cpprev = commit_transaction;
    19c8:	10 68 00 08 	b  %xcc, 19e8 <jbd2_journal_commit_transaction+0x1264>
    19cc:	e0 74 20 e0 	stx  %l0, [ %l0 + 0xe0 ]
				journal->j_checkpoint_transactions;
			commit_transaction->t_cpprev =
				commit_transaction->t_cpnext->t_cpprev;
			commit_transaction->t_cpnext->t_cpprev =
				commit_transaction;
			commit_transaction->t_cpprev->t_cpnext =
    19d0:	a2 10 20 00 	clr  %l1
		if (journal->j_checkpoint_transactions == NULL) {
			journal->j_checkpoint_transactions = commit_transaction;
			commit_transaction->t_cpnext = commit_transaction;
			commit_transaction->t_cpprev = commit_transaction;
		} else {
			commit_transaction->t_cpnext =
    19d4:	c4 74 20 d8 	stx  %g2, [ %l0 + 0xd8 ]
				journal->j_checkpoint_transactions;
			commit_transaction->t_cpprev =
    19d8:	c2 74 20 e0 	stx  %g1, [ %l0 + 0xe0 ]
				commit_transaction->t_cpnext->t_cpprev;
			commit_transaction->t_cpnext->t_cpprev =
    19dc:	e0 70 a0 e0 	stx  %l0, [ %g2 + 0xe0 ]
				commit_transaction;
			commit_transaction->t_cpprev->t_cpnext =
    19e0:	c2 5c 20 e0 	ldx  [ %l0 + 0xe0 ], %g1
    19e4:	e0 70 60 d8 	stx  %l0, [ %g1 + 0xd8 ]
				commit_transaction;
		}
	}
	spin_unlock(&journal->j_list_lock);
    19e8:	40 00 00 00 	call  19e8 <jbd2_journal_commit_transaction+0x1264>
    19ec:	90 10 00 1b 	mov  %i3, %o0

	if (journal->j_commit_callback)
    19f0:	c2 5e 26 78 	ldx  [ %i0 + 0x678 ], %g1
    19f4:	02 c0 40 04 	brz,pn   %g1, 1a04 <jbd2_journal_commit_transaction+0x1280>
    19f8:	90 10 00 18 	mov  %i0, %o0
		journal->j_commit_callback(journal, commit_transaction);
    19fc:	9f c0 40 00 	call  %g1
    1a00:	92 10 00 10 	mov  %l0, %o1

	trace_mark(jbd2_end_commit, "dev %s transaction %d head %d",
		   journal->j_devname, commit_transaction->t_tid,
		   journal->j_tail_sequence);
	jbd_debug(1, "JBD: commit %d complete, head %d\n",
    1a04:	03 00 00 00 	sethi  %hi(0), %g1
    1a08:	c2 08 60 00 	ldub  [ %g1 ], %g1
    1a0c:	80 a0 60 00 	cmp  %g1, 0
    1a10:	02 48 00 10 	be  %icc, 1a50 <jbd2_journal_commit_transaction+0x12cc>
    1a14:	80 a4 60 00 	cmp  %l1, 0
    1a18:	13 00 00 00 	sethi  %hi(0), %o1
    1a1c:	11 00 00 00 	sethi  %hi(0), %o0
    1a20:	17 00 00 00 	sethi  %hi(0), %o3
    1a24:	92 12 60 00 	mov  %o1, %o1
    1a28:	94 10 24 1c 	mov  0x41c, %o2
    1a2c:	90 12 20 00 	mov  %o0, %o0
    1a30:	40 00 00 00 	call  1a30 <jbd2_journal_commit_transaction+0x12ac>
    1a34:	96 12 e0 00 	mov  %o3, %o3
    1a38:	11 00 00 00 	sethi  %hi(0), %o0
    1a3c:	d2 06 25 b0 	ld  [ %i0 + 0x5b0 ], %o1
    1a40:	d4 06 25 a8 	ld  [ %i0 + 0x5a8 ], %o2
    1a44:	40 00 00 00 	call  1a44 <jbd2_journal_commit_transaction+0x12c0>
    1a48:	90 12 20 00 	mov  %o0, %o0
		  journal->j_commit_sequence, journal->j_tail_sequence);
	if (to_free)
    1a4c:	80 a4 60 00 	cmp  %l1, 0
    1a50:	02 48 00 05 	be  %icc, 1a64 <jbd2_journal_commit_transaction+0x12e0>
    1a54:	90 06 21 70 	add  %i0, 0x170, %o0
		kfree(commit_transaction);
    1a58:	40 00 00 00 	call  1a58 <jbd2_journal_commit_transaction+0x12d4>
    1a5c:	90 10 00 10 	mov  %l0, %o0

	wake_up(&journal->j_wait_done_commit);
    1a60:	90 06 21 70 	add  %i0, 0x170, %o0
    1a64:	92 10 20 03 	mov  3, %o1
    1a68:	94 10 20 01 	mov  1, %o2
    1a6c:	40 00 00 00 	call  1a6c <jbd2_journal_commit_transaction+0x12e8>
    1a70:	96 10 20 00 	clr  %o3
}
    1a74:	81 cf e0 08 	rett  %i7 + 8
    1a78:	01 00 00 00 	nop 

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-25 17:07                     ` Alexander Beregalov
@ 2009-03-25 19:43                       ` Jan Kara
  2009-03-25 22:38                         ` Alexander Beregalov
  0 siblings, 1 reply; 24+ messages in thread
From: Jan Kara @ 2009-03-25 19:43 UTC (permalink / raw)
  To: Alexander Beregalov
  Cc: Theodore Tso, linux-next, linux-ext4, LKML, sparclinux

On Wed 25-03-09 20:07:46, Alexander Beregalov wrote:
> 2009/3/25 Jan Kara <jack@suse.cz>:
> > On Wed 25-03-09 18:29:10, Alexander Beregalov wrote:
> >> 2009/3/25 Jan Kara <jack@suse.cz>:
> >> > On Wed 25-03-09 18:18:43, Alexander Beregalov wrote:
> >> >> 2009/3/25 Jan Kara <jack@suse.cz>:
> >> >> >> > So, I think I need to try it on 2.6.29-rc7 again.
> >> >> >>   I've looked into this. Obviously, what's happenning is that we delete
> >> >> >> an inode and jbd2_journal_release_jbd_inode() finds inode is just under
> >> >> >> writeout in transaction commit and thus it waits. But it gets never woken
> >> >> >> up and because it has a handle from the transaction, every one eventually
> >> >> >> blocks on waiting for a transaction to finish.
> >> >> >>   But I don't really see how that can happen. The code is really
> >> >> >> straightforward and everything happens under j_list_lock... Strange.
> >> >> >  BTW: Is the system SMP?
> >> >> No, it is UP system.
> >> >  Even stranger. And do you have CONFIG_PREEMPT set?
> >> >
> >> >> The bug exists even in 2.6.29, I posted it with a new topic.
> >> >  OK, I've sort-of expected this.
> >>
> >> CONFIG_PREEMPT_RCU=y
> >> CONFIG_PREEMPT_RCU_TRACE=y
> >> # CONFIG_PREEMPT_NONE is not set
> >> # CONFIG_PREEMPT_VOLUNTARY is not set
> >> CONFIG_PREEMPT=y
> >> CONFIG_DEBUG_PREEMPT=y
> >> # CONFIG_PREEMPT_TRACER is not set
> >>
> >> config is attached.
> >  Thanks for the data. I still don't see how the wakeup can get lost. The
> > process even cannot be preempted when we are in the section protected by
> > j_list_lock... Can you send me a disassembly of functions
> > jbd2_journal_release_jbd_inode() and journal_submit_data_buffers() so that
> > I can see whether the compiler has not reordered something unexpectedly?
  Thanks for the disassembly...

> By default gcc inlines journal_submit_data_buffers()
> Here is -fno-inline version. Default version is in attach.
> ====
> 
> static int journal_submit_data_buffers(journal_t *journal,
>                 transaction_t *commit_transaction)
> {
>       9c:       9d e3 bf 40     save  %sp, -192, %sp
>       a0:       11 00 00 00     sethi  %hi(0), %o0
>         struct jbd2_inode *jinode;
>         int err, ret = 0;
>         struct address_space *mapping;
> 
>         spin_lock(&journal->j_list_lock);
>       a4:       a4 06 25 70     add  %i0, 0x570, %l2
>  * our inode list. We use JI_COMMIT_RUNNING flag to protect inode we currently
>  * operate on from being released while we write out pages.
>  */
> static int journal_submit_data_buffers(journal_t *journal,
>                 transaction_t *commit_transaction)
> {
>       a8:       90 12 20 00     mov  %o0, %o0
>       ac:       40 00 00 00     call  ac <journal_submit_data_buffers+0x10>
>       b0:       b0 10 20 00     clr  %i0
>         struct jbd2_inode *jinode;
>         int err, ret = 0;
>         struct address_space *mapping;
> 
>         spin_lock(&journal->j_list_lock);
>         list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
>       b4:       a6 06 60 60     add  %i1, 0x60, %l3
> {
>         struct jbd2_inode *jinode;
>         int err, ret = 0;
>         struct address_space *mapping;
> 
>         spin_lock(&journal->j_list_lock);
>       b8:       40 00 00 00     call  b8 <journal_submit_data_buffers+0x1c>
>       bc:       90 10 00 12     mov  %l2, %o0
>         list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
>       c0:       10 68 00 1d     b  %xcc, 134 <journal_submit_data_buffers+0x98>
>       c4:       c2 5e 60 60     ldx  [ %i1 + 0x60 ], %g1
>                 mapping = jinode->i_vfs_inode->i_mapping;
>                 jinode->i_flags |= JI_COMMIT_RUNNING;
>                 spin_unlock(&journal->j_list_lock);
>       c8:       90 10 00 12     mov  %l2, %o0
>         struct address_space *mapping;
> 
>         spin_lock(&journal->j_list_lock);
>         list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
>                 mapping = jinode->i_vfs_inode->i_mapping;
>                 jinode->i_flags |= JI_COMMIT_RUNNING;
>       cc:       c2 04 60 28     ld  [ %l1 + 0x28 ], %g1
  Here we load jbd2_inode->i_flags into %g1.

>         int err, ret = 0;
>         struct address_space *mapping;
> 
>         spin_lock(&journal->j_list_lock);
>         list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
>                 mapping = jinode->i_vfs_inode->i_mapping;
>       d0:       e0 58 a1 e0     ldx  [ %g2 + 0x1e0 ], %l0
>                 jinode->i_flags |= JI_COMMIT_RUNNING;
>       d4:       82 10 60 01     or  %g1, 1, %g1
  Here we set JI_COMMIT_RUNNING.

>                 spin_unlock(&journal->j_list_lock);
>       d8:       40 00 00 00     call  d8 <journal_submit_data_buffers+0x3c>
  Here we seem to call preempt_disable() (it would be useful if we could
confirm that - easiest option I know is compiling JBD2 into a kernel but
some object file trickery should be able to find it out as well...)

>       dc:       c2 24 60 28     st  %g1, [ %l1 + 0x28 ]
  And here we store the register back to memory - but we could be already
preempted here which could cause bugs...

>                  * submit the inode data buffers. We use writepage
>                  * instead of writepages. Because writepages can do
>                  * block allocation  with delalloc. We need to write
>                  * only allocated blocks here.
>                  */
>                 err = journal_submit_inode_data_buffers(mapping);
>       e0:       7f ff ff d3     call  2c <journal_submit_inode_data_buffers>
>       e4:       90 10 00 10     mov  %l0, %o0
>                 if (!ret)
>       e8:       80 a6 20 00     cmp  %i0, 0
>       ec:       b1 64 40 08     move  %icc, %o0, %i0
>                         ret = err;
>                 spin_lock(&journal->j_list_lock);
>       f0:       40 00 00 00     call  f0 <journal_submit_data_buffers+0x54>
>       f4:       90 10 00 12     mov  %l2, %o0
>                 J_ASSERT(jinode->i_transaction == commit_transaction);
>       f8:       c2 5c 40 00     ldx  [ %l1 ], %g1
>       fc:       80 a0 40 19     cmp  %g1, %i1
>      100:       22 68 00 07     be,a   %xcc, 11c
> <journal_submit_data_buffers+0x80>
>      104:       c2 04 60 28     ld  [ %l1 + 0x28 ], %g1
  Again, here we load jinode->i_flags.

>      108:       11 00 00 00     sethi  %hi(0), %o0
>      10c:       92 10 21 04     mov  0x104, %o1
>      110:       40 00 00 00     call  110 <journal_submit_data_buffers+0x74>
>      114:       90 12 20 00     mov  %o0, %o0
>      118:       91 d0 20 05     ta  5
>                 jinode->i_flags &= ~JI_COMMIT_RUNNING;
>                 wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
>      11c:       90 04 60 28     add  %l1, 0x28, %o0
>      120:       92 10 20 00     clr  %o1
>                 err = journal_submit_inode_data_buffers(mapping);
>                 if (!ret)
>                         ret = err;
>                 spin_lock(&journal->j_list_lock);
>                 J_ASSERT(jinode->i_transaction == commit_transaction);
>                 jinode->i_flags &= ~JI_COMMIT_RUNNING;
>      124:       82 08 7f fe     and  %g1, -2, %g1
  Here we go &= ~JI_COMMIT_RUNNING

>                 wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
>      128:       40 00 00 00     call  128 <journal_submit_data_buffers+0x8c>
>      12c:       c2 24 60 28     st  %g1, [ %l1 + 0x28 ]
  And only here we store it back to memory...

>         struct jbd2_inode *jinode;
>         int err, ret = 0;
>         struct address_space *mapping;
> 
>         spin_lock(&journal->j_list_lock);
>         list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
>      130:       c2 5c 60 10     ldx  [ %l1 + 0x10 ], %g1
>      134:       a2 00 7f f0     add  %g1, -16, %l1
>          * prefetches into the prefetch-cache which only is accessible
>          * by floating point operations in UltraSPARC-III and later.
>          * By contrast, "#one_write" prefetches into the L2 cache
>          * in shared state.
>          */
>         __asm__ __volatile__("prefetch [%0], #one_write"
>      138:       c2 5c 60 10     ldx  [ %l1 + 0x10 ], %g1
>      13c:       c7 68 40 00     prefetch  [ %g1 ], #one_write
>      140:       82 04 60 10     add  %l1, 0x10, %g1
>      144:       80 a4 c0 01     cmp  %l3, %g1
>      148:       32 6f ff e0     bne,a   %xcc, c8
> <journal_submit_data_buffers+0x2c>
>      14c:       c4 5c 60 20     ldx  [ %l1 + 0x20 ], %g2
>                 spin_lock(&journal->j_list_lock);
>                 J_ASSERT(jinode->i_transaction == commit_transaction);
>                 wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
>         }
>         spin_unlock(&journal->j_list_lock);
>      150:       90 10 00 12     mov  %l2, %o0
>      154:       40 00 00 00     call  154 <journal_submit_data_buffers+0xb8>
>      158:       b1 3e 20 00     sra  %i0, 0, %i0
>         return ret;
> }
>      15c:       81 cf e0 08     rett  %i7 + 8
>      160:       01 00 00 00     nop
  So the compiled code looks a bit suspitious to me. Having the disassembly
with symbols properly resolved would help confirm it. I'm adding sparc list
to CC just in case someone sees the problem...

									Honza
-- 
Jan Kara <jack@suse.cz>
SUSE Labs, CR
--
To unsubscribe from this list: send the line "unsubscribe sparclinux" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-25 19:43                       ` Jan Kara
@ 2009-03-25 22:38                         ` Alexander Beregalov
  2009-03-26  0:00                           ` Jan Kara
  2009-03-31 10:01                           ` Jan Kara
  0 siblings, 2 replies; 24+ messages in thread
From: Alexander Beregalov @ 2009-03-25 22:38 UTC (permalink / raw)
  To: Jan Kara; +Cc: Theodore Tso, linux-next, linux-ext4, LKML, sparclinux

2009/3/25 Jan Kara <jack@suse.cz>:
> On Wed 25-03-09 20:07:46, Alexander Beregalov wrote:
>> 2009/3/25 Jan Kara <jack@suse.cz>:
>> > On Wed 25-03-09 18:29:10, Alexander Beregalov wrote:
>> >> 2009/3/25 Jan Kara <jack@suse.cz>:
>> >> > On Wed 25-03-09 18:18:43, Alexander Beregalov wrote:
>> >> >> 2009/3/25 Jan Kara <jack@suse.cz>:
>> >> >> >> > So, I think I need to try it on 2.6.29-rc7 again.
>> >> >> >>   I've looked into this. Obviously, what's happenning is that we delete
>> >> >> >> an inode and jbd2_journal_release_jbd_inode() finds inode is just under
>> >> >> >> writeout in transaction commit and thus it waits. But it gets never woken
>> >> >> >> up and because it has a handle from the transaction, every one eventually
>> >> >> >> blocks on waiting for a transaction to finish.
>> >> >> >>   But I don't really see how that can happen. The code is really
>> >> >> >> straightforward and everything happens under j_list_lock... Strange.
>> >> >> >  BTW: Is the system SMP?
>> >> >> No, it is UP system.
>> >> >  Even stranger. And do you have CONFIG_PREEMPT set?
>> >> >
>> >> >> The bug exists even in 2.6.29, I posted it with a new topic.
>> >> >  OK, I've sort-of expected this.
>> >>
>> >> CONFIG_PREEMPT_RCU=y
>> >> CONFIG_PREEMPT_RCU_TRACE=y
>> >> # CONFIG_PREEMPT_NONE is not set
>> >> # CONFIG_PREEMPT_VOLUNTARY is not set
>> >> CONFIG_PREEMPT=y
>> >> CONFIG_DEBUG_PREEMPT=y
>> >> # CONFIG_PREEMPT_TRACER is not set
>> >>
>> >> config is attached.
>> >  Thanks for the data. I still don't see how the wakeup can get lost. The
>> > process even cannot be preempted when we are in the section protected by
>> > j_list_lock... Can you send me a disassembly of functions
>> > jbd2_journal_release_jbd_inode() and journal_submit_data_buffers() so that
>> > I can see whether the compiler has not reordered something unexpectedly?
>  Thanks for the disassembly...
>
>> By default gcc inlines journal_submit_data_buffers()
>> Here is -fno-inline version. Default version is in attach.
>> ====
>>
>> static int journal_submit_data_buffers(journal_t *journal,
>>                 transaction_t *commit_transaction)
>> {
>>       9c:       9d e3 bf 40     save  %sp, -192, %sp
>>       a0:       11 00 00 00     sethi  %hi(0), %o0
>>         struct jbd2_inode *jinode;
>>         int err, ret = 0;
>>         struct address_space *mapping;
>>
>>         spin_lock(&journal->j_list_lock);
>>       a4:       a4 06 25 70     add  %i0, 0x570, %l2
>>  * our inode list. We use JI_COMMIT_RUNNING flag to protect inode we currently
>>  * operate on from being released while we write out pages.
>>  */
>> static int journal_submit_data_buffers(journal_t *journal,
>>                 transaction_t *commit_transaction)
>> {
>>       a8:       90 12 20 00     mov  %o0, %o0
>>       ac:       40 00 00 00     call  ac <journal_submit_data_buffers+0x10>
>>       b0:       b0 10 20 00     clr  %i0
>>         struct jbd2_inode *jinode;
>>         int err, ret = 0;
>>         struct address_space *mapping;
>>
>>         spin_lock(&journal->j_list_lock);
>>         list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
>>       b4:       a6 06 60 60     add  %i1, 0x60, %l3
>> {
>>         struct jbd2_inode *jinode;
>>         int err, ret = 0;
>>         struct address_space *mapping;
>>
>>         spin_lock(&journal->j_list_lock);
>>       b8:       40 00 00 00     call  b8 <journal_submit_data_buffers+0x1c>
>>       bc:       90 10 00 12     mov  %l2, %o0
>>         list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
>>       c0:       10 68 00 1d     b  %xcc, 134 <journal_submit_data_buffers+0x98>
>>       c4:       c2 5e 60 60     ldx  [ %i1 + 0x60 ], %g1
>>                 mapping = jinode->i_vfs_inode->i_mapping;
>>                 jinode->i_flags |= JI_COMMIT_RUNNING;
>>                 spin_unlock(&journal->j_list_lock);
>>       c8:       90 10 00 12     mov  %l2, %o0
>>         struct address_space *mapping;
>>
>>         spin_lock(&journal->j_list_lock);
>>         list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
>>                 mapping = jinode->i_vfs_inode->i_mapping;
>>                 jinode->i_flags |= JI_COMMIT_RUNNING;
>>       cc:       c2 04 60 28     ld  [ %l1 + 0x28 ], %g1
>  Here we load jbd2_inode->i_flags into %g1.
>
>>         int err, ret = 0;
>>         struct address_space *mapping;
>>
>>         spin_lock(&journal->j_list_lock);
>>         list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
>>                 mapping = jinode->i_vfs_inode->i_mapping;
>>       d0:       e0 58 a1 e0     ldx  [ %g2 + 0x1e0 ], %l0
>>                 jinode->i_flags |= JI_COMMIT_RUNNING;
>>       d4:       82 10 60 01     or  %g1, 1, %g1
>  Here we set JI_COMMIT_RUNNING.
>
>>                 spin_unlock(&journal->j_list_lock);
>>       d8:       40 00 00 00     call  d8 <journal_submit_data_buffers+0x3c>
>  Here we seem to call preempt_disable() (it would be useful if we could
> confirm that - easiest option I know is compiling JBD2 into a kernel but
> some object file trickery should be able to find it out as well...)
  55bab0:       82 10 60 01     or  %g1, 1, %g1
                spin_unlock(&journal->j_list_lock);
  55bab4:       40 06 4b 20     call  6ee734 <_spin_unlock>
  55bab8:       c2 24 e0 28     st  %g1, [ %l3 + 0x28 ]
<..>
void __lockfunc _spin_unlock(spinlock_t *lock)
{
  6ee734:       9d e3 bf 40     save  %sp, -192, %sp
  6ee738:       11 00 1f f9     sethi  %hi(0x7fe400), %o0
  6ee73c:       7f fb 36 59     call  5bc0a0 <_mcount>
  6ee740:       90 12 22 40     or  %o0, 0x240, %o0     ! 7fe640
<rt_trace_on+0xc8>
        spin_release(&lock->dep_map, 1, _RET_IP_);
  6ee744:       94 10 00 1f     mov  %i7, %o2
  6ee748:       92 10 20 01     mov  1, %o1
  6ee74c:       7f f6 21 18     call  476bac <lock_release>
  6ee750:       90 06 20 18     add  %i0, 0x18, %o0
        _raw_spin_unlock(lock);
  6ee754:       7f fb 7f 91     call  5ce598 <_raw_spin_unlock>
  6ee758:       90 10 00 18     mov  %i0, %o0
        preempt_enable();
  6ee75c:       40 00 05 fd     call  6eff50 <sub_preempt_count>
  6ee760:       90 10 20 01     mov  1, %o0
  6ee764:       c2 59 a0 08     ldx  [ %g6 + 8 ], %g1
  6ee768:       82 08 60 08     and  %g1, 8, %g1
  6ee76c:       02 c8 40 04     brz  %g1, 6ee77c <_spin_unlock+0x48>
  6ee770:       01 00 00 00     nop
  6ee774:       7f ff f4 f1     call  6ebb38 <preempt_schedule>
  6ee778:       01 00 00 00     nop
  6ee77c:       81 cf e0 08     rett  %i7 + 8
  6ee780:       01 00 00 00     nop
}


>
>>       dc:       c2 24 60 28     st  %g1, [ %l1 + 0x28 ]
>  And here we store the register back to memory - but we could be already
> preempted here which could cause bugs...
>
>>                  * submit the inode data buffers. We use writepage
>>                  * instead of writepages. Because writepages can do
>>                  * block allocation  with delalloc. We need to write
>>                  * only allocated blocks here.
>>                  */
>>                 err = journal_submit_inode_data_buffers(mapping);
>>       e0:       7f ff ff d3     call  2c <journal_submit_inode_data_buffers>
>>       e4:       90 10 00 10     mov  %l0, %o0
>>                 if (!ret)
>>       e8:       80 a6 20 00     cmp  %i0, 0
>>       ec:       b1 64 40 08     move  %icc, %o0, %i0
>>                         ret = err;
>>                 spin_lock(&journal->j_list_lock);
>>       f0:       40 00 00 00     call  f0 <journal_submit_data_buffers+0x54>
>>       f4:       90 10 00 12     mov  %l2, %o0
>>                 J_ASSERT(jinode->i_transaction == commit_transaction);
>>       f8:       c2 5c 40 00     ldx  [ %l1 ], %g1
>>       fc:       80 a0 40 19     cmp  %g1, %i1
>>      100:       22 68 00 07     be,a   %xcc, 11c
>> <journal_submit_data_buffers+0x80>
>>      104:       c2 04 60 28     ld  [ %l1 + 0x28 ], %g1
>  Again, here we load jinode->i_flags.
>
>>      108:       11 00 00 00     sethi  %hi(0), %o0
>>      10c:       92 10 21 04     mov  0x104, %o1
>>      110:       40 00 00 00     call  110 <journal_submit_data_buffers+0x74>
>>      114:       90 12 20 00     mov  %o0, %o0
>>      118:       91 d0 20 05     ta  5
>>                 jinode->i_flags &= ~JI_COMMIT_RUNNING;
>>                 wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
>>      11c:       90 04 60 28     add  %l1, 0x28, %o0
>>      120:       92 10 20 00     clr  %o1
>>                 err = journal_submit_inode_data_buffers(mapping);
>>                 if (!ret)
>>                         ret = err;
>>                 spin_lock(&journal->j_list_lock);
>>                 J_ASSERT(jinode->i_transaction == commit_transaction);
>>                 jinode->i_flags &= ~JI_COMMIT_RUNNING;
>>      124:       82 08 7f fe     and  %g1, -2, %g1
>  Here we go &= ~JI_COMMIT_RUNNING
>
>>                 wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
>>      128:       40 00 00 00     call  128 <journal_submit_data_buffers+0x8c>
>>      12c:       c2 24 60 28     st  %g1, [ %l1 + 0x28 ]
>  And only here we store it back to memory...

                spin_lock(&journal->j_list_lock);
  55c104:       40 06 48 3c     call  6ee1f4 <_spin_lock>
  55c108:       90 10 00 12     mov  %l2, %o0
                jinode->i_flags &= ~JI_COMMIT_RUNNING;
  55c10c:       c2 04 20 28     ld  [ %l0 + 0x28 ], %g1
                wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
  55c110:       90 04 20 28     add  %l0, 0x28, %o0
  55c114:       92 10 20 00     clr  %o1
                        if (!ret)
                                ret = err;
                }
                spin_lock(&journal->j_list_lock);
                jinode->i_flags &= ~JI_COMMIT_RUNNING;
  55c118:       82 08 7f fe     and  %g1, -2, %g1
                wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
  55c11c:       7f fc 27 6e     call  465ed4 <wake_up_bit>
  55c120:       c2 24 20 28     st  %g1, [ %l0 + 0x28 ]
<..>
void __lockfunc _spin_lock(spinlock_t *lock)
{
  6ee1f4:       9d e3 bf 30     save  %sp, -208, %sp
  6ee1f8:       11 00 1f f9     sethi  %hi(0x7fe400), %o0
  6ee1fc:       7f fb 37 a9     call  5bc0a0 <_mcount>
  6ee200:       90 12 21 c8     or  %o0, 0x1c8, %o0     ! 7fe5c8
<rt_trace_on+0x50>
        preempt_disable();
  6ee204:       40 00 07 83     call  6f0010 <add_preempt_count>
  6ee208:       90 10 20 01     mov  1, %o0
        spin_acquire(&lock->dep_map, 0, 0, _RET_IP_);
  6ee20c:       92 10 20 00     clr  %o1
  6ee210:       90 06 20 18     add  %i0, 0x18, %o0
  6ee214:       fe 73 a8 af     stx  %i7, [ %sp + 0x8af ]
  6ee218:       94 10 20 00     clr  %o2
  6ee21c:       96 10 20 00     clr  %o3
  6ee220:       98 10 20 02     mov  2, %o4
  6ee224:       7f f6 21 a5     call  4768b8 <lock_acquire>
  6ee228:       9a 10 20 00     clr  %o5
        LOCK_CONTENDED(lock, _raw_spin_trylock, _raw_spin_lock);
  6ee22c:       7f fb 81 33     call  5ce6f8 <_raw_spin_lock>
  6ee230:       90 10 00 18     mov  %i0, %o0
}
  6ee234:       81 cf e0 08     rett  %i7 + 8
  6ee238:       01 00 00 00     nop
<..>
void wake_up_bit(void *word, int bit)
{
  465ed4:       9d e3 bf 40     save  %sp, -192, %sp
  465ed8:       11 00 1f f2     sethi  %hi(0x7fc800), %o0
  465edc:       40 05 58 71     call  5bc0a0 <_mcount>
  465ee0:       90 12 23 c8     or  %o0, 0x3c8, %o0     ! 7fcbc8
<kthread_stop_lock+0x88>
        __wake_up_bit(bit_waitqueue(word, bit), word, bit);
  465ee4:       92 10 00 19     mov  %i1, %o1
  465ee8:       7f ff ff c5     call  465dfc <bit_waitqueue>
  465eec:       90 10 00 18     mov  %i0, %o0
  465ef0:       92 10 00 18     mov  %i0, %o1
  465ef4:       7f ff ff e7     call  465e90 <__wake_up_bit>
  465ef8:       94 10 00 19     mov  %i1, %o2
}
  465efc:       81 cf e0 08     rett  %i7 + 8
  465f00:       01 00 00 00     nop


>
>>         struct jbd2_inode *jinode;
>>         int err, ret = 0;
>>         struct address_space *mapping;
>>
>>         spin_lock(&journal->j_list_lock);
>>         list_for_each_entry(jinode, &commit_transaction->t_inode_list, i_list) {
>>      130:       c2 5c 60 10     ldx  [ %l1 + 0x10 ], %g1
>>      134:       a2 00 7f f0     add  %g1, -16, %l1
>>          * prefetches into the prefetch-cache which only is accessible
>>          * by floating point operations in UltraSPARC-III and later.
>>          * By contrast, "#one_write" prefetches into the L2 cache
>>          * in shared state.
>>          */
>>         __asm__ __volatile__("prefetch [%0], #one_write"
>>      138:       c2 5c 60 10     ldx  [ %l1 + 0x10 ], %g1
>>      13c:       c7 68 40 00     prefetch  [ %g1 ], #one_write
>>      140:       82 04 60 10     add  %l1, 0x10, %g1
>>      144:       80 a4 c0 01     cmp  %l3, %g1
>>      148:       32 6f ff e0     bne,a   %xcc, c8
>> <journal_submit_data_buffers+0x2c>
>>      14c:       c4 5c 60 20     ldx  [ %l1 + 0x20 ], %g2
>>                 spin_lock(&journal->j_list_lock);
>>                 J_ASSERT(jinode->i_transaction == commit_transaction);
>>                 wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
>>         }
>>         spin_unlock(&journal->j_list_lock);
>>      150:       90 10 00 12     mov  %l2, %o0
>>      154:       40 00 00 00     call  154 <journal_submit_data_buffers+0xb8>
>>      158:       b1 3e 20 00     sra  %i0, 0, %i0
>>         return ret;
>> }
>>      15c:       81 cf e0 08     rett  %i7 + 8
>>      160:       01 00 00 00     nop
>  So the compiled code looks a bit suspitious to me. Having the disassembly
> with symbols properly resolved would help confirm it. I'm adding sparc list
> to CC just in case someone sees the problem...
>
>                                                                        Honza
> --
> Jan Kara <jack@suse.cz>
> SUSE Labs, CR
>

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-25 22:38                         ` Alexander Beregalov
@ 2009-03-26  0:00                           ` Jan Kara
  2009-03-26  0:17                             ` Jiri Gaisler
  2009-03-31 10:01                           ` Jan Kara
  1 sibling, 1 reply; 24+ messages in thread
From: Jan Kara @ 2009-03-26  0:00 UTC (permalink / raw)
  To: Alexander Beregalov
  Cc: Theodore Tso, linux-next, linux-ext4, LKML, sparclinux

  Hi,

  thanks for the updated disassembly.

>   55bab0:       82 10 60 01     or  %g1, 1, %g1
>                 spin_unlock(&journal->j_list_lock);
>   55bab4:       40 06 4b 20     call  6ee734 <_spin_unlock>
>   55bab8:       c2 24 e0 28     st  %g1, [ %l3 + 0x28 ]
  OK, so it really seems that:
  jinode->i_flags |= JI_COMMIT_RUNNING;
  spin_unlock(&journal->j_list_lock);

  has been compiled to
  ld [ %l3 + 0x28 ], %g1
  or  %g1, 1, %g1
  call  6ee734 <_spin_unlock>
  st  %g1, [ %l3 + 0x28 ]

  Which seems like a bug in the compiler or in the way implement compiler
barriers in spin_unlock() on UP sparc. Or is there some sparc magic by which
this is correct code? Any clever sparc guy?

									Honza
-- 
Jan Kara <jack@suse.cz>
SUSE Labs, CR

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-26  0:00                           ` Jan Kara
@ 2009-03-26  0:17                             ` Jiri Gaisler
  2009-03-26  0:25                               ` Jan Kara
  0 siblings, 1 reply; 24+ messages in thread
From: Jiri Gaisler @ 2009-03-26  0:17 UTC (permalink / raw)
  To: Jan Kara
  Cc: Alexander Beregalov, Theodore Tso, linux-next, linux-ext4, LKML,
	sparclinux



Jan Kara wrote:
>   Hi,
> 
>   thanks for the updated disassembly.
> 
>>   55bab0:       82 10 60 01     or  %g1, 1, %g1
>>                 spin_unlock(&journal->j_list_lock);
>>   55bab4:       40 06 4b 20     call  6ee734 <_spin_unlock>
>>   55bab8:       c2 24 e0 28     st  %g1, [ %l3 + 0x28 ]
>   OK, so it really seems that:
>   jinode->i_flags |= JI_COMMIT_RUNNING;
>   spin_unlock(&journal->j_list_lock);
> 
>   has been compiled to
>   ld [ %l3 + 0x28 ], %g1
>   or  %g1, 1, %g1
>   call  6ee734 <_spin_unlock>
>   st  %g1, [ %l3 + 0x28 ]
> 
>   Which seems like a bug in the compiler or in the way implement compiler
> barriers in spin_unlock() on UP sparc. Or is there some sparc magic by which
> this is correct code? Any clever sparc guy?
> 
> 									Honza


Looks fine to me - the store is made in the branch delay slot
of the call, so it will occur before the first instruction at
the call target address executes.
Jiri.

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-26  0:17                             ` Jiri Gaisler
@ 2009-03-26  0:25                               ` Jan Kara
  0 siblings, 0 replies; 24+ messages in thread
From: Jan Kara @ 2009-03-26  0:25 UTC (permalink / raw)
  To: Jiri Gaisler
  Cc: Alexander Beregalov, Theodore Tso, linux-next, linux-ext4, LKML,
	sparclinux

On Thu 26-03-09 01:17:06, Jiri Gaisler wrote:
> Jan Kara wrote:
> >   Hi,
> > 
> >   thanks for the updated disassembly.
> > 
> >>   55bab0:       82 10 60 01     or  %g1, 1, %g1
> >>                 spin_unlock(&journal->j_list_lock);
> >>   55bab4:       40 06 4b 20     call  6ee734 <_spin_unlock>
> >>   55bab8:       c2 24 e0 28     st  %g1, [ %l3 + 0x28 ]
> >   OK, so it really seems that:
> >   jinode->i_flags |= JI_COMMIT_RUNNING;
> >   spin_unlock(&journal->j_list_lock);
> > 
> >   has been compiled to
> >   ld [ %l3 + 0x28 ], %g1
> >   or  %g1, 1, %g1
> >   call  6ee734 <_spin_unlock>
> >   st  %g1, [ %l3 + 0x28 ]
> > 
> >   Which seems like a bug in the compiler or in the way implement compiler
> > barriers in spin_unlock() on UP sparc. Or is there some sparc magic by which
> > this is correct code? Any clever sparc guy?
> > 
> Looks fine to me - the store is made in the branch delay slot
> of the call, so it will occur before the first instruction at
> the call target address executes.
  Thanks for explanation. I knew sparc had some surprising features like
this ;).
								Honza
-- 
Jan Kara <jack@suse.cz>
SUSE Labs, CR

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-25 22:38                         ` Alexander Beregalov
  2009-03-26  0:00                           ` Jan Kara
@ 2009-03-31 10:01                           ` Jan Kara
  2009-03-31 10:07                             ` Alexander Beregalov
  1 sibling, 1 reply; 24+ messages in thread
From: Jan Kara @ 2009-03-31 10:01 UTC (permalink / raw)
  To: Alexander Beregalov
  Cc: Theodore Tso, linux-next, linux-ext4, LKML, sparclinux

On Thu 26-03-09 01:38:32, Alexander Beregalov wrote:
> 2009/3/25 Jan Kara <jack@suse.cz>:
> > On Wed 25-03-09 20:07:46, Alexander Beregalov wrote:
> >> 2009/3/25 Jan Kara <jack@suse.cz>:
> >> > On Wed 25-03-09 18:29:10, Alexander Beregalov wrote:
> >> >> 2009/3/25 Jan Kara <jack@suse.cz>:
> >> >> > On Wed 25-03-09 18:18:43, Alexander Beregalov wrote:
> >> >> >> 2009/3/25 Jan Kara <jack@suse.cz>:
> >> >> >> >> > So, I think I need to try it on 2.6.29-rc7 again.
> >> >> >> >>   I've looked into this. Obviously, what's happenning is that we delete
> >> >> >> >> an inode and jbd2_journal_release_jbd_inode() finds inode is just under
> >> >> >> >> writeout in transaction commit and thus it waits. But it gets never woken
> >> >> >> >> up and because it has a handle from the transaction, every one eventually
> >> >> >> >> blocks on waiting for a transaction to finish.
> >> >> >> >>   But I don't really see how that can happen. The code is really
> >> >> >> >> straightforward and everything happens under j_list_lock... Strange.
> >> >> >> >  BTW: Is the system SMP?
> >> >> >> No, it is UP system.
> >> >> >  Even stranger. And do you have CONFIG_PREEMPT set?
> >> >> >
> >> >> >> The bug exists even in 2.6.29, I posted it with a new topic.
> >> >> >  OK, I've sort-of expected this.
> >> >>
> >> >> CONFIG_PREEMPT_RCU=y
> >> >> CONFIG_PREEMPT_RCU_TRACE=y
> >> >> # CONFIG_PREEMPT_NONE is not set
> >> >> # CONFIG_PREEMPT_VOLUNTARY is not set
> >> >> CONFIG_PREEMPT=y
> >> >> CONFIG_DEBUG_PREEMPT=y
> >> >> # CONFIG_PREEMPT_TRACER is not set
> >> >>
> >> >> config is attached.
> >> >  Thanks for the data. I still don't see how the wakeup can get lost. The
> >> > process even cannot be preempted when we are in the section protected by
> >> > j_list_lock... Can you send me a disassembly of functions
> >> > jbd2_journal_release_jbd_inode() and journal_submit_data_buffers() so that
> >> > I can see whether the compiler has not reordered something unexpectedly?
> >  Thanks for the disassembly...
> >
> >> By default gcc inlines journal_submit_data_buffers()
> >> Here is -fno-inline version. Default version is in attach.
  <snip>

  I'm helpless here. I don't see how we can miss a wakeup (plus you seem to
be the only one reporting the bug). Could you please compile and test the kernel
with the attached patch? It will print to kernel log when we go to sleep
waiting for inode commit and when we send wakeups etc. When you hit the
deadlock, please send me your kernel log. It should help with debugging why do
we miss the wakeup. Thanks.

									Honza
-- 
Jan Kara <jack@suse.cz>
SUSE Labs, CR
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-31 10:01                           ` Jan Kara
@ 2009-03-31 10:07                             ` Alexander Beregalov
  2009-03-31 12:33                               ` Jan Kara
  0 siblings, 1 reply; 24+ messages in thread
From: Alexander Beregalov @ 2009-03-31 10:07 UTC (permalink / raw)
  To: Jan Kara; +Cc: Theodore Tso, linux-next, linux-ext4, LKML, sparclinux

2009/3/31 Jan Kara <jack@suse.cz>:
> On Thu 26-03-09 01:38:32, Alexander Beregalov wrote:
>> 2009/3/25 Jan Kara <jack@suse.cz>:
>> > On Wed 25-03-09 20:07:46, Alexander Beregalov wrote:
>> >> 2009/3/25 Jan Kara <jack@suse.cz>:
>> >> > On Wed 25-03-09 18:29:10, Alexander Beregalov wrote:
>> >> >> 2009/3/25 Jan Kara <jack@suse.cz>:
>> >> >> > On Wed 25-03-09 18:18:43, Alexander Beregalov wrote:
>> >> >> >> 2009/3/25 Jan Kara <jack@suse.cz>:
>> >> >> >> >> > So, I think I need to try it on 2.6.29-rc7 again.
>> >> >> >> >>   I've looked into this. Obviously, what's happenning is that we delete
>> >> >> >> >> an inode and jbd2_journal_release_jbd_inode() finds inode is just under
>> >> >> >> >> writeout in transaction commit and thus it waits. But it gets never woken
>> >> >> >> >> up and because it has a handle from the transaction, every one eventually
>> >> >> >> >> blocks on waiting for a transaction to finish.
>> >> >> >> >>   But I don't really see how that can happen. The code is really
>> >> >> >> >> straightforward and everything happens under j_list_lock... Strange.
>> >> >> >> >  BTW: Is the system SMP?
>> >> >> >> No, it is UP system.
>> >> >> >  Even stranger. And do you have CONFIG_PREEMPT set?
>> >> >> >
>> >> >> >> The bug exists even in 2.6.29, I posted it with a new topic.
>> >> >> >  OK, I've sort-of expected this.
>> >> >>
>> >> >> CONFIG_PREEMPT_RCU=y
>> >> >> CONFIG_PREEMPT_RCU_TRACE=y
>> >> >> # CONFIG_PREEMPT_NONE is not set
>> >> >> # CONFIG_PREEMPT_VOLUNTARY is not set
>> >> >> CONFIG_PREEMPT=y
>> >> >> CONFIG_DEBUG_PREEMPT=y
>> >> >> # CONFIG_PREEMPT_TRACER is not set
>> >> >>
>> >> >> config is attached.
>> >> >  Thanks for the data. I still don't see how the wakeup can get lost. The
>> >> > process even cannot be preempted when we are in the section protected by
>> >> > j_list_lock... Can you send me a disassembly of functions
>> >> > jbd2_journal_release_jbd_inode() and journal_submit_data_buffers() so that
>> >> > I can see whether the compiler has not reordered something unexpectedly?
>> >  Thanks for the disassembly...
>> >
>> >> By default gcc inlines journal_submit_data_buffers()
>> >> Here is -fno-inline version. Default version is in attach.
>  <snip>
>
>  I'm helpless here. I don't see how we can miss a wakeup (plus you seem to
> be the only one reporting the bug). Could you please compile and test the kernel
> with the attached patch? It will print to kernel log when we go to sleep
> waiting for inode commit and when we send wakeups etc. When you hit the
> deadlock, please send me your kernel log. It should help with debugging why do
> we miss the wakeup. Thanks.

Which patch?

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-31 10:07                             ` Alexander Beregalov
@ 2009-03-31 12:33                               ` Jan Kara
  2009-04-02 18:50                                 ` Alexander Beregalov
  0 siblings, 1 reply; 24+ messages in thread
From: Jan Kara @ 2009-03-31 12:33 UTC (permalink / raw)
  To: Alexander Beregalov
  Cc: Theodore Tso, linux-next, linux-ext4, LKML, sparclinux

[-- Attachment #1: Type: text/plain, Size: 2902 bytes --]

On Tue 31-03-09 14:07:30, Alexander Beregalov wrote:
> 2009/3/31 Jan Kara <jack@suse.cz>:
> > On Thu 26-03-09 01:38:32, Alexander Beregalov wrote:
> >> 2009/3/25 Jan Kara <jack@suse.cz>:
> >> > On Wed 25-03-09 20:07:46, Alexander Beregalov wrote:
> >> >> 2009/3/25 Jan Kara <jack@suse.cz>:
> >> >> > On Wed 25-03-09 18:29:10, Alexander Beregalov wrote:
> >> >> >> 2009/3/25 Jan Kara <jack@suse.cz>:
> >> >> >> > On Wed 25-03-09 18:18:43, Alexander Beregalov wrote:
> >> >> >> >> 2009/3/25 Jan Kara <jack@suse.cz>:
> >> >> >> >> >> > So, I think I need to try it on 2.6.29-rc7 again.
> >> >> >> >> >>   I've looked into this. Obviously, what's happenning is that we delete
> >> >> >> >> >> an inode and jbd2_journal_release_jbd_inode() finds inode is just under
> >> >> >> >> >> writeout in transaction commit and thus it waits. But it gets never woken
> >> >> >> >> >> up and because it has a handle from the transaction, every one eventually
> >> >> >> >> >> blocks on waiting for a transaction to finish.
> >> >> >> >> >>   But I don't really see how that can happen. The code is really
> >> >> >> >> >> straightforward and everything happens under j_list_lock... Strange.
> >> >> >> >> >  BTW: Is the system SMP?
> >> >> >> >> No, it is UP system.
> >> >> >> >  Even stranger. And do you have CONFIG_PREEMPT set?
> >> >> >> >
> >> >> >> >> The bug exists even in 2.6.29, I posted it with a new topic.
> >> >> >> >  OK, I've sort-of expected this.
> >> >> >>
> >> >> >> CONFIG_PREEMPT_RCU=y
> >> >> >> CONFIG_PREEMPT_RCU_TRACE=y
> >> >> >> # CONFIG_PREEMPT_NONE is not set
> >> >> >> # CONFIG_PREEMPT_VOLUNTARY is not set
> >> >> >> CONFIG_PREEMPT=y
> >> >> >> CONFIG_DEBUG_PREEMPT=y
> >> >> >> # CONFIG_PREEMPT_TRACER is not set
> >> >> >>
> >> >> >> config is attached.
> >> >> >  Thanks for the data. I still don't see how the wakeup can get lost. The
> >> >> > process even cannot be preempted when we are in the section protected by
> >> >> > j_list_lock... Can you send me a disassembly of functions
> >> >> > jbd2_journal_release_jbd_inode() and journal_submit_data_buffers() so that
> >> >> > I can see whether the compiler has not reordered something unexpectedly?
> >> >  Thanks for the disassembly...
> >> >
> >> >> By default gcc inlines journal_submit_data_buffers()
> >> >> Here is -fno-inline version. Default version is in attach.
> >  <snip>
> >
> >  I'm helpless here. I don't see how we can miss a wakeup (plus you seem to
> > be the only one reporting the bug). Could you please compile and test the kernel
> > with the attached patch? It will print to kernel log when we go to sleep
> > waiting for inode commit and when we send wakeups etc. When you hit the
> > deadlock, please send me your kernel log. It should help with debugging why do
> > we miss the wakeup. Thanks.
> 
> Which patch?
  Ups. Forgot to attach ;).

										Honza
-- 
Jan Kara <jack@suse.cz>
SUSE Labs, CR

[-- Attachment #2: 0001-ext4-Debug-sleepers-in-iput.patch --]
[-- Type: text/x-patch, Size: 1983 bytes --]

>From 123ab7510c04c698077e5756b4de6c66ce8ee71e Mon Sep 17 00:00:00 2001
From: Jan Kara <jack@suse.cz>
Date: Tue, 31 Mar 2009 11:57:10 +0200
Subject: [PATCH] ext4: Debug sleepers in iput()

Signed-off-by: Jan Kara <jack@suse.cz>
---
 fs/jbd2/commit.c  |    4 ++++
 fs/jbd2/journal.c |    6 ++++++
 2 files changed, 10 insertions(+), 0 deletions(-)

diff --git a/fs/jbd2/commit.c b/fs/jbd2/commit.c
index 62804e5..f47b8a3 100644
--- a/fs/jbd2/commit.c
+++ b/fs/jbd2/commit.c
@@ -259,6 +259,8 @@ static int journal_submit_data_buffers(journal_t *journal,
 		spin_lock(&journal->j_list_lock);
 		J_ASSERT(jinode->i_transaction == commit_transaction);
 		jinode->i_flags &= ~JI_COMMIT_RUNNING;
+		if (jinode->i_flags & 4)
+			printk(KERN_INFO "JBD2: Waking up sleeper on ino %lu\n", jinode->i_vfs_inode->i_ino);
 		wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
 	}
 	spin_unlock(&journal->j_list_lock);
@@ -296,6 +298,8 @@ static int journal_finish_inode_data_buffers(journal_t *journal,
 		}
 		spin_lock(&journal->j_list_lock);
 		jinode->i_flags &= ~JI_COMMIT_RUNNING;
+		if (jinode->i_flags & 4)
+			printk(KERN_INFO "JBD2: Waking up sleeper on ino %lu\n", jinode->i_vfs_inode->i_ino);
 		wake_up_bit(&jinode->i_flags, __JI_COMMIT_RUNNING);
 	}
 
diff --git a/fs/jbd2/journal.c b/fs/jbd2/journal.c
index 5814410..5459fd9 100644
--- a/fs/jbd2/journal.c
+++ b/fs/jbd2/journal.c
@@ -2225,11 +2225,17 @@ restart:
 	if (jinode->i_flags & JI_COMMIT_RUNNING) {
 		wait_queue_head_t *wq;
 		DEFINE_WAIT_BIT(wait, &jinode->i_flags, __JI_COMMIT_RUNNING);
+		unsigned long ino = jinode->i_vfs_inode->i_ino;
+
+		jinode->i_flags |= 4;
+		printk(KERN_INFO "JBD2: Waiting for ino %lu\n", ino);
+
 		wq = bit_waitqueue(&jinode->i_flags, __JI_COMMIT_RUNNING);
 		prepare_to_wait(wq, &wait.wait, TASK_UNINTERRUPTIBLE);
 		spin_unlock(&journal->j_list_lock);
 		schedule();
 		finish_wait(wq, &wait.wait);
+		printk(KERN_INFO "JBD2: Woken on ino %lu\n", ino);
 		goto restart;
 	}
 
-- 
1.6.0.2


^ permalink raw reply related	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-03-31 12:33                               ` Jan Kara
@ 2009-04-02 18:50                                 ` Alexander Beregalov
  2009-04-04 21:09                                   ` Alexander Beregalov
  0 siblings, 1 reply; 24+ messages in thread
From: Alexander Beregalov @ 2009-04-02 18:50 UTC (permalink / raw)
  To: Jan Kara; +Cc: Theodore Tso, linux-next, linux-ext4, LKML, sparclinux

>> >  I'm helpless here. I don't see how we can miss a wakeup (plus you seem to
>> > be the only one reporting the bug). Could you please compile and test the kernel
>> > with the attached patch? It will print to kernel log when we go to sleep
>> > waiting for inode commit and when we send wakeups etc. When you hit the
>> > deadlock, please send me your kernel log. It should help with debugging why do
>> > we miss the wakeup. Thanks.
>>
>> Which patch?
>  Ups. Forgot to attach ;).

Cannot reproduce it on current 2.6.29-git. Strange.
It should already have all ext4/jbd2 patches from next-20090310,
but anyway it happened with 2.6.29-rc8 also.
I ran dbench in cycle on two indentical hosts for more than 24 hours
with no hang tasks.

I will try 2.6.29.
--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-04-02 18:50                                 ` Alexander Beregalov
@ 2009-04-04 21:09                                   ` Alexander Beregalov
  2009-04-06  9:20                                     ` Jan Kara
  0 siblings, 1 reply; 24+ messages in thread
From: Alexander Beregalov @ 2009-04-04 21:09 UTC (permalink / raw)
  To: Jan Kara; +Cc: Theodore Tso, linux-next, linux-ext4, LKML, sparclinux

2009/4/2 Alexander Beregalov <a.beregalov@gmail.com>:
>>> >  I'm helpless here. I don't see how we can miss a wakeup (plus you seem to
>>> > be the only one reporting the bug). Could you please compile and test the kernel
>>> > with the attached patch? It will print to kernel log when we go to sleep
>>> > waiting for inode commit and when we send wakeups etc. When you hit the
>>> > deadlock, please send me your kernel log. It should help with debugging why do
>>> > we miss the wakeup. Thanks.
>>>
>>> Which patch?
>>  Ups. Forgot to attach ;).
>
> Cannot reproduce it on current 2.6.29-git. Strange.
> It should already have all ext4/jbd2 patches from next-20090310,
> but anyway it happened with 2.6.29-rc8 also.
> I ran dbench in cycle on two indentical hosts for more than 24 hours
> with no hang tasks.
>
> I will try 2.6.29.

I cannot reproduce it with vanilla v2.6.29.
It seems the problem has gone.
Thanks Jan.

The patch output:
[133886.375874] JBD2: Waiting for ino 1062
[133886.376372] JBD2: Waking up sleeper on ino 1062
[133886.376824] JBD2: Woken on ino 1062
[134611.108451] JBD2: Waiting for ino 1102
[134611.108903] JBD2: Waking up sleeper on ino 1102
[134611.109787] JBD2: Woken on ino 1102
[134611.132912] JBD2: Waiting for ino 1074
[134611.133311] JBD2: Waking up sleeper on ino 1074
[134611.133707] JBD2: Woken on ino 1074

^ permalink raw reply	[flat|nested] 24+ messages in thread

* Re: next-20090310: ext4 hangs
  2009-04-04 21:09                                   ` Alexander Beregalov
@ 2009-04-06  9:20                                     ` Jan Kara
  0 siblings, 0 replies; 24+ messages in thread
From: Jan Kara @ 2009-04-06  9:20 UTC (permalink / raw)
  To: Alexander Beregalov
  Cc: Theodore Tso, linux-next, linux-ext4, LKML, sparclinux

On Sun 05-04-09 01:09:31, Alexander Beregalov wrote:
> 2009/4/2 Alexander Beregalov <a.beregalov@gmail.com>:
> >>> >  I'm helpless here. I don't see how we can miss a wakeup (plus you seem to
> >>> > be the only one reporting the bug). Could you please compile and test the kernel
> >>> > with the attached patch? It will print to kernel log when we go to sleep
> >>> > waiting for inode commit and when we send wakeups etc. When you hit the
> >>> > deadlock, please send me your kernel log. It should help with debugging why do
> >>> > we miss the wakeup. Thanks.
> >>>
> >>> Which patch?
> >>  Ups. Forgot to attach ;).
> >
> > Cannot reproduce it on current 2.6.29-git. Strange.
> > It should already have all ext4/jbd2 patches from next-20090310,
> > but anyway it happened with 2.6.29-rc8 also.
> > I ran dbench in cycle on two indentical hosts for more than 24 hours
> > with no hang tasks.
> >
> > I will try 2.6.29.
> 
> I cannot reproduce it with vanilla v2.6.29.
> It seems the problem has gone.
> Thanks Jan.
  Thanks for testing. I'm glad we have one mystery less ;).
 
> The patch output:
> [133886.375874] JBD2: Waiting for ino 1062
> [133886.376372] JBD2: Waking up sleeper on ino 1062
> [133886.376824] JBD2: Woken on ino 1062
> [134611.108451] JBD2: Waiting for ino 1102
> [134611.108903] JBD2: Waking up sleeper on ino 1102
> [134611.109787] JBD2: Woken on ino 1102
> [134611.132912] JBD2: Waiting for ino 1074
> [134611.133311] JBD2: Waking up sleeper on ino 1074
> [134611.133707] JBD2: Woken on ino 1074
  Yes, this is how it should always look...

									Honza
-- 
Jan Kara <jack@suse.cz>
SUSE Labs, CR

^ permalink raw reply	[flat|nested] 24+ messages in thread

end of thread, other threads:[~2009-04-06  9:20 UTC | newest]

Thread overview: 24+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-03-10 12:17 next-20090310: ext4 hangs Alexander Beregalov
2009-03-10 12:46 ` Theodore Tso
2009-03-10 12:54   ` Alexander Beregalov
2009-03-10 14:18   ` Alexander Beregalov
2009-03-10 15:47     ` Theodore Tso
2009-03-11 16:07       ` Alexander Beregalov
2009-03-25 15:11         ` Jan Kara
2009-03-25 15:15           ` Jan Kara
2009-03-25 15:18             ` Alexander Beregalov
2009-03-25 15:22               ` Jan Kara
2009-03-25 15:29                 ` Alexander Beregalov
2009-03-25 16:15                   ` Jan Kara
2009-03-25 17:07                     ` Alexander Beregalov
2009-03-25 19:43                       ` Jan Kara
2009-03-25 22:38                         ` Alexander Beregalov
2009-03-26  0:00                           ` Jan Kara
2009-03-26  0:17                             ` Jiri Gaisler
2009-03-26  0:25                               ` Jan Kara
2009-03-31 10:01                           ` Jan Kara
2009-03-31 10:07                             ` Alexander Beregalov
2009-03-31 12:33                               ` Jan Kara
2009-04-02 18:50                                 ` Alexander Beregalov
2009-04-04 21:09                                   ` Alexander Beregalov
2009-04-06  9:20                                     ` Jan Kara

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).