Linux-Bluetooth Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH] Bluetooth: remove redundant assignment to variable icid
@ 2020-01-07 18:00 Colin King
  2020-01-08 13:57 ` Simon Horman
  2020-01-08 20:45 ` Marcel Holtmann
  0 siblings, 2 replies; 3+ messages in thread
From: Colin King @ 2020-01-07 18:00 UTC (permalink / raw)
  To: Marcel Holtmann, Johan Hedberg, David S . Miller,
	linux-bluetooth, netdev
  Cc: kernel-janitors, linux-kernel

From: Colin Ian King <colin.king@canonical.com>

Variable icid is being rc is assigned with a value that is never
read. The assignment is redundant and can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
---
 net/bluetooth/l2cap_core.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c
index 1bca608e0170..195459a1e53e 100644
--- a/net/bluetooth/l2cap_core.c
+++ b/net/bluetooth/l2cap_core.c
@@ -5081,7 +5081,6 @@ static inline int l2cap_move_channel_req(struct l2cap_conn *conn,
 	chan->move_role = L2CAP_MOVE_ROLE_RESPONDER;
 	l2cap_move_setup(chan);
 	chan->move_id = req->dest_amp_id;
-	icid = chan->dcid;
 
 	if (req->dest_amp_id == AMP_ID_BREDR) {
 		/* Moving to BR/EDR */
-- 
2.24.0


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

* Re: [PATCH] Bluetooth: remove redundant assignment to variable icid
  2020-01-07 18:00 [PATCH] Bluetooth: remove redundant assignment to variable icid Colin King
@ 2020-01-08 13:57 ` Simon Horman
  2020-01-08 20:45 ` Marcel Holtmann
  1 sibling, 0 replies; 3+ messages in thread
From: Simon Horman @ 2020-01-08 13:57 UTC (permalink / raw)
  To: Colin King
  Cc: Marcel Holtmann, Johan Hedberg, David S . Miller,
	linux-bluetooth, netdev, kernel-janitors, linux-kernel

On Tue, Jan 07, 2020 at 06:00:13PM +0000, Colin King wrote:
> From: Colin Ian King <colin.king@canonical.com>
> 
> Variable icid is being rc is assigned with a value that is never
> read. The assignment is redundant and can be removed.
> 
> Addresses-Coverity: ("Unused value")
> Signed-off-by: Colin Ian King <colin.king@canonical.com>

Reviewed-by: Simon Horman <simon.horman@netronome.com>

> ---
>  net/bluetooth/l2cap_core.c | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/net/bluetooth/l2cap_core.c b/net/bluetooth/l2cap_core.c
> index 1bca608e0170..195459a1e53e 100644
> --- a/net/bluetooth/l2cap_core.c
> +++ b/net/bluetooth/l2cap_core.c
> @@ -5081,7 +5081,6 @@ static inline int l2cap_move_channel_req(struct l2cap_conn *conn,
>  	chan->move_role = L2CAP_MOVE_ROLE_RESPONDER;
>  	l2cap_move_setup(chan);
>  	chan->move_id = req->dest_amp_id;
> -	icid = chan->dcid;
>  
>  	if (req->dest_amp_id == AMP_ID_BREDR) {
>  		/* Moving to BR/EDR */
> -- 
> 2.24.0
> 

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

* Re: [PATCH] Bluetooth: remove redundant assignment to variable icid
  2020-01-07 18:00 [PATCH] Bluetooth: remove redundant assignment to variable icid Colin King
  2020-01-08 13:57 ` Simon Horman
@ 2020-01-08 20:45 ` Marcel Holtmann
  1 sibling, 0 replies; 3+ messages in thread
From: Marcel Holtmann @ 2020-01-08 20:45 UTC (permalink / raw)
  To: Colin King
  Cc: Johan Hedberg, David S. Miller, BlueZ devel list, netdev,
	kernel-janitors, linux-kernel

Hi Colin,

> Variable icid is being rc is assigned with a value that is never
> read. The assignment is redundant and can be removed.
> 
> Addresses-Coverity: ("Unused value")
> Signed-off-by: Colin Ian King <colin.king@canonical.com>
> ---
> net/bluetooth/l2cap_core.c | 1 -
> 1 file changed, 1 deletion(-)

patch has been applied to bluetooth-next tree.

Regards

Marcel


^ 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 --
2020-01-07 18:00 [PATCH] Bluetooth: remove redundant assignment to variable icid Colin King
2020-01-08 13:57 ` Simon Horman
2020-01-08 20:45 ` Marcel Holtmann

Linux-Bluetooth Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-bluetooth/0 linux-bluetooth/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-bluetooth linux-bluetooth/ https://lore.kernel.org/linux-bluetooth \
		linux-bluetooth@vger.kernel.org
	public-inbox-index linux-bluetooth

Example config snippet for mirrors

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


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