Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp2069536rwd; Fri, 26 May 2023 00:57:37 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4/bTaKUvOPUo3b6Fq3AZL6owJRTi5ex4jVdFvreH+QxdRnZoQgLvxB66VYpYgeQ5S9S457 X-Received: by 2002:a17:902:d490:b0:1ae:35ba:8c8f with SMTP id c16-20020a170902d49000b001ae35ba8c8fmr2060428plg.13.1685087857379; Fri, 26 May 2023 00:57:37 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685087857; cv=none; d=google.com; s=arc-20160816; b=Adm8GcsrEDXNLx5QW/f1BBhLmQ43CpEzcgOnGvIxxHT74XELPRrW7AwGA6x+IEcAWw Ctvn0RQaom3K7Ovo8FAftr9hG8FgLU73A5nW6qLyJcBFX2VJVBC6qCkGe/KOjF22YgFy cPc+iGcGytTc4xbE61zbH2ptjR7dKBkPhSW947dAmHASFQi/mgzv4Q3uyVeBVvjFC54U HgaB0WThuYeqXis4IdD1r/bkcanhyKlfyVXNvKGWghAgxeaFuSP9wMJOgqKm9H4stCTr lex5BqMcpbbVSMZlk2KwMVSlq/ujXnw3L8OEYIxv6Hw1b2iRGCWLO0UYQfMp9K5mGHDz eEMw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:dkim-signature :from; bh=oOmQSgGQ6GXRy+CXlTBCbtdD3PPlc5WTLjdtC+9c0jg=; b=0C/QPEEcPW+5qe38lP2Wz/vRgFhhZtFDhHv3uamHqe20ZAAjCgK+nUfKAFuagryjv8 Evdg9es4NOjijGfhtJsIcbSYA5i+Yiv01ZqRGbYy5vFL+MM7tgOKQPKJuW3NIwKl6L1h GuW8I58C7PJafKRroL6FCvVh/hJCtbGuWpAQyvziJw9p1/gaFprKZ40PnH4mIw7zkp80 MABsL3IpOguySwD4w0fuHA8Qg0PGq8VgkKLdybJh0xuo9Z4i88XybxfPTP6wruQJXq/r /a4jKFieMlq8awjCg3hD9jVvP15Z1brqYCn9YlHakZhgRk1proy8SSaXl8jBj1942kN9 C44A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@weissschuh.net header.s=mail header.b=hS0Zhw49; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id u17-20020a170902e5d100b001a69cb5f7besi3492958plf.525.2023.05.26.00.57.23; Fri, 26 May 2023 00:57:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@weissschuh.net header.s=mail header.b=hS0Zhw49; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242545AbjEZHv3 (ORCPT + 99 others); Fri, 26 May 2023 03:51:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44816 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242509AbjEZHvX (ORCPT ); Fri, 26 May 2023 03:51:23 -0400 Received: from todd.t-8ch.de (todd.t-8ch.de [IPv6:2a01:4f8:c010:41de::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B127A12C; Fri, 26 May 2023 00:51:22 -0700 (PDT) From: =?utf-8?q?Thomas_Wei=C3=9Fschuh?= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=weissschuh.net; s=mail; t=1685087480; bh=gPWy5ndLt8ct+Uazqw50nw4PJv+qz+MZWnYipjEuHg4=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=hS0Zhw49+9al2kcGPElURWIe30L2/bYj8kjizboi2kD8xqnP0LBrFnz83CKPrR42X SfK7Df3aVXH45ub41nImcZk3CcDZNB2Ggne5+avq1v+d4Ljrp1FdBv84xjAnLFqirN G+EzzKz+WFKD5/Tl0IhyKHp8BKZ/KvTgBYN3LB00= Date: Fri, 26 May 2023 09:51:20 +0200 Subject: [PATCH v2 2/2] selftests/nolibc: prevent coredumps during test execution MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit Message-Id: <20230526-nolibc-test-no-dump-v2-2-a66500bf73fc@weissschuh.net> References: <20230526-nolibc-test-no-dump-v2-0-a66500bf73fc@weissschuh.net> In-Reply-To: <20230526-nolibc-test-no-dump-v2-0-a66500bf73fc@weissschuh.net> To: Willy Tarreau , Shuah Khan Cc: linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, =?utf-8?q?Thomas_Wei=C3=9Fschuh?= X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1685087479; l=989; i=linux@weissschuh.net; s=20221212; h=from:subject:message-id; bh=gPWy5ndLt8ct+Uazqw50nw4PJv+qz+MZWnYipjEuHg4=; b=A16KBhfIrmPXrI7A758j3aA9reNvLxMKPt3tolDoX8rZOSZw+NGQWP4roP4PFqUUkHl9iKw1f i/mOxuWmA9uDplYB3WGGUDFJw/6O37J6Hs8cEhEp8XykrOlNuipSP+m X-Developer-Key: i=linux@weissschuh.net; a=ed25519; pk=KcycQgFPX2wGR5azS7RhpBqedglOZVgRPfdFSPB1LNw= X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The child process forked during stackprotector tests intentionally gets killed with SIGABRT. By default this will trigger writing a coredump. The writing of the coredump can spam the systems coredump machinery and take some time. Timings for the full run of nolibc-test: Before: 200ms After: 20ms This is on a desktop x86 system with systemd-coredumpd enabled. Signed-off-by: Thomas Weißschuh --- tools/testing/selftests/nolibc/nolibc-test.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/testing/selftests/nolibc/nolibc-test.c b/tools/testing/selftests/nolibc/nolibc-test.c index 95ff2867a91d..3296e8567fa5 100644 --- a/tools/testing/selftests/nolibc/nolibc-test.c +++ b/tools/testing/selftests/nolibc/nolibc-test.c @@ -831,6 +831,7 @@ static int run_protection(int min, int max) close(STDOUT_FILENO); close(STDERR_FILENO); + prctl(PR_SET_DUMPABLE, 0, 0, 0, 0); smash_stack(); return 1; -- 2.40.1