Received: by 2002:ab2:69cc:0:b0:1f4:be93:e15a with SMTP id n12csp131860lqp; Fri, 12 Apr 2024 12:35:40 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWpw/Fv32twKDVQ6TbRg6vluozl8ex6cdID+mnhHAfpsy7ZuKrU4+i53VCypbtXSuQ+yZQKz2S0ByMan6nLaWEmZVIGGS4YjjBkyRIyyA== X-Google-Smtp-Source: AGHT+IF7KMCBFAWaBjcIaBAus6xD0SVxmnqd0hTD1QVt7py80yMFgl0i8j+Sf4LvFBKPD3L/aKIO X-Received: by 2002:a05:622a:6f0f:b0:436:86a9:bb34 with SMTP id iv15-20020a05622a6f0f00b0043686a9bb34mr3589984qtb.24.1712950540653; Fri, 12 Apr 2024 12:35:40 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712950540; cv=pass; d=google.com; s=arc-20160816; b=CIAjpWJrqzPozOJlBtM7cN+XOJQEguQPtUDM6X4T30nYoDrXJjK0A/LXMhzOPCRUX3 PN70FqF9EscWWs53kXWSTf0U1rZckN1/3f31fTGgQy103nqFNtpF6H8xtUpqCJYt5mwK T3OSesln845W0KHHF031QErK78PaGuXoGUmVVF2qytFahmIQZU7H3737FUGkxYIKC7dS p2UvaRJrk1MJJQtGF8Nw2lvODhAi5UvZiOOSZCMQWcgWU/gpyoOVxjClQ9QusT+RngGq P9u295/IdStm5H7nOfMCfFN9G1WkNzDdAIcAf4PKOwOcfIyeVejxUfEpJWoD7OpXvMPZ I40Q== 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:date:dkim-signature; bh=wmhZgnduSoB9HTp1EOHCUZWMTUbBylJxN1xdqV6A8gE=; fh=+nf3xsUObfH9Yp5NDiwu6oI02KIu+MFZ4MEudg/3pt8=; b=GvzLIb3nPuTgy2Gstf6NKQAyYTWLV28AOiUznwbMPjXblgevmtuoXRWm2iKSM4Gd70 dY2WckWtej5fS2vIyeMwSKmJJvZEeg2W6Q01mwJkR2bFcSqvWTYyGyQXfTlcC/4j1/e5 xIF4eKpk9MymjVfdUz8ZVya2EBQcb/xRtJQr3wZS0+xiDEROumGgFU9DH5WrR2cjSJCF KXhfZq0eEXgRXNguP5AOunoYCeRNXGmR7ylzEw2DbbnjnSwxf+nwSxftRpeFAvRPTcL+ Z+OTzWJJoetkEo/TwWth4vhBpoB4N+ECbzat341YoHIoYJ7VdWF2vStpMF2S6LWzB3mr edZg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=cpwJTI4i; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-143263-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-143263-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id v18-20020a05622a145200b0043665a58b5dsi3987751qtx.381.2024.04.12.12.35.40 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 12 Apr 2024 12:35:40 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-143263-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=cpwJTI4i; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-143263-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-143263-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 ny.mirrors.kernel.org (Postfix) with ESMTPS id 624E91C23179 for ; Fri, 12 Apr 2024 19:35:40 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id E44BF150984; Fri, 12 Apr 2024 19:35:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="cpwJTI4i" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 138E584DE1; Fri, 12 Apr 2024 19:35:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712950532; cv=none; b=HtCUgvpQQdSvtX80Cc908yHAo6V5v2uTyetE0GzVCOEzkQtSJTJH/VdSLCrL5PH5W4BHF1oM2bTdU+N7QqEf9MbnWfEfFxdBSQoTjFwpGIeDAsCc+Xzu/SEyfSV3FAObVUu2ml4+ltydjf378VNoVqVBSw+CmFqxCrniMKeTNFk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712950532; c=relaxed/simple; bh=ofVVy4zferD+RNPrdaRnvyrBwq7zff5WYyjwpk4ktSY=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=PuukcwaS7oqp2wn9mIdhSBxQA7XtIq/y+HUr4lG+/6UNrF8z56DE3jkb/is6AhEDbgRsag0V2PBPjuxAUmXI7HIGrTW7lS6YaKjgZaLDMSm5XjtOg1DuLU+F0tlgrfKSt+w8NDqU10+hbuIkQ/KDoNhRjXZmUp2/c0jS8uf1Kl4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=cpwJTI4i; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 15CC7C113CC; Fri, 12 Apr 2024 19:35:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1712950531; bh=ofVVy4zferD+RNPrdaRnvyrBwq7zff5WYyjwpk4ktSY=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=cpwJTI4itTVfMiJUAOaybYNjldBMEvIp9h9tBGn60Kgn9Loqjmt4XdA5pgDeSlzpr UGcd2U1xM+oSLRjKs71liI3qDqECEGzQUwzYZQwMWx4y3zRPvuSBFAjB2QV8mSK21g HUrvb/GII4suEGh113rDQ2KxVXlv07Sa4QllDSSbwCmC+0pgBSnYwd7xejC5rNBqvO 6K3EXjyk/9Gh0sFert6VdVwGrqNCsGWBN2Y1qT26TLsZvbB2xvZC8Xx9CbrZeLfjfs JXpeCmDsZtzp71VYw/dqSenJUY+UMKZ2AMv8Thi74mvCIETUmnvuUj6IrUQiU6cPhk /lGx3S6BuF7tA== Date: Fri, 12 Apr 2024 16:35:28 -0300 From: Arnaldo Carvalho de Melo To: Ian Rogers Cc: Peter Zijlstra , Ingo Molnar , Namhyung Kim , Mark Rutland , Alexander Shishkin , Jiri Olsa , Adrian Hunter , linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v1] perf list: Esacpe \r in json output Message-ID: References: <20240410222353.1722840-1-irogers@google.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: <20240410222353.1722840-1-irogers@google.com> On Wed, Apr 10, 2024 at 03:23:53PM -0700, Ian Rogers wrote: > Events like for sapphirerapids have \r in the uncore descriptions. The > non-escaped versions of this fail json validation the the perf list > test. Thanks, applied to perf-tools-next, - Arnaldo > Signed-off-by: Ian Rogers > --- > tools/perf/builtin-list.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/tools/perf/builtin-list.c b/tools/perf/builtin-list.c > index 02bf608d585e..9333cc64c2ce 100644 > --- a/tools/perf/builtin-list.c > +++ b/tools/perf/builtin-list.c > @@ -313,6 +313,9 @@ static void fix_escape_fprintf(FILE *fp, struct strbuf *buf, const char *fmt, .. > case '\n': > strbuf_addstr(buf, "\\n"); > break; > + case '\r': > + strbuf_addstr(buf, "\\r"); > + break; > case '\\': > fallthrough; > case '\"': > -- > 2.44.0.478.gd926399ef9-goog