Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp4582120pxj; Wed, 12 May 2021 08:38:26 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyjGDNWn3DnTnjH3Of1qIwkZARPBMGMKk4+1Yqd7huL25VLCyBXq3QSlbE44wSsOsVYj+U7 X-Received: by 2002:aa7:d90d:: with SMTP id a13mr43053938edr.76.1620833905989; Wed, 12 May 2021 08:38:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1620833905; cv=none; d=google.com; s=arc-20160816; b=ZpQSiTV0m3OcW7qgiISA+gWpjt3YZXUMAKE3IMLzaJPR8mDX10swCh4jqZJdigzIfr vNVa16mo8fPEj6TXhWqtqkv8IfJU5jfqU0NOShWEd4fnjYOHOzobT9kThybiI7zYcRxK JLL0xf/22JGtuq+W8HpWY2eX9SIgUJTDyXCFYiemQcQWxUJiIAXCkeXtkHy2VUraUBjp khSvKhdgqkNlb5FJMUsGx4eMBnT2TGz5aXEnua3WEL+7bsU3Spr2TdfjL9/6WRPKNATz Y/SWOGsBeqvqVrc5p0dNJ46DaZlapgwjyynNwpfVIOZfwZjXd7+BEGjhYbEMgSSPBQVW nIUA== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=curVm6RYK70c7mJw2agAaV5JOAS7PbNP7SXE5/rgnVc=; b=qSNIPFXHLDCzmxkLXIt0+T4s6xtQKgzC3OD7NhRYfUvWXevIC7TteFsfYa8CBeoCrd MsY7J+1q2qENpHVkCNusNTuPj2ubYurfBgvmmjCrzBZYqRDxowDLfAoJnOFbDwPFWZlt dXRML3cloNxKD11i4BYG+bOCyxDD2Fv3bcekhtmHnPhz7864Y4XJ0UYGxB9IvyJsRGXD Ax639JokTCtyUtTgcx85qIuSL3PIFcBsiZSBiG57nC1PEbmcijDp37M6qNbeMEQDosRF RO68Tc4AkKs9J3LkN29mP/qClAYnNkp/hcpBaAIFrbS4v6TseV6TE3hShzKoAfif8ctc WUzA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="SiBk/di5"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id k19si284474ejv.98.2021.05.12.08.38.02; Wed, 12 May 2021 08:38:25 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b="SiBk/di5"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236007AbhELPg2 (ORCPT + 99 others); Wed, 12 May 2021 11:36:28 -0400 Received: from mail.kernel.org ([198.145.29.99]:50548 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234272AbhELPQV (ORCPT ); Wed, 12 May 2021 11:16:21 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 6F79F61979; Wed, 12 May 2021 15:06:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1620831967; bh=1KwjSEPuyYELqNeMMr9CppIyN2C+J6HxBghmNQPymyM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=SiBk/di5dFMMpBxvpT71ZL6HuBAm0MpsGEoDHjJZsgy4bWDly+1ZCloa2z7+tu4X0 tZk8HS5bOZ4FqsztN/dspUXwwx+7FoBlw9JcXgsFAbMvctNuDg6RZCh1M2BOVZBbeQ dsreJtAqUFLS5ol/AMUGfplxmIL5GdSdIx03MDa0= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Vasily Gorbik , David Hildenbrand , Christian Borntraeger , Cornelia Huck , Janosch Frank , Heiko Carstens Subject: [PATCH 5.10 087/530] s390: fix detection of vector enhancements facility 1 vs. vector packed decimal facility Date: Wed, 12 May 2021 16:43:17 +0200 Message-Id: <20210512144822.645889783@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210512144819.664462530@linuxfoundation.org> References: <20210512144819.664462530@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: David Hildenbrand commit b208108638c4bd3215792415944467c36f5dfd97 upstream. The PoP documents: 134: The vector packed decimal facility is installed in the z/Architecture architectural mode. When bit 134 is one, bit 129 is also one. 135: The vector enhancements facility 1 is installed in the z/Architecture architectural mode. When bit 135 is one, bit 129 is also one. Looks like we confuse the vector enhancements facility 1 ("EXT") with the Vector packed decimal facility ("BCD"). Let's fix the facility checks. Detected while working on QEMU/tcg z14 support and only unlocking the vector enhancements facility 1, but not the vector packed decimal facility. Fixes: 2583b848cad0 ("s390: report new vector facilities") Cc: Vasily Gorbik Signed-off-by: David Hildenbrand Reviewed-by: Christian Borntraeger Reviewed-by: Cornelia Huck Reviewed-by: Janosch Frank Link: https://lore.kernel.org/r/20210503121244.25232-1-david@redhat.com Signed-off-by: Heiko Carstens Signed-off-by: Greg Kroah-Hartman --- arch/s390/kernel/setup.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/arch/s390/kernel/setup.c +++ b/arch/s390/kernel/setup.c @@ -925,9 +925,9 @@ static int __init setup_hwcaps(void) if (MACHINE_HAS_VX) { elf_hwcap |= HWCAP_S390_VXRS; if (test_facility(134)) - elf_hwcap |= HWCAP_S390_VXRS_EXT; - if (test_facility(135)) elf_hwcap |= HWCAP_S390_VXRS_BCD; + if (test_facility(135)) + elf_hwcap |= HWCAP_S390_VXRS_EXT; if (test_facility(148)) elf_hwcap |= HWCAP_S390_VXRS_EXT2; if (test_facility(152))