Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp144249yba; Thu, 25 Apr 2019 20:00:13 -0700 (PDT) X-Google-Smtp-Source: APXvYqw+0hMcOQd/0x5tKNy3ZQNbK2aYB/cDJxS8Jh93U91XArOrgV5gyaLgt7zXXuUnI4kq2H9v X-Received: by 2002:aa7:9e5b:: with SMTP id z27mr22222893pfq.186.1556247613781; Thu, 25 Apr 2019 20:00:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1556247613; cv=none; d=google.com; s=arc-20160816; b=N5A5ECOztLEox29NcuzBJomEMSH9o5l8VtzhK/VrnbL9CgYdMCYlSdMh9CxV/AYYzc yITquJWFzuD1ATFPl9PiG7f5HLGaO8fKkoEJYZXTdACJvIbpnFtz3zOzJK1V16GAio/j d57MFS6CtKtH/zNx+sT2mFl7OT3x1IcwevbaIBGVGIudEu6nX/rkLA7V0g4NwdU/Ex48 2awtcrunH566wqHhxNxuKDMKaV3ikYLCCJ31W5X/dvovVhNl/dpXhUEZH1b6jDP+ImEl UsfPI1g/smIMSxhLca0HaRls5ZJQAGF2eKd+3kLoWBukpQbOJMFsEueACIU7gr+EPxXZ w1eA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from; bh=ZZ3zRjeWWgmrB7ZHQntq/57QL6f5mO8fzOADZJ/m9wk=; b=CbFxyUY0ImprPPgS7HbL3d4Clr5Hz6VkfrhnSpDfPo80FDy/TzHLXt9/uFSZlVyWeF r5RPs77jTbBbGf88SHJP52O5AFn3+SAm5sJCBspQtbBwZB/lG4LaLrjOappKo6N+KXEa ZuM0egk1Ri0mz6I2Q6Wr+7nS/mF5l9xJEoRAOZGJ3B+2J3ydTeLcqMiKUoet1f7lMfdW gVrNxWcG/w6z3QeemDQIDl9zkUzenu9OMxZPoqAfgCHvrzUznFykOnY+PgCgrtEJWLkb SzzmbiCR7kdk42WkRvBvlZ3L4AQAars5iotgx3TxkAlXegb+UH65g150+NVil12JOkSL OWYA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a2si22998774pgn.530.2019.04.25.19.59.58; Thu, 25 Apr 2019 20:00:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727298AbfDZCSO (ORCPT + 99 others); Thu, 25 Apr 2019 22:18:14 -0400 Received: from szxga06-in.huawei.com ([45.249.212.32]:37666 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726086AbfDZCSO (ORCPT ); Thu, 25 Apr 2019 22:18:14 -0400 Received: from DGGEMS411-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id CF38B5D256DEA74723D7; Fri, 26 Apr 2019 10:18:11 +0800 (CST) Received: from linux-ibm.site (10.175.102.37) by DGGEMS411-HUB.china.huawei.com (10.3.19.211) with Microsoft SMTP Server id 14.3.439.0; Fri, 26 Apr 2019 10:18:01 +0800 From: Xiongfeng Wang To: CC: , , Subject: [PATCH] firmware: arm_sdei: Prohibit probing in '_sdei_handler' Date: Fri, 26 Apr 2019 10:16:36 +0800 Message-ID: <1556244996-1047-1-git-send-email-wangxiongfeng2@huawei.com> X-Mailer: git-send-email 1.7.12.4 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.175.102.37] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Functions called in '_sdei_handler' are needed to be marked as 'nokprobe'. Because these functions are called in NMI context and neither the arch-code's debug infrastructure nor kprobes core supports this. Signed-off-by: Xiongfeng Wang Reviewed-by: James Morse --- drivers/firmware/arm_sdei.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/firmware/arm_sdei.c b/drivers/firmware/arm_sdei.c index e6376f9..9cd70d1 100644 --- a/drivers/firmware/arm_sdei.c +++ b/drivers/firmware/arm_sdei.c @@ -165,6 +165,7 @@ static int invoke_sdei_fn(unsigned long function_id, unsigned long arg0, return err; } +NOKPROBE_SYMBOL(invoke_sdei_fn); static struct sdei_event *sdei_event_find(u32 event_num) { @@ -879,6 +880,7 @@ static void sdei_smccc_smc(unsigned long function_id, { arm_smccc_smc(function_id, arg0, arg1, arg2, arg3, arg4, 0, 0, res); } +NOKPROBE_SYMBOL(sdei_smccc_smc); static void sdei_smccc_hvc(unsigned long function_id, unsigned long arg0, unsigned long arg1, @@ -887,6 +889,7 @@ static void sdei_smccc_hvc(unsigned long function_id, { arm_smccc_hvc(function_id, arg0, arg1, arg2, arg3, arg4, 0, 0, res); } +NOKPROBE_SYMBOL(sdei_smccc_hvc); int sdei_register_ghes(struct ghes *ghes, sdei_event_callback *normal_cb, sdei_event_callback *critical_cb) -- 1.7.12.4