DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH] net/mlx5: fix build failure on Windows
@ 2023-02-17 14:37 Maxime Coquelin
  2023-02-17 16:56 ` Thomas Monjalon
  2023-02-18 20:56 ` Slava Ovsiienko
  0 siblings, 2 replies; 3+ messages in thread
From: Maxime Coquelin @ 2023-02-17 14:37 UTC (permalink / raw)
  To: dev, viacheslavo, thomas; +Cc: Maxime Coquelin

__always_inline is not supported on Windows, let's use
__rte_always_inline instead.

..\drivers\net\mlx5/mlx5_hws_cnt.h:162:8: error: unknown type name '__always_inline'

static __always_inline struct mlx5_hws_cnt_pool *

       ^

..\drivers\net\mlx5/mlx5_hws_cnt.h:165:9: error: incompatible pointer types returning 'struct mlx5_hws_cnt_pool *' from a function with result type 'int *' [-Werror,-Wincompatible-pointer-types]

        return cpool->cfg.host_cpool ? cpool->cfg.host_cpool : cpool;

Fixes: 13ea6bdcc7ee ("net/mlx5: support counters in cross port shared mode")

Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
---
 drivers/net/mlx5/mlx5_hws_cnt.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/mlx5/mlx5_hws_cnt.h b/drivers/net/mlx5/mlx5_hws_cnt.h
index d35d083eeb..b4f3db0533 100644
--- a/drivers/net/mlx5/mlx5_hws_cnt.h
+++ b/drivers/net/mlx5/mlx5_hws_cnt.h
@@ -159,7 +159,7 @@ struct mlx5_hws_age_param {
  * @return
  *   Internal index
  */
-static __always_inline struct mlx5_hws_cnt_pool *
+static __rte_always_inline struct mlx5_hws_cnt_pool *
 mlx5_hws_cnt_host_pool(struct mlx5_hws_cnt_pool *cpool)
 {
 	return cpool->cfg.host_cpool ? cpool->cfg.host_cpool : cpool;
-- 
2.39.1


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

* Re: [PATCH] net/mlx5: fix build failure on Windows
  2023-02-17 14:37 [PATCH] net/mlx5: fix build failure on Windows Maxime Coquelin
@ 2023-02-17 16:56 ` Thomas Monjalon
  2023-02-18 20:56 ` Slava Ovsiienko
  1 sibling, 0 replies; 3+ messages in thread
From: Thomas Monjalon @ 2023-02-17 16:56 UTC (permalink / raw)
  To: Maxime Coquelin; +Cc: dev, viacheslavo

17/02/2023 15:37, Maxime Coquelin:
> __always_inline is not supported on Windows, let's use
> __rte_always_inline instead.
> 
> ..\drivers\net\mlx5/mlx5_hws_cnt.h:162:8: error: unknown type name '__always_inline'
> 
> static __always_inline struct mlx5_hws_cnt_pool *
> 
>        ^
> 
> ..\drivers\net\mlx5/mlx5_hws_cnt.h:165:9: error: incompatible pointer types returning 'struct mlx5_hws_cnt_pool *' from a function with result type 'int *' [-Werror,-Wincompatible-pointer-types]
> 
>         return cpool->cfg.host_cpool ? cpool->cfg.host_cpool : cpool;
> 
> Fixes: 13ea6bdcc7ee ("net/mlx5: support counters in cross port shared mode")
> 
> Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>

Applied, thanks.




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

* RE: [PATCH] net/mlx5: fix build failure on Windows
  2023-02-17 14:37 [PATCH] net/mlx5: fix build failure on Windows Maxime Coquelin
  2023-02-17 16:56 ` Thomas Monjalon
@ 2023-02-18 20:56 ` Slava Ovsiienko
  1 sibling, 0 replies; 3+ messages in thread
From: Slava Ovsiienko @ 2023-02-18 20:56 UTC (permalink / raw)
  To: Maxime Coquelin, dev, NBU-Contact-Thomas Monjalon (EXTERNAL)


> -----Original Message-----
> From: Maxime Coquelin <maxime.coquelin@redhat.com>
> Sent: Friday, February 17, 2023 4:37 PM
> To: dev@dpdk.org; Slava Ovsiienko <viacheslavo@nvidia.com>; NBU-Contact-
> Thomas Monjalon (EXTERNAL) <thomas@monjalon.net>
> Cc: Maxime Coquelin <maxime.coquelin@redhat.com>
> Subject: [PATCH] net/mlx5: fix build failure on Windows
> 
> __always_inline is not supported on Windows, let's use __rte_always_inline
> instead.
> 
> ..\drivers\net\mlx5/mlx5_hws_cnt.h:162:8: error: unknown type name
> '__always_inline'
> 
> static __always_inline struct mlx5_hws_cnt_pool *
> 
>        ^
> 
> ..\drivers\net\mlx5/mlx5_hws_cnt.h:165:9: error: incompatible pointer types
> returning 'struct mlx5_hws_cnt_pool *' from a function with result type 'int *' [-
> Werror,-Wincompatible-pointer-types]
> 
>         return cpool->cfg.host_cpool ? cpool->cfg.host_cpool : cpool;
> 
> Fixes: 13ea6bdcc7ee ("net/mlx5: support counters in cross port shared mode")
> 
> Signed-off-by: Maxime Coquelin <maxime.coquelin@redhat.com>
Acked-by: Viacheslav Ovsiienko <viacheslavo@nvidia.com>

Thank you for the fix,
With best regards,
Slava



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

end of thread, other threads:[~2023-02-18 20:56 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-02-17 14:37 [PATCH] net/mlx5: fix build failure on Windows Maxime Coquelin
2023-02-17 16:56 ` Thomas Monjalon
2023-02-18 20:56 ` Slava Ovsiienko

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