Linux-HyperV Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH] Drivers: hv: vmbus: remove unused function
@ 2021-04-14  6:21 Jiapeng Chong
  2021-04-14 14:48 ` Michael Kelley
  0 siblings, 1 reply; 3+ messages in thread
From: Jiapeng Chong @ 2021-04-14  6:21 UTC (permalink / raw)
  To: kys
  Cc: haiyangz, sthemmin, wei.liu, linux-hyperv, linux-kernel, Jiapeng Chong

Fix the following clang warning:

drivers/hv/ring_buffer.c:89:1: warning: unused function
'hv_set_next_read_location' [-Wunused-function].

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
---
 drivers/hv/ring_buffer.c | 9 ---------
 1 file changed, 9 deletions(-)

diff --git a/drivers/hv/ring_buffer.c b/drivers/hv/ring_buffer.c
index 35833d4..78d4043 100644
--- a/drivers/hv/ring_buffer.c
+++ b/drivers/hv/ring_buffer.c
@@ -84,15 +84,6 @@ static void hv_signal_on_write(u32 old_write, struct vmbus_channel *channel)
 	ring_info->ring_buffer->write_index = next_write_location;
 }
 
-/* Set the next read location for the specified ring buffer. */
-static inline void
-hv_set_next_read_location(struct hv_ring_buffer_info *ring_info,
-		    u32 next_read_location)
-{
-	ring_info->ring_buffer->read_index = next_read_location;
-	ring_info->priv_read_index = next_read_location;
-}
-
 /* Get the size of the ring buffer. */
 static inline u32
 hv_get_ring_buffersize(const struct hv_ring_buffer_info *ring_info)
-- 
1.8.3.1


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

* RE: [PATCH] Drivers: hv: vmbus: remove unused function
  2021-04-14  6:21 [PATCH] Drivers: hv: vmbus: remove unused function Jiapeng Chong
@ 2021-04-14 14:48 ` Michael Kelley
  2021-04-14 15:15   ` Wei Liu
  0 siblings, 1 reply; 3+ messages in thread
From: Michael Kelley @ 2021-04-14 14:48 UTC (permalink / raw)
  To: Jiapeng Chong, KY Srinivasan
  Cc: Haiyang Zhang, Stephen Hemminger, wei.liu, linux-hyperv, linux-kernel

From: Jiapeng Chong <jiapeng.chong@linux.alibaba.com> Sent: Tuesday, April 13, 2021 11:21 PM
> 
> Fix the following clang warning:
> 
> drivers/hv/ring_buffer.c:89:1: warning: unused function
> 'hv_set_next_read_location' [-Wunused-function].
> 
> Reported-by: Abaci Robot <abaci@linux.alibaba.com>
> Signed-off-by: Jiapeng Chong <jiapeng.chong@linux.alibaba.com>
> ---
>  drivers/hv/ring_buffer.c | 9 ---------
>  1 file changed, 9 deletions(-)
> 
> diff --git a/drivers/hv/ring_buffer.c b/drivers/hv/ring_buffer.c
> index 35833d4..78d4043 100644
> --- a/drivers/hv/ring_buffer.c
> +++ b/drivers/hv/ring_buffer.c
> @@ -84,15 +84,6 @@ static void hv_signal_on_write(u32 old_write, struct vmbus_channel
> *channel)
>  	ring_info->ring_buffer->write_index = next_write_location;
>  }
> 
> -/* Set the next read location for the specified ring buffer. */
> -static inline void
> -hv_set_next_read_location(struct hv_ring_buffer_info *ring_info,
> -		    u32 next_read_location)
> -{
> -	ring_info->ring_buffer->read_index = next_read_location;
> -	ring_info->priv_read_index = next_read_location;
> -}
> -
>  /* Get the size of the ring buffer. */
>  static inline u32
>  hv_get_ring_buffersize(const struct hv_ring_buffer_info *ring_info)
> --
> 1.8.3.1

This function became unused as of commit 4226ff69a3df 
("vmbus: simplify hv_ringbuffer_read") on 7/17/2017.

Reviewed-by: Michael Kelley <mikelley@microsoft.com>

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

* Re: [PATCH] Drivers: hv: vmbus: remove unused function
  2021-04-14 14:48 ` Michael Kelley
@ 2021-04-14 15:15   ` Wei Liu
  0 siblings, 0 replies; 3+ messages in thread
From: Wei Liu @ 2021-04-14 15:15 UTC (permalink / raw)
  To: Michael Kelley
  Cc: Jiapeng Chong, KY Srinivasan, Haiyang Zhang, Stephen Hemminger,
	wei.liu, linux-hyperv, linux-kernel

On Wed, Apr 14, 2021 at 02:48:17PM +0000, Michael Kelley wrote:
> From: Jiapeng Chong <jiapeng.chong@linux.alibaba.com> Sent: Tuesday, April 13, 2021 11:21 PM
[...]
> This function became unused as of commit 4226ff69a3df 
> ("vmbus: simplify hv_ringbuffer_read") on 7/17/2017.
> 
> Reviewed-by: Michael Kelley <mikelley@microsoft.com>

Applied to hyperv-next. Thanks.

Wei.

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

end of thread, back to index

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-14  6:21 [PATCH] Drivers: hv: vmbus: remove unused function Jiapeng Chong
2021-04-14 14:48 ` Michael Kelley
2021-04-14 15:15   ` Wei Liu

Linux-HyperV Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-hyperv/0 linux-hyperv/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-hyperv linux-hyperv/ https://lore.kernel.org/linux-hyperv \
		linux-hyperv@vger.kernel.org
	public-inbox-index linux-hyperv

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-hyperv


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git