Received: by 2002:ab2:3319:0:b0:1ef:7a0f:c32d with SMTP id i25csp729937lqc; Fri, 8 Mar 2024 09:58:37 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCX/DwbjD/01cAnjnvm3RsyvNOTJDB/61j+VjWb9eeV7EQ1me7k/4JDxXSZMTKyBdn8UeEDLgEGZ/n1OUmVoo6l7LHk1lzVav4k4LvvZaQ== X-Google-Smtp-Source: AGHT+IGIqt0MlEBGzZYNMQlp5CknahuSzaUs/izaIT4V2muBLxb7Jd5w/jFHikUAd533Oi5E+BZU X-Received: by 2002:a2e:b889:0:b0:2d4:62c:c9d6 with SMTP id r9-20020a2eb889000000b002d4062cc9d6mr766ljp.22.1709920717599; Fri, 08 Mar 2024 09:58:37 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709920717; cv=pass; d=google.com; s=arc-20160816; b=wmR+7Hj6ikWOLz3nm8qv3qdqybif2SpJJ7E8Ga4gGgfn2/GCrleJFi69+HCaU7hKB0 dH01eE0zlWHEQ7DPa+BUpag2ByW5GSp8BOyfYnVYsCapN/6rldae+pU4NRRvi4iUnXOG A/R4v7fZ5DvFbpqii6jm5jg5sVgRORCZSv/KrjmfJ9Oajqf9qiHs1/vbt++TboBGcdpw M7C4mwUWbgIiawmg9NMoQTg5H9bhQAqI9s5BEBc5P35BYPz6sNQ9PhPiRgQyxbbtj9Ej rH3sOsY7UxFWxkYhrPI6PfJqSW4V05l0lcSwYb2jX+6A1ja827HI0xzsBX61X3Dy2W2z ag7Q== 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:subject:cc:to :dkim-signature:dkim-signature:from; bh=rb4j/fngEBckvfiSTCJqL9xaGeMYTtosqeRUGbOZKI0=; fh=DfBukoAxbWIiwViAhJy/znmoKLckCTkeetB328V/TC4=; b=Ms5JbqkWnwQVNgba4N8RnnBXjdm9lNRFht9O+qc6gwbv5NdLdqZ67ksRTUdGy1VaWH 8CwO8l0l6LGellowi+9Cr8jQoNXXujSFsC3yYeUTXWzDJgdtxud+qwR4Mga/qhA+xmMF dynSNXjisZNi8kMSmG9QS+Q2x0ZuDGrNULMECyT4vbUmjg2nySYjuESjnNxexttoUAD8 0gMfaYqe9h9/bEt6qZ+azsOMHDsnP5+u8fR4hU6HsBIGpYfFuxzbBktJFQgCGxcmpwg1 RNYv2sa/kvi6buyQNrQxqBlHJ/kUuIjSATDhrLGhuzYba/8YMtUPtn17NJxknBA4zJ+B /EPQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=S0RyszwI; 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-97424-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-97424-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id f19-20020a05640214d300b005681b9fd6a0si15061edx.35.2024.03.08.09.58.37 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 08 Mar 2024 09:58:37 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-97424-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=S0RyszwI; 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-97424-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-97424-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 am.mirrors.kernel.org (Postfix) with ESMTPS id 4A69D1F228AB for ; Fri, 8 Mar 2024 17:58:37 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BA90B5579F; Fri, 8 Mar 2024 17:58:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="S0RyszwI"; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b="mKcWA01d" 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 7F0F6282EB; Fri, 8 Mar 2024 17:58:21 +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=1709920703; cv=none; b=pN8k8ausbc3rssdXAr8MCKDvFjvGkVL49IYGCAYZaCk4Ew6VzOkUilF2sJGnMMuAMIlJ8oI0YZUsS7vSEvHNlbKOHanm313HKZ2Yd5z2aCJIU7CQFHGgMvpqKr1xp9RkmOHOLsgWrrv1+qj4dIk7SdqUHSWU75U7OuFqUlA2XsI= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709920703; c=relaxed/simple; bh=rb4j/fngEBckvfiSTCJqL9xaGeMYTtosqeRUGbOZKI0=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=LarfHqCz5xnk//SbwYkP1o48BKAgHPDKfhqnfsDp7pfUHOfNLMpGFS0YwyeImwalh+QmrSwwFBoewj7X6O0tQfJyxf4sZm6MMDU1jHpVWF2VMGLdbx2qGuhOKsIVeLBRV1WlaOHbEhEPtLGF/EM5d8DVic4J6FfjgJyERzRCpCw= 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=S0RyszwI; dkim=permerror (0-bit key) header.d=linutronix.de header.i=@linutronix.de header.b=mKcWA01d; 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: Sebastian Andrzej Siewior DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1709920699; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=rb4j/fngEBckvfiSTCJqL9xaGeMYTtosqeRUGbOZKI0=; b=S0RyszwIUN4ilqUtNGWL2DoIBFS6HL3AXshFOKdIcBylQs6EmgeURpOvx5LDYdv42LUJpQ qJu1PJho/gvB9Bsp4uAX4oMXjUD1Zzsy6bVinq+nK9+Z8EiPXvi/xoDy8TWXKe3Jh9uWH4 C0BSXcD/O9qFIOXEt0UOIEkEvqqI+P+b19R808XEfljK5mEYPhH1oczU5CFoGzIThZWo8W 2Mfgjfndktq/OwdUHQt3RBLtdOgcAt7hhuPlNJlpl157wZ8txOpTLde1kISwZwD6cICUsJ nTSp0IF2b/2SSiU7L7WpqvTrT966U4GScwfdhmnJu/B5ZZf0BzKaZBholojHDw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1709920699; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=rb4j/fngEBckvfiSTCJqL9xaGeMYTtosqeRUGbOZKI0=; b=mKcWA01d/b7ypBUfma0R9lss93FkwXKYdDbSzqtz8La0U2PjByiAQmwx6vN5QbIlDN10pn obZEJa4AtCBTeKBg== To: linux-perf-users@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Adrian Hunter , Alexander Shishkin , Arnaldo Carvalho de Melo , Ian Rogers , Ingo Molnar , Jiri Olsa , Mark Rutland , Namhyung Kim , Peter Zijlstra , Thomas Gleixner Subject: [PATCH 0/4] perf: Make SIGTRAP and __perf_pending_irq() work on RT. Date: Fri, 8 Mar 2024 18:51:26 +0100 Message-ID: <20240308175810.2894694-1-bigeasy@linutronix.de> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Hi, Arnaldo reported that "perf test sigtrap" fails on PREEMPT_RT. Sending the signal gets delayed until event_sched_out() which then uses task_work_add() for its delivery. This breaks on PREEMPT_RT because the signal is delivered with disabled preemption. While looking at this, I also stumbled upon __perf_pending_irq() which requires disabled interrupts but this is not the case on PREEMPT_RT. This series aim to address both issues while not introducing a new issue at the same time ;) Any testing is appreciated. Sebastian