2019-02-11 15:24:12

by Souptick Joarder

[permalink] [raw]
Subject: [PATCH] staging: android: vsoc: Remove VSOC_WAIT_FOR_INCOMING_INTERRUPT

As mentioned in TODO list, Removed VSOC_WAIT_FOR_INCOMING_INTERRUPT
ioctl. This functionality has been superseded by the futex and is
there for legacy reasons.

Signed-off-by: Souptick Joarder <[email protected]>
---
drivers/staging/android/uapi/vsoc_shm.h | 7 -------
drivers/staging/android/vsoc.c | 5 -----
2 files changed, 12 deletions(-)

diff --git a/drivers/staging/android/uapi/vsoc_shm.h b/drivers/staging/android/uapi/vsoc_shm.h
index 6291fb2..69090cc 100644
--- a/drivers/staging/android/uapi/vsoc_shm.h
+++ b/drivers/staging/android/uapi/vsoc_shm.h
@@ -232,13 +232,6 @@ struct vsoc_shm_layout_descriptor {
#define VSOC_MAYBE_SEND_INTERRUPT_TO_HOST _IO(0xF5, 2)

/*
- * When this returns the guest will scan host_to_guest_signal_table to
- * check for new futexes to wake.
- */
-/* TODO(ghartman): Consider moving this to the bottom half */
-#define VSOC_WAIT_FOR_INCOMING_INTERRUPT _IO(0xF5, 3)
-
-/*
* Guest HALs will use this to retrieve the region description after
* opening their device node.
*/
diff --git a/drivers/staging/android/vsoc.c b/drivers/staging/android/vsoc.c
index 22571ab..a842ff7 100644
--- a/drivers/staging/android/vsoc.c
+++ b/drivers/staging/android/vsoc.c
@@ -592,11 +592,6 @@ static long vsoc_ioctl(struct file *filp, unsigned int cmd, unsigned long arg)
case VSOC_SEND_INTERRUPT_TO_HOST:
writel(reg_num, vsoc_dev.regs + DOORBELL);
return 0;
- case VSOC_WAIT_FOR_INCOMING_INTERRUPT:
- wait_event_interruptible
- (reg_data->interrupt_wait_queue,
- (atomic_read(reg_data->incoming_signalled) != 0));
- break;

case VSOC_DESCRIBE_REGION:
return do_vsoc_describe_region
--
1.9.1



2019-02-11 15:42:01

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH] staging: android: vsoc: Remove VSOC_WAIT_FOR_INCOMING_INTERRUPT

On Mon, Feb 11, 2019 at 08:56:02PM +0530, Souptick Joarder wrote:
> As mentioned in TODO list, Removed VSOC_WAIT_FOR_INCOMING_INTERRUPT
> ioctl. This functionality has been superseded by the futex and is
> there for legacy reasons.
>
> Signed-off-by: Souptick Joarder <[email protected]>
> ---
> drivers/staging/android/uapi/vsoc_shm.h | 7 -------
> drivers/staging/android/vsoc.c | 5 -----
> 2 files changed, 12 deletions(-)

So userspace is all fixed up now and this ioctl can be dropped? Any
pointers to the userspace commit that did this?

thanks,

greg k-h

2019-02-11 15:48:23

by Souptick Joarder

[permalink] [raw]
Subject: Re: [PATCH] staging: android: vsoc: Remove VSOC_WAIT_FOR_INCOMING_INTERRUPT

On Mon, Feb 11, 2019 at 9:10 PM Greg KH <[email protected]> wrote:
>
> On Mon, Feb 11, 2019 at 08:56:02PM +0530, Souptick Joarder wrote:
> > As mentioned in TODO list, Removed VSOC_WAIT_FOR_INCOMING_INTERRUPT
> > ioctl. This functionality has been superseded by the futex and is
> > there for legacy reasons.
> >
> > Signed-off-by: Souptick Joarder <[email protected]>
> > ---
> > drivers/staging/android/uapi/vsoc_shm.h | 7 -------
> > drivers/staging/android/vsoc.c | 5 -----
> > 2 files changed, 12 deletions(-)
>
> So userspace is all fixed up now and this ioctl can be dropped? Any
> pointers to the userspace commit that did this?

I am not sure about user space part.

2019-02-11 15:58:47

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH] staging: android: vsoc: Remove VSOC_WAIT_FOR_INCOMING_INTERRUPT

On Mon, Feb 11, 2019 at 09:21:19PM +0530, Souptick Joarder wrote:
> On Mon, Feb 11, 2019 at 9:10 PM Greg KH <[email protected]> wrote:
> >
> > On Mon, Feb 11, 2019 at 08:56:02PM +0530, Souptick Joarder wrote:
> > > As mentioned in TODO list, Removed VSOC_WAIT_FOR_INCOMING_INTERRUPT
> > > ioctl. This functionality has been superseded by the futex and is
> > > there for legacy reasons.
> > >
> > > Signed-off-by: Souptick Joarder <[email protected]>
> > > ---
> > > drivers/staging/android/uapi/vsoc_shm.h | 7 -------
> > > drivers/staging/android/vsoc.c | 5 -----
> > > 2 files changed, 12 deletions(-)
> >
> > So userspace is all fixed up now and this ioctl can be dropped? Any
> > pointers to the userspace commit that did this?
>
> I am not sure about user space part.

Then we can not just delete the ioctl :)


2019-02-11 16:41:54

by Souptick Joarder

[permalink] [raw]
Subject: Re: [PATCH] staging: android: vsoc: Remove VSOC_WAIT_FOR_INCOMING_INTERRUPT

On Mon, Feb 11, 2019 at 9:27 PM Greg KH <[email protected]> wrote:
>
> On Mon, Feb 11, 2019 at 09:21:19PM +0530, Souptick Joarder wrote:
> > On Mon, Feb 11, 2019 at 9:10 PM Greg KH <[email protected]> wrote:
> > >
> > > On Mon, Feb 11, 2019 at 08:56:02PM +0530, Souptick Joarder wrote:
> > > > As mentioned in TODO list, Removed VSOC_WAIT_FOR_INCOMING_INTERRUPT
> > > > ioctl. This functionality has been superseded by the futex and is
> > > > there for legacy reasons.
> > > >
> > > > Signed-off-by: Souptick Joarder <[email protected]>
> > > > ---
> > > > drivers/staging/android/uapi/vsoc_shm.h | 7 -------
> > > > drivers/staging/android/vsoc.c | 5 -----
> > > > 2 files changed, 12 deletions(-)
> > >
> > > So userspace is all fixed up now and this ioctl can be dropped? Any
> > > pointers to the userspace commit that did this?
> >
> > I am not sure about user space part.
>
> Then we can not just delete the ioctl :)

Agree, but where to verify the user space commit ?
Any pointer to the source code path ?

2019-02-11 20:31:39

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH] staging: android: vsoc: Remove VSOC_WAIT_FOR_INCOMING_INTERRUPT

On Mon, Feb 11, 2019 at 10:15:18PM +0530, Souptick Joarder wrote:
> On Mon, Feb 11, 2019 at 9:27 PM Greg KH <[email protected]> wrote:
> >
> > On Mon, Feb 11, 2019 at 09:21:19PM +0530, Souptick Joarder wrote:
> > > On Mon, Feb 11, 2019 at 9:10 PM Greg KH <[email protected]> wrote:
> > > >
> > > > On Mon, Feb 11, 2019 at 08:56:02PM +0530, Souptick Joarder wrote:
> > > > > As mentioned in TODO list, Removed VSOC_WAIT_FOR_INCOMING_INTERRUPT
> > > > > ioctl. This functionality has been superseded by the futex and is
> > > > > there for legacy reasons.
> > > > >
> > > > > Signed-off-by: Souptick Joarder <[email protected]>
> > > > > ---
> > > > > drivers/staging/android/uapi/vsoc_shm.h | 7 -------
> > > > > drivers/staging/android/vsoc.c | 5 -----
> > > > > 2 files changed, 12 deletions(-)
> > > >
> > > > So userspace is all fixed up now and this ioctl can be dropped? Any
> > > > pointers to the userspace commit that did this?
> > >
> > > I am not sure about user space part.
> >
> > Then we can not just delete the ioctl :)
>
> Agree, but where to verify the user space commit ?
> Any pointer to the source code path ?

Please work with the android developers to solve this. It should be in
AOSP "somewhere" :(

good luck,

greg k-h

2019-02-11 20:31:54

by Todd Kjos

[permalink] [raw]
Subject: Re: [PATCH] staging: android: vsoc: Remove VSOC_WAIT_FOR_INCOMING_INTERRUPT

+Alistair Strachan

On Mon, Feb 11, 2019 at 9:11 AM Greg KH <[email protected]> wrote:
>
> On Mon, Feb 11, 2019 at 10:15:18PM +0530, Souptick Joarder wrote:
> > On Mon, Feb 11, 2019 at 9:27 PM Greg KH <[email protected]> wrote:
> > >
> > > On Mon, Feb 11, 2019 at 09:21:19PM +0530, Souptick Joarder wrote:
> > > > On Mon, Feb 11, 2019 at 9:10 PM Greg KH <[email protected]> wrote:
> > > > >
> > > > > On Mon, Feb 11, 2019 at 08:56:02PM +0530, Souptick Joarder wrote:
> > > > > > As mentioned in TODO list, Removed VSOC_WAIT_FOR_INCOMING_INTERRUPT
> > > > > > ioctl. This functionality has been superseded by the futex and is
> > > > > > there for legacy reasons.
> > > > > >
> > > > > > Signed-off-by: Souptick Joarder <[email protected]>
> > > > > > ---
> > > > > > drivers/staging/android/uapi/vsoc_shm.h | 7 -------
> > > > > > drivers/staging/android/vsoc.c | 5 -----
> > > > > > 2 files changed, 12 deletions(-)
> > > > >
> > > > > So userspace is all fixed up now and this ioctl can be dropped? Any
> > > > > pointers to the userspace commit that did this?
> > > >
> > > > I am not sure about user space part.
> > >
> > > Then we can not just delete the ioctl :)
> >
> > Agree, but where to verify the user space commit ?
> > Any pointer to the source code path ?
>
> Please work with the android developers to solve this. It should be in
> AOSP "somewhere" :(
>
> good luck,
>
> greg k-h

2019-02-11 20:39:41

by Alistair Strachan

[permalink] [raw]
Subject: Re: [PATCH] staging: android: vsoc: Remove VSOC_WAIT_FOR_INCOMING_INTERRUPT

On Mon, Feb 11, 2019 at 9:22 AM Todd Kjos <[email protected]> wrote:
>
> +Alistair Strachan
>
> On Mon, Feb 11, 2019 at 9:11 AM Greg KH <[email protected]> wrote:
> >
> > On Mon, Feb 11, 2019 at 10:15:18PM +0530, Souptick Joarder wrote:
> > > On Mon, Feb 11, 2019 at 9:27 PM Greg KH <[email protected]> wrote:
> > > >
> > > > On Mon, Feb 11, 2019 at 09:21:19PM +0530, Souptick Joarder wrote:
> > > > > On Mon, Feb 11, 2019 at 9:10 PM Greg KH <[email protected]> wrote:
> > > > > >
> > > > > > On Mon, Feb 11, 2019 at 08:56:02PM +0530, Souptick Joarder wrote:
> > > > > > > As mentioned in TODO list, Removed VSOC_WAIT_FOR_INCOMING_INTERRUPT
> > > > > > > ioctl. This functionality has been superseded by the futex and is
> > > > > > > there for legacy reasons.
> > > > > > >
> > > > > > > Signed-off-by: Souptick Joarder <[email protected]>
> > > > > > > ---
> > > > > > > drivers/staging/android/uapi/vsoc_shm.h | 7 -------
> > > > > > > drivers/staging/android/vsoc.c | 5 -----
> > > > > > > 2 files changed, 12 deletions(-)
> > > > > >
> > > > > > So userspace is all fixed up now and this ioctl can be dropped? Any
> > > > > > pointers to the userspace commit that did this?

The ioctl is still being used and cannot be removed.

> > > > >
> > > > > I am not sure about user space part.
> > > >
> > > > Then we can not just delete the ioctl :)
> > >
> > > Agree, but where to verify the user space commit ?
> > > Any pointer to the source code path ?

The userspace code using the Linux 'vsoc' staging driver can be cloned
from here:

https://android.googlesource.com/device/google/cuttlefish_common

> >
> > Please work with the android developers to solve this. It should be in
> > AOSP "somewhere" :(

I'm working on documenting this better on source.android.com. Stay tuned.

> >
> > good luck,
> >
> > greg k-h

2019-02-12 13:13:25

by Souptick Joarder

[permalink] [raw]
Subject: Re: [PATCH] staging: android: vsoc: Remove VSOC_WAIT_FOR_INCOMING_INTERRUPT

On Tue, Feb 12, 2019 at 12:28 AM Alistair Strachan <[email protected]> wrote:
>
> On Mon, Feb 11, 2019 at 9:22 AM Todd Kjos <[email protected]> wrote:
> >
> > +Alistair Strachan
> >
> > On Mon, Feb 11, 2019 at 9:11 AM Greg KH <[email protected]> wrote:
> > >
> > > On Mon, Feb 11, 2019 at 10:15:18PM +0530, Souptick Joarder wrote:
> > > > On Mon, Feb 11, 2019 at 9:27 PM Greg KH <[email protected]> wrote:
> > > > >
> > > > > On Mon, Feb 11, 2019 at 09:21:19PM +0530, Souptick Joarder wrote:
> > > > > > On Mon, Feb 11, 2019 at 9:10 PM Greg KH <[email protected]> wrote:
> > > > > > >
> > > > > > > On Mon, Feb 11, 2019 at 08:56:02PM +0530, Souptick Joarder wrote:
> > > > > > > > As mentioned in TODO list, Removed VSOC_WAIT_FOR_INCOMING_INTERRUPT
> > > > > > > > ioctl. This functionality has been superseded by the futex and is
> > > > > > > > there for legacy reasons.
> > > > > > > >
> > > > > > > > Signed-off-by: Souptick Joarder <[email protected]>
> > > > > > > > ---
> > > > > > > > drivers/staging/android/uapi/vsoc_shm.h | 7 -------
> > > > > > > > drivers/staging/android/vsoc.c | 5 -----
> > > > > > > > 2 files changed, 12 deletions(-)
> > > > > > >
> > > > > > > So userspace is all fixed up now and this ioctl can be dropped? Any
> > > > > > > pointers to the userspace commit that did this?
>
> The ioctl is still being used and cannot be removed.

I think, it's good to add this info in TODO file. I can edit it if you are ok.

>
> > > > > >
> > > > > > I am not sure about user space part.
> > > > >
> > > > > Then we can not just delete the ioctl :)
> > > >
> > > > Agree, but where to verify the user space commit ?
> > > > Any pointer to the source code path ?
>
> The userspace code using the Linux 'vsoc' staging driver can be cloned
> from here:
>
> https://android.googlesource.com/device/google/cuttlefish_common

Thanks.
>
> > >
> > > Please work with the android developers to solve this. It should be in
> > > AOSP "somewhere" :(
>
> I'm working on documenting this better on source.android.com. Stay tuned.
>
> > >
> > > good luck,
> > >
> > > greg k-h