From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from desiato.infradead.org (desiato.infradead.org [90.155.92.199]) (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 EE7871E5B64 for ; Mon, 8 Dec 2025 08:39:02 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=90.155.92.199 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1765183145; cv=none; b=Ka0IMiF0lhV9bDcfdursfwznKZi6RqP9JH+afHSO5X8eo+gU5sEh1hC4w+AhvVW7fTkow9bGxxdTpYhKB5QcDBc4axnAM38/z7JMtAnfwj/spP4MxXvYUZtv4Dgz8ns+PD/ViH3+6NbPWNrAxAcJ7JrxrhNb4oX/Lhsh6jlI5No= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1765183145; c=relaxed/simple; bh=ZYqrpY508uykDxm58SSqRfhQnA4u1ms6plNFaGOI8b8=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=Z4E6qZcR1+bDpwwa0OVI6Poztek69Wkjc0k0FroHFCOaCHpBvrK58xG2ALRwb9Xvu7NoWxsabbkn8+ACLYevXzpsw4RFOgNPCbUnU7Xzma4eSpd7+i0iIMQx4QyxkUo3pxP3y4MyrX3X/6xivzU76TpsFMa2YlpLO8p7yduSHeE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=infradead.org; spf=none smtp.mailfrom=infradead.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b=RuP5DRiN; arc=none smtp.client-ip=90.155.92.199 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=infradead.org Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=infradead.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="RuP5DRiN" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=In-Reply-To:Content-Transfer-Encoding: Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: Sender:Reply-To:Content-ID:Content-Description; bh=2IRb5pnGxgPYjrKvinwaSc06boe9sEJvHadKT5T2lrI=; b=RuP5DRiNIgxuIjBHVIsh4k46+R 8e9iW3mgRT4SD/CaJ6hRLeJPa0WvqS+qta4RTyEIUzFhKV4+HqxcQy8z7gc8w9OSN/u0oztVA8SUc 31zWeGfOltid8G80jjZRe6vfhXByvQXFWo4nK6QeZ/hxuuY7SoksAYhtY+eJC1JbND8l+tLNwA1cj akoWahaJ6HANaHAVR+EgUoRS5jf/PpuQErpMf6X7Wn6D57wkfZKpsMAdoMhAqYTlVmhbq2QokpwKR Ux4fAQevXysH1UYhEE0rr7Y3HBP9ISqvhjLmtPCL1KLLvCXtNb/DE/09MQDDKDEDKXDTkRzAlMDGS nF3438zA==; Received: from 77-249-17-252.cable.dynamic.v4.ziggo.nl ([77.249.17.252] helo=noisy.programming.kicks-ass.net) by desiato.infradead.org with esmtpsa (Exim 4.98.2 #2 (Red Hat Linux)) id 1vSVuG-00000009sjg-3ODo; Mon, 08 Dec 2025 07:43:40 +0000 Received: by noisy.programming.kicks-ass.net (Postfix, from userid 1000) id 9802230301A; Mon, 08 Dec 2025 09:38:57 +0100 (CET) Date: Mon, 8 Dec 2025 09:38:57 +0100 From: Peter Zijlstra To: Brendan Jackman Cc: Andrew Morton , linux-kernel@vger.kernel.org, kees@kernel.org, acarmina@redhat.com, jpoimboe@kernel.org, mark.rutland@arm.com, maciej.wieczor-retman@intel.com Subject: Re: [PATCH] bug: hush suggest-attribute=format for __warn_printf() Message-ID: <20251208083857.GA3707837@noisy.programming.kicks-ass.net> References: <20251207-warn-printf-gcc-v1-1-b597d612b94b@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=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20251207-warn-printf-gcc-v1-1-b597d612b94b@google.com> On Sun, Dec 07, 2025 at 03:53:18AM +0000, Brendan Jackman wrote: > Recent additions to this function cause GCC 14.3.0 to get excited and > suggest a missing attribute: > > lib/bug.c: In function ‘__warn_printf’: > lib/bug.c:187:25: error: function ‘__warn_printf’ might be a candidate for ‘gnu_printf’ format attribute [-Werror=suggest-attribute=format] > 187 | vprintk(fmt, *args); > | ^~~~~~~ > > Disable the diagnostic locally, following the pattern used for stuff > like va_format(). No real objection, but why haven't I seen this in my own builds? Most of my machines are on gcc-14 / gcc-15.