From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from shards.monkeyblade.net ([184.105.139.130]:59928 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933351AbeCHB0Q (ORCPT ); Wed, 7 Mar 2018 20:26:16 -0500 Date: Wed, 07 Mar 2018 20:26:14 -0500 (EST) Message-Id: <20180307.202614.2171616742901831874.davem@davemloft.net> To: laszlth@gmail.com Cc: kuznet@ms2.inr.ac.ru, yoshfuji@linux-ipv6.org, netdev@vger.kernel.org Subject: Re: [PATCH] net: remove VLA usage From: David Miller In-Reply-To: <20180308001953.GA2190@laszlth> References: <20180308001953.GA2190@laszlth> Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: netdev-owner@vger.kernel.org List-ID: From: Laszlo Toth Date: Thu, 8 Mar 2018 01:19:53 +0100 > Separated snmp_seq_show_tcp_udp() to tcp and udp variants, > so the usage of max_t() for the array size can be emitted. > > Signed-off-by: Laszlo Toth But it's a max on a constant value, computed at compile time. I don't see at all why this is necessary. If the compiler can't figure this out, fix it. If the compiler warns on this with -Wvla, fix it. Because there is no reason to have two separate routines for this. Thank you.