Received: by 2002:ab2:620c:0:b0:1ef:ffd0:ce49 with SMTP id o12csp1003886lqt; Tue, 19 Mar 2024 09:56:46 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWY/eTy7sGv+iWJ/E0Dv/jJVhaxMNp1ROz50n4xiornJqtous/aK3+LtAUWfGfxm0MzuzGxerNmel2e6L8Oj304WnXUg1RXjpRgzr0Aew== X-Google-Smtp-Source: AGHT+IG0AgSSRplCfZfjVJ8Zk4Uvz5G/msfivgTPBi16/1Z3r0TrkWdNJkBbwNVz14hXh1tWKcGX X-Received: by 2002:a0d:e4c4:0:b0:60c:ced3:8e26 with SMTP id n187-20020a0de4c4000000b0060cced38e26mr12592086ywe.13.1710867406276; Tue, 19 Mar 2024 09:56:46 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710867406; cv=pass; d=google.com; s=arc-20160816; b=HXiIMwMNbUyeZrDhzd5bTAoRW1VBkKbdE/sHiZaVlcHB7Q7C8m+43rMaj0mtQ3etTv Dt1/AalxAiQvEA1CIV423E2Zt8RpK03Yat50JRsUV7QbxnNXX7jIaOM4aWiWYDbNmFti vI+Ka6+FOBKR3/coRBzVq+9wSruWMCPx//g+fTzHFtNmUGcn16usd6uhaptWw+GPN3sl IXH2/S3lsKVh5fUmqXFBaTH0/Yazccix34TG5wx8nfNsi3ooNr3pK8hjz0XCvVNaULfF VNyGFe6JLQmd25Y2yEFOueuRsiP+jHzzVEpE/GMgX+gua4GiDsNXCSmatkHgMU2HaPJD 0eYw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :subject:cc:to:from:date; bh=xj6Dr9T5O63sGKdeXgvZH5BdFF+EiLzQOomWT/k0nRY=; fh=2W2CxoUWBITYWEypmpcoxwnk/wMvjYmNwyO/jWIYVUQ=; b=azPA3NaR+PbvjqLS4wkVamIKaI+IokSaW6S0VpOUqrtwh2TP9lFSkEaDYiKtU+Op1D Vcd/IaWpFJ+WbK8qHQOZdsg8waI0nd4V/BvX2x5ZDAnGmHwA4OWy+ORGQ+L1oA2G3r8O JBQrI0+Lm2xkdbFuam+s3h8mrtgXNtFWo4u/Vz9ZlFtEePvksl7HApn9AKUnx6Edy1x4 84wLPU9eH8iB80HjgGmV2n7UWQLid+rk/Gc/sfyZcEmbJHGPktOJpXvy7DuNpI59kBlo 0/xJC84V2xW9xS9tFyWVXurPWhY/uWUEfFVymSA8oLgV3JDSCXlOGU/GvQvNsjd5ejD6 SNZg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-107870-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-107870-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id j20-20020a05622a039400b0042ed1303b2dsi12488097qtx.264.2024.03.19.09.56.46 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 19 Mar 2024 09:56:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-107870-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; arc=pass (i=1); spf=pass (google.com: domain of linux-kernel+bounces-107870-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-107870-linux.lists.archive=gmail.com@vger.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 C55701C2267C for ; Tue, 19 Mar 2024 16:56:29 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1CACE1BDEB; Tue, 19 Mar 2024 16:56:13 +0000 (UTC) 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 9D09218EC0 for ; Tue, 19 Mar 2024 16:56:12 +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=1710867372; cv=none; b=ADSy52U4qg75oHJ+tiIPqYPAHyAQXmPnI22JjqsuarQBggmLJFhKlJayvetTC/55SmrmGe7iR6sXnn9ks/AmcTOCKa9u9jd5TWP19ri2kWsvzIcj8r3GuCpW3OxwNfEenYHkN1FtkGVOGxuvnMFp9TTf4wwIhrA1/Pb0yN4Acyc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710867372; c=relaxed/simple; bh=shhA6J6IcnJOSAhU1RZmsl4eapiTt7sfthNIV7XitGo=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=PF2DehjFNsuujV2I0oFmxdqlRIhDKxvP5X8vpQcKX7in/fVla0fmtidz9BOsyjkvR8jyTFvzsDNaDl3dWDGthKmiuzN333uesKkQmsUZbrwdvOvA+DY3HwKedo1eOkoJM1FFl+iNpWVfHKDduXLYzNZRZnMXp3FjVLPIMn1ZXHY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id DB314C433C7; Tue, 19 Mar 2024 16:56:10 +0000 (UTC) Date: Tue, 19 Mar 2024 12:58:33 -0400 From: Steven Rostedt To: Linus Torvalds Cc: LKML , Masami Hiramatsu , Mathieu Desnoyers , Alison Schofield , Beau Belgrave , Huang Yiwei , John Garry , Randy Dunlap , Thorsten Blum , Vincent Donnefort , linke li Subject: Re: [GIT PULL v2] tracing: Updates for v6.9 Message-ID: <20240319125833.30098a37@gandalf.local.home> In-Reply-To: References: <20240318113053.7f87ce7f@gandalf.local.home> X-Mailer: Claws Mail 3.19.1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) 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-Transfer-Encoding: 7bit On Tue, 19 Mar 2024 09:23:10 -0700 Linus Torvalds wrote: > On Mon, 18 Mar 2024 at 08:28, Steven Rostedt wrote: > > > > - Added checks to make sure that the source of __string() is also the > > source of __assign_str() so that it can be safely removed in the next > > merge window. > > Aargh. > > I didn't notice this initially, because it doesn't happen with gcc (or > maybe not with allmodconfig), but with clang I get > > CC [M] net/sunrpc/sched.o > In file included from net/sunrpc/sched.c:31: > In file included from ./include/trace/events/sunrpc.h:2524: > In file included from ./include/trace/define_trace.h:102: > In file included from ./include/trace/trace_events.h:419: > include/trace/events/sunrpc.h:707:4: error: result of comparison > against a string literal is unspecified (use an explicit string > comparison function instead) [-Werror,-Wstring-compare] > > and then about 250 lines ot messy "explanations" for how it was > expanded because it happens on line 709 too in the same macro, and it > ends up being three macros deep or something. > > So no, this all needs to be re-done. That > > WARN_ON_ONCE(__builtin_constant_p(src) ? \ > strcmp((src), __data_offsets.dst##_ptr_) : \ > (src) != __data_offsets.dst##_ptr_); \ > > does *NOT* work. > > Also, looking at that __assign_str() macro, it seems literally insane. > On the next line it will do > > memcpy(__str__, __data_offsets.dst##_ptr_ ? : \ > EVENT_NULL_STR, __len__); \ > > so now it checks "__data_offsets.dst##_ptr_" for NULL - but that's one > line after it just did that strcmp on it. > > WTF? > > This code is completely bogus. The WARN_ON_ONCE() was added separately and missed that we do now allow it to be NULL. I'll fix that. -- Steve