Received: by 2002:a05:6a10:6d10:0:0:0:0 with SMTP id gq16csp324120pxb; Tue, 12 Apr 2022 02:55:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzjT5vE2zU1VqX1ZbNEEKfnRjGscUPsm9wseYGr2/sfTAxtT/Gz8lQc3e/ddyymfMmFh9Gj X-Received: by 2002:a17:902:a710:b0:156:5650:f94a with SMTP id w16-20020a170902a71000b001565650f94amr35813242plq.86.1649757303837; Tue, 12 Apr 2022 02:55:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649757303; cv=none; d=google.com; s=arc-20160816; b=NtwjPO4p/8l0ZY9pkZB9A5ClYE6FZYmf4jCRdMoIA7xnaZ8TwpBdTmfUuur+sh/Yal ykReEQC8CumUjm3obWgjaFPNIZvAOhLadzIt7LOtZ6+bE97ybwn3Mq/92HMEsfJAiyFU AHK5+8d5FjNzdFhtKjb/9mPMF9BVGKzjys292sq1HQh2fE2aAuZU72gf2QGSUDbmx+nO +q0s31MQXScbgGRi5FVoA2q5LKCzVxDNeB5DcDWc8fP7nffCaiCGAXFElZdeAimoJLXj avuG9RSzsFFtxvWZfDTbtrJ431AlyiqKKPkLs5+oRc16bNksYvIxt7OJTvmon2fnR6Ab X3YQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=hjV85bpMkNJuL8vvhI9IAAgoX1lYtvK7CB2b32NFcGE=; b=vThcqPCOgO2KiRlprq0F1V7YqnPAY7FOhIjvQoy6q+8IpMAotlr2wcp4lH+8u5Oqbe tq+XZm8HE/gX7ktGUlkc8pWi5bHrcCCFoHNw2le2y8Cuahzf+tL7Obb3c3KMt1qlQkmh pzPvC+FLOe1RZwl33xerHM5q1NLWTJQ6gDZ0CHHMSTcR3kj8kGyPBGbWHNy7/E9bHSed AokuI9EgheYnNr1BdaYmPiYE1zvi2mwQ8gEtnJUSZqOwW3aNF+JdvKX52eJrotzHMWll 4XO/4F+7sBvfvyEyh52SrhSsYZ/ejVaqvqO/w8zCbX1yvCxyJgxGlbT+pmvCLvnwe3wB ctrw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@brainfault-org.20210112.gappssmtp.com header.s=20210112 header.b=2WTmPakh; 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 m23-20020a63f617000000b00383f7ddd81fsi2263338pgh.346.2022.04.12.02.54.49; Tue, 12 Apr 2022 02:55:03 -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=@brainfault-org.20210112.gappssmtp.com header.s=20210112 header.b=2WTmPakh; 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 S240694AbiDIDxd (ORCPT + 99 others); Fri, 8 Apr 2022 23:53:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58230 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234150AbiDIDxb (ORCPT ); Fri, 8 Apr 2022 23:53:31 -0400 Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A414F332DCC for ; Fri, 8 Apr 2022 20:51:25 -0700 (PDT) Received: by mail-wm1-x336.google.com with SMTP id c190-20020a1c35c7000000b0038e37907b5bso8872327wma.0 for ; Fri, 08 Apr 2022 20:51:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=brainfault-org.20210112.gappssmtp.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=hjV85bpMkNJuL8vvhI9IAAgoX1lYtvK7CB2b32NFcGE=; b=2WTmPakhdY7m3RR1J07Q3HKF1lUUw9xYcvbeLmdmCbGu1QsrzEF4yovjQ0w0PTqUP8 ttUY4tWy+XJwxrc5eD98+gpJlyvafAhc5eahueerCdGExOWlMyceUC4SSm3BEAWLpoyX bsJdfVmNiSmv38SYHT3dlVZt/EStxBgDHN9WuZ3jj8tElkN2+eLulHgK4z+qjG6AuZEZ JEnEE39kL7T9irPQd/LL8aplExKzX14Ib9lV2E/eIugV2sd+u5TLYpsWJTBiU2ja4mYF UmQNAKfH6PykEeJvOrTXhKGFherqje+MPiA4F74VK9myrEuen1txu7tXO0Iqv2D/XgW3 Wmcw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=hjV85bpMkNJuL8vvhI9IAAgoX1lYtvK7CB2b32NFcGE=; b=ew0o2PO2u+1ezogrJSHgD4Yyzlwjdk3CsaMcwtuYyvSM0MS6LDUl01ajQ7kKncuatl uKNVvb0SFDlfk5XztAceFJRJq8HqdGd1YHk1E/ZeIRsyVhPQh5h8TQlRzvfrEKX/TbN/ bX//gLZB7lcR01QLyDwAjUlRq7M9I9diqKtoGkHaM/R9JNZq+e6amQFzT2Ufiqc9LNBG w/qAwv22SnfqrxXwYoNd6BI5ZfFpT7W1lrbqfWy8KdG7JEFTWW2K0voAPSC8jKBgT/Ga qUBssbP6BkuR/AD9k5UbQHpKO6+8TEfy2oTBT4Y77CzCqh84ogbv1j7udpB3t8qcatAX 6/6A== X-Gm-Message-State: AOAM53343O1P9wRv8o2oAVY4JyeXx270W5Ra3BOjIbKX6A9q4m5zcrxn qCVtz3rGMEhHOs3yDYhvY6XWt9fIwvAeijYqNKNaVw== X-Received: by 2002:a05:600c:1d04:b0:38c:ba2f:88ba with SMTP id l4-20020a05600c1d0400b0038cba2f88bamr19619710wms.137.1649476284108; Fri, 08 Apr 2022 20:51:24 -0700 (PDT) MIME-Version: 1.0 References: <20220408092415.1603661-1-heiko@sntech.de> In-Reply-To: <20220408092415.1603661-1-heiko@sntech.de> From: Anup Patel Date: Sat, 9 Apr 2022 09:21:11 +0530 Message-ID: Subject: Re: [PATCH] RISC-V: KVM: include missing hwcap.h into vcpu_fp To: Heiko Stuebner Cc: Atish Patra , Paul Walmsley , Palmer Dabbelt , Albert Ou , KVM General , "open list:KERNEL VIRTUAL MACHINE FOR RISC-V (KVM/riscv)" , linux-riscv , "linux-kernel@vger.kernel.org List" Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable 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_NONE, 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 On Fri, Apr 8, 2022 at 2:54 PM Heiko Stuebner wrote: > > vcpu_fp uses the riscv_isa_extension mechanism which gets > defined in hwcap.h but doesn't include that head file. > > While it seems to work in most cases, in certain conditions > this can lead to build failures like > > ../arch/riscv/kvm/vcpu_fp.c: In function =E2=80=98kvm_riscv_vcpu_fp_reset= =E2=80=99: > ../arch/riscv/kvm/vcpu_fp.c:22:13: error: implicit declaration of functio= n =E2=80=98riscv_isa_extension_available=E2=80=99 [-Werror=3Dimplicit-funct= ion-declaration] > 22 | if (riscv_isa_extension_available(&isa, f) || > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ > ../arch/riscv/kvm/vcpu_fp.c:22:49: error: =E2=80=98f=E2=80=99 undeclared = (first use in this function) > 22 | if (riscv_isa_extension_available(&isa, f) || > > Fix this by simply including the necessary header. > > Fixes: 0a86512dc113 ("RISC-V: KVM: Factor-out FP virtualization into sepa= rate sources") > Signed-off-by: Heiko Stuebner I have queued this for RC fixes. Thanks, Anup > --- > arch/riscv/kvm/vcpu_fp.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/arch/riscv/kvm/vcpu_fp.c b/arch/riscv/kvm/vcpu_fp.c > index 4449a976e5a6..d4308c512007 100644 > --- a/arch/riscv/kvm/vcpu_fp.c > +++ b/arch/riscv/kvm/vcpu_fp.c > @@ -11,6 +11,7 @@ > #include > #include > #include > +#include > > #ifdef CONFIG_FPU > void kvm_riscv_vcpu_fp_reset(struct kvm_vcpu *vcpu) > -- > 2.35.1 >