Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-23 Thread Simon Horman
On Wed, Oct 23, 2019 at 06:36:13PM +0800, Jason Wang wrote: > > On 2019/10/23 下午6:13, Simon Horman wrote: > > On Tue, Oct 22, 2019 at 09:32:36AM +0800, Jason Wang wrote: > > > On 2019/10/22 上午12:31, Simon Horman wrote: > > > > On Mon, Oct 21, 2019 at 05:55:33PM +0800, Zhu, Lingshan wrote: > > > >

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-23 Thread Jason Wang
On 2019/10/23 下午6:13, Simon Horman wrote: On Tue, Oct 22, 2019 at 09:32:36AM +0800, Jason Wang wrote: On 2019/10/22 上午12:31, Simon Horman wrote: On Mon, Oct 21, 2019 at 05:55:33PM +0800, Zhu, Lingshan wrote: On 10/16/2019 5:53 PM, Simon Horman wrote: Hi Zhu, thanks for your patch. On

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-23 Thread Simon Horman
On Tue, Oct 22, 2019 at 09:32:36AM +0800, Jason Wang wrote: > > On 2019/10/22 上午12:31, Simon Horman wrote: > > On Mon, Oct 21, 2019 at 05:55:33PM +0800, Zhu, Lingshan wrote: > > > On 10/16/2019 5:53 PM, Simon Horman wrote: > > > > Hi Zhu, > > > > > > > > thanks for your patch. > > > > > > > >

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-22 Thread Zhu Lingshan
On 10/22/2019 9:32 AM, Jason Wang wrote: On 2019/10/22 上午12:31, Simon Horman wrote: On Mon, Oct 21, 2019 at 05:55:33PM +0800, Zhu, Lingshan wrote: On 10/16/2019 5:53 PM, Simon Horman wrote: Hi Zhu, thanks for your patch. On Wed, Oct 16, 2019 at 09:10:40AM +0800, Zhu Lingshan wrote: ...

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-21 Thread Jason Wang
On 2019/10/22 上午12:31, Simon Horman wrote: On Mon, Oct 21, 2019 at 05:55:33PM +0800, Zhu, Lingshan wrote: On 10/16/2019 5:53 PM, Simon Horman wrote: Hi Zhu, thanks for your patch. On Wed, Oct 16, 2019 at 09:10:40AM +0800, Zhu Lingshan wrote: ... +static void ifcvf_read_dev_config(struct

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-21 Thread Simon Horman
On Mon, Oct 21, 2019 at 05:55:33PM +0800, Zhu, Lingshan wrote: > > On 10/16/2019 5:53 PM, Simon Horman wrote: > > Hi Zhu, > > > > thanks for your patch. > > > > On Wed, Oct 16, 2019 at 09:10:40AM +0800, Zhu Lingshan wrote: ... > > > +static void ifcvf_read_dev_config(struct ifcvf_hw *hw, u64

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-21 Thread Jason Wang
On 2019/10/21 下午6:00, Zhu, Lingshan wrote: On 10/16/2019 4:40 PM, Jason Wang wrote: On 2019/10/16 上午9:30, Zhu Lingshan wrote: This commit introduced ifcvf_base layer, which handles IFC VF NIC hardware operations and configurations. It's better to describe the difference between ifc vf

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-21 Thread Jason Wang
On 2019/10/21 下午5:57, Zhu, Lingshan wrote: On 10/16/2019 4:45 PM, Jason Wang wrote: On 2019/10/16 上午9:30, Zhu Lingshan wrote: + */ +#define IFCVF_TRANSPORT_F_START 28 +#define IFCVF_TRANSPORT_F_END   34 + +#define IFC_SUPPORTED_FEATURES \ +    ((1ULL << VIRTIO_NET_F_MAC)    | \

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-21 Thread Zhu, Lingshan
On 10/16/2019 4:40 PM, Jason Wang wrote: On 2019/10/16 上午9:30, Zhu Lingshan wrote: This commit introduced ifcvf_base layer, which handles IFC VF NIC hardware operations and configurations. It's better to describe the difference between ifc vf and virtio in the commit log or is there a

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-21 Thread Zhu, Lingshan
On 10/16/2019 4:45 PM, Jason Wang wrote: On 2019/10/16 上午9:30, Zhu Lingshan wrote: + */ +#define IFCVF_TRANSPORT_F_START 28 +#define IFCVF_TRANSPORT_F_END   34 + +#define IFC_SUPPORTED_FEATURES \ +    ((1ULL << VIRTIO_NET_F_MAC)    | \ + (1ULL << VIRTIO_F_ANY_LAYOUT)  

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-21 Thread Zhu, Lingshan
On 10/16/2019 5:53 PM, Simon Horman wrote: Hi Zhu, thanks for your patch. On Wed, Oct 16, 2019 at 09:10:40AM +0800, Zhu Lingshan wrote: This commit introduced ifcvf_base layer, which handles IFC VF NIC hardware operations and configurations. Signed-off-by: Zhu Lingshan ---

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-16 Thread Simon Horman
Hi Zhu, thanks for your patch. On Wed, Oct 16, 2019 at 09:10:40AM +0800, Zhu Lingshan wrote: > This commit introduced ifcvf_base layer, which handles IFC VF NIC > hardware operations and configurations. > > Signed-off-by: Zhu Lingshan > --- > drivers/vhost/ifcvf/ifcvf_base.c | 390 >

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-16 Thread Jason Wang
On 2019/10/16 上午9:30, Zhu Lingshan wrote: + */ +#define IFCVF_TRANSPORT_F_START 28 +#define IFCVF_TRANSPORT_F_END 34 + +#define IFC_SUPPORTED_FEATURES \ + ((1ULL << VIRTIO_NET_F_MAC) | \ +(1ULL << VIRTIO_F_ANY_LAYOUT)| \

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-16 Thread Jason Wang
On 2019/10/16 上午9:30, Zhu Lingshan wrote: This commit introduced ifcvf_base layer, which handles IFC VF NIC hardware operations and configurations. It's better to describe the difference between ifc vf and virtio in the commit log or is there a open doc for this? Signed-off-by: Zhu

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-15 Thread Stephen Hemminger
On Wed, 16 Oct 2019 09:03:17 +0800 Zhu Lingshan wrote: > + IFC_INFO(>dev, "PCI capability mapping:\n" > + "common cfg: %p\n" > + "notify base: %p\n" > + "isr cfg: %p\n" > + "device

Re: [RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-15 Thread Stephen Hemminger
On Wed, 16 Oct 2019 09:03:17 +0800 Zhu Lingshan wrote: > +int ifcvf_init_hw(struct ifcvf_hw *hw, struct pci_dev *dev) > +{ > + int ret; > + u8 pos; > + struct virtio_pci_cap cap; > + u32 i; > + u16 notify_off; For network code, the preferred declaration style is reverse

[RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-15 Thread Zhu Lingshan
This commit introduced ifcvf_base layer, which handles IFC VF NIC hardware operations and configurations. Signed-off-by: Zhu Lingshan --- drivers/vhost/ifcvf/ifcvf_base.c | 390 +++ drivers/vhost/ifcvf/ifcvf_base.h | 137 ++ 2 files changed, 527

[RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-15 Thread Zhu Lingshan
This commit introduced ifcvf_base layer, which handles IFC VF NIC hardware operations and configurations. Signed-off-by: Zhu Lingshan --- drivers/vhost/ifcvf/ifcvf_base.c | 390 +++ drivers/vhost/ifcvf/ifcvf_base.h | 137 ++ 2 files changed, 527

[RFC 1/2] vhost: IFC VF hardware operation layer

2019-10-15 Thread Zhu Lingshan
This commit introduced ifcvf_base layer, which handles IFC VF NIC hardware operations and configurations. Signed-off-by: Zhu Lingshan --- drivers/vhost/ifcvf/ifcvf_base.c | 390 +++ drivers/vhost/ifcvf/ifcvf_base.h | 137 ++ 2 files changed, 527