kvm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v3] vhost_vdpa: fix the problem in vhost_vdpa_set_config_call
@ 2021-01-26  7:16 Cindy Lu
  2021-01-26  8:28 ` Jason Wang
  0 siblings, 1 reply; 7+ messages in thread
From: Cindy Lu @ 2021-01-26  7:16 UTC (permalink / raw)
  To: lulu, jasowang, mst, kvm, linux-kernel, virtualization, netdev; +Cc: stable

In vhost_vdpa_set_config_call, the cb.private should be vhost_vdpa.
this cb.private will finally use in vhost_vdpa_config_cb as
vhost_vdpa. Fix this issue.

Cc: stable@vger.kernel.org
Fixes: 776f395004d82 ("vhost_vdpa: Support config interrupt in vdpa")
Signed-off-by: Cindy Lu <lulu@redhat.com>
---
 drivers/vhost/vdpa.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/vhost/vdpa.c b/drivers/vhost/vdpa.c
index ef688c8c0e0e..3fbb9c1f49da 100644
--- a/drivers/vhost/vdpa.c
+++ b/drivers/vhost/vdpa.c
@@ -319,7 +319,7 @@ static long vhost_vdpa_set_config_call(struct vhost_vdpa *v, u32 __user *argp)
 	struct eventfd_ctx *ctx;
 
 	cb.callback = vhost_vdpa_config_cb;
-	cb.private = v->vdpa;
+	cb.private = v;
 	if (copy_from_user(&fd, argp, sizeof(fd)))
 		return  -EFAULT;
 
-- 
2.21.3


^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Re: [PATCH v3] vhost_vdpa: fix the problem in vhost_vdpa_set_config_call
  2021-01-26  7:16 [PATCH v3] vhost_vdpa: fix the problem in vhost_vdpa_set_config_call Cindy Lu
@ 2021-01-26  8:28 ` Jason Wang
  0 siblings, 0 replies; 7+ messages in thread
From: Jason Wang @ 2021-01-26  8:28 UTC (permalink / raw)
  To: Cindy Lu, mst, kvm, linux-kernel, virtualization, netdev; +Cc: stable


On 2021/1/26 下午3:16, Cindy Lu wrote:
> In vhost_vdpa_set_config_call, the cb.private should be vhost_vdpa.
> this cb.private will finally use in vhost_vdpa_config_cb as
> vhost_vdpa. Fix this issue.
>
> Cc: stable@vger.kernel.org
> Fixes: 776f395004d82 ("vhost_vdpa: Support config interrupt in vdpa")
> Signed-off-by: Cindy Lu <lulu@redhat.com>


Acked-by: Jason Wang <jasowang@redhat.com>


> ---
>   drivers/vhost/vdpa.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/vhost/vdpa.c b/drivers/vhost/vdpa.c
> index ef688c8c0e0e..3fbb9c1f49da 100644
> --- a/drivers/vhost/vdpa.c
> +++ b/drivers/vhost/vdpa.c
> @@ -319,7 +319,7 @@ static long vhost_vdpa_set_config_call(struct vhost_vdpa *v, u32 __user *argp)
>   	struct eventfd_ctx *ctx;
>   
>   	cb.callback = vhost_vdpa_config_cb;
> -	cb.private = v->vdpa;
> +	cb.private = v;
>   	if (copy_from_user(&fd, argp, sizeof(fd)))
>   		return  -EFAULT;
>   


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v3] vhost_vdpa: fix the problem in vhost_vdpa_set_config_call
  2021-01-12  7:49 ` Greg KH
@ 2021-01-13  4:13   ` Cindy Lu
  0 siblings, 0 replies; 7+ messages in thread
From: Cindy Lu @ 2021-01-13  4:13 UTC (permalink / raw)
  To: Greg KH
  Cc: Jason Wang, Michael Tsirkin, kvm, linux-kernel, virtualization,
	netdev, Zhu, Lingshan, stable

On Tue, Jan 12, 2021 at 3:53 PM Greg KH <gregkh@linuxfoundation.org> wrote:
>
> On Tue, Jan 12, 2021 at 01:36:29PM +0800, Cindy Lu wrote:
> > In vhost_vdpa_set_config_call, the cb.private should be vhost_vdpa.
> > this cb.private will finally use in vhost_vdpa_config_cb as
> > vhost_vdpa. Fix this issue.
> >
> > Fixes: 776f395004d82 ("vhost_vdpa: Support config interrupt in vdpa")
> > Acked-by: Jason Wang <jasowang@redhat.com>
> > Signed-off-by: Cindy Lu <lulu@redhat.com>
> > ---
> >  drivers/vhost/vdpa.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
>
> <formletter>
>
> This is not the correct way to submit patches for inclusion in the
> stable kernel tree.  Please read:
>     https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
> for how to do this properly.
>
> </formletter>
>
Thanks Greg, I will fix this and send a new version


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v3] vhost_vdpa: fix the problem in vhost_vdpa_set_config_call
  2021-01-13  3:38 ` Jason Wang
@ 2021-01-13  4:12   ` Cindy Lu
  0 siblings, 0 replies; 7+ messages in thread
From: Cindy Lu @ 2021-01-13  4:12 UTC (permalink / raw)
  To: Jason Wang
  Cc: Michael Tsirkin, kvm, linux-kernel, virtualization, netdev, Zhu,
	Lingshan, stable

On Wed, Jan 13, 2021 at 11:38 AM Jason Wang <jasowang@redhat.com> wrote:
>
>
> On 2021/1/12 下午1:36, Cindy Lu wrote:
> > In vhost_vdpa_set_config_call, the cb.private should be vhost_vdpa.
> > this cb.private will finally use in vhost_vdpa_config_cb as
> > vhost_vdpa. Fix this issue.
> >
> > Fixes: 776f395004d82 ("vhost_vdpa: Support config interrupt in vdpa")
> > Acked-by: Jason Wang <jasowang@redhat.com>
> > Signed-off-by: Cindy Lu <lulu@redhat.com>
> > ---
>
>
> Hi Cindy:
>
> I think at least you forget to cc stable.
>
> Thanks
>
Sure Thanks Jason I will post a new version
>
> >   drivers/vhost/vdpa.c | 2 +-
> >   1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/vhost/vdpa.c b/drivers/vhost/vdpa.c
> > index ef688c8c0e0e..3fbb9c1f49da 100644
> > --- a/drivers/vhost/vdpa.c
> > +++ b/drivers/vhost/vdpa.c
> > @@ -319,7 +319,7 @@ static long vhost_vdpa_set_config_call(struct vhost_vdpa *v, u32 __user *argp)
> >       struct eventfd_ctx *ctx;
> >
> >       cb.callback = vhost_vdpa_config_cb;
> > -     cb.private = v->vdpa;
> > +     cb.private = v;
> >       if (copy_from_user(&fd, argp, sizeof(fd)))
> >               return  -EFAULT;
> >
>


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v3] vhost_vdpa: fix the problem in vhost_vdpa_set_config_call
  2021-01-12  5:36 Cindy Lu
  2021-01-12  7:49 ` Greg KH
@ 2021-01-13  3:38 ` Jason Wang
  2021-01-13  4:12   ` Cindy Lu
  1 sibling, 1 reply; 7+ messages in thread
From: Jason Wang @ 2021-01-13  3:38 UTC (permalink / raw)
  To: Cindy Lu, mst, kvm, linux-kernel, virtualization, netdev, lingshan.zhu
  Cc: stable


On 2021/1/12 下午1:36, Cindy Lu wrote:
> In vhost_vdpa_set_config_call, the cb.private should be vhost_vdpa.
> this cb.private will finally use in vhost_vdpa_config_cb as
> vhost_vdpa. Fix this issue.
>
> Fixes: 776f395004d82 ("vhost_vdpa: Support config interrupt in vdpa")
> Acked-by: Jason Wang <jasowang@redhat.com>
> Signed-off-by: Cindy Lu <lulu@redhat.com>
> ---


Hi Cindy:

I think at least you forget to cc stable.

Thanks


>   drivers/vhost/vdpa.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/vhost/vdpa.c b/drivers/vhost/vdpa.c
> index ef688c8c0e0e..3fbb9c1f49da 100644
> --- a/drivers/vhost/vdpa.c
> +++ b/drivers/vhost/vdpa.c
> @@ -319,7 +319,7 @@ static long vhost_vdpa_set_config_call(struct vhost_vdpa *v, u32 __user *argp)
>   	struct eventfd_ctx *ctx;
>   
>   	cb.callback = vhost_vdpa_config_cb;
> -	cb.private = v->vdpa;
> +	cb.private = v;
>   	if (copy_from_user(&fd, argp, sizeof(fd)))
>   		return  -EFAULT;
>   


^ permalink raw reply	[flat|nested] 7+ messages in thread

* Re: [PATCH v3] vhost_vdpa: fix the problem in vhost_vdpa_set_config_call
  2021-01-12  5:36 Cindy Lu
@ 2021-01-12  7:49 ` Greg KH
  2021-01-13  4:13   ` Cindy Lu
  2021-01-13  3:38 ` Jason Wang
  1 sibling, 1 reply; 7+ messages in thread
From: Greg KH @ 2021-01-12  7:49 UTC (permalink / raw)
  To: Cindy Lu
  Cc: jasowang, mst, kvm, linux-kernel, virtualization, netdev,
	lingshan.zhu, stable

On Tue, Jan 12, 2021 at 01:36:29PM +0800, Cindy Lu wrote:
> In vhost_vdpa_set_config_call, the cb.private should be vhost_vdpa.
> this cb.private will finally use in vhost_vdpa_config_cb as
> vhost_vdpa. Fix this issue.
> 
> Fixes: 776f395004d82 ("vhost_vdpa: Support config interrupt in vdpa")
> Acked-by: Jason Wang <jasowang@redhat.com>
> Signed-off-by: Cindy Lu <lulu@redhat.com>
> ---
>  drivers/vhost/vdpa.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

<formletter>

This is not the correct way to submit patches for inclusion in the
stable kernel tree.  Please read:
    https://www.kernel.org/doc/html/latest/process/stable-kernel-rules.html
for how to do this properly.

</formletter>

^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH v3] vhost_vdpa: fix the problem in vhost_vdpa_set_config_call
@ 2021-01-12  5:36 Cindy Lu
  2021-01-12  7:49 ` Greg KH
  2021-01-13  3:38 ` Jason Wang
  0 siblings, 2 replies; 7+ messages in thread
From: Cindy Lu @ 2021-01-12  5:36 UTC (permalink / raw)
  To: lulu, jasowang, mst, kvm, linux-kernel, virtualization, netdev,
	lingshan.zhu
  Cc: stable

In vhost_vdpa_set_config_call, the cb.private should be vhost_vdpa.
this cb.private will finally use in vhost_vdpa_config_cb as
vhost_vdpa. Fix this issue.

Fixes: 776f395004d82 ("vhost_vdpa: Support config interrupt in vdpa")
Acked-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Cindy Lu <lulu@redhat.com>
---
 drivers/vhost/vdpa.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/vhost/vdpa.c b/drivers/vhost/vdpa.c
index ef688c8c0e0e..3fbb9c1f49da 100644
--- a/drivers/vhost/vdpa.c
+++ b/drivers/vhost/vdpa.c
@@ -319,7 +319,7 @@ static long vhost_vdpa_set_config_call(struct vhost_vdpa *v, u32 __user *argp)
 	struct eventfd_ctx *ctx;
 
 	cb.callback = vhost_vdpa_config_cb;
-	cb.private = v->vdpa;
+	cb.private = v;
 	if (copy_from_user(&fd, argp, sizeof(fd)))
 		return  -EFAULT;
 
-- 
2.21.3


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2021-01-26 19:02 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-26  7:16 [PATCH v3] vhost_vdpa: fix the problem in vhost_vdpa_set_config_call Cindy Lu
2021-01-26  8:28 ` Jason Wang
  -- strict thread matches above, loose matches on Subject: below --
2021-01-12  5:36 Cindy Lu
2021-01-12  7:49 ` Greg KH
2021-01-13  4:13   ` Cindy Lu
2021-01-13  3:38 ` Jason Wang
2021-01-13  4:12   ` Cindy Lu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).