Received: by 2002:ab2:60d1:0:b0:1f7:5705:b850 with SMTP id i17csp1951352lqm; Fri, 3 May 2024 10:54:55 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWqqNKsHHkeOVf+6q8P8XfKbYfaTdKtG8XN/ds2gKi+mpTGEQiRSBoF3b8mnP3VWcdq/7p/ZyUPFeu/a0Kl0dHgvN8PHddEHVqq6U4LXw== X-Google-Smtp-Source: AGHT+IHIC3Ii+fkf8AAIdOCzQbbtzbpDOQHeHFCE3MTkBu2JKN/q60Y61Ow9uQOs09jTgMW070Ve X-Received: by 2002:ac2:53bb:0:b0:51e:e876:3504 with SMTP id j27-20020ac253bb000000b0051ee8763504mr2256196lfh.16.1714758895151; Fri, 03 May 2024 10:54:55 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1714758895; cv=pass; d=google.com; s=arc-20160816; b=C6zAuWM8b7JldiE+7vtOa7Xg1OY/INL9cWSi/NNsVmcdVJhAzI/s6Cmd1IQiB65jFE OKMDHRfSrblCoLgYaKH2UFgx9y/T20O7LviVD0aPPW1x50OJB4xPhaPKlejBJfScWY5U QN7JFpagUg5TTMYY5MHGQUXXJl9jHMOkzaBSH0vooAwl+x2wBVldA7sr1rfyGMvReat2 BcZ3ylU0pod83xZnV7lTE3pzxeGPoWtE8mjck+X2L71FgL91nfcLGpvxgOixhyOuBNXz xjt1Yb1R6i3b0OlC+sOoAAdfJhIeqMyr5SDgiJI30QSAylWmPRZIbRt4f0LSYHoteaUX DHPQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:dkim-signature:date; bh=viaLAewCzGtCTKetlsX4e8AVwuJyrmIUfGHPX1vb/sw=; fh=kKD51KF4Zcl2E16Ljirk6tMEAdpFTBv/oAm2qWFsX1E=; b=GoISgE076Rm46dd+vRXE2bBiDuTSI1EkiyEyMz+CS3OTRzGiDLj6qLuIuZS4SSrzpa 15yWBkKSC393ddzHKAVWPP3YBbT5TM7gsq/aLbBhKbMaQm/GXTLOK6izLlAQjFY3p1IK 2N8xAjm3G1RUQsgZ4k2UMP7CTmd/sOW/gdDQTxkN3smSH4suHbjLyuy2ykyr37MWFEom brOmT+GaQ0T54XwzgswM/eQn54/4w8TXBz+Vq1VJV/RuDhCSNpSDmhewCm2j27rONWng clj6kkRhVn4nMeEcepOkHTWx0FVV7Hh8bi6Xxls6knRClWauowMudTM6JTfiqNHOKEmB xVZg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=w3LHePTe; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-167991-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-167991-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id g22-20020a0564021ed600b00572d69111f0si709147edg.89.2024.05.03.10.54.55 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 03 May 2024 10:54:55 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-167991-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=w3LHePTe; arc=pass (i=1 spf=pass spfdomain=linux.dev dkim=pass dkdomain=linux.dev dmarc=pass fromdomain=linux.dev); spf=pass (google.com: domain of linux-kernel+bounces-167991-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-167991-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id D2C2B1F22857 for ; Fri, 3 May 2024 17:54:54 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E50D3158213; Fri, 3 May 2024 17:54:46 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="w3LHePTe" Received: from out-183.mta0.migadu.com (out-183.mta0.migadu.com [91.218.175.183]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B197B15533D for ; Fri, 3 May 2024 17:54:44 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=91.218.175.183 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714758886; cv=none; b=SE0nrDXaINB5l1hNZIJnV7S3wSkH0kYE8cqr8pJt2e3B7/TTEQfDDa5Lam9NwCsM5fAjgfUjVLwm2J0FUy/ETrW0WE92BQd0c1Vv0rMQrwweJ1/mPrvNJNdKF5w4WYhjR0Um8Ksaz1c2pEi/reAHxXj21lXXAODxIlvLHcO2NMg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714758886; c=relaxed/simple; bh=lypo2M4qo87JGtdc3hDkTp3pEo6t7MvTelzTkGrBKlU=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=hSLimCFE/VyqAvMgz9B1SUQYRgSvlldwstolbvBPnQXT6FJ/3p5GFzJ5iif6E6Je+28UN9M0rhbxCEtV7ReCJdsbdifgeEohAmXYFtqr7N1xHsj73rLXjMZCPXw9EUyOPTfK0uFkFLSN0Ytm1bVw9vtOS+8IkX5L9S5sKH4ZvtY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=w3LHePTe; arc=none smtp.client-ip=91.218.175.183 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Date: Fri, 3 May 2024 10:54:36 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1714758882; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=viaLAewCzGtCTKetlsX4e8AVwuJyrmIUfGHPX1vb/sw=; b=w3LHePTeLz2K9FRYMUNxS0jF0kYOiNeduwQD8+4Y7GA9YHHWJydFV5bJtZBGuhwbEHjcGY NjvQKoPD+odFWT6rzgaNHNzKFO2j5VP/PsjME0UqhJMJEDtZLeAP+Am9BJ9V7/D4A3/68r rJOxx5DkCTOJOpWB87WtS80/G6IA2UA= X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Roman Gushchin To: John Hubbard Cc: Shuah Khan , Tejun Heo , Zefan Li , Johannes Weiner , Michal Hocko , Shakeel Butt , Muchun Song , Waiman Long , Yosry Ahmed , Nhat Pham , Chengming Zhou , Valentin Obst , linux-kselftest@vger.kernel.org, cgroups@vger.kernel.org, linux-mm@kvack.org, LKML , llvm@lists.linux.dev Subject: Re: [PATCH 2/4] selftests/cgroup: fix clang warnings: uninitialized fd variable Message-ID: References: <20240503035105.93280-1-jhubbard@nvidia.com> <20240503035105.93280-3-jhubbard@nvidia.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240503035105.93280-3-jhubbard@nvidia.com> X-Migadu-Flow: FLOW_OUT On Thu, May 02, 2024 at 08:51:03PM -0700, John Hubbard wrote: > First of all, in order to build with clang at all, one must first apply > Valentin Obst's build fix for LLVM [1]. Once that is done, then when > building with clang, via: > > make LLVM=1 -C tools/testing/selftests > > ...clang warns about fd being used uninitialized, in > test_memcg_reclaim()'s error handling path. > > Fix this by initializing fd to -1. > > [1] https://lore.kernel.org/all/20240329-selftests-libmk-llvm-rfc-v1-1-2f9ed7d1c49f@valentinobst.de/ > > Signed-off-by: John Hubbard Reviewed-by: Roman Gushchin