Skip to contentSkip to conversation

net/mlx5: fix an unused-function warning

PATCH In review Arnd Bergmann 3 participants 3 messages Jul 17, 2018 – Jul 18, 2018

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

PATCH 1/1 net/mlx5: fix an unused-function warning

These dummy helpers are all intended to be inline functions, but one of them by accident came without the 'inline' keyword, causing a harmless warning:

In file included from drivers/net/ethernet/mellanox/mlx5/core/main.c:63:
drivers/net/ethernet/mellanox/mlx5/core/accel/tls.h:79:1: error: 'mlx5_accel_tls_add_flow' defined but not used [-Werror=unused-function]
mlx5_accel_tls_add_flow(struct mlx5_core_dev *mdev, void *flow,

Fixes ab412e1dd7db ("net/mlx5: Accel, add TLS rx offload routines")
---
 drivers/net/ethernet/mellanox/mlx5/core/accel/tls.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/mellanox/mlx5/core/accel/tls.h +1 -1
index 2228c1083528..def4093ebfae 100644
@@ -75,7 +75,7 @@ void mlx5_accel_tls_cleanup(struct mlx5_core_dev *mdev);
 
 #else
 
-static int
+static inline int
 mlx5_accel_tls_add_flow(struct mlx5_core_dev *mdev, void *flow,
 			struct tls_crypto_info *crypto_info,
 			u32 start_offload_tcp_sn, u32 *p_swid,
Signature · 1 line
2.9.0
Acked-by on v1 1/1
#1 lore raw
Quoted 10 lines · Arnd Bergmann

These dummy helpers are all intended to be inline functions, but one of them by accident came without the 'inline' keyword, causing a harmless warning:

In file included from drivers/net/ethernet/mellanox/mlx5/core/main.c:63:
drivers/net/ethernet/mellanox/mlx5/core/accel/tls.h:79:1: error: 'mlx5_accel_tls_add_flow' defined but not used [-Werror=unused-function]
mlx5_accel_tls_add_flow(struct mlx5_core_dev *mdev, void *flow,

Fixes ab412e1dd7db ("net/mlx5: Accel, add TLS rx offload routines")

Dave, you can take this one to net-next.

Thanks!

Quoted 24 lines
---
 drivers/net/ethernet/mellanox/mlx5/core/accel/tls.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/ethernet/mellanox/mlx5/core/accel/tls.h +1 -2
index 2228c1083528..def4093ebfae 100644
@@ -75,7 +75,7 @@ void mlx5_accel_tls_cleanup(struct mlx5_core_dev *mdev);
 
 #else
 
-static int
+static inline int
 mlx5_accel_tls_add_flow(struct mlx5_core_dev *mdev, void *flow,
                        struct tls_crypto_info *crypto_info,
                        u32 start_offload_tcp_sn, u32 *p_swid,
--

2.9.0

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html

maintainer
#2 lore raw

From: Saeed Mahameed <[email protected]>
Date: Tue, 17 Jul 2018 17:42:25 -0700

Quoted 9 lines · Arnd Bergmann
Quoted 8 lines

These dummy helpers are all intended to be inline functions, but one of them by accident came without the 'inline' keyword, causing a harmless warning:

In file included from drivers/net/ethernet/mellanox/mlx5/core/main.c:63:
drivers/net/ethernet/mellanox/mlx5/core/accel/tls.h:79:1: error: 'mlx5_accel_tls_add_flow' defined but not used [-Werror=unused-function]
mlx5_accel_tls_add_flow(struct mlx5_core_dev *mdev, void *flow,

Quoted 6 lines
Quoted 2 lines
Fixes ab412e1dd7db ("net/mlx5: Accel, add TLS rx offload routines")

Dave, you can take this one to net-next.

Sure, done.