linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] net/mlx5: remove unreachable return
@ 2020-09-21 11:41 Pavel Machek
  2020-09-22  5:54 ` Saeed Mahameed
  0 siblings, 1 reply; 4+ messages in thread
From: Pavel Machek @ 2020-09-21 11:41 UTC (permalink / raw)
  To: eranbe, lariel, saeedm, saeedm, leon, davem, kuba, netdev,
	linux-rdma, linux-kernel

[-- Attachment #1: Type: text/plain, Size: 824 bytes --]

The last return statement is unreachable code. I'm not sure if it will
provoke any warnings, but it looks ugly.
    
Signed-off-by: Pavel Machek (CIP) <pavel@denx.de>

diff --git a/drivers/net/ethernet/mellanox/mlx5/core/lib/clock.c b/drivers/net/ethernet/mellanox/mlx5/core/lib/clock.c
index 2d55b7c22c03..a804f92ccf23 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/lib/clock.c
+++ b/drivers/net/ethernet/mellanox/mlx5/core/lib/clock.c
@@ -431,8 +431,6 @@ static int mlx5_ptp_verify(struct ptp_clock_info *ptp, unsigned int pin,
 	default:
 		return -EOPNOTSUPP;
 	}
-
-	return -EOPNOTSUPP;
 }
 
 static const struct ptp_clock_info mlx5_ptp_clock_info = {


-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

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

* Re: [PATCH] net/mlx5: remove unreachable return
  2020-09-21 11:41 [PATCH] net/mlx5: remove unreachable return Pavel Machek
@ 2020-09-22  5:54 ` Saeed Mahameed
  2020-09-22 19:54   ` Saeed Mahameed
  0 siblings, 1 reply; 4+ messages in thread
From: Saeed Mahameed @ 2020-09-22  5:54 UTC (permalink / raw)
  To: Pavel Machek, eranbe, lariel, saeedm, leon, davem, kuba, netdev,
	linux-rdma, linux-kernel

On Mon, 2020-09-21 at 13:41 +0200, Pavel Machek wrote:
> The last return statement is unreachable code. I'm not sure if it
> will
> provoke any warnings, but it looks ugly.
>     
> Signed-off-by: Pavel Machek (CIP) <pavel@denx.de>
> 
> 

Applied to net-next-mlx5.

Thanks,
Saeed.


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

* Re: [PATCH] net/mlx5: remove unreachable return
  2020-09-22  5:54 ` Saeed Mahameed
@ 2020-09-22 19:54   ` Saeed Mahameed
  2020-09-22 20:05     ` Pavel Machek
  0 siblings, 1 reply; 4+ messages in thread
From: Saeed Mahameed @ 2020-09-22 19:54 UTC (permalink / raw)
  To: Pavel Machek, eranbe, lariel, saeedm, leon, davem, kuba, netdev,
	linux-rdma, linux-kernel

On Mon, 2020-09-21 at 22:54 -0700, Saeed Mahameed wrote:
> On Mon, 2020-09-21 at 13:41 +0200, Pavel Machek wrote:
> > The last return statement is unreachable code. I'm not sure if it
> > will
> > provoke any warnings, but it looks ugly.
> >     
> > Signed-off-by: Pavel Machek (CIP) <pavel@denx.de>
> > 
> > 
> 
> Applied to net-next-mlx5.
> 
> Thanks,
> Saeed.
> 

Actually checkpatch reports this issue:
WARNING:NO_AUTHOR_SIGN_OFF: Missing Signed-off-by: line by nominal
patch author 'Pavel Machek <pavel@ucw.cz>'

Do you want me to override the Signed-off-by tag with the above email ?

Thanks,
Saeed.


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

* Re: [PATCH] net/mlx5: remove unreachable return
  2020-09-22 19:54   ` Saeed Mahameed
@ 2020-09-22 20:05     ` Pavel Machek
  0 siblings, 0 replies; 4+ messages in thread
From: Pavel Machek @ 2020-09-22 20:05 UTC (permalink / raw)
  To: Saeed Mahameed
  Cc: eranbe, lariel, saeedm, leon, davem, kuba, netdev, linux-rdma,
	linux-kernel

[-- Attachment #1: Type: text/plain, Size: 1037 bytes --]

On Tue 2020-09-22 12:54:20, Saeed Mahameed wrote:
> On Mon, 2020-09-21 at 22:54 -0700, Saeed Mahameed wrote:
> > On Mon, 2020-09-21 at 13:41 +0200, Pavel Machek wrote:
> > > The last return statement is unreachable code. I'm not sure if it
> > > will
> > > provoke any warnings, but it looks ugly.
> > >     
> > > Signed-off-by: Pavel Machek (CIP) <pavel@denx.de>
> > > 
> > > 
> > 
> > Applied to net-next-mlx5.
> > 
> > Thanks,
> > Saeed.
> > 
> 
> Actually checkpatch reports this issue:
> WARNING:NO_AUTHOR_SIGN_OFF: Missing Signed-off-by: line by nominal
> patch author 'Pavel Machek <pavel@ucw.cz>'
> 
> Do you want me to override the Signed-off-by tag with the above email ?

Sorry about that.

Actually, overriding patch author to match signoff would be better (I
should have sent it from: denx), but either way is okay with me.

Best regards,
									Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

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

end of thread, other threads:[~2020-09-22 20:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-09-21 11:41 [PATCH] net/mlx5: remove unreachable return Pavel Machek
2020-09-22  5:54 ` Saeed Mahameed
2020-09-22 19:54   ` Saeed Mahameed
2020-09-22 20:05     ` Pavel Machek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).