Received: by 2002:a05:6359:c8b:b0:c7:702f:21d4 with SMTP id go11csp5974374rwb; Wed, 21 Sep 2022 15:33:18 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5IcPEjPAKzPF4GeOvoXwa4QH4o/Ys0iCkAYt8KuGo/titxXb3wAIi9k4gTCaCk7lySS3Bi X-Received: by 2002:a17:902:f604:b0:172:ffa5:2ed9 with SMTP id n4-20020a170902f60400b00172ffa52ed9mr341466plg.7.1663799597819; Wed, 21 Sep 2022 15:33:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1663799597; cv=none; d=google.com; s=arc-20160816; b=hbQCULhQRPKdt6YbYg0ogoEgtFjFeDMgUDNLOWJpfztT7zmu4pxJ/sex3iw7swK0G9 i0Cbt7vlulnPZzi2dXlfN8lsVMehJLHwfyy+QMX5Qrn08jfechK/sxpRXpnAu1K2sOcu o+6vX+ka2vCGZHnbkC5yl5oEoO21BZaMxJUoOEjkOBYBqX40DPcElrbVy33GPGQcO8pj uZqS5x6H1bpYPN+9Xw7Le2bfU0gkDRkyimJY50OdEVUXtH9/VEs9rhqS+QhTzbtpFQZ1 PYwGe0Y9HFpjnv9+qpb27Emhpu1iWc5zKnMNqzLGJsWNCXIhA/Q/ZOkOt2+gloR138Kq fxLw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:to:content-transfer-encoding:mime-version :message-id:date:subject:cc:from:dkim-signature; bh=pNiBU06AGrcp2W7TASu6fynoklavjSC6OPveK31UOzA=; b=KIT8nmYlF8juu5quNchm2W4ON3f7nyrpXVHF02wiBe1UrsFwCfgyns8EvbyenXt+qh A6J/gAru27AhK74vqb2U/F7z+qLkAybxlE8IdyMW/TnOY+QganH1+2Bisdsw2pTN8rVj XpmkF8Tv8M84A8oFMc0I3mpS6vSzFwaWtpIwPiLW3I5juMHZEJds30qPS7JNW4w9mMZ8 2fgNhCC6S4j9yO4PJ76bctFpiARhHZ8EHTgwu2CHve2aSAquJYO+1k0rlCkLlm1VUzJW 9vQedlggmQ6v+Dj2AKj3OMhIHWrzCNF2ydtefPb42hxCtRQaMdNAp/efERUepFL5KVIh CTFw== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@rivosinc-com.20210112.gappssmtp.com header.s=20210112 header.b=AODJ1Met; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id il18-20020a17090b165200b001fe0682652esi4453516pjb.184.2022.09.21.15.33.05; Wed, 21 Sep 2022 15:33:17 -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=fail header.i=@rivosinc-com.20210112.gappssmtp.com header.s=20210112 header.b=AODJ1Met; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229779AbiIUVpN (ORCPT + 99 others); Wed, 21 Sep 2022 17:45:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46928 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229814AbiIUVpK (ORCPT ); Wed, 21 Sep 2022 17:45:10 -0400 Received: from mail-pj1-x1035.google.com (mail-pj1-x1035.google.com [IPv6:2607:f8b0:4864:20::1035]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A17358276F for ; Wed, 21 Sep 2022 14:45:09 -0700 (PDT) Received: by mail-pj1-x1035.google.com with SMTP id go6so7859809pjb.2 for ; Wed, 21 Sep 2022 14:45:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rivosinc-com.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date; bh=pNiBU06AGrcp2W7TASu6fynoklavjSC6OPveK31UOzA=; b=AODJ1Met9EqOFJ4cncAvFVOLy/vjD28tPZRu9cI+tOqlRM3XwC4eEObWXuwfBkBDN9 mOxBzSvjST4aYkBWFRHz1i1TJdk+/i5lB5ynpkAt6eAlo+QxDJrBkrn0Nz9SAtAVDY1g INj4t/p1sDMlNYYXorqVirr7LRBXBgWuUwvt84cU+QVW9pprJuTsmbWkhd9pB/4afNoF fKHaWzrCX4Q+5bdJiBCMYtqwKZfI1kNxNfYAeaCtFoSNcog9h4iY5lkEtpEu8/gIQtT+ B29rZ0Im5wgfComzCEXUmaqTAJ0b2hW9OHNlgL53UFClryljl0yxXK494k68dC0RE4nK lZ7w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date; bh=pNiBU06AGrcp2W7TASu6fynoklavjSC6OPveK31UOzA=; b=wXj3NrpWQFqWQgRzZy00ItyYAbSqZCNPDBhroKjwBqzqKhxfuOQwBeio2ET+/EhC6A J6C2epMBnyl5vdufI2k/17PDafVm/kCvxiVtL5UU/I/lBpxhDypDs8FBu8MoUD8tEtVr LuRx+GPexcazdKN97yZUGU5qyvEr+x84vrk9ZXl5kVrih0D/y9USXbw7Ha0IOpzzaKW3 tv75gKlFk6ZzjbXXPyBI8O01+mKHKcgwEuYyhFekne4hf3lKC2yYWjAcDsRblCesgyuN A2SpIE5obx50mN8dOJhiEnadkJ38wTOIRJTa48GlXV3Q96eoQ5lDkqaZxe7dUVU01thx WuSQ== X-Gm-Message-State: ACrzQf2v9GopYXISeZTE+puODBS2/X8fX+8yZQvgX3B6bMq5/OV3cHaG NKQaQKRB/CCdFLec5y28brwCMQ== X-Received: by 2002:a17:902:e547:b0:178:7cf4:90e9 with SMTP id n7-20020a170902e54700b001787cf490e9mr232284plf.158.1663796709143; Wed, 21 Sep 2022 14:45:09 -0700 (PDT) Received: from stillson.ba.rivosinc.com ([66.220.2.162]) by smtp.gmail.com with ESMTPSA id k7-20020aa79727000000b005484d133127sm2634536pfg.129.2022.09.21.14.45.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 21 Sep 2022 14:45:08 -0700 (PDT) From: Chris Stillson Cc: Guo Ren , Guo Ren , Greentime Hu , Anup Patel , Palmer Dabbelt , Paul Walmsley , Palmer Dabbelt , Albert Ou , Eric Biederman , Kees Cook , Atish Patra , Oleg Nesterov , Guo Ren , Heinrich Schuchardt , Conor Dooley , Arnaud Pouliquen , Chris Stillson , Paolo Bonzini , Alexandre Ghiti , Arnd Bergmann , Vincent Chen , Heiko Stuebner , Dao Lu , Jisheng Zhang , Sunil V L , Nick Knight , Han-Kuan Chen , Changbin Du , Li Zhengyu , Alexander Graf , Ard Biesheuvel , Tsukasa OI , Yury Norov , Nicolas Saenz Julienne , "Paul E. McKenney" , Frederic Weisbecker , Mark Rutland , Vitaly Wool , Myrtle Shah , Ruinland Tsai , Catalin Marinas , Mark Brown , Will Deacon , Alexey Dobriyan , Huacai Chen , Janosch Frank , Christian Brauner , Eugene Syromiatnikov , Peter Collingbourne , Colin Cross , Andrew Morton , Suren Baghdasaryan , Barret Rhoden , Davidlohr Bueso , linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, kvm@vger.kernel.org, kvm-riscv@lists.infradead.org Subject: [PATCH v12 01/17] riscv: Rename __switch_to_aux -> fpu Date: Wed, 21 Sep 2022 14:43:43 -0700 Message-Id: <20220921214439.1491510-1-stillson@rivosinc.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net To: unlisted-recipients:; (no To-header on input) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Guo Ren The name of __switch_to_aux is not clear and rename it with the determine function: __switch_to_fpu. Next we could add other regs' switch. Signed-off-by: Guo Ren Signed-off-by: Guo Ren Signed-off-by: Greentime Hu Reviewed-by: Anup Patel Reviewed-by: Palmer Dabbelt --- arch/riscv/include/asm/switch_to.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/arch/riscv/include/asm/switch_to.h b/arch/riscv/include/asm/switch_to.h index 11463489fec6..df1aa589b7fd 100644 --- a/arch/riscv/include/asm/switch_to.h +++ b/arch/riscv/include/asm/switch_to.h @@ -46,7 +46,7 @@ static inline void fstate_restore(struct task_struct *task, } } -static inline void __switch_to_aux(struct task_struct *prev, +static inline void __switch_to_fpu(struct task_struct *prev, struct task_struct *next) { struct pt_regs *regs; @@ -65,7 +65,7 @@ static __always_inline bool has_fpu(void) static __always_inline bool has_fpu(void) { return false; } #define fstate_save(task, regs) do { } while (0) #define fstate_restore(task, regs) do { } while (0) -#define __switch_to_aux(__prev, __next) do { } while (0) +#define __switch_to_fpu(__prev, __next) do { } while (0) #endif extern struct task_struct *__switch_to(struct task_struct *, @@ -76,7 +76,7 @@ do { \ struct task_struct *__prev = (prev); \ struct task_struct *__next = (next); \ if (has_fpu()) \ - __switch_to_aux(__prev, __next); \ + __switch_to_fpu(__prev, __next); \ ((last) = __switch_to(__prev, __next)); \ } while (0) -- 2.25.1