Hello.
I'm running my LSM module on kernel 2.6.23 / Debian Sarge.
I encountered the following warning message.
It seems that calling down_read(&namespace_sem) is not permitted
inside mutex_lock(&inode->i_mutex) , but I'm not sure.
Is it illegal to refer namespace_sem while inode's mutex held?
=======================================================
[ INFO: possible circular locking dependency detected ]
2.6.23-tomoyo2.1 #27
-------------------------------------------------------
rcS/1093 is trying to acquire lock:
(&namespace_sem){----}, at: [<c017ca7b>] m_start+0x11/0x20
but task is already holding lock:
(&inode->i_mutex){--..}, at: [<c0171e79>] open_namei+0xf2/0x522
which lock already depends on the new lock.
the existing dependency chain (in reverse order) is:
-> #1 (&inode->i_mutex){--..}:
[<c017d35b>] graft_tree+0x62/0xca
[<c013ab37>] check_prev_add+0xc4/0x1bc
[<c017d35b>] graft_tree+0x62/0xca
[<c013ac85>] check_prevs_add+0x56/0xcb
[<c013af9c>] validate_chain+0x2a2/0x31f
[<c01312ec>] __kernel_text_address+0x18/0x23
[<c0104b1b>] dump_trace+0x6f/0x87
[<c013cc54>] __lock_acquire+0x6f2/0x762
[<c013af6f>] validate_chain+0x275/0x31f
[<c013d25e>] lock_acquire+0x79/0x93
[<c017d35b>] graft_tree+0x62/0xca
[<c0331518>] __mutex_lock_slowpath+0xea/0x280
[<c017d35b>] graft_tree+0x62/0xca
[<c017d35b>] graft_tree+0x62/0xca
[<c017d8f1>] do_add_mount+0x8a/0xe7
[<c017de52>] do_mount+0x1a9/0x1c0
[<c0152d76>] __alloc_pages+0x64/0x2b6
[<c017dc5f>] copy_mount_options+0x4d/0x97
[<c017e0b5>] sys_mount+0x79/0xb5
[<c01012f4>] name_to_dev_t+0x4d/0x25d
[<c0331258>] schedule_timeout+0x79/0x8d
[<c019b741>] create_proc_entry+0x73/0x86
[<c012a023&g...