Received: by 2002:a05:6a10:1287:0:0:0:0 with SMTP id d7csp631967pxv; Thu, 15 Jul 2021 12:01:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwoqRZcppede2jNWv9qqoLMOepuD+X1IkxuO5OAGYxwb67wIU6V9yLRuuQN2nQ0UTteP5fL X-Received: by 2002:a05:6e02:2188:: with SMTP id j8mr3695189ila.14.1626375691385; Thu, 15 Jul 2021 12:01:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1626375691; cv=none; d=google.com; s=arc-20160816; b=wYFHbkFgFypjFZRFrIPBt5Vs9tale/DlJa1ed7pHSKGrYw5eMGRFaY8vyiFxeL6EX/ zntuYGqJRkve5TzlceomN1BwwVkgnyQemSkAqN+ZGDTnNS1z9RzTusPZmKpFyqchFxu9 cWytNvL6bK/llXWLUwVaTIDRp09Hanc+X1zXyCt111tae3B/263CeAdNU4CfKTwE1tUp ZIKcUlzZboo9cjnJ9OObRp/4rg5zbdaBV+aFkUR7Nn87P2LbQuhtQf3QsSi+W3a2JeSp /4LpmfWzlCD+wNItog3yDHBLpUI8SOORmn2w+0RIDV1mQn0NwWPxRxq2zYF5G3z6LX5f wHbg== 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=exEj29hqGrmXBjwe4dlGJA1LsSTTpcCGE9G6jZL7wSE=; b=TWgl1R81O2uOgCv8aSgtgHIWYJhkRgUrQdr+ui2ddhIHU+YCRLtK2HAPS87QzxtnNo qxg6UukBSPjb+bfCXAEHdK+a5snCzU26NqNC/99t72fQr+sKUDhNzrRz5fnabEaX8VB1 ZKZCf+cCJLBj4nOtj0P3Lj3e0m1lk/shlqvGboG1uDyZeXL8FyPKlOKOdRRoedggWx4y nXkRCgQM59SOBNr1cLad15LLo3f3PD4GRl1vYKpjl3D3DZeqXFj2s4LEQfLNZCSX6T12 ZjIXXTguvSko5kNOgRZLDj1wXi8IsENEGHt+YsrhioBZjMv6Peus+/sBAw1a8k1X2HpX ebFQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=zc5DZ0ZI; 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 w10si8081145jad.45.2021.07.15.12.01.18; Thu, 15 Jul 2021 12:01:31 -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=zc5DZ0ZI; 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 S243120AbhGOTDC (ORCPT + 99 others); Thu, 15 Jul 2021 15:03:02 -0400 Received: from mail.kernel.org ([198.145.29.99]:56184 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S240898AbhGOSxh (ORCPT ); Thu, 15 Jul 2021 14:53:37 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 49741613E3; Thu, 15 Jul 2021 18:50:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1626375043; bh=EfF/j/9tYFALjllAB11e/KdjZIR9rz7LwCtzJFJiq8M=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=zc5DZ0ZIHy6t37jyL5UyHm5tfcaoEYzku6B7zesQoiUynLJb47v5EaEJ/ebx9EVH3 Z4Ql8O1JIBXD5dRLwajjcqWMNd+q64uGhRMYnwASf3ZyuoVco06lCbkyQno+XAiijT N/6zX3+CgDgA+w9mb2g/sH9qZjWfKRl4KmUzbU70= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Paul Cercueil , Thomas Bogendoerfer Subject: [PATCH 5.10 134/215] MIPS: MT extensions are not available on MIPS32r1 Date: Thu, 15 Jul 2021 20:38:26 +0200 Message-Id: <20210715182623.255659127@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210715182558.381078833@linuxfoundation.org> References: <20210715182558.381078833@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: Paul Cercueil commit cad065ed8d8831df67b9754cc4437ed55d8b48c0 upstream. MIPS MT extensions were added with the MIPS 34K processor, which was based on the MIPS32r2 ISA. This fixes a build error when building a generic kernel for a MIPS32r1 CPU. Fixes: c434b9f80b09 ("MIPS: Kconfig: add MIPS_GENERIC_KERNEL symbol") Cc: stable@vger.kernel.org # v5.9 Signed-off-by: Paul Cercueil Signed-off-by: Thomas Bogendoerfer Signed-off-by: Greg Kroah-Hartman --- arch/mips/include/asm/cpu-features.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) --- a/arch/mips/include/asm/cpu-features.h +++ b/arch/mips/include/asm/cpu-features.h @@ -64,6 +64,8 @@ ((MIPS_ISA_REV >= (ge)) && (MIPS_ISA_REV < (lt))) #define __isa_range_or_flag(ge, lt, flag) \ (__isa_range(ge, lt) || ((MIPS_ISA_REV < (lt)) && __isa(flag))) +#define __isa_range_and_ase(ge, lt, ase) \ + (__isa_range(ge, lt) && __ase(ase)) /* * SMP assumption: Options of CPU 0 are a superset of all processors. @@ -423,7 +425,7 @@ #endif #ifndef cpu_has_mipsmt -#define cpu_has_mipsmt __isa_lt_and_ase(6, MIPS_ASE_MIPSMT) +#define cpu_has_mipsmt __isa_range_and_ase(2, 6, MIPS_ASE_MIPSMT) #endif #ifndef cpu_has_vp