Received: by 2002:a05:6500:1b8f:b0:1fa:5c73:8e2d with SMTP id df15csp1335117lqb; Thu, 30 May 2024 07:26:14 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUQOBhXlaCaKAMlDphSZlcFuDSkGpZELfAm7isI5e35e43glQcXk+H/eskrJavn6KWBZcx9TTd13FbsezLN/xD+f3HfRAx9tQyHaNOQEw== X-Google-Smtp-Source: AGHT+IGnPobYGHOkxa32YmmK/+BlsHnSiMWcmDTRCXzAV8TeZkPa8yZziCCAB800iiWArCN7YdGl X-Received: by 2002:ac2:456c:0:b0:51c:348:3ba9 with SMTP id 2adb3069b0e04-52b7d4282c8mr1482030e87.22.1717079173928; Thu, 30 May 2024 07:26:13 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717079173; cv=pass; d=google.com; s=arc-20160816; b=zgtwUu3wa6uTVTOmakGL19u7vc/FFKiKo8RAulG5Kihy97DbexNaWqIdxA/hZVBcoH Vpia68ilsg0v+7Mp40YaTQdU5PRKMnQZ63XOGW+ne5NwOsdm4hNK1XYFAfGNTXcBW5JV 8AQVXffekiZynKzcvNm248YTnXmfIg1E8EYSLM+uOI+MjREgGH4Ds3SV7humCKhbxUMr QU1Ter1RNJsrbraAYMWQdAdS5dGrvr9Cvu4kEXekCTc0bQVb8sYXR7q2VcSIJXiHcPRc wrjrwhdU0N5Bd98MYNSERQLHaO2lc2oOww+fm0Ir66/H8U9XJF1XcHHwdzv/3BOpGSWB dtYQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=Nsdkf/hEokdRbVfsff4bOqv3Tbq/llwdsETViLwX3BI=; fh=yBMj+TGhyeDp/v2yBxfWHuw41ns8Em+9QHX1J9I0C7A=; b=zdhGKVZGOo27BWMY5M635eq//tVXJybQAVJ+0NKfEdnJZScQmycaFkgCGYBDuOZVaZ u4Abr6rkzhtWeh6Wap41H2jFvjI8BAbLh0lnYYug17TLBVwW34Xm5UljAgUA4el+8qlT ixyByQO0xFSZxiCyY4rD4YcZn5X1V81sM3rC+fW8XFGwc8ojBPrii6n8qjnMsveaJ2+/ /XSM7bHrPKDrYPAY1Dtu6lsKihSBoiIGCcCbhbcXcMfVzbRqaBtoOrwHIa5hl3q22+K3 MHrgJEkXkRLQKmdRZ4+nbgY3RzwyX/isp8PeQX+Jfqzf1NkIPjTtRmetK21am1TbGpDx r2lQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=google header.b=RD+Z1RpA; arc=pass (i=1 spf=pass spfdomain=linuxfoundation.org dkim=pass dkdomain=linuxfoundation.org dmarc=pass fromdomain=linuxfoundation.org); spf=pass (google.com: domain of linux-kernel+bounces-195515-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-195515-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id a640c23a62f3a-a6536ce7800si194654066b.856.2024.05.30.07.26.13 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 30 May 2024 07:26:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-195515-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=@linuxfoundation.org header.s=google header.b=RD+Z1RpA; arc=pass (i=1 spf=pass spfdomain=linuxfoundation.org dkim=pass dkdomain=linuxfoundation.org dmarc=pass fromdomain=linuxfoundation.org); spf=pass (google.com: domain of linux-kernel+bounces-195515-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-195515-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org 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 A00EB1F22DDA for ; Thu, 30 May 2024 14:26:13 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id CDB8217C235; Thu, 30 May 2024 14:25:24 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="RD+Z1RpA" Received: from mail-io1-f48.google.com (mail-io1-f48.google.com [209.85.166.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 568FC176248 for ; Thu, 30 May 2024 14:25:22 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.166.48 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717079124; cv=none; b=a9aUchAvjkGx6mxhjusvEj7c0Ift2zf6NkbYWGZnLk2Xe1nh8/ehSkfHQ3SwK1B0g2dfrX8p6MQzGmrSBLYPxVOPkH2Mpb5brzS/iiIyX/htc65crfN6Xj0ojDnHNpU6fPa4lUaDh1qJKTDvnqb1FILWBtERcmB1UD6LcVNpPEM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717079124; c=relaxed/simple; bh=g/X45uSF6k+HRkBUhwjSpxSxuIqXtM9kMM336BDvTlw=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=XnCiM/86UVwl4VwxIh4dCEarAFojeY7L+dPoowNTD+3qLn3Xc6V4UUJiNuqjHsaEWSNkrSM+lflqdnyZT2TlKOJcvK6VE0WThZC0TqyO8SvdsJtfqc/tJZVWzydHLYi47YeHcOLk2VwezzO1sm2J3zAbIoWZvDCJQK2QRZX+kPQ= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linuxfoundation.org; spf=pass smtp.mailfrom=linuxfoundation.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=RD+Z1RpA; arc=none smtp.client-ip=209.85.166.48 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linuxfoundation.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linuxfoundation.org Received: by mail-io1-f48.google.com with SMTP id ca18e2360f4ac-7e22af6fed5so4631139f.2 for ; Thu, 30 May 2024 07:25:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=google; t=1717079121; x=1717683921; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :from:to:cc:subject:date:message-id:reply-to; bh=Nsdkf/hEokdRbVfsff4bOqv3Tbq/llwdsETViLwX3BI=; b=RD+Z1RpAzQpOdC7U+oHVdomJ6iMeO2XvQo57qkFkRE3lZuzhlcD0OstuzQqPYdcs47 G6jY/SqKhOvKL2d+WqHDalzPAy5XSLFvXS2S9il20hED8braufeUBbUNKr7b2VK6O8zf vNj59lLtWXeH0iFIfQvy5CcoKDmguMLLBniek= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717079121; x=1717683921; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=Nsdkf/hEokdRbVfsff4bOqv3Tbq/llwdsETViLwX3BI=; b=JOywnyrf6K8NUvr/goz4kW6m6i1yE8k+ajBSpz23UhddU1B1Hd/5Hag9s1M0L3YYAo 3jOQfOnTV8K6g1iXa8BLHAB2sn2gRwVyH2sA02IJUDrCbg/OBTb62r/bxhWYOXTCOQGt 8+P9V5Yelq2VyvbzR+LPIGPVZ+Brk+IpZcUQaU2ZPIIZgKDScAynFVDoMUj19Pj3ad1a KOrFaVWkBujXJEDhxMA1vWtg6R3jZQEJAcOYu6XGR3R+CV1rkqp9jSMOaR4sowg4LXbR IxEgtYvcYHTvdm5xLALyj7xNTHd8sMoj370WEz/toavU/1VVSGv89SIPSvQTnISZYeTX CB5Q== X-Forwarded-Encrypted: i=1; AJvYcCWaZZaolwgb7tXSNclbjaK6dKRhH0eW9dfYE+hBCZy4Mswc/KoiSQN5H0S+aB3rV9n3+RBrwIq585MD5oC1z4lcSX2L3I7BwAbKHdUM X-Gm-Message-State: AOJu0YwNGsP8VKBk5btMsGcSMog/WFLdCFlWaIyupmSBHyKKyQw16MRU Ac9mg1FEgwU7qn7SopMT/L3LeM7tKVDl/5ftJJcFsbxpGvOWK4W8ZH40QAl7B5Eu3a+tXwrBCip B X-Received: by 2002:a05:6602:19c9:b0:7e1:8bc8:8228 with SMTP id ca18e2360f4ac-7eaf5b73813mr241539839f.0.1717079120876; Thu, 30 May 2024 07:25:20 -0700 (PDT) Received: from [192.168.1.128] ([38.175.170.29]) by smtp.gmail.com with ESMTPSA id 8926c6da1cb9f-4b10cf31917sm1404185173.45.2024.05.30.07.25.20 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 30 May 2024 07:25:20 -0700 (PDT) Message-ID: <88c64f5e-4586-4b38-b3c8-0c3af93a71ae@linuxfoundation.org> Date: Thu, 30 May 2024 08:25:18 -0600 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 2/2] selftests/lib.mk: silence some clang warnings that gcc already ignores To: John Hubbard , Shuah Khan Cc: Beau Belgrave , Steven Rostedt , Mark Brown , Naresh Kamboju , Nick Desaulniers , Justin Stitt , Bill Wendling , sunliming , Masami Hiramatsu , Valentin Obst , linux-kselftest@vger.kernel.org, LKML , llvm@lists.linux.dev, Nathan Chancellor , Shuah Khan References: <20240529020842.127275-1-jhubbard@nvidia.com> <20240529020842.127275-3-jhubbard@nvidia.com> Content-Language: en-US From: Shuah Khan In-Reply-To: <20240529020842.127275-3-jhubbard@nvidia.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 5/28/24 20:08, John Hubbard wrote: > gcc defaults to silence (off) for the following warnings, but clang > defaults to the opposite. These warnings are not useful for kselftests, > so silence them for the clang builds as well: Please you add more information on why they aren't useful for kselftests. > > -Wno-address-of-packed-member > -Wno-gnu-variable-sized-type-not-at-end > > This eliminates warnings for the net/ and user_events/ kselftest > subsystems, in these files: > > ./net/af_unix/scm_rights.c > ./net/timestamping.c > ./net/ipsec.c > ./user_events/perf_test.c > > Cc: Nathan Chancellor > Signed-off-by: John Hubbard > --- > tools/testing/selftests/lib.mk | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/tools/testing/selftests/lib.mk b/tools/testing/selftests/lib.mk > index 2902787b89b2..41e879f3f8a2 100644 > --- a/tools/testing/selftests/lib.mk > +++ b/tools/testing/selftests/lib.mk > @@ -50,6 +50,12 @@ else > CLANG_FLAGS += --target=$(notdir $(CROSS_COMPILE:%-=%)) > endif # CROSS_COMPILE > > +# gcc defaults to silence (off) for the following warnings, but clang defaults > +# to the opposite. These warnings are not useful for kselftests, so silence them > +# for the clang builds as well. > +CFLAGS += -Wno-address-of-packed-member > +CFLAGS += -Wno-gnu-variable-sized-type-not-at-end > + > CC := $(CLANG) $(CLANG_FLAGS) -fintegrated-as > else > CC := $(CROSS_COMPILE)gcc thanks, -- Shuah