All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-24  6:54 ` Dexuan Cui
  0 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-24  6:54 UTC (permalink / raw)
  To: gregkh, driverdev-devel, KY Srinivasan, Haiyang Zhang, Stephen Hemminger
  Cc: Vitaly Kuznetsov, jasowang, apw, olaf, linux-kernel, Rolf Neugebauer


Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in hv_need_to_signal_on_read()")
added the proper mb(), but removed the test "prev_write_sz < pending_sz"
when making the signal decision.

As a result, the guest can signal the host unnecessarily,
and then the host can throttle the guest because the host
thinks the guest is buggy or malicious; finally the user
running stress test can perceive intermittent freeze of
the guest.

This patch brings back the test, and properly handles the
in-place consumption APIs used by NetVSC (see get_next_pkt_raw(),
put_pkt_raw() and commit_rd_index()).

Fixes: a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in hv_need_to_signal_on_read()")
Signed-off-by: Dexuan Cui <decui@microsoft.com>
Reported-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Tested-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Cc: "K. Y. Srinivasan" <kys@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Cc: Stephen Hemminger <sthemmin@microsoft.com>
Cc: <stable@vger.kernel.org>
---

The patch also changes drivers/net/hyperv/netvsc.c (Haiyang Zhang
and Stephen Hemminger have known about this patch).

This is a must, because only applying the VMBus changes will
break the netvsc driver, so the patch should go through the
char-misc tree as a whole.

The changes to netvsc.c are small enough, and hence there should be
no conflict.

 drivers/hv/ring_buffer.c    |  1 +
 drivers/net/hyperv/netvsc.c |  6 ++++++
 include/linux/hyperv.h      | 32 ++++++++++++++++++++++++++++++--
 3 files changed, 37 insertions(+), 2 deletions(-)

diff --git a/drivers/hv/ring_buffer.c b/drivers/hv/ring_buffer.c
index cd49cb1..308dbda 100644
--- a/drivers/hv/ring_buffer.c
+++ b/drivers/hv/ring_buffer.c
@@ -383,6 +383,7 @@ int hv_ringbuffer_read(struct vmbus_channel *channel,
 		return ret;
 	}
 
+	init_cached_read_index(channel);
 	next_read_location = hv_get_next_read_location(inring_info);
 	next_read_location = hv_copyfrom_ringbuffer(inring_info, &desc,
 						    sizeof(desc),
diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
index 5a1cc08..86e5749 100644
--- a/drivers/net/hyperv/netvsc.c
+++ b/drivers/net/hyperv/netvsc.c
@@ -1295,6 +1295,9 @@ void netvsc_channel_cb(void *context)
 	ndev = hv_get_drvdata(device);
 	buffer = get_per_channel_state(channel);
 
+	/* commit_rd_index() -> hv_signal_on_read() needs this. */
+	init_cached_read_index(channel);
+
 	do {
 		desc = get_next_pkt_raw(channel);
 		if (desc != NULL) {
@@ -1347,6 +1350,9 @@ void netvsc_channel_cb(void *context)
 
 			bufferlen = bytes_recvd;
 		}
+
+		init_cached_read_index(channel);
+
 	} while (1);
 
 	if (bufferlen > NETVSC_PACKET_SIZE)
diff --git a/include/linux/hyperv.h b/include/linux/hyperv.h
index 42fe43f..183efde 100644
--- a/include/linux/hyperv.h
+++ b/include/linux/hyperv.h
@@ -128,6 +128,7 @@ struct hv_ring_buffer_info {
 	u32 ring_data_startoffset;
 	u32 priv_write_index;
 	u32 priv_read_index;
+	u32 cached_read_index;
 };
 
 /*
@@ -180,6 +181,19 @@ static inline u32 hv_get_bytes_to_write(struct hv_ring_buffer_info *rbi)
 	return write;
 }
 
+static inline u32 hv_get_cached_bytes_to_write(
+	const struct hv_ring_buffer_info *rbi)
+{
+	u32 read_loc, write_loc, dsize, write;
+
+	dsize = rbi->ring_datasize;
+	read_loc = rbi->cached_read_index;
+	write_loc = rbi->ring_buffer->write_index;
+
+	write = write_loc >= read_loc ? dsize - (write_loc - read_loc) :
+		read_loc - write_loc;
+	return write;
+}
 /*
  * VMBUS version is 32 bit entity broken up into
  * two 16 bit quantities: major_number. minor_number.
@@ -1488,7 +1502,7 @@ hv_get_ring_buffer(struct hv_ring_buffer_info *ring_info)
 
 static inline  void hv_signal_on_read(struct vmbus_channel *channel)
 {
-	u32 cur_write_sz;
+	u32 cur_write_sz, cached_write_sz;
 	u32 pending_sz;
 	struct hv_ring_buffer_info *rbi = &channel->inbound;
 
@@ -1512,12 +1526,24 @@ static inline  void hv_signal_on_read(struct vmbus_channel *channel)
 
 	cur_write_sz = hv_get_bytes_to_write(rbi);
 
-	if (cur_write_sz >= pending_sz)
+	if (cur_write_sz < pending_sz)
+		return;
+
+	cached_write_sz = hv_get_cached_bytes_to_write(rbi);
+	if (cached_write_sz < pending_sz)
 		vmbus_setevent(channel);
 
 	return;
 }
 
+static inline void
+init_cached_read_index(struct vmbus_channel *channel)
+{
+	struct hv_ring_buffer_info *rbi = &channel->inbound;
+
+	rbi->cached_read_index = rbi->ring_buffer->read_index;
+}
+
 /*
  * An API to support in-place processing of incoming VMBUS packets.
  */
@@ -1569,6 +1595,8 @@ static inline void put_pkt_raw(struct vmbus_channel *channel,
  * This call commits the read index and potentially signals the host.
  * Here is the pattern for using the "in-place" consumption APIs:
  *
+ * init_cached_read_index();
+ *
  * while (get_next_pkt_raw() {
  *	process the packet "in-place";
  *	put_pkt_raw();
-- 
2.1.0

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

* [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-24  6:54 ` Dexuan Cui
  0 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-24  6:54 UTC (permalink / raw)
  To: gregkh, driverdev-devel, KY Srinivasan, Haiyang Zhang, Stephen Hemminger
  Cc: Vitaly Kuznetsov, jasowang, apw, olaf, linux-kernel, Rolf Neugebauer


Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in hv_need_to_signal_on_read()")
added the proper mb(), but removed the test "prev_write_sz < pending_sz"
when making the signal decision.

As a result, the guest can signal the host unnecessarily,
and then the host can throttle the guest because the host
thinks the guest is buggy or malicious; finally the user
running stress test can perceive intermittent freeze of
the guest.

This patch brings back the test, and properly handles the
in-place consumption APIs used by NetVSC (see get_next_pkt_raw(),
put_pkt_raw() and commit_rd_index()).

Fixes: a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in hv_need_to_signal_on_read()")
Signed-off-by: Dexuan Cui <decui@microsoft.com>
Reported-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Tested-by: Rolf Neugebauer <rolf.neugebauer@docker.com>
Cc: "K. Y. Srinivasan" <kys@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Cc: Stephen Hemminger <sthemmin@microsoft.com>
Cc: <stable@vger.kernel.org>
---

The patch also changes drivers/net/hyperv/netvsc.c (Haiyang Zhang
and Stephen Hemminger have known about this patch).

This is a must, because only applying the VMBus changes will
break the netvsc driver, so the patch should go through the
char-misc tree as a whole.

The changes to netvsc.c are small enough, and hence there should be
no conflict.

 drivers/hv/ring_buffer.c    |  1 +
 drivers/net/hyperv/netvsc.c |  6 ++++++
 include/linux/hyperv.h      | 32 ++++++++++++++++++++++++++++++--
 3 files changed, 37 insertions(+), 2 deletions(-)

diff --git a/drivers/hv/ring_buffer.c b/drivers/hv/ring_buffer.c
index cd49cb1..308dbda 100644
--- a/drivers/hv/ring_buffer.c
+++ b/drivers/hv/ring_buffer.c
@@ -383,6 +383,7 @@ int hv_ringbuffer_read(struct vmbus_channel *channel,
 		return ret;
 	}
 
+	init_cached_read_index(channel);
 	next_read_location = hv_get_next_read_location(inring_info);
 	next_read_location = hv_copyfrom_ringbuffer(inring_info, &desc,
 						    sizeof(desc),
diff --git a/drivers/net/hyperv/netvsc.c b/drivers/net/hyperv/netvsc.c
index 5a1cc08..86e5749 100644
--- a/drivers/net/hyperv/netvsc.c
+++ b/drivers/net/hyperv/netvsc.c
@@ -1295,6 +1295,9 @@ void netvsc_channel_cb(void *context)
 	ndev = hv_get_drvdata(device);
 	buffer = get_per_channel_state(channel);
 
+	/* commit_rd_index() -> hv_signal_on_read() needs this. */
+	init_cached_read_index(channel);
+
 	do {
 		desc = get_next_pkt_raw(channel);
 		if (desc != NULL) {
@@ -1347,6 +1350,9 @@ void netvsc_channel_cb(void *context)
 
 			bufferlen = bytes_recvd;
 		}
+
+		init_cached_read_index(channel);
+
 	} while (1);
 
 	if (bufferlen > NETVSC_PACKET_SIZE)
diff --git a/include/linux/hyperv.h b/include/linux/hyperv.h
index 42fe43f..183efde 100644
--- a/include/linux/hyperv.h
+++ b/include/linux/hyperv.h
@@ -128,6 +128,7 @@ struct hv_ring_buffer_info {
 	u32 ring_data_startoffset;
 	u32 priv_write_index;
 	u32 priv_read_index;
+	u32 cached_read_index;
 };
 
 /*
@@ -180,6 +181,19 @@ static inline u32 hv_get_bytes_to_write(struct hv_ring_buffer_info *rbi)
 	return write;
 }
 
+static inline u32 hv_get_cached_bytes_to_write(
+	const struct hv_ring_buffer_info *rbi)
+{
+	u32 read_loc, write_loc, dsize, write;
+
+	dsize = rbi->ring_datasize;
+	read_loc = rbi->cached_read_index;
+	write_loc = rbi->ring_buffer->write_index;
+
+	write = write_loc >= read_loc ? dsize - (write_loc - read_loc) :
+		read_loc - write_loc;
+	return write;
+}
 /*
  * VMBUS version is 32 bit entity broken up into
  * two 16 bit quantities: major_number. minor_number.
@@ -1488,7 +1502,7 @@ hv_get_ring_buffer(struct hv_ring_buffer_info *ring_info)
 
 static inline  void hv_signal_on_read(struct vmbus_channel *channel)
 {
-	u32 cur_write_sz;
+	u32 cur_write_sz, cached_write_sz;
 	u32 pending_sz;
 	struct hv_ring_buffer_info *rbi = &channel->inbound;
 
@@ -1512,12 +1526,24 @@ static inline  void hv_signal_on_read(struct vmbus_channel *channel)
 
 	cur_write_sz = hv_get_bytes_to_write(rbi);
 
-	if (cur_write_sz >= pending_sz)
+	if (cur_write_sz < pending_sz)
+		return;
+
+	cached_write_sz = hv_get_cached_bytes_to_write(rbi);
+	if (cached_write_sz < pending_sz)
 		vmbus_setevent(channel);
 
 	return;
 }
 
+static inline void
+init_cached_read_index(struct vmbus_channel *channel)
+{
+	struct hv_ring_buffer_info *rbi = &channel->inbound;
+
+	rbi->cached_read_index = rbi->ring_buffer->read_index;
+}
+
 /*
  * An API to support in-place processing of incoming VMBUS packets.
  */
@@ -1569,6 +1595,8 @@ static inline void put_pkt_raw(struct vmbus_channel *channel,
  * This call commits the read index and potentially signals the host.
  * Here is the pattern for using the "in-place" consumption APIs:
  *
+ * init_cached_read_index();
+ *
  * while (get_next_pkt_raw() {
  *	process the packet "in-place";
  *	put_pkt_raw();
-- 
2.1.0

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-24  6:54 ` Dexuan Cui
@ 2017-01-24 16:08   ` Stephen Hemminger
  -1 siblings, 0 replies; 28+ messages in thread
From: Stephen Hemminger @ 2017-01-24 16:08 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: gregkh, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

On Tue, 24 Jan 2017 06:54:46 +0000
Dexuan Cui <decui@microsoft.com> wrote:

> +static inline void
> +init_cached_read_index(struct vmbus_channel *channel)
> +{
> +	struct hv_ring_buffer_info *rbi = &channel->inbound;
> +
> +	rbi->cached_read_index = rbi->ring_buffer->read_index;
> +}

Looks good thanks. This should go in right away. Which versions are impacted?
Should it also go to stable?

In a future patch, the API function names for interacting with the ring buffer
should be changed to all have common prefix (hv_) and maybe do a little rethinking
about what needs to be in ring buffer and what could be local variables.

For example, the cached_read_index is only useful over the span of the loop
reading from the ring buffer. For me, it would be cleaner with a ring_buffer
iterator object which could abstract the API better. 

	struct vmbus_ringbuffer_iter iter;

	vmbus_begin_read(&iter, channel);
	while ((desc = vmbus_next_read(&iter), channel) {
	    ...
	}
	vmbus_end_read(&iter, channel);

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-24 16:08   ` Stephen Hemminger
  0 siblings, 0 replies; 28+ messages in thread
From: Stephen Hemminger @ 2017-01-24 16:08 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: gregkh, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

On Tue, 24 Jan 2017 06:54:46 +0000
Dexuan Cui <decui@microsoft.com> wrote:

> +static inline void
> +init_cached_read_index(struct vmbus_channel *channel)
> +{
> +	struct hv_ring_buffer_info *rbi = &channel->inbound;
> +
> +	rbi->cached_read_index = rbi->ring_buffer->read_index;
> +}

Looks good thanks. This should go in right away. Which versions are impacted?
Should it also go to stable?

In a future patch, the API function names for interacting with the ring buffer
should be changed to all have common prefix (hv_) and maybe do a little rethinking
about what needs to be in ring buffer and what could be local variables.

For example, the cached_read_index is only useful over the span of the loop
reading from the ring buffer. For me, it would be cleaner with a ring_buffer
iterator object which could abstract the API better. 

	struct vmbus_ringbuffer_iter iter;

	vmbus_begin_read(&iter, channel);
	while ((desc = vmbus_next_read(&iter), channel) {
	    ...
	}
	vmbus_end_read(&iter, channel);

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-24 16:08   ` Stephen Hemminger
@ 2017-01-26  6:10     ` Dexuan Cui
  -1 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26  6:10 UTC (permalink / raw)
  To: Stephen Hemminger
  Cc: gregkh, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: Stephen Hemminger [mailto:stephen@networkplumber.org]
> Sent: Wednesday, January 25, 2017 00:08
> To: Dexuan Cui <decui@microsoft.com>
> Cc: gregkh@linuxfoundation.org; driverdev-devel@linuxdriverproject.org; KY
> Srinivasan <kys@microsoft.com>; Haiyang Zhang <haiyangz@microsoft.com>;
> Stephen Hemminger <sthemmin@microsoft.com>; olaf@aepfle.de; Rolf
> Neugebauer <rolf.neugebauer@docker.com>; jasowang@redhat.com; linux-
> kernel@vger.kernel.org; apw@canonical.com
> Subject: Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
> 
> On Tue, 24 Jan 2017 06:54:46 +0000
> Dexuan Cui <decui@microsoft.com> wrote:
> 
> > +static inline void
> > +init_cached_read_index(struct vmbus_channel *channel)
> > +{
> > +	struct hv_ring_buffer_info *rbi = &channel->inbound;
> > +
> > +	rbi->cached_read_index = rbi->ring_buffer->read_index;
> > +}
> 
> Looks good thanks. This should go in right away. Which versions are impacted?
> Should it also go to stable?

Yes, it needs to go to stable.
I have Cc-ed  <stable@vger.kernel.org> in the patch's changelog, so it should be
included in the stable tree automatically.

As I checked against the kernels listed on the homapage of www.kernel.org, the
below versions are impacted:
v3.16.39
v3.18.47
v4.1.38
v4.8.17
v4.9.5
v4.10-rc5

It's interesting v4.4.44 is not impacted, but actually it needs both the 2 patches:
i.e. this patch, and the previous one:
Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in hv_need_to_signal_on_read()")

> In a future patch, the API function names for interacting with the ring buffer
> should be changed to all have common prefix (hv_) and maybe do a little
> rethinking  about what needs to be in ring buffer and what could be local variables.
> 
> For example, the cached_read_index is only useful over the span of the loop
> reading from the ring buffer. For me, it would be cleaner with a ring_buffer
> iterator object which could abstract the API better.
> 
> 	struct vmbus_ringbuffer_iter iter;
> 
> 	vmbus_begin_read(&iter, channel);
> 	while ((desc = vmbus_next_read(&iter), channel) {
> 	    ...
> 	}
> 	vmbus_end_read(&iter, channel);

I agree. Please help to clean all these up.  :-)

Thanks,
-- Dexuan

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26  6:10     ` Dexuan Cui
  0 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26  6:10 UTC (permalink / raw)
  To: Stephen Hemminger
  Cc: gregkh, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: Stephen Hemminger [mailto:stephen@networkplumber.org]
> Sent: Wednesday, January 25, 2017 00:08
> To: Dexuan Cui <decui@microsoft.com>
> Cc: gregkh@linuxfoundation.org; driverdev-devel@linuxdriverproject.org; KY
> Srinivasan <kys@microsoft.com>; Haiyang Zhang <haiyangz@microsoft.com>;
> Stephen Hemminger <sthemmin@microsoft.com>; olaf@aepfle.de; Rolf
> Neugebauer <rolf.neugebauer@docker.com>; jasowang@redhat.com; linux-
> kernel@vger.kernel.org; apw@canonical.com
> Subject: Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
> 
> On Tue, 24 Jan 2017 06:54:46 +0000
> Dexuan Cui <decui@microsoft.com> wrote:
> 
> > +static inline void
> > +init_cached_read_index(struct vmbus_channel *channel)
> > +{
> > +	struct hv_ring_buffer_info *rbi = &channel->inbound;
> > +
> > +	rbi->cached_read_index = rbi->ring_buffer->read_index;
> > +}
> 
> Looks good thanks. This should go in right away. Which versions are impacted?
> Should it also go to stable?

Yes, it needs to go to stable.
I have Cc-ed  <stable@vger.kernel.org> in the patch's changelog, so it should be
included in the stable tree automatically.

As I checked against the kernels listed on the homapage of www.kernel.org, the
below versions are impacted:
v3.16.39
v3.18.47
v4.1.38
v4.8.17
v4.9.5
v4.10-rc5

It's interesting v4.4.44 is not impacted, but actually it needs both the 2 patches:
i.e. this patch, and the previous one:
Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in hv_need_to_signal_on_read()")

> In a future patch, the API function names for interacting with the ring buffer
> should be changed to all have common prefix (hv_) and maybe do a little
> rethinking  about what needs to be in ring buffer and what could be local variables.
> 
> For example, the cached_read_index is only useful over the span of the loop
> reading from the ring buffer. For me, it would be cleaner with a ring_buffer
> iterator object which could abstract the API better.
> 
> 	struct vmbus_ringbuffer_iter iter;
> 
> 	vmbus_begin_read(&iter, channel);
> 	while ((desc = vmbus_next_read(&iter), channel) {
> 	    ...
> 	}
> 	vmbus_end_read(&iter, channel);

I agree. Please help to clean all these up.  :-)

Thanks,
-- Dexuan

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-26  6:10     ` Dexuan Cui
@ 2017-01-26  7:16       ` gregkh
  -1 siblings, 0 replies; 28+ messages in thread
From: gregkh @ 2017-01-26  7:16 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

On Thu, Jan 26, 2017 at 06:10:19AM +0000, Dexuan Cui wrote:
> > From: Stephen Hemminger [mailto:stephen@networkplumber.org]
> > Sent: Wednesday, January 25, 2017 00:08
> > To: Dexuan Cui <decui@microsoft.com>
> > Cc: gregkh@linuxfoundation.org; driverdev-devel@linuxdriverproject.org; KY
> > Srinivasan <kys@microsoft.com>; Haiyang Zhang <haiyangz@microsoft.com>;
> > Stephen Hemminger <sthemmin@microsoft.com>; olaf@aepfle.de; Rolf
> > Neugebauer <rolf.neugebauer@docker.com>; jasowang@redhat.com; linux-
> > kernel@vger.kernel.org; apw@canonical.com
> > Subject: Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
> > 
> > On Tue, 24 Jan 2017 06:54:46 +0000
> > Dexuan Cui <decui@microsoft.com> wrote:
> > 
> > > +static inline void
> > > +init_cached_read_index(struct vmbus_channel *channel)
> > > +{
> > > +	struct hv_ring_buffer_info *rbi = &channel->inbound;
> > > +
> > > +	rbi->cached_read_index = rbi->ring_buffer->read_index;
> > > +}
> > 
> > Looks good thanks. This should go in right away. Which versions are impacted?
> > Should it also go to stable?
> 
> Yes, it needs to go to stable.
> I have Cc-ed  <stable@vger.kernel.org> in the patch's changelog, so it should be
> included in the stable tree automatically.
> 
> As I checked against the kernels listed on the homapage of www.kernel.org, the
> below versions are impacted:
> v3.16.39
> v3.18.47
> v4.1.38
> v4.8.17
> v4.9.5
> v4.10-rc5
> 
> It's interesting v4.4.44 is not impacted, but actually it needs both the 2 patches:
> i.e. this patch, and the previous one:
> Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in hv_need_to_signal_on_read()")

That patch does not apply to the 4.4-stable tree, which is why it was
not included there.  If you feel it should be included, please provide a
backport and send it to the stable@vger.kernel.org mailing list.

thanks,

greg k-h

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26  7:16       ` gregkh
  0 siblings, 0 replies; 28+ messages in thread
From: gregkh @ 2017-01-26  7:16 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

On Thu, Jan 26, 2017 at 06:10:19AM +0000, Dexuan Cui wrote:
> > From: Stephen Hemminger [mailto:stephen@networkplumber.org]
> > Sent: Wednesday, January 25, 2017 00:08
> > To: Dexuan Cui <decui@microsoft.com>
> > Cc: gregkh@linuxfoundation.org; driverdev-devel@linuxdriverproject.org; KY
> > Srinivasan <kys@microsoft.com>; Haiyang Zhang <haiyangz@microsoft.com>;
> > Stephen Hemminger <sthemmin@microsoft.com>; olaf@aepfle.de; Rolf
> > Neugebauer <rolf.neugebauer@docker.com>; jasowang@redhat.com; linux-
> > kernel@vger.kernel.org; apw@canonical.com
> > Subject: Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
> > 
> > On Tue, 24 Jan 2017 06:54:46 +0000
> > Dexuan Cui <decui@microsoft.com> wrote:
> > 
> > > +static inline void
> > > +init_cached_read_index(struct vmbus_channel *channel)
> > > +{
> > > +	struct hv_ring_buffer_info *rbi = &channel->inbound;
> > > +
> > > +	rbi->cached_read_index = rbi->ring_buffer->read_index;
> > > +}
> > 
> > Looks good thanks. This should go in right away. Which versions are impacted?
> > Should it also go to stable?
> 
> Yes, it needs to go to stable.
> I have Cc-ed  <stable@vger.kernel.org> in the patch's changelog, so it should be
> included in the stable tree automatically.
> 
> As I checked against the kernels listed on the homapage of www.kernel.org, the
> below versions are impacted:
> v3.16.39
> v3.18.47
> v4.1.38
> v4.8.17
> v4.9.5
> v4.10-rc5
> 
> It's interesting v4.4.44 is not impacted, but actually it needs both the 2 patches:
> i.e. this patch, and the previous one:
> Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in hv_need_to_signal_on_read()")

That patch does not apply to the 4.4-stable tree, which is why it was
not included there.  If you feel it should be included, please provide a
backport and send it to the stable@vger.kernel.org mailing list.

thanks,

greg k-h

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-26  7:16       ` gregkh
@ 2017-01-26  7:44         ` Dexuan Cui
  -1 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26  7:44 UTC (permalink / raw)
  To: gregkh
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > Dexuan Cui <decui@microsoft.com> wrote:
> > As I checked against the kernels listed on the homapage,
> > the below versions are impacted:
> > v3.16.39
> > v3.18.47
> > v4.1.38
> > v4.8.17
> > v4.9.5
> > v4.10-rc5
> >
> > It's interesting v4.4.44 is not impacted, but actually it needs both the 2 patches:
> > i.e. this patch, and the previous one:
> > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> hv_need_to_signal_on_read()")
> 
> That patch does not apply to the 4.4-stable tree, which is why it was
> not included there.  If you feel it should be included, please provide a
> backport and send it to the stable@vger.kernel.org mailing list.
> 
> greg k-h

Thanks! I'll do the backport after this patch goes in the mainline.

Thanks,
-- Dexuan

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26  7:44         ` Dexuan Cui
  0 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26  7:44 UTC (permalink / raw)
  To: gregkh
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > Dexuan Cui <decui@microsoft.com> wrote:
> > As I checked against the kernels listed on the homapage,
> > the below versions are impacted:
> > v3.16.39
> > v3.18.47
> > v4.1.38
> > v4.8.17
> > v4.9.5
> > v4.10-rc5
> >
> > It's interesting v4.4.44 is not impacted, but actually it needs both the 2 patches:
> > i.e. this patch, and the previous one:
> > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> hv_need_to_signal_on_read()")
> 
> That patch does not apply to the 4.4-stable tree, which is why it was
> not included there.  If you feel it should be included, please provide a
> backport and send it to the stable@vger.kernel.org mailing list.
> 
> greg k-h

Thanks! I'll do the backport after this patch goes in the mainline.

Thanks,
-- Dexuan

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-26  7:44         ` Dexuan Cui
@ 2017-01-26  7:49           ` gregkh
  -1 siblings, 0 replies; 28+ messages in thread
From: gregkh @ 2017-01-26  7:49 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

On Thu, Jan 26, 2017 at 07:44:46AM +0000, Dexuan Cui wrote:
> > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > Dexuan Cui <decui@microsoft.com> wrote:
> > > As I checked against the kernels listed on the homapage,
> > > the below versions are impacted:
> > > v3.16.39
> > > v3.18.47
> > > v4.1.38
> > > v4.8.17
> > > v4.9.5
> > > v4.10-rc5
> > >
> > > It's interesting v4.4.44 is not impacted, but actually it needs both the 2 patches:
> > > i.e. this patch, and the previous one:
> > > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> > hv_need_to_signal_on_read()")
> > 
> > That patch does not apply to the 4.4-stable tree, which is why it was
> > not included there.  If you feel it should be included, please provide a
> > backport and send it to the stable@vger.kernel.org mailing list.
> > 
> > greg k-h
> 
> Thanks! I'll do the backport after this patch goes in the mainline.

Why wait?

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26  7:49           ` gregkh
  0 siblings, 0 replies; 28+ messages in thread
From: gregkh @ 2017-01-26  7:49 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: olaf, Stephen Hemminger, Rolf Neugebauer, Haiyang Zhang,
	driverdev-devel, linux-kernel, apw, jasowang

On Thu, Jan 26, 2017 at 07:44:46AM +0000, Dexuan Cui wrote:
> > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > Dexuan Cui <decui@microsoft.com> wrote:
> > > As I checked against the kernels listed on the homapage,
> > > the below versions are impacted:
> > > v3.16.39
> > > v3.18.47
> > > v4.1.38
> > > v4.8.17
> > > v4.9.5
> > > v4.10-rc5
> > >
> > > It's interesting v4.4.44 is not impacted, but actually it needs both the 2 patches:
> > > i.e. this patch, and the previous one:
> > > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> > hv_need_to_signal_on_read()")
> > 
> > That patch does not apply to the 4.4-stable tree, which is why it was
> > not included there.  If you feel it should be included, please provide a
> > backport and send it to the stable@vger.kernel.org mailing list.
> > 
> > greg k-h
> 
> Thanks! I'll do the backport after this patch goes in the mainline.

Why wait?
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-26  7:49           ` gregkh
@ 2017-01-26  8:27             ` Dexuan Cui
  -1 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26  8:27 UTC (permalink / raw)
  To: gregkh
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > > It's interesting v4.4.44 is not impacted, but actually it needs both the 2
> patches:
> > > > i.e. this patch, and the previous one:
> > > > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> > > hv_need_to_signal_on_read()")
> > >
> > > That patch does not apply to the 4.4-stable tree, which is why it was
> > > not included there.  If you feel it should be included, please provide a
> > > backport and send it to the stable@vger.kernel.org mailing list.
> > >
> > > greg k-h
> >
> > Thanks! I'll do the backport after this patch goes in the mainline.
> 
> Why wait?

I thought a patch must first appear in Linus's tree, before it can be
back-ported to the stable tree?

-- Dexuan

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26  8:27             ` Dexuan Cui
  0 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26  8:27 UTC (permalink / raw)
  To: gregkh
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > > It's interesting v4.4.44 is not impacted, but actually it needs both the 2
> patches:
> > > > i.e. this patch, and the previous one:
> > > > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> > > hv_need_to_signal_on_read()")
> > >
> > > That patch does not apply to the 4.4-stable tree, which is why it was
> > > not included there.  If you feel it should be included, please provide a
> > > backport and send it to the stable@vger.kernel.org mailing list.
> > >
> > > greg k-h
> >
> > Thanks! I'll do the backport after this patch goes in the mainline.
> 
> Why wait?

I thought a patch must first appear in Linus's tree, before it can be
back-ported to the stable tree?

-- Dexuan

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-26  8:27             ` Dexuan Cui
@ 2017-01-26  9:16               ` gregkh
  -1 siblings, 0 replies; 28+ messages in thread
From: gregkh @ 2017-01-26  9:16 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

On Thu, Jan 26, 2017 at 08:27:26AM +0000, Dexuan Cui wrote:
> > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > > > It's interesting v4.4.44 is not impacted, but actually it needs both the 2
> > patches:
> > > > > i.e. this patch, and the previous one:
> > > > > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> > > > hv_need_to_signal_on_read()")
> > > >
> > > > That patch does not apply to the 4.4-stable tree, which is why it was
> > > > not included there.  If you feel it should be included, please provide a
> > > > backport and send it to the stable@vger.kernel.org mailing list.
> > > >
> > > > greg k-h
> > >
> > > Thanks! I'll do the backport after this patch goes in the mainline.
> > 
> > Why wait?
> 
> I thought a patch must first appear in Linus's tree, before it can be
> back-ported to the stable tree?

Commit a389fcfd2cb5 _IS_ in Linus's tree, it was released in the 4.7-rc1
kernel, which happened in May of 2016.

thanks,

greg k-h

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26  9:16               ` gregkh
  0 siblings, 0 replies; 28+ messages in thread
From: gregkh @ 2017-01-26  9:16 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

On Thu, Jan 26, 2017 at 08:27:26AM +0000, Dexuan Cui wrote:
> > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > > > It's interesting v4.4.44 is not impacted, but actually it needs both the 2
> > patches:
> > > > > i.e. this patch, and the previous one:
> > > > > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> > > > hv_need_to_signal_on_read()")
> > > >
> > > > That patch does not apply to the 4.4-stable tree, which is why it was
> > > > not included there.  If you feel it should be included, please provide a
> > > > backport and send it to the stable@vger.kernel.org mailing list.
> > > >
> > > > greg k-h
> > >
> > > Thanks! I'll do the backport after this patch goes in the mainline.
> > 
> > Why wait?
> 
> I thought a patch must first appear in Linus's tree, before it can be
> back-ported to the stable tree?

Commit a389fcfd2cb5 _IS_ in Linus's tree, it was released in the 4.7-rc1
kernel, which happened in May of 2016.

thanks,

greg k-h

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-26  9:16               ` gregkh
@ 2017-01-26  9:31                 ` Dexuan Cui
  -1 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26  9:31 UTC (permalink / raw)
  To: gregkh
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > > > > It's interesting v4.4.44 is not impacted, but actually it needs both the 2
> > > patches:
> > > > > > i.e. this patch, and the previous one:
> > > > > > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> > > > > hv_need_to_signal_on_read()")
> > > > >
> > > > > That patch does not apply to the 4.4-stable tree, which is why it was
> > > > > not included there.  If you feel it should be included, please provide a
> > > > > backport and send it to the stable@vger.kernel.org mailing list.
> > > > >
> > > > > greg k-h
> > > >
> > > > Thanks! I'll do the backport after this patch goes in the mainline.
> > >
> > > Why wait?
> >
> > I thought a patch must first appear in Linus's tree, before it can be
> > back-ported to the stable tree?
> 
> Commit a389fcfd2cb5 _IS_ in Linus's tree, it was released in the 4.7-rc1
> kernel, which happened in May of 2016.
> 
> greg k-h

Sorry, it looks I didn't make it clear. :-)

v4.4.44 needs 2 patches, i.e. a389fcfd2cb5, and this patch (which is not in
Linus's tree yet).  Only backporting the first patch immediately is not enough
and is also improper IMO, because the first patch introduces a new issue,
which is being resolved by this patch. So my understanding is that I should
backport the 2 patches together.

Thanks,
-- Dexuan

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26  9:31                 ` Dexuan Cui
  0 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26  9:31 UTC (permalink / raw)
  To: gregkh
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > > > > It's interesting v4.4.44 is not impacted, but actually it needs both the 2
> > > patches:
> > > > > > i.e. this patch, and the previous one:
> > > > > > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> > > > > hv_need_to_signal_on_read()")
> > > > >
> > > > > That patch does not apply to the 4.4-stable tree, which is why it was
> > > > > not included there.  If you feel it should be included, please provide a
> > > > > backport and send it to the stable@vger.kernel.org mailing list.
> > > > >
> > > > > greg k-h
> > > >
> > > > Thanks! I'll do the backport after this patch goes in the mainline.
> > >
> > > Why wait?
> >
> > I thought a patch must first appear in Linus's tree, before it can be
> > back-ported to the stable tree?
> 
> Commit a389fcfd2cb5 _IS_ in Linus's tree, it was released in the 4.7-rc1
> kernel, which happened in May of 2016.
> 
> greg k-h

Sorry, it looks I didn't make it clear. :-)

v4.4.44 needs 2 patches, i.e. a389fcfd2cb5, and this patch (which is not in
Linus's tree yet).  Only backporting the first patch immediately is not enough
and is also improper IMO, because the first patch introduces a new issue,
which is being resolved by this patch. So my understanding is that I should
backport the 2 patches together.

Thanks,
-- Dexuan

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-26  9:31                 ` Dexuan Cui
@ 2017-01-26 10:10                   ` gregkh
  -1 siblings, 0 replies; 28+ messages in thread
From: gregkh @ 2017-01-26 10:10 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

On Thu, Jan 26, 2017 at 09:31:32AM +0000, Dexuan Cui wrote:
> > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > > > > > It's interesting v4.4.44 is not impacted, but actually it needs both the 2
> > > > patches:
> > > > > > > i.e. this patch, and the previous one:
> > > > > > > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> > > > > > hv_need_to_signal_on_read()")
> > > > > >
> > > > > > That patch does not apply to the 4.4-stable tree, which is why it was
> > > > > > not included there.  If you feel it should be included, please provide a
> > > > > > backport and send it to the stable@vger.kernel.org mailing list.
> > > > > >
> > > > > > greg k-h
> > > > >
> > > > > Thanks! I'll do the backport after this patch goes in the mainline.
> > > >
> > > > Why wait?
> > >
> > > I thought a patch must first appear in Linus's tree, before it can be
> > > back-ported to the stable tree?
> > 
> > Commit a389fcfd2cb5 _IS_ in Linus's tree, it was released in the 4.7-rc1
> > kernel, which happened in May of 2016.
> > 
> > greg k-h
> 
> Sorry, it looks I didn't make it clear. :-)
> 
> v4.4.44 needs 2 patches, i.e. a389fcfd2cb5, and this patch (which is not in
> Linus's tree yet).  Only backporting the first patch immediately is not enough
> and is also improper IMO, because the first patch introduces a new issue,
> which is being resolved by this patch. So my understanding is that I should
> backport the 2 patches together.

Ok, that makes a bit more sense, thanks.  I'll wait for your "real"
patch to hit Linus's tree then.

greg k-h

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26 10:10                   ` gregkh
  0 siblings, 0 replies; 28+ messages in thread
From: gregkh @ 2017-01-26 10:10 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

On Thu, Jan 26, 2017 at 09:31:32AM +0000, Dexuan Cui wrote:
> > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > > > > > It's interesting v4.4.44 is not impacted, but actually it needs both the 2
> > > > patches:
> > > > > > > i.e. this patch, and the previous one:
> > > > > > > Commit a389fcfd2cb5 ("Drivers: hv: vmbus: Fix signaling logic in
> > > > > > hv_need_to_signal_on_read()")
> > > > > >
> > > > > > That patch does not apply to the 4.4-stable tree, which is why it was
> > > > > > not included there.  If you feel it should be included, please provide a
> > > > > > backport and send it to the stable@vger.kernel.org mailing list.
> > > > > >
> > > > > > greg k-h
> > > > >
> > > > > Thanks! I'll do the backport after this patch goes in the mainline.
> > > >
> > > > Why wait?
> > >
> > > I thought a patch must first appear in Linus's tree, before it can be
> > > back-ported to the stable tree?
> > 
> > Commit a389fcfd2cb5 _IS_ in Linus's tree, it was released in the 4.7-rc1
> > kernel, which happened in May of 2016.
> > 
> > greg k-h
> 
> Sorry, it looks I didn't make it clear. :-)
> 
> v4.4.44 needs 2 patches, i.e. a389fcfd2cb5, and this patch (which is not in
> Linus's tree yet).  Only backporting the first patch immediately is not enough
> and is also improper IMO, because the first patch introduces a new issue,
> which is being resolved by this patch. So my understanding is that I should
> backport the 2 patches together.

Ok, that makes a bit more sense, thanks.  I'll wait for your "real"
patch to hit Linus's tree then.

greg k-h

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-26 10:10                   ` gregkh
@ 2017-01-26 10:24                     ` Dexuan Cui
  -1 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26 10:24 UTC (permalink / raw)
  To: gregkh
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> To: Dexuan Cui <decui@microsoft.com>
> >
> > v4.4.44 needs 2 patches, i.e. a389fcfd2cb5, and this patch (which is not in
> > Linus's tree yet).  Only backporting the first patch immediately is not enough
> > and is also improper IMO, because the first patch introduces a new issue,
> > which is being resolved by this patch. So my understanding is that I should
> > backport the 2 patches together.
> 
> Ok, that makes a bit more sense, thanks.  I'll wait for your "real"
> patch to hit Linus's tree then.
> 
> greg k-h

Hi Greg,
I expect this patch (i.e. the "real" patch) would go in your char-misc tree first,
then it would be merged into Linus's tree, as we usually did.

IMO this is an important fix, but it's not so urgent that Linus would notice
it and pick it up directly.

Thanks,
-- Dexuan

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26 10:24                     ` Dexuan Cui
  0 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26 10:24 UTC (permalink / raw)
  To: gregkh
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> To: Dexuan Cui <decui@microsoft.com>
> >
> > v4.4.44 needs 2 patches, i.e. a389fcfd2cb5, and this patch (which is not in
> > Linus's tree yet).  Only backporting the first patch immediately is not enough
> > and is also improper IMO, because the first patch introduces a new issue,
> > which is being resolved by this patch. So my understanding is that I should
> > backport the 2 patches together.
> 
> Ok, that makes a bit more sense, thanks.  I'll wait for your "real"
> patch to hit Linus's tree then.
> 
> greg k-h

Hi Greg,
I expect this patch (i.e. the "real" patch) would go in your char-misc tree first,
then it would be merged into Linus's tree, as we usually did.

IMO this is an important fix, but it's not so urgent that Linus would notice
it and pick it up directly.

Thanks,
-- Dexuan

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-26 10:24                     ` Dexuan Cui
@ 2017-01-26 10:28                       ` gregkh
  -1 siblings, 0 replies; 28+ messages in thread
From: gregkh @ 2017-01-26 10:28 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

On Thu, Jan 26, 2017 at 10:24:32AM +0000, Dexuan Cui wrote:
> > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > To: Dexuan Cui <decui@microsoft.com>
> > >
> > > v4.4.44 needs 2 patches, i.e. a389fcfd2cb5, and this patch (which is not in
> > > Linus's tree yet).  Only backporting the first patch immediately is not enough
> > > and is also improper IMO, because the first patch introduces a new issue,
> > > which is being resolved by this patch. So my understanding is that I should
> > > backport the 2 patches together.
> > 
> > Ok, that makes a bit more sense, thanks.  I'll wait for your "real"
> > patch to hit Linus's tree then.
> > 
> > greg k-h
> 
> Hi Greg,
> I expect this patch (i.e. the "real" patch) would go in your char-misc tree first,
> then it would be merged into Linus's tree, as we usually did.

That's fine, I'll wait for the maintainer of the subsystem to forward it
on to me, like all other hyperv patches :)

Or, at the very least, have one of them ack it so that I can take it...

thanks,

greg k-hmu

> 
> IMO this is an important fix, but it's not so urgent that Linus would notice
> it and pick it up directly.
> 
> Thanks,
> -- Dexuan

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

* Re: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26 10:28                       ` gregkh
  0 siblings, 0 replies; 28+ messages in thread
From: gregkh @ 2017-01-26 10:28 UTC (permalink / raw)
  To: Dexuan Cui
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

On Thu, Jan 26, 2017 at 10:24:32AM +0000, Dexuan Cui wrote:
> > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > To: Dexuan Cui <decui@microsoft.com>
> > >
> > > v4.4.44 needs 2 patches, i.e. a389fcfd2cb5, and this patch (which is not in
> > > Linus's tree yet).  Only backporting the first patch immediately is not enough
> > > and is also improper IMO, because the first patch introduces a new issue,
> > > which is being resolved by this patch. So my understanding is that I should
> > > backport the 2 patches together.
> > 
> > Ok, that makes a bit more sense, thanks.  I'll wait for your "real"
> > patch to hit Linus's tree then.
> > 
> > greg k-h
> 
> Hi Greg,
> I expect this patch (i.e. the "real" patch) would go in your char-misc tree first,
> then it would be merged into Linus's tree, as we usually did.

That's fine, I'll wait for the maintainer of the subsystem to forward it
on to me, like all other hyperv patches :)

Or, at the very least, have one of them ack it so that I can take it...

thanks,

greg k-hmu

> 
> IMO this is an important fix, but it's not so urgent that Linus would notice
> it and pick it up directly.
> 
> Thanks,
> -- Dexuan

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-26 10:28                       ` gregkh
@ 2017-01-26 10:31                         ` Dexuan Cui
  -1 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26 10:31 UTC (permalink / raw)
  To: gregkh
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > Hi Greg,
> > I expect this patch (i.e. the "real" patch) would go in your char-misc tree first,
> > then it would be merged into Linus's tree, as we usually did.
> 
> That's fine, I'll wait for the maintainer of the subsystem to forward it
> on to me, like all other hyperv patches :)
> 
> Or, at the very least, have one of them ack it so that I can take it...
> thanks,
> 
> greg k-hmu

Got it. Thanks for the clarification!

Thanks,
-- Dexuan

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26 10:31                         ` Dexuan Cui
  0 siblings, 0 replies; 28+ messages in thread
From: Dexuan Cui @ 2017-01-26 10:31 UTC (permalink / raw)
  To: gregkh
  Cc: Stephen Hemminger, driverdev-devel, KY Srinivasan, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw

> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > Hi Greg,
> > I expect this patch (i.e. the "real" patch) would go in your char-misc tree first,
> > then it would be merged into Linus's tree, as we usually did.
> 
> That's fine, I'll wait for the maintainer of the subsystem to forward it
> on to me, like all other hyperv patches :)
> 
> Or, at the very least, have one of them ack it so that I can take it...
> thanks,
> 
> greg k-hmu

Got it. Thanks for the clarification!

Thanks,
-- Dexuan

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
  2017-01-26 10:28                       ` gregkh
@ 2017-01-26 19:16                         ` KY Srinivasan
  -1 siblings, 0 replies; 28+ messages in thread
From: KY Srinivasan @ 2017-01-26 19:16 UTC (permalink / raw)
  To: gregkh, Dexuan Cui
  Cc: Stephen Hemminger, driverdev-devel, Haiyang Zhang,
	Stephen Hemminger, olaf, Rolf Neugebauer, jasowang, linux-kernel,
	apw



> -----Original Message-----
> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> Sent: Thursday, January 26, 2017 2:28 AM
> To: Dexuan Cui <decui@microsoft.com>
> Cc: Stephen Hemminger <stephen@networkplumber.org>; driverdev-
> devel@linuxdriverproject.org; KY Srinivasan <kys@microsoft.com>; Haiyang
> Zhang <haiyangz@microsoft.com>; Stephen Hemminger
> <sthemmin@microsoft.com>; olaf@aepfle.de; Rolf Neugebauer
> <rolf.neugebauer@docker.com>; jasowang@redhat.com; linux-
> kernel@vger.kernel.org; apw@canonical.com
> Subject: Re: [PATCH] Drivers: hv: vmbus: finally fix
> hv_need_to_signal_on_read()
> 
> On Thu, Jan 26, 2017 at 10:24:32AM +0000, Dexuan Cui wrote:
> > > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > To: Dexuan Cui <decui@microsoft.com>
> > > >
> > > > v4.4.44 needs 2 patches, i.e. a389fcfd2cb5, and this patch (which is not
> in
> > > > Linus's tree yet).  Only backporting the first patch immediately is not
> enough
> > > > and is also improper IMO, because the first patch introduces a new
> issue,
> > > > which is being resolved by this patch. So my understanding is that I
> should
> > > > backport the 2 patches together.
> > >
> > > Ok, that makes a bit more sense, thanks.  I'll wait for your "real"
> > > patch to hit Linus's tree then.
> > >
> > > greg k-h
> >
> > Hi Greg,
> > I expect this patch (i.e. the "real" patch) would go in your char-misc tree
> first,
> > then it would be merged into Linus's tree, as we usually did.
> 
> That's fine, I'll wait for the maintainer of the subsystem to forward it
> on to me, like all other hyperv patches :)

I am putting together a set that I will be forwarding that includes this patch.

K. Y
> 
> Or, at the very least, have one of them ack it so that I can take it...
> 
> thanks,
> 
> greg k-hmu
> 
> >
> > IMO this is an important fix, but it's not so urgent that Linus would notice
> > it and pick it up directly.
> >
> > Thanks,
> > -- Dexuan

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

* RE: [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read()
@ 2017-01-26 19:16                         ` KY Srinivasan
  0 siblings, 0 replies; 28+ messages in thread
From: KY Srinivasan @ 2017-01-26 19:16 UTC (permalink / raw)
  To: gregkh, Dexuan Cui
  Cc: olaf, Stephen Hemminger, Rolf Neugebauer, Haiyang Zhang,
	driverdev-devel, linux-kernel, apw, jasowang



> -----Original Message-----
> From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> Sent: Thursday, January 26, 2017 2:28 AM
> To: Dexuan Cui <decui@microsoft.com>
> Cc: Stephen Hemminger <stephen@networkplumber.org>; driverdev-
> devel@linuxdriverproject.org; KY Srinivasan <kys@microsoft.com>; Haiyang
> Zhang <haiyangz@microsoft.com>; Stephen Hemminger
> <sthemmin@microsoft.com>; olaf@aepfle.de; Rolf Neugebauer
> <rolf.neugebauer@docker.com>; jasowang@redhat.com; linux-
> kernel@vger.kernel.org; apw@canonical.com
> Subject: Re: [PATCH] Drivers: hv: vmbus: finally fix
> hv_need_to_signal_on_read()
> 
> On Thu, Jan 26, 2017 at 10:24:32AM +0000, Dexuan Cui wrote:
> > > From: gregkh@linuxfoundation.org [mailto:gregkh@linuxfoundation.org]
> > > To: Dexuan Cui <decui@microsoft.com>
> > > >
> > > > v4.4.44 needs 2 patches, i.e. a389fcfd2cb5, and this patch (which is not
> in
> > > > Linus's tree yet).  Only backporting the first patch immediately is not
> enough
> > > > and is also improper IMO, because the first patch introduces a new
> issue,
> > > > which is being resolved by this patch. So my understanding is that I
> should
> > > > backport the 2 patches together.
> > >
> > > Ok, that makes a bit more sense, thanks.  I'll wait for your "real"
> > > patch to hit Linus's tree then.
> > >
> > > greg k-h
> >
> > Hi Greg,
> > I expect this patch (i.e. the "real" patch) would go in your char-misc tree
> first,
> > then it would be merged into Linus's tree, as we usually did.
> 
> That's fine, I'll wait for the maintainer of the subsystem to forward it
> on to me, like all other hyperv patches :)

I am putting together a set that I will be forwarding that includes this patch.

K. Y
> 
> Or, at the very least, have one of them ack it so that I can take it...
> 
> thanks,
> 
> greg k-hmu
> 
> >
> > IMO this is an important fix, but it's not so urgent that Linus would notice
> > it and pick it up directly.
> >
> > Thanks,
> > -- Dexuan
_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

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

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

Thread overview: 28+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-01-24  6:54 [PATCH] Drivers: hv: vmbus: finally fix hv_need_to_signal_on_read() Dexuan Cui
2017-01-24  6:54 ` Dexuan Cui
2017-01-24 16:08 ` Stephen Hemminger
2017-01-24 16:08   ` Stephen Hemminger
2017-01-26  6:10   ` Dexuan Cui
2017-01-26  6:10     ` Dexuan Cui
2017-01-26  7:16     ` gregkh
2017-01-26  7:16       ` gregkh
2017-01-26  7:44       ` Dexuan Cui
2017-01-26  7:44         ` Dexuan Cui
2017-01-26  7:49         ` gregkh
2017-01-26  7:49           ` gregkh
2017-01-26  8:27           ` Dexuan Cui
2017-01-26  8:27             ` Dexuan Cui
2017-01-26  9:16             ` gregkh
2017-01-26  9:16               ` gregkh
2017-01-26  9:31               ` Dexuan Cui
2017-01-26  9:31                 ` Dexuan Cui
2017-01-26 10:10                 ` gregkh
2017-01-26 10:10                   ` gregkh
2017-01-26 10:24                   ` Dexuan Cui
2017-01-26 10:24                     ` Dexuan Cui
2017-01-26 10:28                     ` gregkh
2017-01-26 10:28                       ` gregkh
2017-01-26 10:31                       ` Dexuan Cui
2017-01-26 10:31                         ` Dexuan Cui
2017-01-26 19:16                       ` KY Srinivasan
2017-01-26 19:16                         ` KY Srinivasan

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.