All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] scsi: fcoe: remove redundant call to skb_transport_header
@ 2019-08-15  9:14 ` Colin King
  0 siblings, 0 replies; 4+ messages in thread
From: Colin King @ 2019-08-15  9:14 UTC (permalink / raw)
  To: Hannes Reinecke, James E . J . Bottomley, Martin K . Petersen,
	linux-scsi
  Cc: kernel-janitors, linux-kernel

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

Pointer fh is being assigned a return value from the call to
skb_transport_header however this value is never read and fh
is being re-assigned immediately afterwards with a new value.
Since there are side-effects from calling skb_transport_header
the call is redundant and can be removed.

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

diff --git a/drivers/scsi/fcoe/fcoe.c b/drivers/scsi/fcoe/fcoe.c
index 587d4bbb7d22..6fd61555120a 100644
--- a/drivers/scsi/fcoe/fcoe.c
+++ b/drivers/scsi/fcoe/fcoe.c
@@ -1617,7 +1617,6 @@ static inline int fcoe_filter_frames(struct fc_lport *lport,
 	else
 		fr_flags(fp) |= FCPHF_CRC_UNCHECKED;
 
-	fh = (struct fc_frame_header *) skb_transport_header(skb);
 	fh = fc_frame_header_get(fp);
 	if (fh->fh_r_ctl = FC_RCTL_DD_SOL_DATA && fh->fh_type = FC_TYPE_FCP)
 		return 0;
-- 
2.20.1

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

end of thread, other threads:[~2019-08-29 21:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-08-15  9:14 [PATCH] scsi: fcoe: remove redundant call to skb_transport_header Colin King
2019-08-15  9:14 ` Colin King
2019-08-29 21:45 ` Martin K. Petersen
2019-08-29 21:45   ` Martin K. Petersen

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.