Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp12967189rwl; Wed, 4 Jan 2023 01:18:39 -0800 (PST) X-Google-Smtp-Source: AMrXdXsxBUZ9n8m1JNHSJlNNJ0OtKMeYZ2q9rr86Rc+vFDxZOKtqUT+ASn3t4Bfs9X3JKl2wQq48 X-Received: by 2002:a17:902:c102:b0:192:8e05:1505 with SMTP id 2-20020a170902c10200b001928e051505mr30357618pli.31.1672823918821; Wed, 04 Jan 2023 01:18:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1672823918; cv=none; d=google.com; s=arc-20160816; b=nQUrNZXgEG3fj2WW3UazkMvjo+LKpVEmDaifHVfXHf6713E07kHeQtUp7PY6zg9zXL VeiR0Wn2vyKb4ndl6VKuaovSDQ95KL6SDWVwDs4W33OsnU4jolYTRYgD7JiL96MTY8aX 5pAlbtcyFh0gn6qVuzKJI7MrGJUsIt7OSsZp7iwSk5DPOF5PspzHtizn8S/sNLgSkKMF 7qU4/OsEUu5CTIWD7zbNDE2TL4307CU7JvexmOgmvm5KsoLIie1Ss4SBc6FnY6EEa9Mk H+mgps21X40xZK1n7FxJCogWSBQe1XttF0UODIfydq0HfehtrzuhKGHwAszjIrE9DOHE zMNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:subject:user-agent:mime-version:date:message-id; bh=Sy05dRn6E4+AURuIQML5cl3A6icNkQuEGvoJagbbpjk=; b=TdhXdTO3oEOxm2aGvSYVCULFtgJKX8b3Pxh/frSPuSnWmdMgnS8UElJvoZWWwfnsXU ih4cncO+rUH8bwvG30Yp/+ZhZf03ioHGY+mMfACgFIiwdI/S/Ud3C/h1P/fB1wVhXSOu Qakxd4yVU4fZ8//+LDwqKbIUKs3OkfS0ZGT958h1l1TI8GRBE0z8Stx8CgTvDUsXNKZB 2ihswHRtFKrO1DlSvAyDRUI+Z28wPw4ctl+Wyn4S5hhvCheXVQM7Sf8WKpUZF+yL68ey 0DzXebS7wMhB/xCehq2WQK+WGhfCWAqol15WqqIEaGlfjtgjjhNh2uVUbPkdN1bL6YkD oNww== 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 c18-20020a170902d49200b00186f81a0765si36351487plg.540.2023.01.04.01.18.31; Wed, 04 Jan 2023 01:18:38 -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; 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 S234143AbjADIgG (ORCPT + 57 others); Wed, 4 Jan 2023 03:36:06 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37234 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234054AbjADIff (ORCPT ); Wed, 4 Jan 2023 03:35:35 -0500 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BC88D6478 for ; Wed, 4 Jan 2023 00:35:34 -0800 (PST) Received: from kwepemi500012.china.huawei.com (unknown [172.30.72.57]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4Nn2vd09rRzHw5F; Wed, 4 Jan 2023 16:34:21 +0800 (CST) Received: from [10.67.110.108] (10.67.110.108) by kwepemi500012.china.huawei.com (7.221.188.12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Wed, 4 Jan 2023 16:35:32 +0800 Message-ID: Date: Wed, 4 Jan 2023 16:35:31 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.4.2 Subject: Re: [PATCH v5 9/9] riscv/kprobe: Search free registers from unused caller-saved ones To: =?UTF-8?B?QmrDtnJuIFTDtnBlbA==?= , Chen Guokai , , , , , , CC: , References: <20221224114315.850130-1-chenguokai17@mails.ucas.ac.cn> <20221224114315.850130-10-chenguokai17@mails.ucas.ac.cn> <87pmbwvmmr.fsf@all.your.base.are.belong.to.us> From: "liaochang (A)" In-Reply-To: <87pmbwvmmr.fsf@all.your.base.are.belong.to.us> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit X-Originating-IP: [10.67.110.108] X-ClientProxiedBy: dggems702-chm.china.huawei.com (10.3.19.179) To kwepemi500012.china.huawei.com (7.221.188.12) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-7.3 required=5.0 tests=BAYES_00,NICE_REPLY_A, RCVD_IN_DNSWL_MED,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 在 2023/1/3 2:04, Björn Töpel 写道: > Chen Guokai writes: > >> diff --git a/arch/riscv/kernel/probes/opt.c b/arch/riscv/kernel/probes/opt.c >> index 1c0e9d218f6f..884e77d2df4c 100644 >> --- a/arch/riscv/kernel/probes/opt.c >> +++ b/arch/riscv/kernel/probes/opt.c >> @@ -12,6 +12,7 @@ >> #include >> #include >> #include >> +#include >> >> #include "simulate-insn.h" >> #include "decode-insn.h" >> @@ -130,7 +131,7 @@ static void prepare_detour_buffer(kprobe_opcode_t *code, kprobe_opcode_t *slot, >> * as a destination register before any branch or jump instruction. >> */ >> static void find_register(unsigned long start, unsigned long end, >> - unsigned long *write, unsigned long *read) >> + unsigned long *write, unsigned long *read) > > Probably a patch messup; This makes the series no apply fully. Not sure, i will apply this patch to latest kernel(Linux 6.2-rc2) > > > Björn -- BR, Liao, Chang