From patchwork Wed Nov 9 22:11:04 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Punit Agrawal X-Patchwork-Id: 17854 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp591523wru; Wed, 9 Nov 2022 14:22:16 -0800 (PST) X-Google-Smtp-Source: AMsMyM7uwEUhDsNbCCB1py0TxSxqq2u2V2g7bkFr8lVpP0ybycRlT53wKphUXe0QM48GsQ1987/I X-Received: by 2002:a17:90b:1b4b:b0:213:4d2f:9832 with SMTP id nv11-20020a17090b1b4b00b002134d2f9832mr63781943pjb.233.1668032536066; Wed, 09 Nov 2022 14:22:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668032536; cv=none; d=google.com; s=arc-20160816; b=jxfQKDgMDcFO1oJmRw6Klg9331W/Fd5RtWx0TJkIY55L8ZYutGyHHIkjSJ7hmh8M2j gsslyyoz8232PWQomQUSoRc63BvGf4djkVcaRWMYOUXr9BxNEU7nUd3jkfjshvjW+g/u atsf4NhmfzfTc6VaoKJwPAh7lVd5H69vIR4vmK7zLUrXg/VRJyDJ3GRS93P93aw7yFox UiAL6J7ovAd418lLNCiVT+wg860xUTUj6TYvhf4oo4/+bIZahXtBB1Etr9uP3CNuugD1 rDhHxsQIQ7SMhvNQOLFyq7WNXzPlSi8yiaTfUAhZ7OLZOvK1+p2m7PbnAsnskzU2yujh YItQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=Zjcx5nGJ4+e6voi0gTPzKp2DtAjaGHPzOo3aFzn/OZg=; b=l+lawaDVcX6Xmk248QS2Mg9/UT/YVLS2bWNkfI4Z+sKh9BD+ZtXEwhw3rm+WNrCDyl +G7LxcqDQEL0onWaD1CSfGzlKjTSS51KsjG3f7IZ8eHOgJsayinZlz/+msm1KOYwEajR /8xn+cfh6AyKZwhJV/WRGrAXcHy5umQVXs53/I9by40uP6hs3034IfpOEW/ba8mcP+6S jZi/lFYwa744aIQmvRWkWviczJQ8KALN1W9y+YezvmN+sRuJCCCdzLzwT+vo3F6a8J0U 7lTNXt1Zz3l2IzIkM/UunMvlIU5EqRfY1K4j/tfakFQu7v1qQdOLhCKfkFliwNdX0qnl +Uuw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@bytedance-com.20210112.gappssmtp.com header.s=20210112 header.b="P8/bnQTj"; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=bytedance.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id f4-20020a635104000000b0043ac3ec9d9esi19324194pgb.595.2022.11.09.14.22.03; Wed, 09 Nov 2022 14:22:16 -0800 (PST) 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=@bytedance-com.20210112.gappssmtp.com header.s=20210112 header.b="P8/bnQTj"; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=bytedance.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231461AbiKIWL1 (ORCPT + 99 others); Wed, 9 Nov 2022 17:11:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32928 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231373AbiKIWLW (ORCPT ); Wed, 9 Nov 2022 17:11:22 -0500 Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 27FDC29357 for ; Wed, 9 Nov 2022 14:11:21 -0800 (PST) Received: by mail-wm1-x32a.google.com with SMTP id l39-20020a05600c1d2700b003cf93c8156dso8628wms.4 for ; Wed, 09 Nov 2022 14:11:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bytedance-com.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Zjcx5nGJ4+e6voi0gTPzKp2DtAjaGHPzOo3aFzn/OZg=; b=P8/bnQTjV4nzCnwXorntM1WchaIivdzE2Yt/R7IiG7Ii2vT3PYvJc2avGc1K2y3O+u s0iNoA/aO1/YAFG4W/mqfXudotsG6MV49UwT8SEcx+9rx/sAJZojZH/AnvMi7C1s2ooR vJRuiOjcaHcxSr/SjDVnK1Nj26gR4nOJCHs+KBIUY4IpxIt7X3e/dcziuNJ3pg2i2651 4vh+fe12F9GQ5FvV6yMDjyiC3Pzv8l4Woi/JQNVuxGTX6z5uKb/+4DNXSRVPigX60efB 7aGEfW1PDuXw8ojKxTj8SwEhGyrWjARHK5sBmVhrw1xFbwqDXkRXA4I75qCfkIGrZMbt +lcA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Zjcx5nGJ4+e6voi0gTPzKp2DtAjaGHPzOo3aFzn/OZg=; b=DP4myWAPRbQqQLcgKZgd2w9LKcUwwIldtjX5Va+Gtgs7IlANc2VsyGDK3zBQed/Ar6 wBvk3YEcjdiBoo2jCBX9dIq+klcTpW+kfSDHFR3WjaaBKEGh6w6igY0DANabc+ISPvjH 5xgThQEYfjtFFACRtkJF0pPQZWtb51hbsAECKcErpl2LH8rZs2OWrtJWOZG83e+iD7tV jmk6IuH0l5cBUNwBm7dtZ8CNg1PX5Whom0/qF7JgdPsCfyQKkCtNxq5xotfT8z3nmr8E 6zKOCffTDx7LrtUtDFQm9zae3wY4SPQHjOgk2Hr3wo2cUo9eUSiyXjny9SnDPm14s1Ao VESg== X-Gm-Message-State: ACrzQf0A7YbRsAQuphqCjuwQOAHSPZDBsWdvS+EjyE0Zrg7QSBsaclwy nbxg8BU78dHjYCMDoo7gDpsvKg== X-Received: by 2002:a7b:ca52:0:b0:3cf:5c22:cbee with SMTP id m18-20020a7bca52000000b003cf5c22cbeemr41336461wml.97.1668031879712; Wed, 09 Nov 2022 14:11:19 -0800 (PST) Received: from localhost ([95.148.15.66]) by smtp.gmail.com with ESMTPSA id bn23-20020a056000061700b002305cfb9f3dsm14292893wrb.89.2022.11.09.14.11.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 14:11:19 -0800 (PST) From: Punit Agrawal To: akpm@linux-foundation.org, shuah@kernel.org Cc: adobriyan@gmail.com, linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-kselftest@vger.kernel.org, Punit Agrawal Subject: [PATCH v2 2/2] selftests: proc: Mark proc-pid-vm as x86_64 only Date: Wed, 9 Nov 2022 22:11:04 +0000 Message-Id: <20221109221104.1797802-2-punit.agrawal@bytedance.com> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109221104.1797802-1-punit.agrawal@bytedance.com> References: <20221109221104.1797802-1-punit.agrawal@bytedance.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1749058884134231022?= X-GMAIL-MSGID: =?utf-8?q?1749058884134231022?= The proc-pid-vm test does not have support for architectures other than x86_64. Mark it as such in the Makefile and in the process remove the special casing in the test itself. Signed-off-by: Punit Agrawal --- tools/testing/selftests/proc/Makefile | 2 +- tools/testing/selftests/proc/proc-pid-vm.c | 9 --------- 2 files changed, 1 insertion(+), 10 deletions(-) diff --git a/tools/testing/selftests/proc/Makefile b/tools/testing/selftests/proc/Makefile index 743aaa0cdd52..db953c014bf8 100644 --- a/tools/testing/selftests/proc/Makefile +++ b/tools/testing/selftests/proc/Makefile @@ -11,7 +11,6 @@ TEST_GEN_PROGS += fd-001-lookup TEST_GEN_PROGS += fd-002-posix-eq TEST_GEN_PROGS += fd-003-kthread TEST_GEN_PROGS += proc-loadavg-001 -TEST_GEN_PROGS += proc-pid-vm TEST_GEN_PROGS += proc-self-map-files-001 TEST_GEN_PROGS += proc-self-map-files-002 TEST_GEN_PROGS += proc-self-syscall @@ -29,6 +28,7 @@ TEST_GEN_PROGS += proc-multiple-procfs TEST_GEN_PROGS += proc-fsconfig-hidepid TEST_GEN_PROGS_x86_64 += proc-empty-vm +TEST_GEN_PROGS_x86_64 += proc-pid-vm TEST_GEN_PROGS += $(TEST_GEN_PROGS_$(ARCH)) diff --git a/tools/testing/selftests/proc/proc-pid-vm.c b/tools/testing/selftests/proc/proc-pid-vm.c index 69551bfa215c..6b0cb772b688 100644 --- a/tools/testing/selftests/proc/proc-pid-vm.c +++ b/tools/testing/selftests/proc/proc-pid-vm.c @@ -105,7 +105,6 @@ struct elf64_phdr { uint64_t p_align; }; -#ifdef __x86_64__ #define PAGE_SIZE 4096 #define VADDR (1UL << 32) #define MAPS_OFFSET 73 @@ -209,7 +208,6 @@ static int make_exe(const uint8_t *payload, size_t len) return fd1; } -#endif /* * 0: vsyscall VMA doesn't exist vsyscall=none @@ -225,7 +223,6 @@ static const char str_vsyscall_1[] = static const char str_vsyscall_2[] = "ffffffffff600000-ffffffffff601000 r-xp 00000000 00:00 0 [vsyscall]\n"; -#ifdef __x86_64__ static void sigaction_SIGSEGV(int _, siginfo_t *__, void *___) { _exit(g_vsyscall); @@ -493,9 +490,3 @@ int main(void) return 0; } -#else -int main(void) -{ - return 4; -} -#endif