netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next] net: mlx5: Fix compiling error in tls.c
@ 2019-07-10  9:38 Mao Wenan
  2019-07-11  5:07 ` Saeed Mahameed
  0 siblings, 1 reply; 2+ messages in thread
From: Mao Wenan @ 2019-07-10  9:38 UTC (permalink / raw)
  To: davem, saeedm; +Cc: netdev, linux-kernel, Mao Wenan

There are some errors while compiling tls.c if
CONFIG_MLX5_FPGA_TLS is not obvious on.

drivers/net/ethernet/mellanox/mlx5/core/en_accel/tls.c: In function mlx5e_tls_set_ipv4_flow:
./include/linux/mlx5/device.h:61:39: error: invalid application of sizeof to incomplete type struct mlx5_ifc_tls_flow_bits
 #define __mlx5_st_sz_bits(typ) sizeof(struct mlx5_ifc_##typ##_bits)
                                       ^
./include/linux/compiler.h:330:9: note: in definition of macro __compiletime_assert
   if (!(condition))     \
         ^~~~~~~~~
...

drivers/net/ethernet/mellanox/mlx5/core/en_accel/tls.c: In function mlx5e_tls_build_netdev:
drivers/net/ethernet/mellanox/mlx5/core/en_accel/tls.c:202:13: error: MLX5_ACCEL_TLS_TX undeclared (first use in this function); did you mean __MLX5_ACCEL_TLS_H__?
  if (caps & MLX5_ACCEL_TLS_TX) {
             ^~~~~~~~~~~~~~~~~
             __MLX5_ACCEL_TLS_H__
drivers/net/ethernet/mellanox/mlx5/core/en_accel/tls.c:207:13: error: MLX5_ACCEL_TLS_RX undeclared (first use in this function); did you mean MLX5_ACCEL_TLS_TX?
  if (caps & MLX5_ACCEL_TLS_RX) {
             ^~~~~~~~~~~~~~~~~
             MLX5_ACCEL_TLS_TX
drivers/net/ethernet/mellanox/mlx5/core/en_accel/tls.c:212:15: error: MLX5_ACCEL_TLS_LRO undeclared (first use in this function); did you mean MLX5_ACCEL_TLS_RX?
  if (!(caps & MLX5_ACCEL_TLS_LRO)) {
               ^~~~~~~~~~~~~~~~~~
               MLX5_ACCEL_TLS_RX
make[5]: *** [drivers/net/ethernet/mellanox/mlx5/core/en_accel/tls.o] Error 1
make[5]: *** Waiting for unfinished jobs....
make[4]: *** [drivers/net/ethernet/mellanox/mlx5/core] Error 2
make[3]: *** [drivers/net/ethernet/mellanox] Error 2
make[3]: *** Waiting for unfinished jobs....
make[2]: *** [drivers/net/ethernet] Error 2
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [drivers/net] Error 2
make[1]: *** Waiting for unfinished jobs....
make: *** [drivers] Error 2
make: *** Waiting for unfinished jobs....

this patch is to fix this error using 'depends on MLX5_FPGA_TLS' when MLX5_TLS is set.

Fixes: e2869fb2068b ("net/mlx5: Kconfig, Better organize compilation flags")

Signed-off-by: Mao Wenan <maowenan@huawei.com>
---
 drivers/net/ethernet/mellanox/mlx5/core/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/net/ethernet/mellanox/mlx5/core/Kconfig b/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
index 37fef8c..1da2770 100644
--- a/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
+++ b/drivers/net/ethernet/mellanox/mlx5/core/Kconfig
@@ -139,6 +139,7 @@ config MLX5_TLS
 	depends on MLX5_CORE_EN
 	depends on TLS_DEVICE
 	depends on TLS=y || MLX5_CORE=m
+	depends on MLX5_FPGA_TLS
 	select MLX5_ACCEL
 	default n
 	help
-- 
2.7.4


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

end of thread, other threads:[~2019-07-11  5:07 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-10  9:38 [PATCH net-next] net: mlx5: Fix compiling error in tls.c Mao Wenan
2019-07-11  5:07 ` Saeed Mahameed

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).