Skip to contentSkip to conversation

devlink: Fix error message in devlink_rate_set_ops_supported()

PATCH Applied Dan Carpenter 2 participants 2 messages Jun 9, 2021

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 devlink: Fix error message in devlink_rate_set_ops_supported()

The WARN_ON() macro takes a condition, it doesn't take a message. Use WARN() instead.

Fixes 1897db2ec310 ("devlink: Allow setting tx rate for devlink rate leaf objects")
---
 net/core/devlink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
net/core/devlink.c +1 -1
index 1e953b77a77a..4a5b333c05a0 100644
@@ -1732,7 +1732,7 @@ static bool devlink_rate_set_ops_supported(const struct devlink_ops *ops,
 			return false;
 		}
 	} else {
-		WARN_ON("Unknown type of rate object");
+		WARN(1, "Unknown type of rate object");
 		return false;
 	}
 
Signature · 1 line
2.30.2
#1 lore raw
This patch was applied to netdev/net-next.git (refs/heads/master):

Hello:

This patch was applied to netdev/net-next.git (refs/heads/master):

Quoted 8 lines · On Wed, 9 Jun 2021 12:54:31 +0300 you wrote:

The WARN_ON() macro takes a condition, it doesn't take a message. Use WARN() instead.

Fixes 1897db2ec310 ("devlink: Allow setting tx rate for devlink rate leaf objects")
---
 net/core/devlink.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Here is the summary with links:
- [net-next] devlink: Fix error message in devlink_rate_set_ops_supported()

    https://git.kernel.org/netdev/net-next/c/711d1dee1c86

You are awesome, thank you!
--
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html