Received: by 2002:a05:6358:45e:b0:b5:b6eb:e1f9 with SMTP id 30csp103373rwe; Fri, 26 Aug 2022 01:18:23 -0700 (PDT) X-Google-Smtp-Source: AA6agR5Pw1jZjnXmm2L3eq0UTPFcVXXCTaldZnpfEmbCC49pXcqoEdTlixi84QR5EJ/KGXxM7H93 X-Received: by 2002:a17:907:6e18:b0:73d:63d9:945f with SMTP id sd24-20020a1709076e1800b0073d63d9945fmr4823281ejc.12.1661501903729; Fri, 26 Aug 2022 01:18:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1661501903; cv=none; d=google.com; s=arc-20160816; b=Mwjvv53ILx5TvhweU7saIOK8WA08vPzwjP4azacdpHnsEkFjijV2LY90FHL6B1Peph KpP+VsHQjjY1iCJckecP2Xdd8ySJVqDN1zHbcNbdpLvH2vfaIHFEtVDubaFRQI34LZah v5JcJxn/O56WOp21Iw31vVCxuFJGDZ+lOO1KH2vIqTA+eMgePHLtiJ8850t2dLtUxakq 8zvk9QeuQrfiTFxAAs5dsx8dayVGxP3hgmm3592PrTTJVrc9o6Ra+Hfy2CFsMxWcedJp Dm7V6K4wyMKjAw8i185r6jqB0lg3+sSWuwPeAY//7Y1vD03Ra8fg+gYc95ZQITxRWMoq w0+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:subject:cc:to:from; bh=PBr4VAQb4N5o4GmnG0sxxkkdRDeqURAdlX0xzaCw5DM=; b=ufugebMhkgymLZkspmukW+IK2AxFeReMgKliUcOgJHgmg72320o8VMtRJB08b6ydd3 iED1vKwL7nx9sxd38bcy1CgAspVrQakQkKozJppxXagKJ5xBE/O9guMn4gvmNpFkxZQn z4p903TCkwdfA/zFlt9D3eFEMBIxV8gZ4DGtlLj98o0yA9aFGbD+YJe6CvtM2H4WU7K6 lqUd0FGVJFBJzDYtGsPPbgUTe02Qoid/8ToF7tXMtbbUIhzIaax6jI/3Kp7XJct9YvBN NoDzw0i2OfY/HEYmnfEzphuD5nAbtJapfTVejdRQ9eFNc/3U/X7J2pKq+zIMDD0NW6ns gxeQ== ARC-Authentication-Results: i=1; mx.google.com; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id vw17-20020a170907059100b0073dfcdf2f29si713670ejb.187.2022.08.26.01.17.58; Fri, 26 Aug 2022 01:18:23 -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; 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S245444AbiHZHoE (ORCPT + 99 others); Fri, 26 Aug 2022 03:44:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44042 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S245435AbiHZHoD (ORCPT ); Fri, 26 Aug 2022 03:44:03 -0400 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 520B2C3F5E; Fri, 26 Aug 2022 00:44:02 -0700 (PDT) Received: from dggemv704-chm.china.huawei.com (unknown [172.30.72.54]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4MDWxH1ZNhzmVLR; Fri, 26 Aug 2022 15:41:39 +0800 (CST) Received: from kwepemm600010.china.huawei.com (7.193.23.86) by dggemv704-chm.china.huawei.com (10.3.19.47) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Fri, 26 Aug 2022 15:44:00 +0800 Received: from ubuntu1804.huawei.com (10.67.174.174) by kwepemm600010.china.huawei.com (7.193.23.86) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Fri, 26 Aug 2022 15:43:59 +0800 From: Li Huafei To: , , , , , CC: , , , , , , , , , , , , , , , , , , Subject: [PATCH RESEND v3 0/4] ARM: Convert to ARCH_STACKWALK Date: Fri, 26 Aug 2022 15:40:43 +0800 Message-ID: <20220826074047.107357-1-lihuafei1@huawei.com> X-Mailer: git-send-email 2.17.1 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.67.174.174] X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To kwepemm600010.china.huawei.com (7.193.23.86) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE 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 This series mainly updates the ARM stack trace code to use the newer and simpler arch_stack_walk() interface (see patches 3 and 4). Two issues were fixed before that (see patches 1 and 2). v3 RESEND notes: Rebase to v6.0-rc1. It's been a month since I sent the v3. Linus told me I needed to add the patch to Russell's patch tracker myself, rebase to v6.0-rc1 before that. Thanks Linus for the tip! Since commit af6f23b88e95 ("ARM/dma-mapping: use the generic versions of dma_to_phys/phys_to_dma by default") and commit ae626eb97376 ("ARM/dma-mapping: use dma-direct unconditionally") modified arch/arm/Kconfig, there is a minor conflict with patch 4 when rebase. v3: https://lore.kernel.org/lkml/20220727040022.139387-1-lihuafei1@huawei.com/ - According to the discussion with Linus and Russell in v1: - Add a comment about "regs[1]" in patch 2, and remove the unnecessary ternary operator in the initialization of "frame->ex_frame". - Remove the patch "ARM: stacktrace: Allow stack trace saving for non-current tasks", and keep the check for not being able to unwind non-current tasks (including tasks running on other CPUs) when CONFIG_SMP=y in patch 4. - Rebase to linux-5.19-rc8. v2: https://lore.kernel.org/lkml/20220713110020.85511-1-lihuafei1@huawei.com/ - As suggested by Mark, the commit logs for patch 4 and 5 were refined for easy review. v1: https://lore.kernel.org/lkml/20220712021527.109921-1-lihuafei1@huawei.com/ Li Huafei (4): ARM: stacktrace: Skip frame pointer boundary check for call_with_stack() ARM: stacktrace: Avoid duplicate saving of exception PC value ARM: stacktrace: Make stack walk callback consistent with generic code ARM: stacktrace: Convert stacktrace to generic ARCH_STACKWALK arch/arm/Kconfig | 1 + arch/arm/include/asm/stacktrace.h | 8 +- arch/arm/kernel/perf_callchain.c | 9 +- arch/arm/kernel/return_address.c | 9 +- arch/arm/kernel/stacktrace.c | 191 ++++++++++++++---------------- arch/arm/lib/call_with_stack.S | 2 + 6 files changed, 110 insertions(+), 110 deletions(-) -- 2.17.1