Re: [PATCH net 1/1] hyperv: Fix a bug in netvsc_send()

2014-10-21 Thread Long Li
, October 11, 2014 3:36 AM To: Long Li Cc: David Miller; o...@aepfle.de; net...@vger.kernel.org; jasow...@redhat.com; linux-kernel@vger.kernel.org; a...@canonical.com; de...@linuxdriverproject.org Subject: Re: [PATCH net 1/1] hyperv: Fix a bug in netvsc_send() On Fri, Oct 10, 2014 at 11:39:00PM +

RE: skbuff_fclone_cache poison overwritten

2014-11-11 Thread Long Li
Srinivasan; Haiyang Zhang; Long Li; net...@vger.kernel.org; linux-kernel@vger.kernel.org Subject: skbuff_fclone_cache poison overwritten While using 3.18.0-rc3.x86_64-00116-g6ac94d3 on a Hyper-V 2012 R2 the poison in skbuff_fclone_cache was overwritten: [39099.484435] sd 7:0:0:0: [sdi] Attached SCSI

RE: Inconsistent lock state with Hyper-V memory balloon?

2014-11-11 Thread Long Li
Sitsofe, can you try the patch attached to see if it helps with the problem? Long -Original Message- From: linux-kernel-ow...@vger.kernel.org [mailto:linux-kernel-ow...@vger.kernel.org] On Behalf Of Peter Zijlstra Sent: Monday, November 10, 2014 1:44 AM To: Sitsofe Wheeler Cc: KY

RE: [PATCH 2/4] Drivers: scsi: storvsc: Force discovery of LUNs that may have been removed.

2014-12-30 Thread Long Li
added. Signed-off-by: K. Y. Srinivasan k...@microsoft.com Reviewed-by: Long Li lon...@microsoft.com --- drivers/scsi/storvsc_drv.c | 26 ++ 1 files changed, 26 insertions(+), 0 deletions(-) diff --git a/drivers/scsi/storvsc_drv.c b/drivers/scsi/storvsc_drv.c index

RE: [PATCH 4/4] Drivers: scsi: storvsc: Force SPC-3 compliance on win8 and win8 r2 hosts

2014-12-30 Thread Long Li
james.bottom...@hansenpartnership.com Signed-off-by: K. Y. Srinivasan k...@microsoft.com Reviewed-by: Long Li lon...@microsoft.com --- drivers/scsi/storvsc_drv.c | 13 + 1 files changed, 13 insertions(+), 0 deletions(-) diff --git a/drivers/scsi/storvsc_drv.c b/drivers/scsi

RE: [PATCH 1/4] Drivers: scsi: storvsc: In responce to a scan event, scan the host

2014-12-30 Thread Long Li
. Signed-off-by: K. Y. Srinivasan k...@microsoft.com Reviewed-by: Long Li lon...@microsoft.com --- drivers/scsi/storvsc_drv.c | 19 +++ 1 files changed, 7 insertions(+), 12 deletions(-) diff --git a/drivers/scsi/storvsc_drv.c b/drivers/scsi/storvsc_drv.c index e3ba251

RE: [PATCH 3/4] Drivers: scsi: storvsc: Fix a bug in storvsc limits

2014-12-30 Thread Long Li
these new limits. Fix this bug by setting the limits based on the host. Signed-off-by: K. Y. Srinivasan k...@microsoft.com Reviewed-by: Long Li lon...@microsoft.com --- drivers/scsi/storvsc_drv.c | 15 --- 1 files changed, 12 insertions(+), 3 deletions(-) diff --git a/drivers/scsi

RE: [PATCH] scsi:storvsc enable reading from VPD pages on SPC-2

2014-12-15 Thread Long Li
Thanks Martin for the explanation. I'll send out another patch. -Original Message- From: Martin K. Petersen [mailto:martin.peter...@oracle.com] Sent: Thursday, December 11, 2014 7:04 PM To: Long Li Cc: Martin K. Petersen; KY Srinivasan; Haiyang Zhang; jbottom...@parallels.com

RE: [PATCH net 1/1] hyperv: Fix a bug in netvsc_send()

2014-10-10 Thread Long Li
:29PM -0400, David Miller wrote: From: K. Y. Srinivasan k...@microsoft.com Date: Sun, 5 Oct 2014 10:42:51 -0700 After the packet is successfully sent, we should not touch the packet as it may have been freed. This patch is based on the work done by Long Li lon...@microsoft.com

drivers:scsi:storvsc: Fix a bug in handling ring buffer failures that may result in I/O freeze

2014-12-05 Thread Long Li
When ring buffer returns an error indicating retry, storvsc may not return a proper error code to SCSI when bounce buffer is not used. This has introduced I/O freeze on RAID running atop storvsc devices. This patch fixes it by always returning a proper error code. Signed-off-by: Long Li lon

[PATCH] scsi:storvsc enable reading from VPD pages on SPC-2

2014-12-09 Thread Long Li
Signed-off-by: Long Li lon...@microsoft.com --- drivers/scsi/scsi_devinfo.c | 1 + drivers/scsi/storvsc_drv.c | 10 -- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/drivers/scsi/scsi_devinfo.c b/drivers/scsi/scsi_devinfo.c index c1d04d4..f6fe0b2 100644 --- a/drivers/scsi

RE: [PATCH] scsi:storvsc enable reading from VPD pages on SPC-2

2014-12-10 Thread Long Li
Long == Long Li lon...@microsoft.com writes: Long MSFT targets currently claim SPC-2 compliance while they implement Long post SPC-2 features. With this patch we can correctly handle Long WRITE_SAME_16 issues. Handle the issues or handle WRITE SAME(10/16)? With this patch, the SCSI

RE: [PATCH] scsi:storvsc enable reading from VPD pages on SPC-2

2014-12-10 Thread Long Li
-Original Message- From: Sitsofe Wheeler [mailto:sits...@gmail.com] Sent: Wednesday, December 10, 2014 12:58 PM To: Long Li Cc: KY Srinivasan; Haiyang Zhang; jbottom...@parallels.com; linux- s...@vger.kernel.org; de...@linuxdriverproject.org; linux- ker...@vger.kernel.org Subject

RE: [PATCH 6/7] scsi: storvsc: Don't assume that the scatterlist is not chained

2015-03-23 Thread Long Li
to not make this assumption. Signed-off-by: K. Y. Srinivasan k...@microsoft.com Reviewed-by: Long Li lon...@microsoft.com --- drivers/scsi/storvsc_drv.c | 98 +-- 1 files changed, 57 insertions(+), 41 deletions(-) diff --git a/drivers/scsi

RE: [PATCH 5/7] scsi: storvsc: Fix a bug in copy_from_bounce_buffer()

2015-03-23 Thread Long Li
have acquired. Fix the bug. Signed-off-by: K. Y. Srinivasan k...@microsoft.com Reviewed-by: Long Li lon...@microsoft.com Cc: sta...@vger.kernel.org --- drivers/scsi/storvsc_drv.c | 15 --- 1 files changed, 8 insertions(+), 7 deletions(-) diff --git a/drivers/scsi

RE: [PATCH 1/6] scsi: storvsc: Rather than look for sets of specific protocol versions, make decisions based on ranges.

2015-05-29 Thread Long Li
keith.ma...@microsoft.com Rather than look for sets of specific protocol versions, make decisions based on ranges. This will be safer and require fewer changes going forward as we add more storage protocol versions. Reviewed-by: Long Li lon...@microsoft.com Tested-by: Alex Ng ale

RE: [PATCH 2/6] scsi: storvsc: Use a single value to track protocol versions

2015-05-29 Thread Long Li
value to track protocol versions to simplify comparisons and to be consistent with vmbus version tracking. Reviewed-by: Long Li lon...@microsoft.com Tested-by: Alex Ng ale...@microsoft.com Signed-off-by: Keith Mange keith.ma...@microsoft.com Signed-off-by: K. Y. Srinivasan k...@microsoft.com

RE: [PATCH 5/6] scsi: storvsc: use storage protocol version to determine storage capabilities

2015-05-29 Thread Long Li
Use storage protocol version instead of vmbus protocol version when determining storage capabilities. Reviewed-by: Long Li lon...@microsoft.com Tested-by: Alex Ng ale...@microsoft.com Signed-off-by: Keith Mange keith.ma...@microsoft.com Signed-off-by: K. Y. Srinivasan k...@microsoft.com

RE: [PATCH 4/6] scsi: storvsc: use correct defaults for values determined by protocol negotiation

2015-05-29 Thread Long Li
Use correct defaults for values determined by protocol negotiation, instead of resetting them with every scsi controller. Reviewed-by: Long Li lon...@microsoft.com Tested-by: Alex Ng ale...@microsoft.com Signed-off-by: Keith Mange keith.ma...@microsoft.com Signed-off-by: K. Y. Srinivasan k

RE: [PATCH 3/6] hv:scsi:Untangle the storage protocol negotiation from the vmbus protocol negotiation.

2015-05-29 Thread Long Li
...@microsoft.com Currently we are making decisions based on vmbus protocol versions that have been negotiated; use storage potocol versions instead. Reviewed-by: Long Li lon...@microsoft.com Tested-by: Alex Ng ale...@microsoft.com Signed-off-by: Keith Mange keith.ma...@microsoft.com Signed-off-by: K. Y

RE: [PATCH 6/6] scsi: storvsc: Allow write_same when host is windows 10

2015-05-29 Thread Long Li
for Windows10 and above hosts. Reviewed-by: Long Li lon...@microsoft.com Tested-by: Alex Ng ale...@microsoft.com Signed-off-by: Keith Mange keith.ma...@microsoft.com Signed-off-by: K. Y. Srinivasan k...@microsoft.com --- drivers/scsi/storvsc_drv.c |6 +- 1 files changed, 5 insertions(+), 1

RE: [PATCH] scsi: storvsc: use shost_for_each_device() instead of open coding

2015-07-03 Thread Long Li
-Original Message- From: KY Srinivasan Sent: Friday, July 03, 2015 11:35 AM To: Vitaly Kuznetsov; linux-s...@vger.kernel.org Cc: Long Li; Haiyang Zhang; James E.J. Bottomley; de...@linuxdriverproject.org; linux-kernel@vger.kernel.org Subject: RE: [PATCH] scsi: storvsc: use

[PATCH v2] storvsc: add logging for error/warning messages

2015-12-03 Thread Long Li
Introduce a logging level for storvsc to log certain error/warning messages. Those messages are helpful in some environments, e.g. Microsoft Azure, for customer support and troubleshooting purposes. Signed-off-by: Long Li <lon...@microsoft.com> --- drivers/scsi/storvsc_drv.

RE: [PATCH] storvsc: add more logging for error and warning messages

2015-12-04 Thread Long Li
> -Original Message- > From: Vitaly Kuznetsov [mailto:vkuzn...@redhat.com] > Sent: Friday, December 4, 2015 1:53 AM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; James E.J. B

[PATCH] storvsc: add more logging for error and warning messages

2015-12-03 Thread Long Li
Introduce a logging level for storvsc to log certain error/warning messages. Those messages are helpful in some environments, e.g. Microsoft Azure, for customer support and troubleshooting purposes. Signed-off-by: Long Li <lon...@microsoft.com> --- drivers/scsi/storvsc_drv.

RE: [PATCH] storvsc: add more logging for error and warning messages

2015-12-03 Thread Long Li
Thanks Joe. I'll send out another patch. > -Original Message- > From: Joe Perches [mailto:j...@perches.com] > Sent: Thursday, December 3, 2015 6:28 PM > To: Long Li <lon...@microsoft.com>; KY Srinivasan <k...@microsoft.com>; > Haiyang Zhang <haiya...@micros

RE: [PATCH] sd: remove redundant check for BLK_DEF_MAX_SECTORS

2016-06-07 Thread Long Li
une 6, 2016 8:42 PM > To: Long Li <lon...@microsoft.com> > Cc: Tom Yan <tom.t...@gmail.com>; James E.J. Bottomley > <j...@linux.vnet.ibm.com>; Martin K. Petersen > <martin.peter...@oracle.com>; linux-s...@vger.kernel.org; linux- > ker...@vger.ke

RE: [PATCH] Use the correct size to set block max sectors

2016-06-03 Thread Long Li
Hi Martin, Yes I would like to test it. Please let me know when they get in there. Thanks Long > -Original Message- > From: Martin K. Petersen [mailto:martin.peter...@oracle.com] > Sent: Tuesday, May 31, 2016 7:44 PM > To: Long Li <lon...@microsoft.com> >

[PATCH] sd: remove redundant check for BLK_DEF_MAX_SECTORS

2016-06-03 Thread Long Li
ing values on optional VPD page 0xb0 "Block Limits". Signed-off-by: Long Li <lon...@microsoft.com> --- drivers/scsi/sd.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c index 60bff78..d8c4047 100644 --- a/driv

RE: [PATCH] sd: remove redundant check for BLK_DEF_MAX_SECTORS

2016-06-04 Thread Long Li
e it again. If they want max_sectors to be set by sd, they can use BLOCK LIMITS VPD to tell it to do so. > -Original Message- > From: Tom Yan [mailto:tom.t...@gmail.com] > Sent: Saturday, June 4, 2016 1:41 AM > To: Long Li <lon...@microsoft.com> > Cc: James E.J. Bot

[PATCH] Use the correct size to set block max sectors

2016-05-26 Thread Long Li
The block sector size should be in unit of 512 bytes, not in bytes. Signed-off-by: Long Li <lon...@microsoft.com> --- drivers/scsi/sd.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c index 428c03e..4bce17e 100644 --- a/d

RE: [PATCH] Use the correct size to set block max sectors

2016-05-26 Thread Long Li
> -Original Message- > From: Bart Van Assche [mailto:bart.vanass...@sandisk.com] > Sent: Thursday, May 26, 2016 7:19 PM > To: Long Li <lon...@microsoft.com>; James E.J. Bottomley > <j...@linux.vnet.ibm.com>; Martin K. Petersen > <martin.peter...@o

RE: [PATCH] hv: use substraction to update ring buffer index

2017-01-20 Thread Long Li
> -Original Message- > From: Dexuan Cui > Sent: Sunday, January 15, 2017 7:12 PM > To: Long Li <lon...@microsoft.com>; KY Srinivasan <k...@microsoft.com>; > Haiyang Zhang <haiya...@microsoft.com> > Cc: de...@linuxdriverproject.org; linux-kernel@vger.

[Resend PATCH 1/2 v3] pci-hyperv: properly handle pci bus remove

2017-02-24 Thread Long Li
status hv_pcibus_removed, we can avoid this situation. Signed-off-by: Long Li <lon...@microsoft.com> Reported-by: Xiaofeng Wang <xiaof...@redhat.com> Acked-by: K. Y. Srinivasan <k...@microsoft.com> --- drivers/pci/host/pci-hyperv.c | 20 +--- 1 file changed, 1

[Resend PATCH 2/2 v3] pci-hyperv: lock pci bus on device eject

2017-02-24 Thread Long Li
<de...@microsoft.com> for pointing out the race condition in create_root_hv_pci_bus(). Signed-off-by: Long Li <lon...@microsoft.com> Reported-by: Xiaofeng Wang <xiaof...@redhat.com> Acked-by: K. Y. Srinivasan <k...@microsoft.com> --- drivers/pci/host/pci-hyperv.c | 4

RE: [Resend PATCH 1/2 v3] pci-hyperv: properly handle pci bus remove

2017-02-10 Thread Long Li
> Sent: Friday, January 27, 2017 10:42 AM > To: Long Li <lon...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; Bjorn Helgaas <bhelg...@google.com> > Cc: de...@linuxdriverproject.org; linux-...@vger.kernel.org; linux- > ker...@vger.kernel.org; Long Li <lo

RE: [Resend PATCH 1/2 v3] pci-hyperv: properly handle pci bus remove

2017-02-13 Thread Long Li
> -Original Message- > From: Bjorn Helgaas [mailto:bhelg...@google.com] > Sent: Saturday, February 11, 2017 9:35 AM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; de..

[PATCH 1/2 v4] pci-hyperv: properly handle pci bus remove

2017-02-27 Thread Long Li
status hv_pcibus_removed, we can avoid this situation. Signed-off-by: Long Li <lon...@microsoft.com> Reported-by: Xiaofeng Wang <xiaof...@redhat.com> Acked-by: K. Y. Srinivasan <k...@microsoft.com> --- drivers/pci/host/pci-hyperv.c | 20 +--- 1 file changed, 1

[PATCH 2/2 v4] pci-hyperv: lock pci bus on device eject

2017-02-27 Thread Long Li
<de...@microsoft.com> for pointing out the race condition in create_root_hv_pci_bus(). Signed-off-by: Long Li <lon...@microsoft.com> Reported-by: Xiaofeng Wang <xiaof...@redhat.com> Acked-by: K. Y. Srinivasan <k...@microsoft.com> --- drivers/pci/host/pci-hyperv.c | 4

RE: [Resend PATCH 2/2 v3] pci-hyperv: lock pci bus on device eject

2017-02-27 Thread Long Li
Ok, I will resend. > -Original Message- > From: Greg KH [mailto:g...@kroah.com] > Sent: Saturday, February 25, 2017 12:02 AM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; Bjorn

[PATCH 2/3] storvsc: properly handle SRB_ERROR when sense message is present

2016-09-06 Thread Long Li
From: Long Li <lon...@microsoft.com> When sense message is present on error, we should pass along to the upper layer to decide how to deal with the error. This patch fixes connectivity issues with Fiber Channel devices. --- drivers/scsi/storvsc_drv.c | 3 +++ 1 file changed, 3 inse

[PATCH 0/3] storvsc: fixes issues on Fiber Channel

2016-09-06 Thread Long Li
From: Long Li <lon...@microsoft.com> This patch set fixes connectivity issues and improves performance for Fiber Channel disks. Long Li (3): Use tagged SRB requests if supported by the device Properly handle SRB_ERROR when sense message is present Use block layer default segmen

[PATCH 3/3] storvsc: use block layer default segment size

2016-09-06 Thread Long Li
From: Long Li <lon...@microsoft.com> We no long have the restriction of page size limit in the SG list. Remove it. The driver can properly handle default block segment size. --- drivers/scsi/storvsc_drv.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/scsi/storvsc_d

[PATCH 1/3] storvsc: use tagged SRB requests if supported by the device

2016-09-06 Thread Long Li
From: Long Li <lon...@microsoft.com> Properly set SRB flags when hosting device supports tagged queuing. This patch improves the performance on Fiber Channel disks. --- drivers/scsi/storvsc_drv.c | 8 1 file changed, 8 insertions(+) diff --git a/drivers/scsi/storvsc_drv.c b/d

RE: [PATCH 2/2] pci-hyperv: properly handle device eject

2016-09-13 Thread Long Li
> -Original Message- > From: Dexuan Cui > Sent: Tuesday, September 13, 2016 2:51 AM > To: Long Li <lon...@microsoft.com>; KY Srinivasan <k...@microsoft.com>; > Haiyang Zhang <haiya...@microsoft.com>; Bjorn Helgaas > <bhelg...@google.com> > C

RE: [PATCH 2/2] pci-hyperv: properly handle device eject

2016-09-13 Thread Long Li
> -Original Message- > From: devel [mailto:driverdev-devel-boun...@linuxdriverproject.org] On > Behalf Of Long Li > Sent: Tuesday, September 13, 2016 10:33 AM > To: Dexuan Cui <de...@microsoft.com>; KY Srinivasan > <k...@microsoft.com>; Haiyang Zhang &

RE: [PATCH 2/2] pci-hyperv: properly handle device eject

2016-09-14 Thread Long Li
> -Original Message- > From: Dexuan Cui > Sent: Tuesday, September 13, 2016 10:45 PM > To: Long Li <lon...@microsoft.com>; KY Srinivasan <k...@microsoft.com>; > Haiyang Zhang <haiya...@microsoft.com>; Bjorn Helgaas > <bhelg...@google.com> > C

[PATCH 2/2 v2] pci-hyperv: lock pci bus on device eject

2016-09-14 Thread Long Li
From: Long Li <lon...@microsoft.com> A PCI_EJECT message can arrive at the same time we are calling pci_scan_child_bus in the workqueue for the previous PCI_BUS_RELATIONS message or in create_root_hv_pci_bus(), in this case we could potentailly modify the bus from multiple places. Pr

[PATCH 1/2 v2] pci-hyperv: properly handle pci bus remove

2016-09-14 Thread Long Li
From: Long Li <lon...@microsoft.com> hv_pci_devices_present is called in hv_pci_remove when we remove a PCI device from host (e.g. by disabling SRIOV on a device). In hv_pci_remove, the bus is already removed before the call, so we don't need to rescan the bus in the workqueue schedule

[PATCH 1/2] pci-hyperv: properly handle pci bus remove

2016-09-12 Thread Long Li
From: Long Li <lon...@microsoft.com> hv_pci_devices_present is called in hv_pci_remove when we remove a PCI device from host (e.g. by disabling SRIOV on a device). In hv_pci_remove, the bus is already removed before the call, so we don't need to rescan the bus in the workqueue schedule

[PATCH 2/2] pci-hyperv: properly handle device eject

2016-09-12 Thread Long Li
From: Long Li <lon...@microsoft.com> A PCI_EJECT message can arrive at the same time we are calling pci_scan_child_bus in the workqueue for the previous PCI_BUS_RELATIONS message, in this case we could potentailly modify the bus from two places. Properly lock the bus access. Sign

[PATCH] hv: do not lose pending heartbeat vmbus packets

2016-09-12 Thread Long Li
From: Long Li <lon...@microsoft.com> The host keeps sending heartbeat packets independent of guest responding to them. In some situations, there might be multiple heartbeat packets pending in the ring buffer. Don't lose them, read them all. Signed-off-by: Long Li <lon...@micr

RE: [PATCH 1/3] storvsc: use tagged SRB requests if supported by the device

2016-09-07 Thread Long Li
> -Original Message- > From: Johannes Thumshirn [mailto:jthumsh...@suse.de] > Sent: Wednesday, September 7, 2016 12:47 AM > To: Long Li <lon...@exchange.microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsof

RE: [PATCH 1/2 v2] pci-hyperv: properly handle pci bus remove

2016-09-27 Thread Long Li
> -Original Message- > From: Bjorn Helgaas [mailto:helg...@kernel.org] > Sent: Tuesday, September 27, 2016 12:30 PM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; Bjorn

RE: [PATCH] hv: do not lose pending heartbeat vmbus packets

2016-09-30 Thread Long Li
> -Original Message- > From: Vitaly Kuznetsov [mailto:vkuzn...@redhat.com] > Sent: Thursday, September 29, 2016 2:22 AM > To: KY Srinivasan <k...@microsoft.com>; Long Li <lon...@microsoft.com> > Cc: Haiyang Zhang <haiya...@microsoft.com>; > de...@

[PATCH 1/2 v3] pci-hyperv: properly handle pci bus remove

2016-10-03 Thread Long Li
From: Long Li <lon...@microsoft.com> hv_pci_devices_present is called in hv_pci_remove when we remove a PCI device from host (e.g. by disabling SRIOV on a device). In hv_pci_remove, the bus is already removed before the call, so we don't need to rescan the bus in the workqueue schedule

[PATCH 2/2 v3] pci-hyperv: lock pci bus on device eject

2016-10-03 Thread Long Li
From: Long Li <lon...@microsoft.com> A PCI_EJECT message can arrive at the same time we are calling pci_scan_child_bus in the workqueue for the previous PCI_BUS_RELATIONS message or in create_root_hv_pci_bus(), in this case we could potentailly modify the bus from multiple places. Pr

[PATCH] pci-hyperv: use kmalloc to allocate hypercall params buffer

2016-11-08 Thread Long Li
From: Long Li <lon...@microsoft.com> hv_do_hypercall assumes that we pass a segment from a physically continuous buffer. Buffer allocated on the stack may not work if CONFIG_VMAP_STACK=y is set. Change to use kmalloc to allocate this buffer. The v2 patch adds locking to access the pre-all

RE: [Resend] [PATCH] pci-hyperv: use kmalloc to allocate hypercall params buffer

2016-11-08 Thread Long Li
> -Original Message- > From: Greg KH [mailto:gre...@linuxfoundation.org] > Sent: Monday, November 7, 2016 11:00 PM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; Bjorn

RE: [Resend] [PATCH] pci-hyperv: use kmalloc to allocate hypercall params buffer

2016-11-08 Thread Long Li
> -Original Message- > From: devel [mailto:driverdev-devel-boun...@linuxdriverproject.org] On > Behalf Of Long Li > Sent: Tuesday, November 8, 2016 8:57 AM > To: Greg KH <gre...@linuxfoundation.org> > Cc: linux-...@vger.kernel.org; Haiyang Zhang <haiya...@mic

[Resend] [PATCH] pci-hyperv: use kmalloc to allocate hypercall params buffer

2016-11-07 Thread Long Li
From: Long Li <lon...@microsoft.com> hv_do_hypercall assumes that we pass a segment from a physically continuous buffer. Buffer allocated on the stack may not work if CONFIG_VMAP_STACK=y is set. Use kmalloc to allocate this buffer. Signed-off-by: Long Li <lon...@microsoft.com&

[PATCH] pci-hyperv: move hypercall buffer from stack to heap

2016-11-01 Thread Long Li
From: Long Li <lon...@microsoft.com> We need to pass a segment from a physically continuous buffer to hv_do_hypercall. Buffer allocated on the stack may not work if CONFIG_VMAP_STACK=y is set. Moving the params buffer from stack to buffer returned by kmalloc. Signed-off-by: Long L

RE: [PATCH 1/2 v3] pci-hyperv: properly handle pci bus remove

2017-01-09 Thread Long Li
Hi Bjorn This patch is still pending. The patch has been ack'ed. Do you want me to resend this patch? Thanks Long > -Original Message- > From: KY Srinivasan > Sent: Friday, November 11, 2016 2:21 PM > To: Bjorn Helgaas <helg...@kernel.org>; Long Li <lon...@microso

RE: [PATCH 2/2 v3] pci-hyperv: lock pci bus on device eject

2017-01-09 Thread Long Li
Hi Bjorn, The patch is still pending (along with 1/2 v3). Please let me know if you want me to resend the two patches. Thanks Long > -Original Message- > From: KY Srinivasan > Sent: Tuesday, October 4, 2016 1:49 PM > To: Long Li <lon...@microsoft.com>; Haiy

RE: [PATCH] pci-hyperv: use kmalloc to allocate hypercall params buffer

2016-12-05 Thread Long Li
> -Original Message- > From: Stephen Hemminger [mailto:step...@networkplumber.org] > Sent: Monday, December 5, 2016 8:53 AM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; Bjorn

[PATCH] hv: use substraction to update ring buffer index

2017-01-04 Thread Long Li
From: Long Li <lon...@microsoft.com> The ring buffer code uses %= to calculate index. For x86/64, %= compiles to div, more than 10 times slower than sub. Replace div with sub for this data heavy code path. Signed-off-by: Long Li <lon...@microsoft.com> --- drivers/hv/ring_

[PATCH v2] hv: retry infinitely on hypercall transient failures

2017-01-04 Thread Long Li
From: Long Li <lon...@microsoft.com> Hyper-v host guarantees that a hypercall will finish in reasonable time. Retry infinitely on transient failures to avoid returning error to upper layer. Signed-off-by: Long Li <lon...@microsoft.com> --- drivers/hv/conne

[PATCH] Retry infinitely for hypercall

2017-01-04 Thread Long Li
From: Long Li <lon...@microsoft.com> Hyper-v host guarantees that a hypercall will succeed. Retry infinitely to avoid returning transient failures to upper layer. Signed-off-by: Long Li <lon...@microsoft.com> --- drivers/hv/connection.c | 17 - 1 file changed,

RE: [PATCH] Retry infinitely for hypercall

2017-01-04 Thread Long Li
> -Original Message- > From: Greg KH [mailto:g...@kroah.com] > Sent: Wednesday, January 4, 2017 12:51 PM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; de...@linuxdriverproject.

RE: [PATCH] Retry infinitely for hypercall

2017-01-04 Thread Long Li
> -Original Message- > From: Dan Carpenter [mailto:dan.carpen...@oracle.com] > Sent: Wednesday, January 4, 2017 1:48 PM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; de...@

RE: [PATCH v2] hv: retry infinitely on hypercall transient failures

2017-01-06 Thread Long Li
> -Original Message- > From: Greg KH [mailto:g...@kroah.com] > Sent: Wednesday, January 04, 2017 11:48 PM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; de...@linuxdriverproject.

RE: [PATCH v2] hv: retry infinitely on hypercall transient failures

2017-01-07 Thread Long Li
> -Original Message- > From: Greg KH [mailto:g...@kroah.com] > Sent: Friday, January 06, 2017 11:43 PM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; de...@linuxdriverproject.

RE: [PATCH] hv: use substraction to update ring buffer index

2017-01-06 Thread Long Li
> -Original Message- > From: Dan Carpenter [mailto:dan.carpen...@oracle.com] > Sent: Thursday, January 05, 2017 3:40 AM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; de...@

[PATCH 1/2 v5] pci-hyperv: properly handle pci bus remove

2017-03-23 Thread Long Li
From: Long Li <lon...@microsoft.com> hv_pci_devices_present is called in hv_pci_remove when we remove a PCI device from host (e.g. by disabling SRIOV on a device). In hv_pci_remove, the bus is already removed before the call, so we don't need to rescan the bus in the workqueue schedule

[PATCH 2/2 v5] pci-hyperv: lock pci bus on device eject

2017-03-23 Thread Long Li
From: Long Li <lon...@microsoft.com> A PCI_EJECT message can arrive at the same time we are calling pci_scan_child_bus in the workqueue for the previous PCI_BUS_RELATIONS message or in create_root_hv_pci_bus(), in this case we could potentially modify the bus from multiple places. Properl

[PATCH v3] HV: properly delay KVP packets when negotiation is in progress

2017-03-24 Thread Long Li
From: Long Li <lon...@microsoft.com> The host may send multiple negotiation packets (due to timeout) before the KVP user-mode daemon is connected. We need to defer processing those packets until the daemon is negotiated and connected. It's okay for guest to respond to all negotiation p

RE: [PATCH v2] HV: properly delay KVP packets when negotiation is in progress

2017-03-23 Thread Long Li
> -Original Message- > From: Vitaly Kuznetsov [mailto:vkuzn...@redhat.com] > Sent: Thursday, March 23, 2017 9:04 AM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; Stephen Hemm

[PATCH v3] HV: properly delay KVP packets when negotiation is in progress

2017-03-24 Thread Long Li
From: Long Li <lon...@microsoft.com> The host may send multiple negotiation packets (due to timeout) before the KVP user-mode daemon is connected. We need to defer processing those packets until the daemon is negotiated and connected. It's okay for guest to respond to all negotiation p

RE: [PATCH 2/2] pci-hyperv: Fix an atomic bug

2017-03-27 Thread Long Li
omic bug > > From: K. Y. Srinivasan <k...@microsoft.com> > > The memory allocation here needs to be non-blocking. > Fix the issue. > > Signed-off-by: K. Y. Srinivasan <k...@microsoft.com> > Cc: <sta...@vger.kernel.org> Reviewed-by: Long Li <lon...@mi

RE: [PATCH 1/2] pci-hyperv: Fix a bug in specifying CPU affinity

2017-03-27 Thread Long Li
in specifying CPU affinity > > From: K. Y. Srinivasan <k...@microsoft.com> > > When we have 32 or more CPUs in the affinity mask, we should use a special > constant to specify that to the host. Fix this issue. > > Signed-off-by: K. Y. Srinivasan <k...@mic

[PATCH v2] HV: properly delay KVP packets when negotiation is in progress

2017-03-22 Thread Long Li
<vkuzn...@redhat.com>. Signed-off-by: Long Li <lon...@microsoft.com> --- drivers/hv/hv_kvp.c | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/drivers/hv/hv_kvp.c b/drivers/hv/hv_kvp.c index de26371..845b70b 100644 --- a/drivers/hv/hv_kvp.c +++ b/d

RE: [PATCH 1/2 v4] pci-hyperv: properly handle pci bus remove

2017-03-22 Thread Long Li
> -Original Message- > From: Bjorn Helgaas [mailto:helg...@kernel.org] > Sent: Thursday, March 16, 2017 1:07 PM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; Bjorn

RE: [PATCH] HV: properly delay KVP packets when negotiation is in progress

2017-03-20 Thread Long Li
> -Original Message- > From: Long Li > Sent: Sunday, March 19, 2017 7:49 PM > To: 'Vitaly Kuznetsov' <vkuzn...@redhat.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; Stephen Hemminger > <sthem...@microsoft

RE: [PATCH] HV: properly delay KVP packets when negotiation is in progress

2017-03-19 Thread Long Li
> -Original Message- > From: Vitaly Kuznetsov [mailto:vkuzn...@redhat.com] > Sent: Friday, March 17, 2017 9:16 AM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; Stephen Hemm

[PATCH] HV: properly delay KVP packets when negotiation is in progress

2017-03-16 Thread Long Li
The host may send multiple KVP packets before the negotiation with daemon is finished. We need to keep those packets in ring buffer until the daemon is negotiated and connected. This patch is based on the work of Nick Meier <nick.me...@microsoft.com> Signed-off-by: Long Li <lon...@micr

RE: [PATCH 1/2 v4] pci-hyperv: properly handle pci bus remove

2017-03-16 Thread Long Li
> -Original Message- > From: Bjorn Helgaas [mailto:helg...@kernel.org] > Sent: Thursday, March 16, 2017 1:07 PM > To: Long Li <lon...@microsoft.com> > Cc: KY Srinivasan <k...@microsoft.com>; Haiyang Zhang > <haiya...@microsoft.com>; Bjorn

RE: [PATCH] block-mq: set both block queue and hardware queue restart bit for restart

2017-04-05 Thread Long Li
> -Original Message- > From: Bart Van Assche [mailto:bart.vanass...@sandisk.com] > Sent: Wednesday, April 5, 2017 5:32 PM > To: linux-kernel@vger.kernel.org; linux-bl...@vger.kernel.org; Long Li > <lon...@microsoft.com>; ax...@kernel.dk > Cc: Stephen Hemminger

RE: [PATCH] block-mq: set both block queue and hardware queue restart bit for restart

2017-04-05 Thread Long Li
> -Original Message- > From: KY Srinivasan > Sent: Wednesday, April 5, 2017 9:21 PM > To: Bart Van Assche <bart.vanass...@sandisk.com>; linux- > ker...@vger.kernel.org; linux-bl...@vger.kernel.org; Long Li > <lon...@microsoft.com>; ax...@kernel.dk

RE: [PATCH] block-mq: set both block queue and hardware queue restart bit for restart

2017-04-13 Thread Long Li
> -Original Message- > From: Bart Van Assche [mailto:bart.vanass...@sandisk.com] > Sent: Monday, April 10, 2017 4:48 PM > To: linux-kernel@vger.kernel.org; linux-bl...@vger.kernel.org; KY Srinivasan > <k...@microsoft.com>; Long Li <lon...@microsoft.com>; ax

[PATCH] block-mq: set both block queue and hardware queue restart bit for restart

2017-04-05 Thread Long Li
From: Long Li <lon...@microsoft.com> Under heavy I/O, one hardware queue may be unable to dispatch any I/O to the device layer. This poses a problem with restarting this hardware queue on I/O finish in blk_mq_sched_restart_queues(), becaue there is nothing pending that will finish in

[[PATCH v1] 15/37] [CIFS] SMBD: Post a SMBD data transfer message with data payload

2017-08-02 Thread Long Li
From: Long Li <lon...@microsoft.com> Similar to sending transfer message with page payload, this function creates a SMBD data packet and send it over to RDMA, from iov passed from upper layer. Signed-off-by: Long Li <lon...@microsoft.com> --- fs/cifs/cifs

[[PATCH v1] 05/37] [CIFS] SMBD: Implement API for upper layer to create SMBD transport and establish RDMA connection

2017-08-02 Thread Long Li
From: Long Li <lon...@microsoft.com> Implement the code for connecting to SMBD server. The client and server are connected using RC Queue Pair over RDMA API, which suppports Infiniband, RoCE and iWARP. Upper layer code can call cifs_create_rdma_session to establish a SMBD RDMA conn

[[PATCH v1] 02/37] [CIFS] SMBD: Add structure for SMBD transport

2017-08-02 Thread Long Li
From: Long Li <lon...@microsoft.com> Define a new structure for SMBD transport. This stucture will have all the information on the transport, and it will be stored in the current SMB session. Signed-off-by: Long Li <lon...@microsoft.com> --- fs/cifs/cif

[[PATCH v1] 08/37] [CIFS] SMBD: Define packet format for SMBD data transfer message

2017-08-02 Thread Long Li
From: Long Li <lon...@microsoft.com> Define the packet format for a SMBD data packet with payload Signed-off-by: Long Li <lon...@microsoft.com> --- fs/cifs/cifsrdma.h | 15 +++ 1 file changed, 15 insertions(+) diff --git a/fs/cifs/cifsrdma.h b/fs/cifs/cifsrdma.h i

[[PATCH v1] 04/37] [CIFS] SMBD: Define per-channel SMBD transport parameters and default values

2017-08-02 Thread Long Li
From: Long Li <lon...@microsoft.com> For each channel, SMBD defines per-channel parameters. Those can be negotiated with the server, and are restricted by RDMA hardware limitations. Signed-off-by: Long Li <lon...@microsoft.com> --- fs/cifs/cifsrdma.c | 14 ++ fs/cif

[[PATCH v1] 19/37] [CIFS] SMBD: Manage credits on SMBD client and server

2017-08-02 Thread Long Li
From: Long Li <lon...@microsoft.com> SMB client and server maintain a credit system on the SMBD transport. Credits are used to tell when the client or server can send a packet to the peer, based on current memory or resource usage. Signed-off-by: Long Li <lon...@microsoft.com>

[[PATCH v1] 00/37] Implement SMBD protocol: Series 1

2017-08-02 Thread Long Li
From: Long Li <lon...@microsoft.com> SMB3 defines a protocol for transfer data over RDMA transport such as Infiniband, RoCE and iWARP. The prococol is published in [MS-SMBD] (https://msdn.microsoft.com/en-us/library/hh536346.aspx). This is the series 1 of two patch sets. This pat

[[PATCH v1] 06/37] [CIFS] SMBD: Add definition and cache for SMBD response

2017-08-02 Thread Long Li
From: Long Li <lon...@microsoft.com> Define the data structure for receiving a SMBD response. SMBD responses are allocated through a per-channel mempool. For each server initiated response message, the SMB client must post a SMBD response to the local hardware. Signed-off-by: Long L

[[PATCH v1] 01/37] [CIFS] SMBD: Add parsing for new rdma mount option

2017-08-02 Thread Long Li
From: Long Li <lon...@microsoft.com> When doing mount with "-o rdma", user can specify this is for connecting to a SMBD session. Signed-off-by: Long Li <lon...@microsoft.com> --- fs/cifs/cifs_debug.c | 2 ++ fs/cifs/cifsfs.c | 2 ++ fs/cifs/cifsglob.h | 2 ++ fs/

[[PATCH v1] 18/37] [CIFS] SMBD: Implement API for upper layer to send data

2017-08-02 Thread Long Li
From: Long Li <lon...@microsoft.com> Implement cifs_rdma_write for send an upper layer data. Upper layer uses this function to do a RDMA send. This function is also used to pass SMB packets for doing a RDMA read/write via memory registration. Signed-off-by: Long Li <lon...@micr

  1   2   3   4   5   6   7   8   9   10   >