Received: by 2002:a05:7412:798b:b0:fc:a2b0:25d7 with SMTP id fb11csp579085rdb; Thu, 22 Feb 2024 12:33:44 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVVdSiFLAC30BmBpgzDQxlnZD2UMFiOUkoa1+poxTnj1mNjhxPGwcLcSS0hBmq+WWv5d5soElChA3ZC94ydEPCvIaHAIhujFXi7YJaVEw== X-Google-Smtp-Source: AGHT+IEA7MV+lO3E396qAJMMHm8CSbboE1EcXOo7S2/+2t0KrAQkb+osiEdoetG4uvGny0Kj+JQX X-Received: by 2002:a17:902:c408:b0:1d9:7039:3519 with SMTP id k8-20020a170902c40800b001d970393519mr25721872plk.2.1708634024078; Thu, 22 Feb 2024 12:33:44 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708634024; cv=pass; d=google.com; s=arc-20160816; b=x8zNUFgLDCMxXFqo9CXKR0AkrN9HthtrgIFpct4hqxgJvYUs4NseOSQJEMwR6Xv5JW slAAwa75I/MEdAWMIExzPgAvvjox8mkFCzBt02iNKGJ1sgvqZok9ulhOTV9QsiVuXRaV SROdFORV7uvWf/3ZQ7xIvbL8NJ7IqjOTWC5RdaE7cruF2gaZlsf3AuNhnctGJR8EKNOO X6FTNGmHtRfm+pSBdeUru1Y/SdKuvYDSjw+DyRDz9g29g22NqPho6KfABRFBNEk/6Upu 8Mz9ZmJvo2QdfRKuVgwZMN+jQ6u7cvUfSZRy2iLKMqJbRupwawt65bA0UpXOSnWZSLd+ bCRQ== 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:message-id:date:references :in-reply-to:subject:cc:to:dkim-signature:dkim-signature:from; bh=DniZuGJeiAYZMjYY1WgxfhTrSfX4CCM88FQCLYeTz9I=; fh=WfWwFv4Eud67en7Sld17fmHJVb+ipKTprdTshEpY4aM=; b=H1Df4ktuUsLDsO7fhaIIhl6U0XGZOC0RQkxHIzFCTvprWDLMYIWFaOkxXrQVRT+szS UBnRMonCay9VtfFlx22NMtBwBeZ1air39kBno0/0OlDR0p/sfQFfNihh5k6mA+tgObFV QK/l7HShf5skr2wmhOaIXZbPF48T+y8Lt/uHhch4nB5UtKvCTijh6I1O9dtJqU3ySfUb SaB7rmgn3ewIBkNBiPhOe8G/GnAv28/KnBUJLAmA0xUvXzklUbURqcTKBD1Da/imns83 bLnTxZuG5wr/zympIs2Q9EgIb0AJfFmP3+S/aCxwfh6to2MYL77wRMyD0vBiiOGAoOe/ 4Dwg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=SR77vt2e; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; arc=pass (i=1 spf=pass spfdomain=linutronix.de dkim=pass dkdomain=linutronix.de dmarc=pass fromdomain=linutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-77322-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-77322-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id lv13-20020a1709032a8d00b001d97e406c36si11270658plb.39.2024.02.22.12.33.43 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Feb 2024 12:33:44 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-77322-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=SR77vt2e; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; arc=pass (i=1 spf=pass spfdomain=linutronix.de dkim=pass dkdomain=linutronix.de dmarc=pass fromdomain=linutronix.de); spf=pass (google.com: domain of linux-kernel+bounces-77322-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-77322-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.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 BFF2B28AEF4 for ; Thu, 22 Feb 2024 20:33:43 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0FDC06E602; Thu, 22 Feb 2024 20:33:39 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="SR77vt2e"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="EDOWpG9/" Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) (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 CBDB610A05 for ; Thu, 22 Feb 2024 20:33:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=193.142.43.55 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708634018; cv=none; b=nBlO505P1g7i+IZN+YI0cAlvcoAsejOktTicMv9NYKg6uijZ0TLUM5hpHEGgWuEVRBh3+p5jxGj7nD3Jv+cN2O2D4IUdG+WeEXCeW4uwGu1HzPJLN+07diFEgAuyzOWIs24z5S2MgZhGUoP5HjThWpD1TKp8dyhehpoMWae0/hI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708634018; c=relaxed/simple; bh=4Ps0iR9+3QGUlPjbNsHsXZLbNqooArLyZSC9K1TD72A=; h=From:To:Cc:Subject:In-Reply-To:References:Date:Message-ID: MIME-Version:Content-Type; b=XL13Eth2I6ayUneENXlW8Vd+o/Z/RIr88CSOZtZHqXTeBInZNwvJWmd9T3+aEJrk8XbwLZse/qpbperL0fHS6KHKj+Ig+ELeamBa96OmTlCU2TflDWj6us/O/Cd7+inOR+qEp3pCh4sPQD/aVdx3+jOI6bnPciALghRcZtI4ncg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de; spf=pass smtp.mailfrom=linutronix.de; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=SR77vt2e; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=EDOWpG9/; arc=none smtp.client-ip=193.142.43.55 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linutronix.de From: John Ogness DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1708634009; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=DniZuGJeiAYZMjYY1WgxfhTrSfX4CCM88FQCLYeTz9I=; b=SR77vt2eU/+wJ3ZBnhkR3OsQSE82MJEMnAhkdRz2jX2KfBaYv6vQIz5pt+rD4tQwrF8AZz P6E0+yEHPARD14V7eNz+ewwjfNlEbyhmMlovUClYyXNwUbnZWosMblEElc5ZIkU4T29W6O HJdDC0lTJxLF3M73ZmT80TXaBYQCMOgdmql37SkI/d6Xj9x7am7McP+d7GjrtABbe4WDkP BFAi0cA/KFsHyoCQWIq9w070WZphgnalCfHKR6+JeNXpHHFwxfSGETP53GgE/TOOFwiq5d hZBeVyIhwVaA4caBIw+lFU5v7GDlyr+JFF1ND7A8NBNm+byMnxis13RVu0LAvw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1708634009; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=DniZuGJeiAYZMjYY1WgxfhTrSfX4CCM88FQCLYeTz9I=; b=EDOWpG9/yLz7uA8dVZP7edFdoK8sGABu4QxTWZsQCjuY8Wn4Ws8hzWWStuTwRU+cwKaDbn 7X0R+bb2tqBzC5CA== To: John Stultz , Thomas Gleixner Cc: LKML , Frederic Weisbecker , Steven Rostedt , kernel-team@android.com Subject: Re: [RFC][PATCH] hrtimer: Use printk_deferred_once for hrtimer_interrupt message In-Reply-To: References: <20240222051253.1361002-1-jstultz@google.com> <8734tkfrzz.ffs@tglx> Date: Thu, 22 Feb 2024 21:39:04 +0106 Message-ID: <87wmqwz1bz.fsf@jogness.linutronix.de> 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-Transfer-Encoding: quoted-printable On 2024-02-22, John Stultz wrote: > On Thu, Feb 22, 2024 at 7:17=E2=80=AFAM Thomas Gleixner wrote: >> On Wed, Feb 21 2024 at 21:12, John Stultz wrote: >> > With qemu, I constantly see lockdep warnings after the >> > hrimter_interrupt message is printed: >> > >> > [ 43.434557] hrtimer: interrupt took 6517564 ns >> > [ 43.435000] >> > [ 43.435000] =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D >> > [ 43.435000] [ BUG: Invalid wait context ] >> >> Do you have PROVE_RAW_LOCK_NESTING enabled? > > Yes, I do. Let me know if there's anything else you'd like me to try. This option is to "ensure that the lock nesting rules for PREEMPT_RT enabled kernels are not violated." Since you are not running a PREEMPT_RT enabled kernel, these warnings are irrelevant for _your_ kernel. >> > I thought the new printk work was going to resolve this, but >> > apparently not Yes, it will, but it is not all mainline yet. The full printk rework is only available as part of the PREEMPT_RT patch series [0]. With that series applied, it makes more sense to enable PROVE_RAW_LOCK_NESTING because the series should resolve all known lock nesting problems with PREEMPT_RT. (And indeed, the warning you are reporting does not occur there.) If you really want to test lock nesting for PREEMPT_RT, I recommend applying the PREEMPT_RT series and keeping PROVE_RAW_LOCK_NESTING enabled. Otherwise, if you do not want to apply the PREEMPT_RT series, I recommend disabling PROVE_RAW_LOCK_NESTING. Note that you can apply the PREEMPT_RT series and still choose the !PREEMPT_RT preemption model for your kernel. John Ogness [0] https://git.kernel.org/pub/scm/linux/kernel/git/rt/linux-rt-devel.git/l= og/?h=3Dlinux-6.8.y-rt-rebase