Received: by 2002:a05:7412:bbc7:b0:fc:a2b0:25d7 with SMTP id kh7csp2770574rdb; Mon, 5 Feb 2024 18:13:29 -0800 (PST) X-Google-Smtp-Source: AGHT+IHVpq93/gH/ZsdW/ozFBXTHLsR/nZO4+dGb0lVUvngiddmdap3EkFGUdCA0xrSAC+GTGp8r X-Received: by 2002:a05:6358:9044:b0:178:b0c5:9aef with SMTP id f4-20020a056358904400b00178b0c59aefmr1791544rwf.9.1707185608785; Mon, 05 Feb 2024 18:13:28 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707185608; cv=pass; d=google.com; s=arc-20160816; b=PgTZKk40tY/e0iK4mo/rMo8QGvZg/bKCf4CcUhuSKmkqfjQ34vLddkdd1lVzIcbdGO tZK1HRk2vvaNhBWPFmWxDbgVAiYS3obLnXJgtRojrO9Kl5Pnz1SXgTnrblHubUmJTY5e 1mHVDBMJ5ubaSIxgom5jmWoing1S5lYTyGcdoEVsDPwy6FXBsyGQerXzIGAtwQLQtdPI Vm+SGi6lx/G+V1AZJXoOCmlja2av54f2992DKTVFLP2MsJ18rgYTxKZ++z9CcMlipRTp I88yKoVAQYmyQy6inWktJnXB+yjiJYtJ1niRcsojzkzTrOsE6CWlyNI8a7+4OKbisaSr cGWQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence; bh=KTAyl5iKOFA0ikqjI1lmw6AmuPGoKHG8xJSD/r8dg+4=; fh=/SlgtjG3VEMFFLzc9656dEmvGHxLpCdecO5VCUmV+is=; b=cAnMhsd4HUtPkM8e/q1bd4Y7arAjpS6EbR19m6+rtkeKQf3J+9JyDlECSqJTKXXuhR eqx+WvbnW/YvvnA77rHUf7aXG3n68mnT2+ZllAABgL4Js2xqNUEbClCKyEqCe+40fREv tZpGXbObstjsV6VCWBDUvN1dG+RhDmoSOdAOAlHBCD15fUAPsQUcMEq9AvDgcm30J/xM 0C+b0l6wzSmtZvzJsxx5nA5NdBJedQSsTFV5ELZCaKQLubV6wytW9V7wkbkTRud9WlWD ft23/XqUQoNWrFdJQgGbRZQuIKdt6DHkzRcHWdQyrv12dXmFw8fL40wQ1ULOXb3O0+5j ClYg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-54187-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-54187-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org X-Forwarded-Encrypted: i=1; AJvYcCUO8PPEic+rNpJYYOdbW9Br4eisZijs5nl/czcrrV09I4wNPRpkZJWLbm5bBAKymCFRfImYuHe9jlkcaA9Y/MpsnF5neGHkKy4DaMZmzQ== Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id w7-20020a634907000000b005d9b49b7abasi800986pga.846.2024.02.05.18.13.28 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 05 Feb 2024 18:13:28 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-54187-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-54187-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-54187-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.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 sy.mirrors.kernel.org (Postfix) with ESMTPS id 6AAEAB231E9 for ; Tue, 6 Feb 2024 02:13:21 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E5A9D56B95; Tue, 6 Feb 2024 02:13:04 +0000 (UTC) Received: from mail-pg1-f173.google.com (mail-pg1-f173.google.com [209.85.215.173]) (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 124A456B65; Tue, 6 Feb 2024 02:13:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.215.173 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707185584; cv=none; b=KnGYZItBA4Xqpbfs80y0fktIZa5oytCnHkCAOoR3rNIQ4WkW6uLyYVssKjzVOWc+wl+NSRczg6MgBwulwSITOgO1epXoYOOlHQZZNC486zJTFtfaANiURQYJ8NMt3GF/tEdmAXBCaSfhvNvc4CYWTBXkTD4QK82vVNlWTjPTKKw= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707185584; c=relaxed/simple; bh=bs/ur/xiB+EKXQSIm4/pErFIuws9bv1BgqZoNxClTT8=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=krhpB/feyL2G/BtRsCjVVs5QQ795vAwJkD0/Uos9Yywn5FSIthQzdLinMcSW7faa0Sc6ZSXSMeuRmivsDj5VHxs6+ciMdDNWpRxnmIHRvrEeuHI+nf9AUNOPKlaHrp8uks25cwWpgNK6BuL8Rj7qQA3P4AR+dW/n6bTW+t0XSuw= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org; spf=pass smtp.mailfrom=gmail.com; arc=none smtp.client-ip=209.85.215.173 Authentication-Results: smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-pg1-f173.google.com with SMTP id 41be03b00d2f7-5cddc5455aeso4476655a12.1; Mon, 05 Feb 2024 18:13:02 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1707185582; x=1707790382; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=KTAyl5iKOFA0ikqjI1lmw6AmuPGoKHG8xJSD/r8dg+4=; b=lB45QgIWh0gsXfWvptPQgjq4wPGoEgC7nR3PgTO1BK45Scx2nRr5EK787Zk/ZeE2fl UwBnLgK4Ilq8eO0gUoTLRSsVb75TpDg5Q1DpX5yd76EBeq2ALKNBRlCeuxQXC7DrYlgt PPDwIH3UunHlpaZnHSIoBYJviZrUGkoaImxq1zEoT51i3xkLjkG5wVaq8mU/SDcju85Z AL1Xh4iKJa6Q9cENPi1qND6q6Dx+CbvkdfiaZwrjBD+Na054iSPe8IMNQbgXsq7hok3C /jL1RDKExNfWY88Cydfk0reNZelVcEX9PIQh0tyZmnSfunhTOOPyAcSKQ5MMPo2FFNxY F+Pg== X-Gm-Message-State: AOJu0YyT11PiQYbwT+d92h2sdubCPa+j/TJtV0ego4e2VvD12TBdSO7B jgDGDGqMiOIPlbuV1UAtqwD94N2YJgjS6xnVnZFfdXycBrckQEw76tDes9TwegESEnWVne71/z1 JKQf6He0wuzwpwU8MCzGVh9QpayY= X-Received: by 2002:a05:6a20:1ea5:b0:19c:53e4:e67f with SMTP id dl37-20020a056a201ea500b0019c53e4e67fmr280535pzb.15.1707185581779; Mon, 05 Feb 2024 18:13:01 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: In-Reply-To: From: Namhyung Kim Date: Mon, 5 Feb 2024 18:12:50 -0800 Message-ID: Subject: Re: [RFC] perf: Reconsider an error code selection in bpf_map__fprintf() To: Markus Elfring Cc: linux-perf-users@vger.kernel.org, kernel-janitors@vger.kernel.org, Adrian Hunter , Alexander Shishkin , Alexei Starovoitov , Andrii Nakryiko , Arnaldo Carvalho de Melo , Christy Lee , Daniel Borkmann , Ian Rogers , Ingo Molnar , Jiri Olsa , John Fastabend , KP Singh , Mark Rutland , Martin KaFai Lau , Peter Zijlstra , Song Liu , Yonghong Song , YueHaibing , bpf@vger.kernel.org, netdev@vger.kernel.org, LKML Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hello, On Thu, Feb 1, 2024 at 10:49=E2=80=AFPM Markus Elfring wrote: > > > A null pointer check is performed for the input parameter =E2=80=9Cmap= =E2=80=9D. > > It looks suspicious that the function =E2=80=9CPTR_ERR=E2=80=9D is appl= ied then for > > a corresponding return statement. > > Are contributions also by YueHaibing still waiting on further development= considerations? > > [PATCH -next] perf: Fix pass 0 to PTR_ERR > https://lore.kernel.org/lkml/20220611040719.8160-1-yuehaibing@huawei.com/ > https://lkml.org/lkml/2022/6/11/3 I think we dropped the bpf-loader and it seems bpf_map.[ch] is leftover. I don't see any users of bpf_map__fprintf() in the tree. Maybe we can drop it too. Thanks, Namhyung