[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20220301142019.7ecae6c9@kicinski-fedora-PC1C0HJN.hsd1.ca.comcast.net>
Date: Tue, 1 Mar 2022 14:20:19 -0800
From: Jakub Kicinski <kuba@...nel.org>
To: Dust Li <dust.li@...ux.alibaba.com>
Cc: Karsten Graul <kgraul@...ux.ibm.com>,
Tony Lu <tonylu@...ux.alibaba.com>,
Guangguan Wang <guangguan.wang@...ux.alibaba.com>,
davem@...emloft.net, netdev@...r.kernel.org,
linux-s390@...r.kernel.org, linux-rdma@...r.kernel.org
Subject: Re: [PATCH net-next 3/7] net/smc: add sysctl for autocorking
On Tue, 1 Mar 2022 17:43:58 +0800 Dust Li wrote:
> --- a/net/smc/smc_tx.c
> +++ b/net/smc/smc_tx.c
> @@ -147,7 +147,7 @@ static bool smc_should_autocork(struct smc_sock *smc)
> struct smc_connection *conn = &smc->conn;
> int corking_size;
>
> - corking_size = min(SMC_AUTOCORKING_DEFAULT_SIZE,
> + corking_size = min(sock_net(&smc->sk)->smc.sysctl_autocorking_size,
> conn->sndbuf_desc->len >> 1);
I think this broke the build:
In file included from ../include/linux/kernel.h:26,
from ../include/linux/random.h:11,
from ../include/linux/net.h:18,
from ../net/smc/smc_tx.c:16:
../net/smc/smc_tx.c: In function ‘smc_should_autocork’:
../include/linux/minmax.h:20:35: error: comparison of distinct pointer types lacks a cast [-Werror]
20 | (!!(sizeof((typeof(x) *)1 == (typeof(y) *)1)))
| ^~
../include/linux/minmax.h:26:18: note: in expansion of macro ‘__typecheck’
26 | (__typecheck(x, y) && __no_side_effects(x, y))
| ^~~~~~~~~~~
../include/linux/minmax.h:36:31: note: in expansion of macro ‘__safe_cmp’
36 | __builtin_choose_expr(__safe_cmp(x, y), \
| ^~~~~~~~~~
../include/linux/minmax.h:45:25: note: in expansion of macro ‘__careful_cmp’
45 | #define min(x, y) __careful_cmp(x, y, <)
| ^~~~~~~~~~~~~
../net/smc/smc_tx.c:150:24: note: in expansion of macro ‘min’
150 | corking_size = min(sock_net(&smc->sk)->smc.sysctl_autocorking_size,
| ^~~
Powered by blists - more mailing lists