Received: by 2002:a89:48b:0:b0:1f5:f2ab:c469 with SMTP id a11csp328380lqd; Wed, 24 Apr 2024 03:49:35 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWOjpUJf5v5l00Y3s0YOIHu8/XD0ZFR8eK+wW81jjJzONdxux7uispyxPYREnHQ0vxyEVyAhHitJYi6hQXJIe8DKQbhWzJQl+yCzaqdnw== X-Google-Smtp-Source: AGHT+IFK2EKfaPtxzsymXimb6BsHLV4v2ysoofs4wZ3uOCdygM2YW6S9Ykkg24Ubvr1/SZ4CsnHQ X-Received: by 2002:a17:902:7449:b0:1dd:7da:e0a9 with SMTP id e9-20020a170902744900b001dd07dae0a9mr1935307plt.69.1713955775393; Wed, 24 Apr 2024 03:49:35 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713955775; cv=pass; d=google.com; s=arc-20160816; b=dlM/FpLMOsBjwdoXnKKSEbiIkZkrEOcAf52PIdTEjPxsdr6OaclNTVcnSOKie+TjWw yiw1HKsfFEUsGqkzHi1o/5+eCAgzyPc8OKuRxa8TroWGvrq61XJlY3/Mwx+1/Ex0TuFt /F4YEq6fwTJI2tC9C1A9XPemVelLISMF4ygi3T9g1cU3fauXgtNFxUg2slWE5RwEGlM/ BPVO4DSZQF7nkgEXgW2A+Ix/7vpcRaakM7naQmiJuOATArHPIl44ELvborp8JpVE861n gNc+e0znwWI/IOu3h7SpFa6OkCN4od1bi4TydY7XZc9Cu98coJe8pJo9Drl49tkJYDCS qmvQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=ui-outboundreport:content-transfer-encoding:in-reply-to:from :content-language:subject:references:cc:to:user-agent:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:date:message-id :dkim-signature; bh=Qk2Z9Ur/axCDf3ITMI3JPxcQXOHmAKvjUk3aT8fYJig=; fh=l3fUrkSUtTS0aFxVoZ/XgQCW5c0i8pACsVYQnC3u3Xk=; b=iRcbKBxc2IOAlooSVf0u8VfwUGeupnnbGMv2tDicPlqrTtLztZg6ZS/kCg+K3g99Hk qBluWXi+AqrDquG20Tv/CKciT5KriwUxugDXKCb+j6TSBU19IuB4L/KfXn3vRw7uXPRd dNe4JM8HlYMrz0VpImpsjEIKYDle2wNtf0hufmbuWzWlek8Cn+mk3fcvRXH6S021SaX7 /i5HqGnVQlRl6e1q1u6olQUVf/uQonw+cf9cyk0Kg1MkrJsxJKfO/bLjZ69LNaYt3LwZ LHep6BuhQShhjICjsAXb/9WLUa1eDrdtjhLlTjdrKIIkndu4jdmr2p2HCWu+mjLkUzF6 a/dQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@web.de header.s=s29768273 header.b=HZWPnBpY; arc=pass (i=1 spf=pass spfdomain=web.de dkim=pass dkdomain=web.de dmarc=pass fromdomain=web.de); spf=pass (google.com: domain of linux-kernel+bounces-156748-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-156748-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=web.de Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id d8-20020a170902654800b001e3bfe204c4si10974485pln.650.2024.04.24.03.49.35 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 24 Apr 2024 03:49:35 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-156748-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@web.de header.s=s29768273 header.b=HZWPnBpY; arc=pass (i=1 spf=pass spfdomain=web.de dkim=pass dkdomain=web.de dmarc=pass fromdomain=web.de); spf=pass (google.com: domain of linux-kernel+bounces-156748-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-156748-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=web.de 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 sv.mirrors.kernel.org (Postfix) with ESMTPS id E7209284B3F for ; Wed, 24 Apr 2024 10:49:34 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 16C621598FB; Wed, 24 Apr 2024 10:49:25 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=web.de header.i=markus.elfring@web.de header.b="HZWPnBpY" Received: from mout.web.de (mout.web.de [212.227.17.12]) (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 4F5DB3EA66; Wed, 24 Apr 2024 10:49:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=212.227.17.12 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713955764; cv=none; b=KSjt6QNduziLR2PweJEhSu/JVxU1+drhLpXj5UKWW2ic8PZ30exCORpEuNM9Wc6Mo+lJRxRkx7fxBrMN6ysmZoMyVkyko8DejixAeeVGccjXmlmRBqnxeYfUua0drdiTSl4GiTzATKOQgx0kagzF0qsDZNj5W9EJvQfldCSnKaE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713955764; c=relaxed/simple; bh=Yee0/Osb8LuV3ZB2AQuxep76YOpKew5FVBEd5LX1IP0=; h=Message-ID:Date:MIME-Version:To:Cc:References:Subject:From: In-Reply-To:Content-Type; b=g6AsjhaG48kDI5i1DRtoMKNyJ9Z5WoYYwtxpNFBZGBMF9DqFB5tUPD7wZ3b7LqUINkYPWLvzqosuNvubTSslW0E33Pmi2MjMkzf6ef8QL5XIpULm/LdqzEvx5Y6SNZBIb0OfzGZ3sdIIVz4xTATZBvRiZvVYlBQ4ourWFwnh9v8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=web.de; spf=pass smtp.mailfrom=web.de; dkim=pass (2048-bit key) header.d=web.de header.i=markus.elfring@web.de header.b=HZWPnBpY; arc=none smtp.client-ip=212.227.17.12 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=web.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=web.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=web.de; s=s29768273; t=1713955735; x=1714560535; i=markus.elfring@web.de; bh=Qk2Z9Ur/axCDf3ITMI3JPxcQXOHmAKvjUk3aT8fYJig=; h=X-UI-Sender-Class:Message-ID:Date:MIME-Version:To:Cc:References: Subject:From:In-Reply-To:Content-Type:Content-Transfer-Encoding: cc:content-transfer-encoding:content-type:date:from:message-id: mime-version:reply-to:subject:to; b=HZWPnBpYG78wi6FtGgGW3nJxdpOlFMEO+jprXyl+stSY2M6NWD90qe16+McfvgpC o6lXPzI2TjHFnCyQ5FySjnsIelOoHiir71RG6MBagMPIJJ1NLL8CfBrsMvCetMswa qNqA13j1gXp9ovCSuuXpqYz6T6ixxCnSHolZm5dTEVid+pzZ2wrd5LtHT2ioEOA7T aNt+2zWlxkUApJtNNuYPiEgSbLdqQnI8u88a96IgK6tWF5gxhfRp9Mn315ELA4njF 6DBuWWTweleB4i5mLhc85HeDIoEPiFrNihua+Hbe4RSVuWUuOShiwz5r3d35qU4jB FoAKx/wrycVpbbfqfA== X-UI-Sender-Class: 814a7b36-bfc1-4dae-8640-3722d8ec6cd6 Received: from [192.168.178.21] ([94.31.85.95]) by smtp.web.de (mrweb106 [213.165.67.124]) with ESMTPSA (Nemesis) id 1N62yY-1sjZ4I3ftQ-016hUt; Wed, 24 Apr 2024 12:48:54 +0200 Message-ID: Date: Wed, 24 Apr 2024 12:48:53 +0200 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird To: Kunwu Chan , bpf@vger.kernel.org, linux-kselftest@vger.kernel.org, kernel-janitors@vger.kernel.org, Alexei Starovoitov , Andrii Nakryiko , Daniel Borkmann , Eduard Zingerman , Hao Luo , Jiri Olsa , John Fastabend , KP Singh , Martin KaFai Lau , Mykola Lysenko , Shuah Khan , Song Liu , Stanislav Fomichev , Yonghong Song Cc: LKML , Kunwu Chan References: <20240424020444.2375773-5-chentao@kylinos.cn> Subject: Re: [PATCH bpf-next 4/4] selftests/bpf: Add a null pointer check for the serial_test_tp_attach_query Content-Language: en-GB From: Markus Elfring In-Reply-To: <20240424020444.2375773-5-chentao@kylinos.cn> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:c7wSIBl9mvxe/oo1tdl2vCRED6SYaYM8u6v4WauSkzejejYjAAt np5HfYpoZymH9VE+IZbNGK7UqHxxYOoeUNdeHlUWsqagJoj7pULCM6DnYHOSFT7WVDt91ul agYKJlHPB1bpxlkv27osy0n4hLtJv25QQFmLZR/q4HZ3wmS+4Iuj4o0oBrxiFbHlhoBgknI ktcCV5r86GvRaGWcBc6NA== X-Spam-Flag: NO UI-OutboundReport: notjunk:1;M01:P0:H46wqUsSReI=;BwoCsKVvVwzyZjotKK3Nz6BIaFO X/dcVBjZ2kBDBNMpqeYhSD5fE4tCWcZ5jrxWULfBXJAr2EutOXOpgl1G0qu2H3JLazNGIZVPS PM3RpIj+qFRp+vdy3Ekyl05Ku4BzhxAToEeppc2Sv2tTdwxTHyMf/mCeXrQMdsidwROXDXLvp Cu6rZ90AVRNrMFDZLaPWZlpOT2cXZmxhC2waj+amMoPIGSxaT+FaIZKmSRdkT7SUXoRSOTdTo TEMcOXkYh4hwLboXRK06KVbg8ZT2D7xqBiwJKuFNFYeJqwSPLwdgaKvNwMT+Pz4d6BM1bcLh0 HbXWTr41j4LCOCkZ8lhAipr05tDtXE1tZp57zSVaJItwuy8zEGYUB5cggXlscrTIOBU6wN800 AMloERz30e2+6F7R4AaD2gDpqUZVAK2EwW9C5wjxvQ+Yvp2tadPg6SG3b6BI/HM0wUTCUNsvz Ni1pVUsjoAjvqWRsJiBAMVv81/lU1vNujxtgJxIeukmuxGBspmv3pxl+FH/MPalJL680Ekb+w Ka+hYTjJk9qkGtisXZx9m8hNtlnZjvr/jKNG5ZS64tSKMvuRJN4sm3n5nXn3e3neO2LHewWus Vj84ewHD4KZiRzHWtEyU7FVismC0UQ7sQm4nWC7uGj+0854UawZM24d+FvjDho0Nijsx/DJHw GB2ZLGjCyZwR1q7Ok1SbWRlaZGegWyTnvNHv7OpKBLv2Og5WTpnK27cvgmEMhUTEnXpIBHz7m Ad+oF+tdWJDq0DGgfDmy5cXeSPD8fuIVmylzy1pfQGotMlo8T5P8/VlFztNfRdmyc5P7i3fks ltS7ZFjcRL36hJQsO/0M8GegraZ6hIMpp0ZHvYwIvjQug= =E2=80=A6 > Add the malloc failure checking to avoid possible null > dereference. =E2=80=A6 How do you think about to use the following wording variant? Add a return value check so that a null pointer dereference will be avo= ided after a memory allocation failure. Would you like to add the tag =E2=80=9CFixes=E2=80=9D accordingly? Regards, Markus