Received: by 2002:a05:6358:16cc:b0:ea:6187:17c9 with SMTP id r12csp2858528rwl; Tue, 27 Dec 2022 00:14:45 -0800 (PST) X-Google-Smtp-Source: AMrXdXvFHrbbyWCm5e5YOGJVTT9zHcLSfq+gS555NNXcuwU6YtQlEUfVdQfx3tAw3PFt1nJ7M4yo X-Received: by 2002:a17:906:e2c5:b0:81d:3231:5920 with SMTP id gr5-20020a170906e2c500b0081d32315920mr16644169ejb.61.1672128885299; Tue, 27 Dec 2022 00:14:45 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1672128885; cv=none; d=google.com; s=arc-20160816; b=Ug8CD/vq8iJc6gO2Wkf7qvNgD4e8MjeHtjM4a2FOeGxwtHaERextNBmzHsND+kOLGh VExL878tbFHLtrutAPrq87Dj+jTyaIPxyFeo26b+PbH6EGetx2xRArGnNdYeOICZhrSF isUm/vwgfWOI8P+j7viXxldy2Tf+1WGDf2vPhI/E0gsxZUNFqgMNRE5VQPQ4Pgr+ncpY XE+C9MUxqFeunQNut05oMoTOBEyVL6ot3GwCYs1WI9dj4taBpmMtqvHYL1o8vrBDKh/o KmHzfm2c5fFncUP1TUbSPa3SijBqVxw6kHfSaCb7/szoW0AWgGRXU0gl/rksZQoY/KAD xtag== 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 :message-id:date:subject:cc:to:from; bh=9QMXeupBkMLZ4BrlaetR9xqkIooUx6jo+suljaNYNVA=; b=LkoekW3FfFHU3gG8dR/xu9uT5a9IzYnB7bB2rrOKwv/VmiVA26SOhwPoyOxkWsPNom OxfbypQtiv0pDBLjnbIRCjqwQMZAqbMQb42zLNg9NrlCuLQnKoDTupyTDT8BcM/Dq2vx qLXKa6OKADMtytTR05msKXPXuEkqsvs8ak1vm6glXuoiwQYPdIKj4Q6WiOaRyXVDq8cL 6o1WptXArtpOYY7UfquSEkegpe4g3DzquC5F/240j2MrywIn6r5vW8JITUHPTMgq2orl Aa4Yabm4VolUccudeAGDG1kISHC3r9/PglDjO6MbbSLviIuEa1iiR56TLx3Mh4qUNBvR Pssg== 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y3-20020a056402358300b00468f9f21c11si11989341edc.245.2022.12.27.00.14.29; Tue, 27 Dec 2022 00:14:45 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229928AbiL0H1s (ORCPT + 66 others); Tue, 27 Dec 2022 02:27:48 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45086 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229936AbiL0H1T (ORCPT ); Tue, 27 Dec 2022 02:27:19 -0500 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E08AAE66; Mon, 26 Dec 2022 23:27:18 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 8069A60F90; Tue, 27 Dec 2022 07:27:18 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 2FFD9C433D2; Tue, 27 Dec 2022 07:27:14 +0000 (UTC) From: Huacai Chen To: Arnd Bergmann , Huacai Chen Cc: loongarch@lists.linux.dev, linux-arch@vger.kernel.org, Xuefeng Li , Guo Ren , Xuerui Wang , Jiaxun Yang , linux-kernel@vger.kernel.org, Huacai Chen , stable@vger.kernel.org, Yinyu Cai Subject: [PATCH] LoongArch: Add HWCAP_LOONGARCH_CPUCFG to elf_hwcap Date: Tue, 27 Dec 2022 15:27:24 +0800 Message-Id: <20221227072724.47564-1-chenhuacai@loongson.cn> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-6.7 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_HI,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 HWCAP_LOONGARCH_CPUCFG is missing in elf_hwcap, so add it for glibc's later use. Cc: stable@vger.kernel.org Reported-by: Yinyu Cai Signed-off-by: Huacai Chen --- arch/loongarch/kernel/cpu-probe.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/loongarch/kernel/cpu-probe.c b/arch/loongarch/kernel/cpu-probe.c index 255a09876ef2..3a3fce2d7846 100644 --- a/arch/loongarch/kernel/cpu-probe.c +++ b/arch/loongarch/kernel/cpu-probe.c @@ -94,7 +94,7 @@ static void cpu_probe_common(struct cpuinfo_loongarch *c) c->options = LOONGARCH_CPU_CPUCFG | LOONGARCH_CPU_CSR | LOONGARCH_CPU_TLB | LOONGARCH_CPU_VINT | LOONGARCH_CPU_WATCH; - elf_hwcap |= HWCAP_LOONGARCH_CRC32; + elf_hwcap = HWCAP_LOONGARCH_CPUCFG | HWCAP_LOONGARCH_CRC32; config = read_cpucfg(LOONGARCH_CPUCFG1); if (config & CPUCFG1_UAL) { -- 2.31.1