public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Tao Ma <tao.ma@oracle.com>
To: Mike Christie <michaelc@cs.wisc.edu>
Cc: open-iscsi@googlegroups.com, linux-kernel@vger.kernel.org
Subject: Re: lockdep warning for iscsi in 2.6.33-rc6
Date: Wed, 10 Feb 2010 08:42:04 +0800	[thread overview]
Message-ID: <4B7200DC.60103@oracle.com> (raw)
In-Reply-To: <4B71B7D9.9040501@cs.wisc.edu>

Hi Mike,

Mike Christie wrote:
> On 02/09/2010 12:59 AM, Tao Ma wrote:
>> Hi Mike,
>> I meet with a lockdep warning for iscsi in 2.6.33-rc6.
>> the lockdep is attached.
>>
> 
> If the lockdep output is saying that there is a problem with the iscsi 
> host taking its mutex then the scsi host mutex, I think that might be a 
> mistake in the lockdep detection. We always take the iscsi host mutex 
> then take the scsi host mutex.
> 
> Could it get confused if we are scanning two hosts at the same time? If 
> it is just looking at if a lock is being taken then it would look like 
> host1 has its ihost->mutex and then took its shost->mutex, but then 
> host2 could start to get scanned at the same time, and it is going to 
> take its ihost->mutex. It would then look like we are trying to grab a 
> ihost->mutex while holding a shost->mutex. However, the mutexs are not 
> global and they are different instances of the mutex because each host 
> has its own.
If these 2 mutexes are grabed in the same order(in your description, 
ihost->mutex first and then shost->mutex), there would be no problem.
> 
> If that is not the problem, maybe it has something to do with some sysfs 
> lock and ata doing scanning while iscsi is.
yeah it looks so from the lockdep output.

You know the real bad thing is that after lockdep find an error, it will 
set debug_locks to 0, so any future check will be disabled. As iscsi 
start up very early, no other check can be proceeded.

Regards,
Tao

  reply	other threads:[~2010-02-10  0:42 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-09  6:59 lockdep warning for iscsi in 2.6.33-rc6 Tao Ma
2010-02-09 19:30 ` Mike Christie
2010-02-10  0:42   ` Tao Ma [this message]
2010-02-12 17:21     ` Mike Christie
2010-02-11 20:08 ` Maciej Rutecki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4B7200DC.60103@oracle.com \
    --to=tao.ma@oracle.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=michaelc@cs.wisc.edu \
    --cc=open-iscsi@googlegroups.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox