Re: [PATCH 00/12] VMCI for Linux upstreaming

2013-01-08 Thread Greg KH
On Tue, Jan 08, 2013 at 03:52:33PM -0800, George Zhang wrote:
> * * *
> This series of VMCI linux upstreaming patches include latest udpate from
> VMware to address Greg's and all other's code review comments.

Nice work, thanks for the changes you've made over time, and for your
persistence.  I can't see anything else to complain about, so I've
applied this to my tree and it will show up in linux-next tomorrow or
so.

thanks,

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



[PATCH 00/12] VMCI for Linux upstreaming

2013-01-08 Thread George Zhang
* * *
This series of VMCI linux upstreaming patches include latest udpate from
VMware to address Greg's and all other's code review comments.

Summary of changes:
- Rebase our linux kernel tree from v3.5 to v3.7.
- Fix all checkpatch warnings and errors. Fix some checkpatch with 
-strict
  errors.

  This addresses Greg's comment: On 15 Nov 2012 15:47:14 -0800
  Re: [PATCH 07/12] VMCI: queue pairs implementation.
  chckpatch sanity checking.
- Fix vmci_get_contextid naming error.
- Fix host side queue pair creation bug.
- Fix resource hash table lookup issue.
- Remove __devinit and __devexit device driver annotations.
- Remove ASSERT/BUG_ON for vmci and vsock source codes.

  This addresses Greg's comment on On 15 Nov 2012 15:47:14 -0800
  Re: [PATCH 02/12] VMCI: datagram implementation.
  Remove all BUG_ON(), asserts.
- use standard Linux kernel ioctl interface.

  This addresses Greg's comment on On Thu, 15 Nov 2012 16:01:18 
-0800
  Re: [PATCH 12/12] VMCI: Some header and config files.
  use linux in-kernel IO macros for VMCI.
- Add vmci ioctl code entry in ioctl-number.txt.
- Remove printk from header file. Align properly for macro 
PCI_VENDOR_ID_VMWARE.
  Remove #define for VMCI_DRIVER_VERSION_STRING.
  Remove #define for MODULE_NAME.
  Remove #define for pr_fmt and #define ASSERT(x).
  Remove inline function VMCI_MAKE_HANDLE and vmci_make_handle which 
return a
  structure on stack. use macro instead and use C99 initialization.
  Remove #define for VMCI_HANDLE_TO_CONTEXT_ID and 
VMCI_HANDLE_TO_RESOURCE_ID
  Change macro to inline function for VMCI_HANDLE_EQUAL.
  Remove u32 typedefs for vmci_id, vmci_event, vmci_privilege_flags.
  Use C99 style initialization for struct VMCI_INVALID_HANDLE.
  Use inline function instead of macro for VMCI_HANDLE_INVALID.
  No change for vmw_vmci_api.h location (under include/linux/ 
directory).
  No change for macros VMCI_CONTEXT_IS_VM, VMCI_HOST_CONTEXT_ID,
  VMCI_RESERVED_CID_LIMIT, VMCI_HYPERVISOR_CONTEXT_ID and
  VMCI_WELL_KNOWN_CONTEXT_ID. Still in header file 
include/linux/vmw_vmci_defs.h

  This addresses Greg's several comments on Thu, 15 Nov 2012 
16:01:18 -0800
  Re: [PATCH 12/12] VMCI: Some header and config files.

* * *

In an effort to improve the out-of-the-box experience with Linux
kernels for VMware users, VMware is working on readying the Virtual
Machine Communication Interface (vmw_vmci) and VMCI Sockets
(vmw_vsock) kernel modules for inclusion in the Linux kernel. The
purpose of this post is to acquire feedback on the vmw_vmci kernel
module. The vmw_vsock kernel module will be presented in a later post.


* * *

VMCI allows virtual machines to communicate with host kernel modules
and the VMware hypervisors. User level applications both in a virtual
machine and on the host can use vmw_vmci through VMCI Sockets, a socket
address family designed to be compatible with UDP and TCP at the
interface level. Today, VMCI and VMCI Sockets are used by the VMware
shared folders (HGFS) and various VMware Tools components inside the
guest for zero-config, network-less access to VMware host services. In
addition to this, VMware's users are using VMCI Sockets for various
applications, where network access of the virtual machine is
restricted or non-existent. Examples of this are VMs communicating
with device proxies for proprietary hardware running as host
applications and automated testing of applications running within
virtual machines.

In a virtual machine, VMCI is exposed as a regular PCI device. The
primary communication mechanisms supported are a point-to-point
bidirectional transport based on a pair of memory-mapped queues, and
asynchronous notifications in the form of datagrams and
doorbells. These features are available to kernel level components
such as HGFS and VMCI Sockets through the VMCI kernel API. In addition
to this, the VMCI kernel API provides support for receiving events
related to the state of the VMCI communication channels, and the
virtual machine itself.

Outside the virtual machine, the host side support of the VMCI kernel
module makes the same VMCI kernel API available to VMCI endpoints on
the host. In addition to this, the host side manages each VMCI device
in a virtual machine through a context object. This context object
serves to identify the virtual machine for communication, and to track
the resource consumption of the given VMCI device. Both operations
related to communication between the virtual machine and the host
kernel, and those related to the management of the VMCI device state
in the host kernel, are invoked by the user level component of the
hypervisor through a set of ioctls on the V

Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-11-26 Thread Dmitry Torokhov
On Mon, Nov 26, 2012 at 07:27:07PM -0500, Woody Suwalski wrote:
> Greg KH wrote:
> >On Mon, Nov 26, 2012 at 03:52:31PM -0800, Dmitry Torokhov wrote:
> >>
> >>Mind resending it, please?
> >Now resent.
> I see both versions of Greg's message - one from 15 Nov, one
> today's. On my Gmail account...
> So Greg did post it...
> 

Right, I also see it now in my personal LKML archive but for some
reason it didn't get delivered to my corporate mailbox. Weird.

Thanks,
Dmitry
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-11-26 Thread Woody Suwalski

Greg KH wrote:

On Mon, Nov 26, 2012 at 03:52:31PM -0800, Dmitry Torokhov wrote:

On Monday, November 26, 2012 03:44:26 PM Greg KH wrote:

On Mon, Nov 26, 2012 at 03:36:52PM -0800, Dmitry Torokhov wrote:

On Monday, November 26, 2012 03:23:57 PM Greg KH wrote:

On Mon, Nov 26, 2012 at 03:01:04PM -0800, Dmitry Torokhov wrote:

On Monday, November 26, 2012 02:37:54 PM Greg KH wrote:

On Wed, Nov 21, 2012 at 12:31:04PM -0800, George Zhang wrote:

* * *
This series of VMCI linux upstreaming patches include latest
udpate
from
VMware.

Summary of changes:
- Sparse clean.
- Checkpatch clean with one exception, a "complex macro" in

  which we can't add parentheses.

- Remove all runtime assertions.
- Fix device name, so that existing user clients work.
- Fix VMCI handle lookup.

Given that you failed to answer the questions I asked the last time
you
posted this series, and you did not make any of the changes I asked
for,
I can't accept this (nor should you expect me to.)

And people wonder why reviewers get so grumpy...

My trees are now closed for the 3.8 merge window, so feel free to
try
again after 3.8-rc1 is out, and you have answered, and addressed,
the
questions and comments I made.

Greg, there were 3 specific complaints from you:

1. "Given that this is a static function, there's no need for these
"asserts", right?  Please send a follow-on patch removing all BUG_ON()
calls from these files, it's not acceptable to crash a user's box from
a driver that is handling parameters you are feeding it."

2. "You obviously didn't run checkpatch on this file"

3. "This line causes sparse to complain.  The odds that userspace
knows
what gcc is using for "bool" is pretty low."

Given the fact that the series addresses all 3 I fail to understand
why
you would be grumpy.

You are ignoring my response to patch 12/12 for some reason (which
repeated a bunch of the questions I had with that patch the last time it
was posted.)  That is what I am referring to here.  None of those
questions were addressed.

That one was explicitly acknowledged in
<20121030052234.gh32...@dtor-ws.eng.vmware.com> and fixed in series
posted on 11/01. Since it was fixed in earlier posting we did not
mention it again.

I questioned it on November 15, in:
Message-ID: <20121116000118.ga8...@kroah.com>

Just ignoring that long response is acceptable?  Really?  I didn't ask
enough questions in that review?  I see obvious comments in there that
were _not_ addressed in the November 21st posting of that patch
(typedefs for u32?  No c99 initializers?)

Hmm, neither I nor Google is aware of that msgid... So that would explain
why we have not addressed the comments that were in it ;)

Mind resending it, please?

Now resent.
I see both versions of Greg's message - one from 15 Nov, one today's. On 
my Gmail account...

So Greg did post it...

Cheers, Woody

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-11-26 Thread Greg KH
On Mon, Nov 26, 2012 at 03:52:31PM -0800, Dmitry Torokhov wrote:
> On Monday, November 26, 2012 03:44:26 PM Greg KH wrote:
> > On Mon, Nov 26, 2012 at 03:36:52PM -0800, Dmitry Torokhov wrote:
> > > On Monday, November 26, 2012 03:23:57 PM Greg KH wrote:
> > > > On Mon, Nov 26, 2012 at 03:01:04PM -0800, Dmitry Torokhov wrote:
> > > > > On Monday, November 26, 2012 02:37:54 PM Greg KH wrote:
> > > > > > On Wed, Nov 21, 2012 at 12:31:04PM -0800, George Zhang wrote:
> > > > > > > * * *
> > > > > > > This series of VMCI linux upstreaming patches include latest
> > > > > > > udpate
> > > > > > > from
> > > > > > > VMware.
> > > > > > > 
> > > > > > > Summary of changes:
> > > > > > >   - Sparse clean.
> > > > > > >   - Checkpatch clean with one exception, a "complex macro" in
> > > > > > >   
> > > > > > > which we can't add parentheses.
> > > > > > >   
> > > > > > >   - Remove all runtime assertions.
> > > > > > >   - Fix device name, so that existing user clients work.
> > > > > > >   - Fix VMCI handle lookup.
> > > > > > 
> > > > > > Given that you failed to answer the questions I asked the last time
> > > > > > you
> > > > > > posted this series, and you did not make any of the changes I asked
> > > > > > for,
> > > > > > I can't accept this (nor should you expect me to.)
> > > > > > 
> > > > > > And people wonder why reviewers get so grumpy...
> > > > > > 
> > > > > > My trees are now closed for the 3.8 merge window, so feel free to
> > > > > > try
> > > > > > again after 3.8-rc1 is out, and you have answered, and addressed,
> > > > > > the
> > > > > > questions and comments I made.
> > > > > 
> > > > > Greg, there were 3 specific complaints from you:
> > > > > 
> > > > > 1. "Given that this is a static function, there's no need for these
> > > > > "asserts", right?  Please send a follow-on patch removing all BUG_ON()
> > > > > calls from these files, it's not acceptable to crash a user's box from
> > > > > a driver that is handling parameters you are feeding it."
> > > > > 
> > > > > 2. "You obviously didn't run checkpatch on this file"
> > > > > 
> > > > > 3. "This line causes sparse to complain.  The odds that userspace
> > > > > knows
> > > > > what gcc is using for "bool" is pretty low."
> > > > > 
> > > > > Given the fact that the series addresses all 3 I fail to understand
> > > > > why
> > > > > you would be grumpy.
> > > > 
> > > > You are ignoring my response to patch 12/12 for some reason (which
> > > > repeated a bunch of the questions I had with that patch the last time it
> > > > was posted.)  That is what I am referring to here.  None of those
> > > > questions were addressed.
> > > 
> > > That one was explicitly acknowledged in
> > > <20121030052234.gh32...@dtor-ws.eng.vmware.com> and fixed in series
> > > posted on 11/01. Since it was fixed in earlier posting we did not
> > > mention it again.
> > 
> > I questioned it on November 15, in:
> > Message-ID: <20121116000118.ga8...@kroah.com>
> > 
> > Just ignoring that long response is acceptable?  Really?  I didn't ask
> > enough questions in that review?  I see obvious comments in there that
> > were _not_ addressed in the November 21st posting of that patch
> > (typedefs for u32?  No c99 initializers?)
> 
> Hmm, neither I nor Google is aware of that msgid... So that would explain
> why we have not addressed the comments that were in it ;)
> 
> Mind resending it, please? 

Now resent.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-11-26 Thread George Zhang

Greg

> 
> And why isn't George responding to my comments when I ask questions?
> 
I think Andy or Dmitry replied faster...
We will improve our process from your comments,
Thanks a lot,
George
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-11-26 Thread Dmitry Torokhov
On Monday, November 26, 2012 03:44:26 PM Greg KH wrote:
> On Mon, Nov 26, 2012 at 03:36:52PM -0800, Dmitry Torokhov wrote:
> > On Monday, November 26, 2012 03:23:57 PM Greg KH wrote:
> > > On Mon, Nov 26, 2012 at 03:01:04PM -0800, Dmitry Torokhov wrote:
> > > > On Monday, November 26, 2012 02:37:54 PM Greg KH wrote:
> > > > > On Wed, Nov 21, 2012 at 12:31:04PM -0800, George Zhang wrote:
> > > > > > * * *
> > > > > > This series of VMCI linux upstreaming patches include latest
> > > > > > udpate
> > > > > > from
> > > > > > VMware.
> > > > > > 
> > > > > > Summary of changes:
> > > > > > - Sparse clean.
> > > > > > - Checkpatch clean with one exception, a "complex macro" in
> > > > > > 
> > > > > >   which we can't add parentheses.
> > > > > > 
> > > > > > - Remove all runtime assertions.
> > > > > > - Fix device name, so that existing user clients work.
> > > > > > - Fix VMCI handle lookup.
> > > > > 
> > > > > Given that you failed to answer the questions I asked the last time
> > > > > you
> > > > > posted this series, and you did not make any of the changes I asked
> > > > > for,
> > > > > I can't accept this (nor should you expect me to.)
> > > > > 
> > > > > And people wonder why reviewers get so grumpy...
> > > > > 
> > > > > My trees are now closed for the 3.8 merge window, so feel free to
> > > > > try
> > > > > again after 3.8-rc1 is out, and you have answered, and addressed,
> > > > > the
> > > > > questions and comments I made.
> > > > 
> > > > Greg, there were 3 specific complaints from you:
> > > > 
> > > > 1. "Given that this is a static function, there's no need for these
> > > > "asserts", right?  Please send a follow-on patch removing all BUG_ON()
> > > > calls from these files, it's not acceptable to crash a user's box from
> > > > a driver that is handling parameters you are feeding it."
> > > > 
> > > > 2. "You obviously didn't run checkpatch on this file"
> > > > 
> > > > 3. "This line causes sparse to complain.  The odds that userspace
> > > > knows
> > > > what gcc is using for "bool" is pretty low."
> > > > 
> > > > Given the fact that the series addresses all 3 I fail to understand
> > > > why
> > > > you would be grumpy.
> > > 
> > > You are ignoring my response to patch 12/12 for some reason (which
> > > repeated a bunch of the questions I had with that patch the last time it
> > > was posted.)  That is what I am referring to here.  None of those
> > > questions were addressed.
> > 
> > That one was explicitly acknowledged in
> > <20121030052234.gh32...@dtor-ws.eng.vmware.com> and fixed in series
> > posted on 11/01. Since it was fixed in earlier posting we did not
> > mention it again.
> 
> I questioned it on November 15, in:
>   Message-ID: <20121116000118.ga8...@kroah.com>
> 
> Just ignoring that long response is acceptable?  Really?  I didn't ask
> enough questions in that review?  I see obvious comments in there that
> were _not_ addressed in the November 21st posting of that patch
> (typedefs for u32?  No c99 initializers?)

Hmm, neither I nor Google is aware of that msgid... So that would explain
why we have not addressed the comments that were in it ;)

Mind resending it, please? 

> 
> And why isn't George responding to my comments when I ask questions?
> 
> Also, please start numbering the submissions, this having to reference
> them by date is going to cause us all to get even more confused quicker.

OK, will do.

Thanks,
Dmitry

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-11-26 Thread Greg KH
On Mon, Nov 26, 2012 at 03:36:52PM -0800, Dmitry Torokhov wrote:
> On Monday, November 26, 2012 03:23:57 PM Greg KH wrote:
> > On Mon, Nov 26, 2012 at 03:01:04PM -0800, Dmitry Torokhov wrote:
> > > On Monday, November 26, 2012 02:37:54 PM Greg KH wrote:
> > > > On Wed, Nov 21, 2012 at 12:31:04PM -0800, George Zhang wrote:
> > > > > * * *
> > > > > This series of VMCI linux upstreaming patches include latest udpate
> > > > > from
> > > > > VMware.
> > > > > 
> > > > > Summary of changes:
> > > > >   - Sparse clean.
> > > > >   - Checkpatch clean with one exception, a "complex macro" in
> > > > >   
> > > > > which we can't add parentheses.
> > > > >   
> > > > >   - Remove all runtime assertions.
> > > > >   - Fix device name, so that existing user clients work.
> > > > >   - Fix VMCI handle lookup.
> > > > 
> > > > Given that you failed to answer the questions I asked the last time you
> > > > posted this series, and you did not make any of the changes I asked for,
> > > > I can't accept this (nor should you expect me to.)
> > > > 
> > > > And people wonder why reviewers get so grumpy...
> > > > 
> > > > My trees are now closed for the 3.8 merge window, so feel free to try
> > > > again after 3.8-rc1 is out, and you have answered, and addressed, the
> > > > questions and comments I made.
> > > 
> > > Greg, there were 3 specific complaints from you:
> > > 
> > > 1. "Given that this is a static function, there's no need for these
> > > "asserts", right?  Please send a follow-on patch removing all BUG_ON()
> > > calls from these files, it's not acceptable to crash a user's box from
> > > a driver that is handling parameters you are feeding it."
> > > 
> > > 2. "You obviously didn't run checkpatch on this file"
> > > 
> > > 3. "This line causes sparse to complain.  The odds that userspace knows
> > > what gcc is using for "bool" is pretty low."
> > > 
> > > Given the fact that the series addresses all 3 I fail to understand why
> > > you would be grumpy.
> > 
> > You are ignoring my response to patch 12/12 for some reason (which
> > repeated a bunch of the questions I had with that patch the last time it
> > was posted.)  That is what I am referring to here.  None of those
> > questions were addressed.
> 
> That one was explicitly acknowledged in
> <20121030052234.gh32...@dtor-ws.eng.vmware.com> and fixed in series
> posted on 11/01. Since it was fixed in earlier posting we did not
> mention it again.

I questioned it on November 15, in:
Message-ID: <20121116000118.ga8...@kroah.com>

Just ignoring that long response is acceptable?  Really?  I didn't ask
enough questions in that review?  I see obvious comments in there that
were _not_ addressed in the November 21st posting of that patch
(typedefs for u32?  No c99 initializers?)

And why isn't George responding to my comments when I ask questions?

Also, please start numbering the submissions, this having to reference
them by date is going to cause us all to get even more confused quicker.

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-11-26 Thread Dmitry Torokhov
On Monday, November 26, 2012 03:23:57 PM Greg KH wrote:
> On Mon, Nov 26, 2012 at 03:01:04PM -0800, Dmitry Torokhov wrote:
> > On Monday, November 26, 2012 02:37:54 PM Greg KH wrote:
> > > On Wed, Nov 21, 2012 at 12:31:04PM -0800, George Zhang wrote:
> > > > * * *
> > > > This series of VMCI linux upstreaming patches include latest udpate
> > > > from
> > > > VMware.
> > > > 
> > > > Summary of changes:
> > > > - Sparse clean.
> > > > - Checkpatch clean with one exception, a "complex macro" in
> > > > 
> > > >   which we can't add parentheses.
> > > > 
> > > > - Remove all runtime assertions.
> > > > - Fix device name, so that existing user clients work.
> > > > - Fix VMCI handle lookup.
> > > 
> > > Given that you failed to answer the questions I asked the last time you
> > > posted this series, and you did not make any of the changes I asked for,
> > > I can't accept this (nor should you expect me to.)
> > > 
> > > And people wonder why reviewers get so grumpy...
> > > 
> > > My trees are now closed for the 3.8 merge window, so feel free to try
> > > again after 3.8-rc1 is out, and you have answered, and addressed, the
> > > questions and comments I made.
> > 
> > Greg, there were 3 specific complaints from you:
> > 
> > 1. "Given that this is a static function, there's no need for these
> > "asserts", right?  Please send a follow-on patch removing all BUG_ON()
> > calls from these files, it's not acceptable to crash a user's box from
> > a driver that is handling parameters you are feeding it."
> > 
> > 2. "You obviously didn't run checkpatch on this file"
> > 
> > 3. "This line causes sparse to complain.  The odds that userspace knows
> > what gcc is using for "bool" is pretty low."
> > 
> > Given the fact that the series addresses all 3 I fail to understand why
> > you would be grumpy.
> 
> You are ignoring my response to patch 12/12 for some reason (which
> repeated a bunch of the questions I had with that patch the last time it
> was posted.)  That is what I am referring to here.  None of those
> questions were addressed.

That one was explicitly acknowledged in
<20121030052234.gh32...@dtor-ws.eng.vmware.com> and fixed in series
posted on 11/01. Since it was fixed in earlier posting we did not
mention it again.

> 
> Also, how was I to know that those 3 comments above were addressed?
> When someone posts questions and comments, please respond to those
> comments.  Don't just not respond at all and post the whole series 2
> weeks later with things changed and a vague comment of "summary of
> changes" in the 00 message.  Otherwise I will assume that you never even
> saw my post.

I thought "Sparse clean" and "Checkpatch clean with one exception ..."
are concrete enough, but I am open to improving the messaging. What 
would you like us to say?

> 
> In other words, if someone takes the time to review and post comments,
> the least you can do is acknowledge those comments, right?

We did not want to litter mailing lists with "OK" responses, but will
do in the future.

Thanks,
Dmitry
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-11-26 Thread Greg KH
On Mon, Nov 26, 2012 at 03:01:04PM -0800, Dmitry Torokhov wrote:
> On Monday, November 26, 2012 02:37:54 PM Greg KH wrote:
> > On Wed, Nov 21, 2012 at 12:31:04PM -0800, George Zhang wrote:
> > > * * *
> > > This series of VMCI linux upstreaming patches include latest udpate from
> > > VMware.
> > > 
> > > Summary of changes:
> > >   - Sparse clean.
> > >   - Checkpatch clean with one exception, a "complex macro" in
> > >   
> > > which we can't add parentheses.
> > >   
> > >   - Remove all runtime assertions.
> > >   - Fix device name, so that existing user clients work.
> > >   - Fix VMCI handle lookup.
> > 
> > Given that you failed to answer the questions I asked the last time you
> > posted this series, and you did not make any of the changes I asked for,
> > I can't accept this (nor should you expect me to.)
> > 
> > And people wonder why reviewers get so grumpy...
> > 
> > My trees are now closed for the 3.8 merge window, so feel free to try
> > again after 3.8-rc1 is out, and you have answered, and addressed, the
> > questions and comments I made.
> 
> Greg, there were 3 specific complaints from you:
> 
> 1. "Given that this is a static function, there's no need for these
> "asserts", right?  Please send a follow-on patch removing all BUG_ON()
> calls from these files, it's not acceptable to crash a user's box from
> a driver that is handling parameters you are feeding it."
> 
> 2. "You obviously didn't run checkpatch on this file"
> 
> 3. "This line causes sparse to complain.  The odds that userspace knows
> what gcc is using for "bool" is pretty low."
> 
> Given the fact that the series addresses all 3 I fail to understand why
> you would be grumpy.

You are ignoring my response to patch 12/12 for some reason (which
repeated a bunch of the questions I had with that patch the last time it
was posted.)  That is what I am referring to here.  None of those
questions were addressed.

Also, how was I to know that those 3 comments above were addressed?
When someone posts questions and comments, please respond to those
comments.  Don't just not respond at all and post the whole series 2
weeks later with things changed and a vague comment of "summary of
changes" in the 00 message.  Otherwise I will assume that you never even
saw my post.

In other words, if someone takes the time to review and post comments,
the least you can do is acknowledge those comments, right?

thanks,

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-11-26 Thread Dmitry Torokhov
On Monday, November 26, 2012 02:37:54 PM Greg KH wrote:
> On Wed, Nov 21, 2012 at 12:31:04PM -0800, George Zhang wrote:
> > * * *
> > This series of VMCI linux upstreaming patches include latest udpate from
> > VMware.
> > 
> > Summary of changes:
> > - Sparse clean.
> > - Checkpatch clean with one exception, a "complex macro" in
> > 
> >   which we can't add parentheses.
> > 
> > - Remove all runtime assertions.
> > - Fix device name, so that existing user clients work.
> > - Fix VMCI handle lookup.
> 
> Given that you failed to answer the questions I asked the last time you
> posted this series, and you did not make any of the changes I asked for,
> I can't accept this (nor should you expect me to.)
> 
> And people wonder why reviewers get so grumpy...
> 
> My trees are now closed for the 3.8 merge window, so feel free to try
> again after 3.8-rc1 is out, and you have answered, and addressed, the
> questions and comments I made.

Greg, there were 3 specific complaints from you:

1. "Given that this is a static function, there's no need for these
"asserts", right?  Please send a follow-on patch removing all BUG_ON()
calls from these files, it's not acceptable to crash a user's box from
a driver that is handling parameters you are feeding it."

2. "You obviously didn't run checkpatch on this file"

3. "This line causes sparse to complain.  The odds that userspace knows
what gcc is using for "bool" is pretty low."

Given the fact that the series addresses all 3 I fail to understand why
you would be grumpy.

Anyway, since there vsock has not been reviewed yet we are OK with
postponing this patch series till 3.9.

Thanks,
Dmitry

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 00/12] VMCI for Linux upstreaming

2012-11-26 Thread Greg KH
On Wed, Nov 21, 2012 at 12:31:04PM -0800, George Zhang wrote:
> 
> * * *
> This series of VMCI linux upstreaming patches include latest udpate from
> VMware.
> 
> Summary of changes:
> 
>   - Sparse clean.
>   - Checkpatch clean with one exception, a "complex macro" in
> which we can't add parentheses.
>   - Remove all runtime assertions.
>   - Fix device name, so that existing user clients work.
>   - Fix VMCI handle lookup.

Given that you failed to answer the questions I asked the last time you
posted this series, and you did not make any of the changes I asked for,
I can't accept this (nor should you expect me to.)

And people wonder why reviewers get so grumpy...

My trees are now closed for the 3.8 merge window, so feel free to try
again after 3.8-rc1 is out, and you have answered, and addressed, the
questions and comments I made.

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 00/12] VMCI for Linux upstreaming

2012-11-21 Thread George Zhang

* * *
This series of VMCI linux upstreaming patches include latest udpate from
VMware.

Summary of changes:

- Sparse clean.
- Checkpatch clean with one exception, a "complex macro" in
  which we can't add parentheses.
- Remove all runtime assertions.
- Fix device name, so that existing user clients work.
- Fix VMCI handle lookup.


* * *

In an effort to improve the out-of-the-box experience with Linux
kernels for VMware users, VMware is working on readying the Virtual
Machine Communication Interface (vmw_vmci) and VMCI Sockets
(vmw_vsock) kernel modules for inclusion in the Linux kernel. The
purpose of this post is to acquire feedback on the vmw_vmci kernel
module. The vmw_vsock kernel module will be presented in a later post.


* * *

VMCI allows virtual machines to communicate with host kernel modules
and the VMware hypervisors. User level applications both in a virtual
machine and on the host can use vmw_vmci through VMCI Sockets, a socket
address family designed to be compatible with UDP and TCP at the
interface level. Today, VMCI and VMCI Sockets are used by the VMware
shared folders (HGFS) and various VMware Tools components inside the
guest for zero-config, network-less access to VMware host services. In
addition to this, VMware's users are using VMCI Sockets for various
applications, where network access of the virtual machine is
restricted or non-existent. Examples of this are VMs communicating
with device proxies for proprietary hardware running as host
applications and automated testing of applications running within
virtual machines.

In a virtual machine, VMCI is exposed as a regular PCI device. The
primary communication mechanisms supported are a point-to-point
bidirectional transport based on a pair of memory-mapped queues, and
asynchronous notifications in the form of datagrams and
doorbells. These features are available to kernel level components
such as HGFS and VMCI Sockets through the VMCI kernel API. In addition
to this, the VMCI kernel API provides support for receiving events
related to the state of the VMCI communication channels, and the
virtual machine itself.

Outside the virtual machine, the host side support of the VMCI kernel
module makes the same VMCI kernel API available to VMCI endpoints on
the host. In addition to this, the host side manages each VMCI device
in a virtual machine through a context object. This context object
serves to identify the virtual machine for communication, and to track
the resource consumption of the given VMCI device. Both operations
related to communication between the virtual machine and the host
kernel, and those related to the management of the VMCI device state
in the host kernel, are invoked by the user level component of the
hypervisor through a set of ioctls on the VMCI device node.  To
provide seamless support for nested virtualization, where a virtual
machine may use both a VMCI PCI device to talk to its hypervisor, and
the VMCI host side support to run nested virtual machines, the VMCI
host and virtual machine support are combined in a single kernel
module.

For additional information about the use of VMCI and in particular
VMCI Sockets, please refer to the VMCI Socket Programming Guide
available at https://www.vmware.com/support/developer/vmci-sdk/.



---

George Zhang (12):
  VMCI: context implementation.
  VMCI: datagram implementation.
  VMCI: doorbell implementation.
  VMCI: device driver implementaton.
  VMCI: event handling implementation.
  VMCI: handle array implementation.
  VMCI: queue pairs implementation.
  VMCI: resource object implementation.
  VMCI: routing implementation.
  VMCI: guest side driver implementation.
  VMCI: host side driver implementation.
  VMCI: Some header and config files.


 drivers/misc/Kconfig  |1 
 drivers/misc/Makefile |2 
 drivers/misc/vmw_vmci/Kconfig |   16 
 drivers/misc/vmw_vmci/Makefile|4 
 drivers/misc/vmw_vmci/vmci_common_int.h   |   32 
 drivers/misc/vmw_vmci/vmci_context.c  | 1223 ++
 drivers/misc/vmw_vmci/vmci_context.h  |  183 ++
 drivers/misc/vmw_vmci/vmci_datagram.c |  501 
 drivers/misc/vmw_vmci/vmci_datagram.h |   52 
 drivers/misc/vmw_vmci/vmci_doorbell.c |  605 +
 drivers/misc/vmw_vmci/vmci_doorbell.h |   51 
 drivers/misc/vmw_vmci/vmci_driver.c   |  117 +
 drivers/misc/vmw_vmci/vmci_driver.h   |   50 
 drivers/misc/vmw_vmci/vmci_event.c|  224 ++
 drivers/misc/vmw_vmci/vmci_event.h|   25 
 drivers/misc/vmw_vmci/vmci_guest.c|  757 ++
 drivers/misc/vmw_vmci/vmci_handle_array.c |  142 +
 drivers/misc/vmw_vmci/vmci_handle_array.h |   52 
 drivers/misc/vmw_vmci/vmci_host.c | 1036 +
 drivers/misc/vmw_vmci/vmci_queue_pair.c   | 3439 +
 drivers/misc/vmw_vmci/vmci_queue_pair.h   |  191 ++
 drivers/

[PATCH 00/12] VMCI for Linux upstreaming

2012-11-07 Thread George Zhang

* * *
This series of VMCI linux upstreaming patches include latest udpate from
VMware.

Summary of changes:
- Fix some new sparse issues.
- Remove some unneeded casts for VMCI.
- add more __user annotations for VMCI.
- Remove kernel version-specific bits from vSockets.


* * *

In an effort to improve the out-of-the-box experience with Linux
kernels for VMware users, VMware is working on readying the Virtual
Machine Communication Interface (vmw_vmci) and VMCI Sockets
(vmw_vsock) kernel modules for inclusion in the Linux kernel. The
purpose of this post is to acquire feedback on the vmw_vmci kernel
module. The vmw_vsock kernel module will be presented in a later post.


* * *

VMCI allows virtual machines to communicate with host kernel modules
and the VMware hypervisors. User level applications both in a virtual
machine and on the host can use vmw_vmci through VMCI Sockets, a socket
address family designed to be compatible with UDP and TCP at the
interface level. Today, VMCI and VMCI Sockets are used by the VMware
shared folders (HGFS) and various VMware Tools components inside the
guest for zero-config, network-less access to VMware host services. In
addition to this, VMware's users are using VMCI Sockets for various
applications, where network access of the virtual machine is
restricted or non-existent. Examples of this are VMs communicating
with device proxies for proprietary hardware running as host
applications and automated testing of applications running within
virtual machines.

In a virtual machine, VMCI is exposed as a regular PCI device. The
primary communication mechanisms supported are a point-to-point
bidirectional transport based on a pair of memory-mapped queues, and
asynchronous notifications in the form of datagrams and
doorbells. These features are available to kernel level components
such as HGFS and VMCI Sockets through the VMCI kernel API. In addition
to this, the VMCI kernel API provides support for receiving events
related to the state of the VMCI communication channels, and the
virtual machine itself.

Outside the virtual machine, the host side support of the VMCI kernel
module makes the same VMCI kernel API available to VMCI endpoints on
the host. In addition to this, the host side manages each VMCI device
in a virtual machine through a context object. This context object
serves to identify the virtual machine for communication, and to track
the resource consumption of the given VMCI device. Both operations
related to communication between the virtual machine and the host
kernel, and those related to the management of the VMCI device state
in the host kernel, are invoked by the user level component of the
hypervisor through a set of ioctls on the VMCI device node.  To
provide seamless support for nested virtualization, where a virtual
machine may use both a VMCI PCI device to talk to its hypervisor, and
the VMCI host side support to run nested virtual machines, the VMCI
host and virtual machine support are combined in a single kernel
module.

For additional information about the use of VMCI and in particular
VMCI Sockets, please refer to the VMCI Socket Programming Guide
available at https://www.vmware.com/support/developer/vmci-sdk/.



---

George Zhang (12):
  VMCI: context implementation.
  VMCI: datagram implementation.
  VMCI: doorbell implementation.
  VMCI: device driver implementaton.
  VMCI: event handling implementation.
  VMCI: handle array implementation.
  VMCI: queue pairs implementation.
  VMCI: resource object implementation.
  VMCI: routing implementation.
  VMCI: guest side driver implementation.
  VMCI: host side driver implementation.
  VMCI: Some header and config files.


 drivers/misc/Kconfig  |1 
 drivers/misc/Makefile |2 
 drivers/misc/vmw_vmci/Kconfig |   16 
 drivers/misc/vmw_vmci/Makefile|4 
 drivers/misc/vmw_vmci/vmci_common_int.h   |   34 
 drivers/misc/vmw_vmci/vmci_context.c  | 1246 ++
 drivers/misc/vmw_vmci/vmci_context.h  |  183 ++
 drivers/misc/vmw_vmci/vmci_datagram.c |  506 
 drivers/misc/vmw_vmci/vmci_datagram.h |   52 
 drivers/misc/vmw_vmci/vmci_doorbell.c |  605 +
 drivers/misc/vmw_vmci/vmci_doorbell.h |   51 
 drivers/misc/vmw_vmci/vmci_driver.c   |  116 +
 drivers/misc/vmw_vmci/vmci_driver.h   |   50 
 drivers/misc/vmw_vmci/vmci_event.c|  229 ++
 drivers/misc/vmw_vmci/vmci_event.h|   25 
 drivers/misc/vmw_vmci/vmci_guest.c|  762 ++
 drivers/misc/vmw_vmci/vmci_handle_array.c |  142 +
 drivers/misc/vmw_vmci/vmci_handle_array.h |   52 
 drivers/misc/vmw_vmci/vmci_host.c | 1033 +
 drivers/misc/vmw_vmci/vmci_queue_pair.c   | 3506 +
 drivers/misc/vmw_vmci/vmci_queue_pair.h   |  191 ++
 drivers/misc/vmw_vmci/vmci_resource.c |  232 ++
 drivers/misc/vmw_vmci/vmci_resourc

[PATCH 00/12] VMCI for Linux upstreaming

2012-11-01 Thread George Zhang


* * *
This series of VMCI linux upstreaming patches include latest udpate from
VMware.

Summary of changes:
- Use RCU for context lookup.
- Remove redundant init()/empty functions.
- Remove unnecessary ASSERTs.
- Remove delayed event callbacks.
- Cleanup some comments.
- Cleanup makefiles.
- Drop -I$(src)/shared custom flags from Makefile for VSOCK.
- Rename vmci_ctx_init_ctx() to vmci_ctx_create().
- Get rid of vmci_ctx_init().
- Rename vmci_ctx_release() to vmci_ctx_put().



* * *

In an effort to improve the out-of-the-box experience with Linux
kernels for VMware users, VMware is working on readying the Virtual
Machine Communication Interface (vmw_vmci) and VMCI Sockets
(vmw_vsock) kernel modules for inclusion in the Linux kernel. The
purpose of this post is to acquire feedback on the vmw_vmci kernel
module. The vmw_vsock kernel module will be presented in a later post.


* * *

VMCI allows virtual machines to communicate with host kernel modules
and the VMware hypervisors. User level applications both in a virtual
machine and on the host can use vmw_vmci through VMCI Sockets, a socket
address family designed to be compatible with UDP and TCP at the
interface level. Today, VMCI and VMCI Sockets are used by the VMware
shared folders (HGFS) and various VMware Tools components inside the
guest for zero-config, network-less access to VMware host services. In
addition to this, VMware's users are using VMCI Sockets for various
applications, where network access of the virtual machine is
restricted or non-existent. Examples of this are VMs communicating
with device proxies for proprietary hardware running as host
applications and automated testing of applications running within
virtual machines.

In a virtual machine, VMCI is exposed as a regular PCI device. The
primary communication mechanisms supported are a point-to-point
bidirectional transport based on a pair of memory-mapped queues, and
asynchronous notifications in the form of datagrams and
doorbells. These features are available to kernel level components
such as HGFS and VMCI Sockets through the VMCI kernel API. In addition
to this, the VMCI kernel API provides support for receiving events
related to the state of the VMCI communication channels, and the
virtual machine itself.

Outside the virtual machine, the host side support of the VMCI kernel
module makes the same VMCI kernel API available to VMCI endpoints on
the host. In addition to this, the host side manages each VMCI device
in a virtual machine through a context object. This context object
serves to identify the virtual machine for communication, and to track
the resource consumption of the given VMCI device. Both operations
related to communication between the virtual machine and the host
kernel, and those related to the management of the VMCI device state
in the host kernel, are invoked by the user level component of the
hypervisor through a set of ioctls on the VMCI device node.  To
provide seamless support for nested virtualization, where a virtual
machine may use both a VMCI PCI device to talk to its hypervisor, and
the VMCI host side support to run nested virtual machines, the VMCI
host and virtual machine support are combined in a single kernel
module.

For additional information about the use of VMCI and in particular
VMCI Sockets, please refer to the VMCI Socket Programming Guide
available at https://www.vmware.com/support/developer/vmci-sdk/.


---

George Zhang (12):
  VMCI: context implementation.
  VMCI: datagram implementation.
  VMCI: doorbell implementation.
  VMCI: device driver implementaton.
  VMCI: event handling implementation.
  VMCI: handle array implementation.
  VMCI: queue pairs implementation.
  VMCI: resource object implementation.
  VMCI: routing implementation.
  VMCI: guest side driver implementation.
  VMCI: host side driver implementation.
  VMCI: Some header and config files.


 drivers/misc/Kconfig  |1 
 drivers/misc/Makefile |2 
 drivers/misc/vmw_vmci/Kconfig |   16 
 drivers/misc/vmw_vmci/Makefile|4 
 drivers/misc/vmw_vmci/vmci_common_int.h   |   34 
 drivers/misc/vmw_vmci/vmci_context.c  | 1247 ++
 drivers/misc/vmw_vmci/vmci_context.h  |  183 ++
 drivers/misc/vmw_vmci/vmci_datagram.c |  506 
 drivers/misc/vmw_vmci/vmci_datagram.h |   52 
 drivers/misc/vmw_vmci/vmci_doorbell.c |  645 +
 drivers/misc/vmw_vmci/vmci_doorbell.h |   53 
 drivers/misc/vmw_vmci/vmci_driver.c   |  116 +
 drivers/misc/vmw_vmci/vmci_driver.h   |   50 
 drivers/misc/vmw_vmci/vmci_event.c|  229 ++
 drivers/misc/vmw_vmci/vmci_event.h|   25 
 drivers/misc/vmw_vmci/vmci_guest.c|  762 ++
 drivers/misc/vmw_vmci/vmci_handle_array.c |  142 +
 drivers/misc/vmw_vmci/vmci_handle_array.h |   52 
 drivers/misc/vmw_vmci

Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-10-30 Thread Greg KH
On Tue, Oct 30, 2012 at 12:43:54PM -0700, Dmitry Torokhov wrote:
> On Tue, Oct 30, 2012 at 09:27:23AM -0700, Greg KH wrote:
> > On Tue, Oct 30, 2012 at 09:18:07AM -0700, Dmitry Torokhov wrote:
> > > > > I think that even if we had a special directory for vmci having 
> > > > > network
> > > > > drivers in Dave's realm and pvscsi in James's is best option, so the 
> > > > > new
> > > > > directory would contain vmci and the balloon driver (vsock will go 
> > > > > into
> > > > > net/).  Given that balloon is already in drivers/misc it looked like
> > > > > obvious place for VMCI as well.
> > > > 
> > > > I agree that the individual drivers should go in the subsystem area,
> > > > it's this "hypervisor bus core" type code that I'm questioning.  Right
> > > > now every hypervisor is putting that logic in a different place in the
> > > > kernel, having some consistency here would be nice.
> > > 
> > > Hmm, I wonder if miscellaneous and core hypervisor drivers should end
> > > up in drivers/platform:
> > > 
> > >   drivers/platform/hyperv
> > >   drivers/platform/olpc
> > >   drivers/platform/vmware
> > >   drivers/platform/xen
> > >   drivers/platform/x86
> > 
> > That makes sense to me, nice.
> > 
> > > But really we'd like to get VMCI into mainline first and move to a new
> > > place later if such a better place is found.
> > 
> > Heh, no one wants to fight for something to help everyone out, they just
> > want their own code accepted :)
> 
> No, this is more about finding a person who would be maintaining it and
> thus would review our code. For now we got you tagged and do not want to
> let go of you :P
> 
> Or should we maintain our own stuff and have Linus pull it directly,
> like Xen guys appear to be doing? Really, moving it is not an issue for
> us.

No, I don't mind doing some of the review, and getting it to Linus to
start with, but over time, having you all be the owners and push stuff
directly to him is fine with me.

So I agree, for now, let's leave it as-is.

thanks,

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-10-30 Thread Dmitry Torokhov
On Tue, Oct 30, 2012 at 09:27:23AM -0700, Greg KH wrote:
> On Tue, Oct 30, 2012 at 09:18:07AM -0700, Dmitry Torokhov wrote:
> > > > I think that even if we had a special directory for vmci having network
> > > > drivers in Dave's realm and pvscsi in James's is best option, so the new
> > > > directory would contain vmci and the balloon driver (vsock will go into
> > > > net/).  Given that balloon is already in drivers/misc it looked like
> > > > obvious place for VMCI as well.
> > > 
> > > I agree that the individual drivers should go in the subsystem area,
> > > it's this "hypervisor bus core" type code that I'm questioning.  Right
> > > now every hypervisor is putting that logic in a different place in the
> > > kernel, having some consistency here would be nice.
> > 
> > Hmm, I wonder if miscellaneous and core hypervisor drivers should end
> > up in drivers/platform:
> > 
> > drivers/platform/hyperv
> > drivers/platform/olpc
> > drivers/platform/vmware
> > drivers/platform/xen
> > drivers/platform/x86
> 
> That makes sense to me, nice.
> 
> > But really we'd like to get VMCI into mainline first and move to a new
> > place later if such a better place is found.
> 
> Heh, no one wants to fight for something to help everyone out, they just
> want their own code accepted :)

No, this is more about finding a person who would be maintaining it and
thus would review our code. For now we got you tagged and do not want to
let go of you :P

Or should we maintain our own stuff and have Linus pull it directly,
like Xen guys appear to be doing? Really, moving it is not an issue for
us.

Thanks,
Dmitry
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-10-30 Thread Greg KH
On Tue, Oct 30, 2012 at 09:18:07AM -0700, Dmitry Torokhov wrote:
> > > I think that even if we had a special directory for vmci having network
> > > drivers in Dave's realm and pvscsi in James's is best option, so the new
> > > directory would contain vmci and the balloon driver (vsock will go into
> > > net/).  Given that balloon is already in drivers/misc it looked like
> > > obvious place for VMCI as well.
> > 
> > I agree that the individual drivers should go in the subsystem area,
> > it's this "hypervisor bus core" type code that I'm questioning.  Right
> > now every hypervisor is putting that logic in a different place in the
> > kernel, having some consistency here would be nice.
> 
> Hmm, I wonder if miscellaneous and core hypervisor drivers should end
> up in drivers/platform:
> 
>   drivers/platform/hyperv
>   drivers/platform/olpc
>   drivers/platform/vmware
>   drivers/platform/xen
>   drivers/platform/x86

That makes sense to me, nice.

> But really we'd like to get VMCI into mainline first and move to a new
> place later if such a better place is found.

Heh, no one wants to fight for something to help everyone out, they just
want their own code accepted :)

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-10-30 Thread Dmitry Torokhov
On Tue, Oct 30, 2012 at 08:48:01AM -0700, Greg KH wrote:
> On Mon, Oct 29, 2012 at 09:07:44PM -0700, Dmitry Torokhov wrote:
> > Hi Greg,
> > 
> > On Mon, Oct 29, 2012 at 07:19:38PM -0700, Greg KH wrote:
> > > On Mon, Oct 29, 2012 at 06:03:28PM -0700, George Zhang wrote:
> > > >  drivers/misc/Kconfig  |1
> > > >  drivers/misc/Makefile |2
> > > >  drivers/misc/vmw_vmci/Kconfig |   16
> > > >  drivers/misc/vmw_vmci/Makefile|   43
> > > 
> > > Meta comment here, why drivers/misc/?  The other hypervisor
> > > infrastructures all have their own directory under drivers/  Should we
> > > be moving everything to drivers/hyperv/ somehow?
> > 
> > drivers/hyperv is not the best name for obvious reasons...
> 
> Sorry, yes :)

:)

> 
> > I think that even if we had a special directory for vmci having network
> > drivers in Dave's realm and pvscsi in James's is best option, so the new
> > directory would contain vmci and the balloon driver (vsock will go into
> > net/).  Given that balloon is already in drivers/misc it looked like
> > obvious place for VMCI as well.
> 
> I agree that the individual drivers should go in the subsystem area,
> it's this "hypervisor bus core" type code that I'm questioning.  Right
> now every hypervisor is putting that logic in a different place in the
> kernel, having some consistency here would be nice.

Hmm, I wonder if miscellaneous and core hypervisor drivers should end
up in drivers/platform:

drivers/platform/hyperv
drivers/platform/olpc
drivers/platform/vmware
drivers/platform/xen
drivers/platform/x86

But really we'd like to get VMCI into mainline first and move to a new
place later if such a better place is found.

Thanks,
Dmitry
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-10-30 Thread Greg KH
On Mon, Oct 29, 2012 at 09:07:44PM -0700, Dmitry Torokhov wrote:
> Hi Greg,
> 
> On Mon, Oct 29, 2012 at 07:19:38PM -0700, Greg KH wrote:
> > On Mon, Oct 29, 2012 at 06:03:28PM -0700, George Zhang wrote:
> > >  drivers/misc/Kconfig  |1
> > >  drivers/misc/Makefile |2
> > >  drivers/misc/vmw_vmci/Kconfig |   16
> > >  drivers/misc/vmw_vmci/Makefile|   43
> > 
> > Meta comment here, why drivers/misc/?  The other hypervisor
> > infrastructures all have their own directory under drivers/  Should we
> > be moving everything to drivers/hyperv/ somehow?
> 
> drivers/hyperv is not the best name for obvious reasons...

Sorry, yes :)

> I think that even if we had a special directory for vmci having network
> drivers in Dave's realm and pvscsi in James's is best option, so the new
> directory would contain vmci and the balloon driver (vsock will go into
> net/).  Given that balloon is already in drivers/misc it looked like
> obvious place for VMCI as well.

I agree that the individual drivers should go in the subsystem area,
it's this "hypervisor bus core" type code that I'm questioning.  Right
now every hypervisor is putting that logic in a different place in the
kernel, having some consistency here would be nice.

thanks,

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [Pv-drivers] [PATCH 00/12] VMCI for Linux upstreaming

2012-10-29 Thread Dmitry Torokhov
Hi Greg,

On Mon, Oct 29, 2012 at 07:19:38PM -0700, Greg KH wrote:
> On Mon, Oct 29, 2012 at 06:03:28PM -0700, George Zhang wrote:
> >  drivers/misc/Kconfig  |1
> >  drivers/misc/Makefile |2
> >  drivers/misc/vmw_vmci/Kconfig |   16
> >  drivers/misc/vmw_vmci/Makefile|   43
> 
> Meta comment here, why drivers/misc/?  The other hypervisor
> infrastructures all have their own directory under drivers/  Should we
> be moving everything to drivers/hyperv/ somehow?

drivers/hyperv is not the best name for obvious reasons...

I think that even if we had a special directory for vmci having network
drivers in Dave's realm and pvscsi in James's is best option, so the new
directory would contain vmci and the balloon driver (vsock will go into
net/).  Given that balloon is already in drivers/misc it looked like
obvious place for VMCI as well.

Thanks,
Dmitry

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


Re: [PATCH 00/12] VMCI for Linux upstreaming

2012-10-29 Thread Greg KH
On Mon, Oct 29, 2012 at 06:03:28PM -0700, George Zhang wrote:
>  drivers/misc/Kconfig  |1
>  drivers/misc/Makefile |2
>  drivers/misc/vmw_vmci/Kconfig |   16
>  drivers/misc/vmw_vmci/Makefile|   43

Meta comment here, why drivers/misc/?  The other hypervisor
infrastructures all have their own directory under drivers/  Should we
be moving everything to drivers/hyperv/ somehow?

thanks,

greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/


[PATCH 00/12] VMCI for Linux upstreaming

2012-10-29 Thread George Zhang
* * *
This series of VMCI linux upstreaming patches include latest udpate from
VMware.
-split guest, host and core driver code into different files
-use EXPORT_SYMBOLS_GPL
-remove vmci_device_get and vmci_device_release APIs
-simplify the event deliver mechanism
-driver ioctl code cleanup
-sparse clean




* * *

In an effort to improve the out-of-the-box experience with Linux
kernels for VMware users, VMware is working on readying the Virtual
Machine Communication Interface (vmw_vmci) and VMCI Sockets
(vmw_vsock) kernel modules for inclusion in the Linux kernel. The
purpose of this post is to acquire feedback on the vmw_vmci kernel
module. The vmw_vsock kernel module will be presented in a later post.


* * *

VMCI allows virtual machines to communicate with host kernel modules
and the VMware hypervisors. User level applications both in a virtual
machine and on the host can use vmw_vmci through VMCI Sockets, a socket
address family designed to be compatible with UDP and TCP at the
interface level. Today, VMCI and VMCI Sockets are used by the VMware
shared folders (HGFS) and various VMware Tools components inside the
guest for zero-config, network-less access to VMware host services. In
addition to this, VMware's users are using VMCI Sockets for various
applications, where network access of the virtual machine is
restricted or non-existent. Examples of this are VMs communicating
with device proxies for proprietary hardware running as host
applications and automated testing of applications running within
virtual machines.

In a virtual machine, VMCI is exposed as a regular PCI device. The
primary communication mechanisms supported are a point-to-point
bidirectional transport based on a pair of memory-mapped queues, and
asynchronous notifications in the form of datagrams and
doorbells. These features are available to kernel level components
such as HGFS and VMCI Sockets through the VMCI kernel API. In addition
to this, the VMCI kernel API provides support for receiving events
related to the state of the VMCI communication channels, and the
virtual machine itself.

Outside the virtual machine, the host side support of the VMCI kernel
module makes the same VMCI kernel API available to VMCI endpoints on
the host. In addition to this, the host side manages each VMCI device
in a virtual machine through a context object. This context object
serves to identify the virtual machine for communication, and to track
the resource consumption of the given VMCI device. Both operations
related to communication between the virtual machine and the host
kernel, and those related to the management of the VMCI device state
in the host kernel, are invoked by the user level component of the
hypervisor through a set of ioctls on the VMCI device node.  To
provide seamless support for nested virtualization, where a virtual
machine may use both a VMCI PCI device to talk to its hypervisor, and
the VMCI host side support to run nested virtual machines, the VMCI
host and virtual machine support are combined in a single kernel
module.

For additional information about the use of VMCI and in particular
VMCI Sockets, please refer to the VMCI Socket Programming Guide
available at https://www.vmware.com/support/developer/vmci-sdk/.



---

George Zhang (12):
  VMCI: context implementation.
  VMCI: datagram implementation.
  VMCI: doorbell implementation.
  VMCI: device driver implementaton.
  VMCI: event handling implementation.
  VMCI: handle array implementation.
  VMCI: queue pairs implementation.
  VMCI: resource object implementation.
  VMCI: routing implementation.
  VMCI: guest side driver implementation.
  VMCI: host side driver implementation.
  VMCI: Some header and config files.


 drivers/misc/Kconfig  |1
 drivers/misc/Makefile |2
 drivers/misc/vmw_vmci/Kconfig |   16
 drivers/misc/vmw_vmci/Makefile|   43
 drivers/misc/vmw_vmci/vmci_common_int.h   |   34
 drivers/misc/vmw_vmci/vmci_context.c  | 1290 +++
 drivers/misc/vmw_vmci/vmci_context.h  |  177 +
 drivers/misc/vmw_vmci/vmci_datagram.c |  520 
 drivers/misc/vmw_vmci/vmci_datagram.h |   55
 drivers/misc/vmw_vmci/vmci_doorbell.c |  673 +
 drivers/misc/vmw_vmci/vmci_doorbell.h |   53
 drivers/misc/vmw_vmci/vmci_driver.c   |  159 +
 drivers/misc/vmw_vmci/vmci_driver.h   |   50
 drivers/misc/vmw_vmci/vmci_event.c|  371 +++
 drivers/misc/vmw_vmci/vmci_event.h|   25
 drivers/misc/vmw_vmci/vmci_guest.c|  765 ++
 drivers/misc/vmw_vmci/vmci_handle_array.c |  162 +
 drivers/misc/vmw_vmci/vmci_handle_array.h |   46
 drivers/misc/vmw_vmci/vmci_host.c | 1046 +
 drivers/misc/vmw_vmci/vmci_queue_pair.c   | 3556 +
 drivers/misc/vmw_vmci/vmci_queue_pair.h   |  191 ++
 drivers/misc/vmw_vmci/vmci_resource.c |  237 ++
 drivers/misc/vmw