From: Yishai Hadas <yishaih@nvidia.com>
To: Jason Gunthorpe <jgg@nvidia.com>
Cc: <alex.williamson@redhat.com>, <kvm@vger.kernel.org>,
<kevin.tian@intel.com>, <joao.m.martins@oracle.com>,
<leonro@nvidia.com>, <shayd@nvidia.com>, <maorg@nvidia.com>,
<avihaih@nvidia.com>, <cohuck@redhat.com>
Subject: Re: [PATCH V2 vfio 03/14] vfio/mlx5: Enforce a single SAVE command at a time
Date: Sun, 4 Dec 2022 14:07:20 +0200 [thread overview]
Message-ID: <af31d76a-d802-2fcf-176d-4bbac2b6eb19@nvidia.com> (raw)
In-Reply-To: <Y4lL9CdGcqLWh0F2@nvidia.com>
On 02/12/2022 2:51, Jason Gunthorpe wrote:
> On Thu, Dec 01, 2022 at 05:29:20PM +0200, Yishai Hadas wrote:
>
>> diff --git a/drivers/vfio/pci/mlx5/main.c b/drivers/vfio/pci/mlx5/main.c
>> index 6e9cf2aacc52..4081a0f7e057 100644
>> --- a/drivers/vfio/pci/mlx5/main.c
>> +++ b/drivers/vfio/pci/mlx5/main.c
>> @@ -245,6 +245,8 @@ mlx5vf_pci_save_device_data(struct mlx5vf_pci_core_device *mvdev)
>> stream_open(migf->filp->f_inode, migf->filp);
>> mutex_init(&migf->lock);
>> init_waitqueue_head(&migf->poll_wait);
>> + init_completion(&migf->save_comp);
>> + complete(&migf->save_comp);
> Add comment here
>
> save_comp is being used as a binary semaphore built from a
> completion. A normal mutex cannot be used because the lock is passed
> between kernel threads and lockdep can't model this.
>
> Jason
Sure, will add the comment as part of V3.
Yishai
next prev parent reply other threads:[~2022-12-04 12:07 UTC|newest]
Thread overview: 26+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-01 15:29 [PATCH V2 vfio 00/14] Add migration PRE_COPY support for mlx5 driver Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 01/14] net/mlx5: Introduce ifc bits for pre_copy Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 02/14] vfio: Extend the device migration protocol with PRE_COPY Yishai Hadas
2022-12-01 22:43 ` Alex Williamson
2022-12-04 7:38 ` Leon Romanovsky
2022-12-02 8:48 ` Tian, Kevin
2022-12-04 8:35 ` Yishai Hadas
2022-12-02 9:38 ` Shameerali Kolothum Thodi
2022-12-05 13:54 ` Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 03/14] vfio/mlx5: Enforce a single SAVE command at a time Yishai Hadas
2022-12-02 0:51 ` Jason Gunthorpe
2022-12-04 12:07 ` Yishai Hadas [this message]
2022-12-01 15:29 ` [PATCH V2 vfio 04/14] vfio/mlx5: Refactor PD usage Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 05/14] vfio/mlx5: Refactor MKEY usage Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 06/14] vfio/mlx5: Refactor migration file state Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 07/14] vfio/mlx5: Refactor to use queue based data chunks Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 08/14] vfio/mlx5: Introduce device transitions of PRE_COPY Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 09/14] vfio/mlx5: Introduce SW headers for migration states Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 10/14] vfio/mlx5: Introduce vfio precopy ioctl implementation Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 11/14] vfio/mlx5: Consider temporary end of stream as part of PRE_COPY Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 12/14] vfio/mlx5: Introduce multiple loads Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 13/14] vfio/mlx5: Fallback to STOP_COPY upon specific PRE_COPY error Yishai Hadas
2022-12-01 15:29 ` [PATCH V2 vfio 14/14] vfio/mlx5: Enable MIGRATION_PRE_COPY flag Yishai Hadas
2022-12-02 1:06 ` [PATCH V2 vfio 00/14] Add migration PRE_COPY support for mlx5 driver Jason Gunthorpe
2022-12-02 8:57 ` Tian, Kevin
2022-12-04 11:54 ` Yishai Hadas
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=af31d76a-d802-2fcf-176d-4bbac2b6eb19@nvidia.com \
--to=yishaih@nvidia.com \
--cc=alex.williamson@redhat.com \
--cc=avihaih@nvidia.com \
--cc=cohuck@redhat.com \
--cc=jgg@nvidia.com \
--cc=joao.m.martins@oracle.com \
--cc=kevin.tian@intel.com \
--cc=kvm@vger.kernel.org \
--cc=leonro@nvidia.com \
--cc=maorg@nvidia.com \
--cc=shayd@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