From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 91F90C433FE for ; Wed, 26 Oct 2022 15:01:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234411AbiJZPBR (ORCPT ); Wed, 26 Oct 2022 11:01:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42804 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234144AbiJZPBQ (ORCPT ); Wed, 26 Oct 2022 11:01:16 -0400 Received: from mg.ssi.bg (mg.ssi.bg [193.238.174.37]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 765AB3F1C4; Wed, 26 Oct 2022 08:01:14 -0700 (PDT) Received: from mg.ssi.bg (localhost [127.0.0.1]) by mg.ssi.bg (Proxmox) with ESMTP id D433911E33; Wed, 26 Oct 2022 18:01:13 +0300 (EEST) Received: from ink.ssi.bg (unknown [193.238.174.40]) by mg.ssi.bg (Proxmox) with ESMTP id 9338911F07; Wed, 26 Oct 2022 18:01:12 +0300 (EEST) Received: from ja.ssi.bg (unknown [178.16.129.10]) by ink.ssi.bg (Postfix) with ESMTPS id 654093C07E1; Wed, 26 Oct 2022 18:01:10 +0300 (EEST) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by ja.ssi.bg (8.17.1/8.16.1) with ESMTP id 29QF19DQ097559; Wed, 26 Oct 2022 18:01:09 +0300 Date: Wed, 26 Oct 2022 18:01:09 +0300 (EEST) From: Julian Anastasov To: "Jason A. Donenfeld" cc: netdev@vger.kernel.org, lvs-devel@vger.kernel.org, netfilter-devel@vger.kernel.org, linux-kernel@vger.kernel.org, Pablo Neira Ayuso , Simon Horman , stable@vger.kernel.org Subject: Re: [PATCH] ipvs: use explicitly signed chars In-Reply-To: Message-ID: References: <20221026123216.1575440-1-Jason@zx2c4.com> <4cc36ff5-46fd-c2b3-3292-d6369337fec1@ssi.bg> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Precedence: bulk List-ID: X-Mailing-List: netfilter-devel@vger.kernel.org Hello, On Wed, 26 Oct 2022, Jason A. Donenfeld wrote: > On Wed, Oct 26, 2022 at 05:20:03PM +0300, Julian Anastasov wrote: > > > > Hello, > > > > On Wed, 26 Oct 2022, Jason A. Donenfeld wrote: > > > > > The `char` type with no explicit sign is sometimes signed and sometimes > > > unsigned. This code will break on platforms such as arm, where char is > > > unsigned. So mark it here as explicitly signed, so that the > > > todrop_counter decrement and subsequent comparison is correct. > > > > > > Cc: Pablo Neira Ayuso > > > Cc: Julian Anastasov > > > Cc: Simon Horman > > > Cc: stable@vger.kernel.org > > > Signed-off-by: Jason A. Donenfeld > > > > Looks good to me for -next, thanks! > > This is actually net.git material, not net-next.git material, > considering it fixes a bug on arm and many other archs, and is marked > with a stable@ tag. OK. As algorithm is not SMP safe, the problem is not just for the first 256 packets on these platforms. Regards -- Julian Anastasov