public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Brett Creeley <bcreeley@amd.com>
To: Alex Williamson <alex.williamson@redhat.com>,
	Brett Creeley <brett.creeley@amd.com>
Cc: jgg@ziepe.ca, yishaih@nvidia.com,
	shameerali.kolothum.thodi@huawei.com, kevin.tian@intel.com,
	dan.carpenter@linaro.org, kvm@vger.kernel.org,
	linux-kernel@vger.kernel.org, shannon.nelson@amd.com
Subject: Re: [PATCH v2 vfio 0/3] pds/vfio: Fixes for locking bugs
Date: Mon, 16 Oct 2023 07:49:53 -0700	[thread overview]
Message-ID: <2cd89c2c-96fc-8395-2c44-5804fe5c6594@amd.com> (raw)
In-Reply-To: <20231013150940.50804350.alex.williamson@redhat.com>

On 10/13/2023 2:09 PM, Alex Williamson wrote:
> Caution: This message originated from an External Source. Use proper caution when opening attachments, clicking links, or responding.
> 
> 
> On Wed, 11 Oct 2023 16:01:12 -0700
> Brett Creeley <brett.creeley@amd.com> wrote:
> 
>> This series contains fixes for locking bugs in the recently introduced
>> pds-vfio-pci driver. There was an initial bug reported by Dan Carpenter
>> at:
>>
>> https://lore.kernel.org/kvm/1f9bc27b-3de9-4891-9687-ba2820c1b390@moroto.mountain/
>>
>> However, more locking bugs were found when looking into the previously
>> mentioned issue. So, all fixes are included in this series.
>>
>> v2:
>> https://lore.kernel.org/kvm/20230914191540.54946-1-brett.creeley@amd.com/
>> - Trim the OOPs in the patch commit messages
>> - Rework patch 3/3 to only unlock the spinlock once
> 
> I thought we determined the spinlock, and thus the atomic context, was
> an arbitrary choice.  I would have figured we simply convert it to a
> mutex.  Why didn't we take that route?  Thanks,
> 
> Alex

Hmm. I guess it wasn't completely clear that was the expected solution 
even after Jason's response. However, I can resubmit a v3 with that change.

Thanks,

Brett
> 
>> - Destroy the state_mutex in the driver specific vfio_device_ops.release
>>    callback
>>
>> Brett Creeley (3):
>>    pds/vfio: Fix spinlock bad magic BUG
>>    pds/vfio: Fix mutex lock->magic != lock warning
>>    pds/vfio: Fix possible sleep while in atomic context
>>
>>   drivers/vfio/pci/pds/vfio_dev.c | 27 ++++++++++++++++++++-------
>>   1 file changed, 20 insertions(+), 7 deletions(-)
>>
> 

      reply	other threads:[~2023-10-16 14:50 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-11 23:01 [PATCH v2 vfio 0/3] pds/vfio: Fixes for locking bugs Brett Creeley
2023-10-11 23:01 ` [PATCH v2 vfio 1/3] pds/vfio: Fix spinlock bad magic BUG Brett Creeley
2023-10-12  8:44   ` Shameerali Kolothum Thodi
2023-10-11 23:01 ` [PATCH v2 vfio 2/3] pds/vfio: Fix mutex lock->magic != lock warning Brett Creeley
2023-10-12  9:00   ` Shameerali Kolothum Thodi
2023-10-12 13:50     ` Jason Gunthorpe
2023-10-11 23:01 ` [PATCH v2 vfio 3/3] pds/vfio: Fix possible sleep while in atomic context Brett Creeley
2023-10-13 21:09 ` [PATCH v2 vfio 0/3] pds/vfio: Fixes for locking bugs Alex Williamson
2023-10-16 14:49   ` Brett Creeley [this message]

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=2cd89c2c-96fc-8395-2c44-5804fe5c6594@amd.com \
    --to=bcreeley@amd.com \
    --cc=alex.williamson@redhat.com \
    --cc=brett.creeley@amd.com \
    --cc=dan.carpenter@linaro.org \
    --cc=jgg@ziepe.ca \
    --cc=kevin.tian@intel.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=shameerali.kolothum.thodi@huawei.com \
    --cc=shannon.nelson@amd.com \
    --cc=yishaih@nvidia.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