Message ID | 20210730112443.23245-11-will@kernel.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <SRS0=BD2L=MW=lists.infradead.org=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@kernel.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-17.7 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,INCLUDES_CR_TRAILER,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 92791C4338F for <linux-arm-kernel@archiver.kernel.org>; Fri, 30 Jul 2021 11:31:28 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 63A9461040 for <linux-arm-kernel@archiver.kernel.org>; Fri, 30 Jul 2021 11:31:28 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 63A9461040 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=DZ+z4wRozmogtaW2UCLFPAq6RK9Ur406uja8T0y2kI8=; b=WHMh/37Nh3M5Wb lVGw48lz2dmg3UldYPGGOqNhZ9G1Q06ahvStR1DW052jcbz14KhavU8zdb3J/U8htBN7cLgDXb5bd PzYXtdZsDZbtvIqsAe2menLZXKjYeaZmFU4Hc+DBH6jh2UEc12hG60SlF2A1d0niwMDZvcr0Pt3rP n+QFNizH3IGZWQAB9Rvigiz/u+o3lxQlxOFR4KMDPLHUoJfXFfxZU+5iH4gOF578CA20bYqnJEQOf WNnKXFsXH5K7s+usu4Fh2aT7jJXoPJ83uRCankWkNAPQ4TVv4a9PL8CzLDRKJ7tV6hXzLwLelMBhl uy0YdOlIp1A8H9ELGniQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1m9QhZ-008JFr-45; Fri, 30 Jul 2021 11:29:18 +0000 Received: from mail.kernel.org ([198.145.29.99]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1m9Qdw-008HWG-2s for linux-arm-kernel@lists.infradead.org; Fri, 30 Jul 2021 11:25:33 +0000 Received: by mail.kernel.org (Postfix) with ESMTPSA id 42F9C61042; Fri, 30 Jul 2021 11:25:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1627644331; bh=41tFYtagGI1Lhiz3zWu2NlhWV1lTY0kbWv/RrqQ/NNQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=txOI8EoYqTcyfYriEygEnpS9AUmzRS/hTVAMDDtPpJAOyk+pBnKsszcKdnWVETGKH RGxgHIhsmbHsRm/HBH3DtIZSKP90plIeYjtDiDFHw2FC6H0XQGNZUNC7F3RKsNBokF znlajlq4J94PvqVbJ1hJStn8e+7G5o5DpvBZAzJlsrWyw37a/ufBc7fGtTAogXuYTR AP4UAjopdDNR3KfKC7y1013aTpz2/QbALkTsI334N5DY3r4179mjP33AKFZEkKHEV4 w0TWsT82jr3z6oLc/lZaJPjWiSPuyntp28F2pzPlXvm8C9qq2Z3aNoZU3D22JVIG65 wP/YciuWaYtWw== From: Will Deacon <will@kernel.org> To: linux-arm-kernel@lists.infradead.org Cc: linux-arch@vger.kernel.org, linux-kernel@vger.kernel.org, Will Deacon <will@kernel.org>, Catalin Marinas <catalin.marinas@arm.com>, Marc Zyngier <maz@kernel.org>, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, Peter Zijlstra <peterz@infradead.org>, Morten Rasmussen <morten.rasmussen@arm.com>, Qais Yousef <qais.yousef@arm.com>, Suren Baghdasaryan <surenb@google.com>, Quentin Perret <qperret@google.com>, Tejun Heo <tj@kernel.org>, Johannes Weiner <hannes@cmpxchg.org>, Ingo Molnar <mingo@redhat.com>, Juri Lelli <juri.lelli@redhat.com>, Vincent Guittot <vincent.guittot@linaro.org>, "Rafael J. Wysocki" <rjw@rjwysocki.net>, Dietmar Eggemann <dietmar.eggemann@arm.com>, Daniel Bristot de Oliveira <bristot@redhat.com>, Valentin Schneider <valentin.schneider@arm.com>, Mark Rutland <mark.rutland@arm.com>, kernel-team@android.com Subject: [PATCH v11 10/16] arm64: Implement task_cpu_possible_mask() Date: Fri, 30 Jul 2021 12:24:37 +0100 Message-Id: <20210730112443.23245-11-will@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20210730112443.23245-1-will@kernel.org> References: <20210730112443.23245-1-will@kernel.org> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20210730_042532_214736_AADF7302 X-CRM114-Status: UNSURE ( 9.96 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: <linux-arm-kernel.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-arm-kernel/> List-Post: <mailto:linux-arm-kernel@lists.infradead.org> List-Help: <mailto:linux-arm-kernel-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=subscribe> Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" <linux-arm-kernel-bounces@lists.infradead.org> Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org |
Series |
Add support for 32-bit tasks on asymmetric AArch32 systems
|
expand
|
diff --git a/arch/arm64/include/asm/mmu_context.h b/arch/arm64/include/asm/mmu_context.h index eeb210997149..f4ba93d4ffeb 100644 --- a/arch/arm64/include/asm/mmu_context.h +++ b/arch/arm64/include/asm/mmu_context.h @@ -231,6 +231,19 @@ switch_mm(struct mm_struct *prev, struct mm_struct *next, update_saved_ttbr0(tsk, next); } +static inline const struct cpumask * +task_cpu_possible_mask(struct task_struct *p) +{ + if (!static_branch_unlikely(&arm64_mismatched_32bit_el0)) + return cpu_possible_mask; + + if (!is_compat_thread(task_thread_info(p))) + return cpu_possible_mask; + + return system_32bit_el0_cpumask(); +} +#define task_cpu_possible_mask task_cpu_possible_mask + void verify_cpu_asid_bits(void); void post_ttbr_update_workaround(void);