Linux IOMMU Development
 help / color / mirror / Atom feed
From: Gregor Dick <gdick-s/n/eUQHGBpZroRs9YW3xA@public.gmane.org>
To: Joerg Roedel <joro-zLv9SwRftAIdnm+yROfE0A@public.gmane.org>
Cc: iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org,
	Kieran Mansley <kmansley-s/n/eUQHGBpZroRs9YW3xA@public.gmane.org>
Subject: Re: PROBLEM: Deadlock in attach_device() in AMD IOMMU driver
Date: Tue, 5 May 2015 15:47:48 +0100	[thread overview]
Message-ID: <5548D814.6020807@solarflare.com> (raw)
In-Reply-To: <20150505144159.GI15736-zLv9SwRftAIdnm+yROfE0A@public.gmane.org>

Hi Joerg,

On 05/05/15 15:41, Joerg Roedel wrote:
> Do you see a real deadlock or only the lockdep warning? In the code it
> looks like virtfn_add() takes the sriov->lock of the physical device
> while pci_enable_ats() (when called from there) takes the sriov->lock of
> the virtual function. In this case it couldn't deadlock.

The thread does deadlock. It looks like pci_enable_ats() takes
dev->physfn->sriov->lock, where dev is the VF. I'd understood this to be
a lock protecting SR-IOV state for all VFs configured on the PF (but I'm
not familiar with the code at all!).

Thanks,
Gregor
The information contained in this message is confidential and is intended for the addressee(s) only. If you have received this message in error, please notify the sender immediately and delete the message. Unless you are an addressee (or authorized to receive for an addressee), you may not use, copy or disclose to anyone this message or any information contained in this message. The unauthorized use, disclosure, copying or alteration of this message is strictly prohibited.

  parent reply	other threads:[~2015-05-05 14:47 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-05  9:24 PROBLEM: Deadlock in attach_device() in AMD IOMMU driver Gregor Dick
     [not found] ` <55488C3D.50509-s/n/eUQHGBpZroRs9YW3xA@public.gmane.org>
2015-05-05 14:41   ` Joerg Roedel
     [not found]     ` <20150505144159.GI15736-zLv9SwRftAIdnm+yROfE0A@public.gmane.org>
2015-05-05 14:47       ` Gregor Dick [this message]
     [not found]         ` <5548D814.6020807-s/n/eUQHGBpZroRs9YW3xA@public.gmane.org>
2015-05-05 15:33           ` Joerg Roedel
     [not found]             ` <20150505153344.GR15736-zLv9SwRftAIdnm+yROfE0A@public.gmane.org>
2015-05-06 11:44               ` Gregor Dick
     [not found]                 ` <5549FEA1.9080801-s/n/eUQHGBpZroRs9YW3xA@public.gmane.org>
2015-05-11 10:15                   ` Joerg Roedel

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=5548D814.6020807@solarflare.com \
    --to=gdick-s/n/euqhgbpzrors9yw3xa@public.gmane.org \
    --cc=iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org \
    --cc=joro-zLv9SwRftAIdnm+yROfE0A@public.gmane.org \
    --cc=kmansley-s/n/eUQHGBpZroRs9YW3xA@public.gmane.org \
    /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