Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp114075pxb; Wed, 3 Feb 2021 00:43:59 -0800 (PST) X-Google-Smtp-Source: ABdhPJzyBKC6J6fgY6/m6ZvHtE8/WSrp/3t4DjRGEkx+pAxdEmJm3Le4JirTpFK9bVcThVFA6vwt X-Received: by 2002:aa7:d651:: with SMTP id v17mr1898551edr.91.1612341838998; Wed, 03 Feb 2021 00:43:58 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1612341838; cv=none; d=google.com; s=arc-20160816; b=ircTpa1fRRz0WKFfXtP5LHAfAmBpBREGaaaed30vLaLII6tawk1Jz5+2ebldXjztyh kaKGfBxYBX6nOOafung3amEUBL6t5y2SqJwwfk7ivUCRdSJlPklK1mPpMjlycnRHyWRV mCZHTZd/W/I+TRVtMF2N/N7H2WzyKLuQQ2owpWi9j37PfIf3gdQ2PKokkf7sfMzEBxGG PXto+PKWcU1nCKrUDfnbzqI0XrxL8EQ1RQ3/M3up0ihobODbxEnbSNZ+naBgSRwN1gNG Bf9/8VmdRvTqJkGfzwRmrTKGO5WxbKOCIbrre4pWSCeLaCls6FOK7jir6NuimYuHzIbX g20g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from; bh=Ar86gO6GM0HYaj4pULutQcA/xwAbb7yf68gacdPWWRk=; b=OL7AodlGw1ImwaAj65muNTkp3C6gLZSurT/G1sVYGNOJPe4gzRXtqPA7u9RoLteDa1 SohwzGGUke6rpOxnZYOcxrnH7/KFhn5E3FW4Oz1twSDx6Ej4dGdWDJ2140iJV30/ngDS B15MIxYbaK8cV8r4Z2ttcr4iq2BlOOSMzS8y5/46oq+uhXsuO2P5cJy1Fp1RAQbK/BAB nPcypLkMRZaLPtGa1xnqi8/9L8AcTHxcoU4WgCs2kPaPK+Ll+UjMDqneRPhWXUQBpApn fejgtpEFu6P4ybqcWWb3422RCHK3SSq+ivUhuL5BosV2gnbw+1mhNCm40UxtmSBQGffb co3Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r11si1052866edc.353.2021.02.03.00.43.34; Wed, 03 Feb 2021 00:43:58 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232563AbhBCIlC (ORCPT + 99 others); Wed, 3 Feb 2021 03:41:02 -0500 Received: from mail.loongson.cn ([114.242.206.163]:60398 "EHLO loongson.cn" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S232983AbhBCIkG (ORCPT ); Wed, 3 Feb 2021 03:40:06 -0500 Received: from linux.localdomain (unknown [113.200.148.30]) by mail.loongson.cn (Coremail) with SMTP id AQAAf9Dxf_IsYRpgSJQCAA--.3171S2; Wed, 03 Feb 2021 16:39:08 +0800 (CST) From: Tiezhu Yang To: Shuah Khan Cc: linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] selftests: breakpoints: Fix wrong argument of ptrace() when single step Date: Wed, 3 Feb 2021 16:39:07 +0800 Message-Id: <1612341547-22225-1-git-send-email-yangtiezhu@loongson.cn> X-Mailer: git-send-email 2.1.0 X-CM-TRANSID: AQAAf9Dxf_IsYRpgSJQCAA--.3171S2 X-Coremail-Antispam: 1UD129KBjvdXoWrZw1kWFWUCFWrur18Cw1xKrg_yoWkXrX_uF WfXw4kuFWkWryvy3W5Ww13JrW8Ja13uF4Iqr42qF93Jw4jkrWDtaykCF1kAFyxW3yYg39F y3W8CrW3ur15JjkaLaAFLSUrUUUUUb8apTn2vfkv8UJUUUU8Yxn0WfASr-VFAUDa7-sFnT 9fnUUIcSsGvfJTRUUUb7AYjsxI4VW3JwAYFVCjjxCrM7AC8VAFwI0_Jr0_Gr1l1xkIjI8I 6I8E6xAIw20EY4v20xvaj40_Wr0E3s1l1IIY67AEw4v_Jr0_Jr4l8cAvFVAK0II2c7xJM2 8CjxkF64kEwVA0rcxSw2x7M28EF7xvwVC0I7IYx2IY67AKxVWUCVW8JwA2z4x0Y4vE2Ix0 cI8IcVCY1x0267AKxVW8JVWxJwA2z4x0Y4vEx4A2jsIE14v26F4UJVW0owA2z4x0Y4vEx4 A2jsIEc7CjxVAFwI0_GcCE3s1le2I262IYc4CY6c8Ij28IcVAaY2xG8wAqx4xG64xvF2IE w4CE5I8CrVC2j2WlYx0E2Ix0cI8IcVAFwI0_Jr0_Jr4lYx0Ex4A2jsIE14v26r4j6F4UMc vjeVCFs4IE7xkEbVWUJVW8JwACjcxG0xvY0x0EwIxGrwCY02Avz4vE14v_GFyl42xK82IY c2Ij64vIr41l4I8I3I0E4IkC6x0Yz7v_Jr0_Gr1lx2IqxVAqx4xG67AKxVWUJVWUGwC20s 026x8GjcxK67AKxVWUGVWUWwC2zVAF1VAY17CE14v26r1Y6r17MIIYrxkI7VAKI48JMIIF 0xvE2Ix0cI8IcVAFwI0_Jr0_JF4lIxAIcVC0I7IYx2IY6xkF7I0E14v26r1j6r4UMIIF0x vE42xK8VAvwI8IcIk0rVWrZr1j6s0DMIIF0xvEx4A2jsIE14v26r1j6r4UMIIF0xvEx4A2 jsIEc7CjxVAFwI0_Jr0_GrUvcSsGvfC2KfnxnUUI43ZEXa7IU0qQ6PUUUUU== X-CM-SenderInfo: p1dqw3xlh2x3gn0dqz5rrqw2lrqou0/ Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org According to the error message, the first argument of ptrace() should be PTRACE_SINGLESTEP instead of PTRACE_CONT when ptrace single step. Fixes: f43365ee17f8 ("selftests: arm64: add test for unaligned/inexact watchpoint handling") Signed-off-by: Tiezhu Yang --- tools/testing/selftests/breakpoints/breakpoint_test_arm64.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c b/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c index ad41ea6..2f4d4d6 100644 --- a/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c +++ b/tools/testing/selftests/breakpoints/breakpoint_test_arm64.c @@ -143,7 +143,7 @@ static bool run_test(int wr_size, int wp_size, int wr, int wp) if (!set_watchpoint(pid, wp_size, wp)) return false; - if (ptrace(PTRACE_CONT, pid, NULL, NULL) < 0) { + if (ptrace(PTRACE_SINGLESTEP, pid, NULL, NULL) < 0) { ksft_print_msg( "ptrace(PTRACE_SINGLESTEP) failed: %s\n", strerror(errno)); -- 2.1.0