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 4D847C32771 for ; Mon, 26 Sep 2022 10:45:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234212AbiIZKo5 (ORCPT ); Mon, 26 Sep 2022 06:44:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48578 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236477AbiIZKnu (ORCPT ); Mon, 26 Sep 2022 06:43:50 -0400 Received: from Chamillionaire.breakpoint.cc (Chamillionaire.breakpoint.cc [IPv6:2a0a:51c0:0:12e:520::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0449B1BE87; Mon, 26 Sep 2022 03:25:05 -0700 (PDT) Received: from fw by Chamillionaire.breakpoint.cc with local (Exim 4.92) (envelope-from ) id 1oclIG-0003na-RG; Mon, 26 Sep 2022 12:24:56 +0200 Date: Mon, 26 Sep 2022 12:24:56 +0200 From: Florian Westphal To: Herbert Xu Cc: Florian Westphal , netdev@vger.kernel.org, tgraf@suug.ch, urezki@gmail.com, Paolo Abeni , "David S. Miller" , Eric Dumazet , Jakub Kicinski , linux-kernel@vger.kernel.org, akpm@linux-foundation.org, Martin Zaharinov , Michal Hocko , Paolo Bonzini , kvm@vger.kernel.org Subject: Re: [PATCH net] rhashtable: fix crash due to mm api change Message-ID: <20220926102456.GC12777@breakpoint.cc> References: <20220926083139.48069-1-fw@strlen.de> <20220926085018.GA11304@breakpoint.cc> <20220926100550.GA12777@breakpoint.cc> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Herbert Xu wrote: > Only in the case of kvzalloc. We expect kzalloc to fail, that's > why it gets NOWARN. There is no sane reason for kvzalloc to fail > so it should warn. To me a WARN() only has one purpose: It will get reported to mailing list and a developer can use that to develop a patch/fix. In memory allocation failure, there is no bug, so nothing to fix, so WARN is useless.