Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp3992954iob; Tue, 17 May 2022 11:23:25 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwXsA/Bf0HnP6hfNFybgbanT/U5ZwTvohwzLTca0A+0+CabzlkXyt7NeL2pATauN/eb7sz8 X-Received: by 2002:a05:6402:1393:b0:42a:c36d:67a6 with SMTP id b19-20020a056402139300b0042ac36d67a6mr6237925edv.158.1652811805189; Tue, 17 May 2022 11:23:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652811805; cv=none; d=google.com; s=arc-20160816; b=ZyqDWGtQO/iKj1lccnq7Pn9SRZ7knAkfv1A1EUyLufzMYfVpV7x/LHvn4/koLiCfW5 VtopuXa6ix5Xs/N1CQZJX613fWo80WlhhxDk916kWsC1HaQ3VfYGyI4bXV+DeyskuwxC 3NarE17ZbiD9nTJc+HCI4NKAR210PQ+9STZ0HvMFn1HeP+u+k1cNpGKqPsnb39qKJNrh DFb7pUf04ofKlojdiVQ7hw02cVjCVYpkd9DFerDKF9Ujw0W2V2KGWPqV+IVVjZsnSoVG ylETIqC42cI0tny5VHAVAk6RWDWwzjEUWNjktOZObfzO6NO3+qOzLTe7Tfz8gWLBEWfZ XlVg== 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=/YxdBnzui3ni5Jh3oFs5foUUYY4daAUO1PEkpPdCqlo=; b=o3wWgWHCbepr1kS1OjR5+HnzdW0nqWwVnCp1hOnXd/QhP0m6RIvhTPLfIrzy6aTocG jtGFJlffgHTvaRK4MkkO07uW/xJl7+MnctxhdEamu2frX7z5x2vOs2ExCMjhLGFq3C8f aZdeNizR5IsrQokV6+fPerUJrrSsty/BFf2ZTBaj15qr+y0WVrlMY7jg4DVBbGRGhybD O6N6sTWh9i8Ovv1FIfSgLjNZUm+NPCDcVno7uGvshqJMhm85L9XMHcaXCPmneF++HYaW JR/aHrmO6RuocMi+NjTl/ckgWtywRHs05M3pcKoOVOv+fqZbC7QojWKg6zcGZ3mRra1w Uqsw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b="WHGy/Fig"; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s8-20020a05640217c800b0041d9354ecacsi12390473edy.222.2022.05.17.11.22.58; Tue, 17 May 2022 11:23:25 -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; dkim=pass header.i=@gmail.com header.s=20210112 header.b="WHGy/Fig"; 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=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236811AbiEQA4a (ORCPT + 99 others); Mon, 16 May 2022 20:56:30 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58936 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238390AbiEQAzz (ORCPT ); Mon, 16 May 2022 20:55:55 -0400 Received: from mail-pj1-x102b.google.com (mail-pj1-x102b.google.com [IPv6:2607:f8b0:4864:20::102b]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2080B1FCCE for ; Mon, 16 May 2022 17:55:53 -0700 (PDT) Received: by mail-pj1-x102b.google.com with SMTP id ev18so5357878pjb.4 for ; Mon, 16 May 2022 17:55:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=/YxdBnzui3ni5Jh3oFs5foUUYY4daAUO1PEkpPdCqlo=; b=WHGy/FigKtpjnR0C/zvZzZKw82dDIx9z+0NO4/b1iqKaQ/L6icwl70tjS+vHAAlnKj TVt4JbXCTMQUOyaPvfYy4bIrT86YM0bKZT+chnoq6SJX7+2OhqLV/YUXuXJVuvVDxzJA h14DGve6uUkDhDNUXn8tD7mOT4nCvcP4EKHCdrp8yyhFQGYRTS/sKYQtN66O4GzzyQHx kGFltFCl5MTjCJjEd2YCa8rZTffpg9XoX2bdzfCXAM+MysAZH+jgmnUzJVPXyGxeC25K PN11R+jIzWdIZLs64/9MshIAogvSw8aVUiH0E0quNX/Eqewn5/qXV+4+0QqgJwc9bPwe YdRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=/YxdBnzui3ni5Jh3oFs5foUUYY4daAUO1PEkpPdCqlo=; b=7W2Fq0qk1wTFzColS1ad0QDNZP4fWamjCKjRFc6xCw72B5gGg3WZGoZES/lgzCEj9D 1lpj+cWLjj1iI5gawN1BEfbplqwwp6RLydKJvoNpXdNULHS9H8FhwFKFiEs6da88RBFa Q0idsKxSpow00/1hgwdo2iF6cBre/eydn2bRKCh6B3l5hHL4vDQNSpqtds0K4qEqrfU6 ruQvr19ApiesKv+dryCbzfGl7fPvpEo2itCfAzERavFY/3mXcaNyIIxwSGHHSdRpHECX j3ELdFjU2vOF/kkZDhfZRhvtwa+MRxXYJUpL/0iME9NywdJaDAgCJlAqx+cuED/TCXyd RkDA== X-Gm-Message-State: AOAM530EqNZYjeXgyWD1Robe9swc1nPm6RGuoQRp+Cgo5ATslI1izNBf v97+QugRhfxIdIzGTT/la4O8o4Qchxc7nA== X-Received: by 2002:a17:902:cec9:b0:15e:cbf4:c246 with SMTP id d9-20020a170902cec900b0015ecbf4c246mr19899475plg.1.1652748952205; Mon, 16 May 2022 17:55:52 -0700 (PDT) Received: from localhost ([2409:10:24a0:4700:e8ad:216a:2a9d:6d0c]) by smtp.gmail.com with ESMTPSA id n16-20020a6563d0000000b003c14af50607sm7243875pgv.31.2022.05.16.17.55.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 May 2022 17:55:51 -0700 (PDT) From: Stafford Horne To: LKML Cc: Openrisc , Stafford Horne , Jonas Bonn , Stefan Kristiansson , "Eric W. Biederman" , "Russell King (Oracle)" , Andrew Morton , Michael Ellerman , Kefeng Wang Subject: [PATCH v2 08/13] openrisc/traps: Remove die_if_kernel function Date: Tue, 17 May 2022 09:55:05 +0900 Message-Id: <20220517005510.3500105-9-shorne@gmail.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20220517005510.3500105-1-shorne@gmail.com> References: <20220517005510.3500105-1-shorne@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,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 was noticed when I saw this warning: arch/openrisc/kernel/traps.c:234:6: warning: no previous prototype for 'die_if_kernel' [-Wmissing-prototypes] 234 | void die_if_kernel(const char *str, struct pt_regs *regs, long err) | ^~~~~~~~~~~~~ The die_if_kernel function is not used in the OpenRISC port so remove it. Signed-off-by: Stafford Horne --- arch/openrisc/kernel/traps.c | 9 --------- 1 file changed, 9 deletions(-) diff --git a/arch/openrisc/kernel/traps.c b/arch/openrisc/kernel/traps.c index 9e0937eb31ca..99cd2e6f8873 100644 --- a/arch/openrisc/kernel/traps.c +++ b/arch/openrisc/kernel/traps.c @@ -235,15 +235,6 @@ void __noreturn die(const char *str, struct pt_regs *regs, long err) make_task_dead(SIGSEGV); } -/* This is normally the 'Oops' routine */ -void die_if_kernel(const char *str, struct pt_regs *regs, long err) -{ - if (user_mode(regs)) - return; - - die(str, regs, err); -} - void unhandled_exception(struct pt_regs *regs, int ea, int vector) { printk("Unable to handle exception at EA =0x%x, vector 0x%x", -- 2.31.1