Message ID | 1519790211-16582-5-git-send-email-alex.shi@linaro.org |
---|---|
State | New |
Headers | show
Delivered-To: patch@linaro.org Received: by 10.46.66.2 with SMTP id p2csp567622lja; Tue, 27 Feb 2018 19:58:06 -0800 (PST) X-Google-Smtp-Source: AH8x224KhcmSCInsdrkv0EdNFMqYmk9gGj308GSvEmoud1Nci/vB9+WMguPcjywxCajpWtJsia2G X-Received: by 10.99.96.73 with SMTP id u70mr12693256pgb.199.1519790286185; Tue, 27 Feb 2018 19:58:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519790286; cv=none; d=google.com; s=arc-20160816; b=VYNR6POkMlDHbVqWynALL3d3jki6JKP5LvPA6mOPmybMLIkHpxSQFwBZn2dcbCAkZY ZRb3QZXX+sBx1nxAcBx00rtf8wgHfx4AAKpJlpPye9LFCpVTIHD5CUiP9PTgFKO15w6i W3GNpdqtMqZD3Gj6tJJglxbr4XQdoXwq7Wq+TSHwYTwnVB0zqObCHe3UdqSh6klSTVUO i1LQxEmqIdDQQGzmCWyKgd0fKTgTwB+n0MK0B+PKHkPFHN7w8c2BzPtn96jxADmg8/Pd jhyodT6qmmjFBwTzatyJvXOJJKFyQ4el+/CXFkzqZwCHFjeSdgbzWuawLtaBS26j3lvz Snow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=fBaV2So5mLi7XEyJz2SzruPt01XLduxFQhFmGwjPC28=; b=I9Zi8BsOnRIzu21o9vSRKcMnY1eOX9yfQSpZfjDXmcH/hEbJJRtYwC2AydxnOC2GwS KyTi5yGQvFP3EEgL+e+N2U0vFbayWaOzNqxHm/qxK9Qaq9LJ/lTZrpUOwsezRnGME7d1 zd3Hwzqvp2GDZifJjtlkabTW1C6iccMG0X0K2MO35pmcHk18UNEYuvapDzc3vf8Qck6B gBmvjFKxStG4dBxheu26e5CbO+N3YahNhX4/L2Z7ibcsC+bpYDtTBUKT/sauZ5cRE0pw 2o/FUT3RbkzXPKpSc5E8m08Ph95jRlpiSIxtHk/8Rr2I75LvPZOxYDULhGvLbcknbugM WMCQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=LtkiNWUt; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: <linux-kernel-owner@vger.kernel.org> Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g4-v6si586704plb.114.2018.02.27.19.58.05; Tue, 27 Feb 2018 19:58:06 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=LtkiNWUt; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752003AbeB1D6C (ORCPT <rfc822; dan.rue@linaro.org> + 28 others); Tue, 27 Feb 2018 22:58:02 -0500 Received: from mail-pl0-f66.google.com ([209.85.160.66]:36772 "EHLO mail-pl0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751981AbeB1D56 (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 27 Feb 2018 22:57:58 -0500 Received: by mail-pl0-f66.google.com with SMTP id 61-v6so777082plf.3 for <linux-kernel@vger.kernel.org>; Tue, 27 Feb 2018 19:57:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=fBaV2So5mLi7XEyJz2SzruPt01XLduxFQhFmGwjPC28=; b=LtkiNWUtxuJbVzTPhxAZVglhCF0Rin+SCEqA2+LieCgm65oSSLCMJDrSm+PCdiXBcc OndWn9Rmwy+j3z33F7uP716uucFG4PN5+Bkvt/XV9V6xq1LPKIInHcIQXR1AhUqjaPll MoeXULksvI8rnTGiFyr4ogZVZ/TFW9Xnmx/Zc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=fBaV2So5mLi7XEyJz2SzruPt01XLduxFQhFmGwjPC28=; b=E38H+LgbuFW09Pnf7xRPIzlO9B+4qi9xBjyUtU0f2tD5b8pJnLGKFkZOv+zZybbGlE cI5qzW6j5KAe9F9EQWFxux8ddrt3vllNA4La3akaemPNLeHmfBNxaQoF7vIN9pU2TMPN zyzBCPZS/7vyG3r1AleOGwwZpMDsanxxINew/kfmHrI7bzjGmfbCerLpO+XM23YcCOih NbJaj4YCLYVuUOfmjZcO4EeCWeSdvCKY0yJSFRW0f9iNWW7f8Q/bY2e7aWWQiN6bsfze jSSe1VOCEsrBntMgqvPDAOyd7G45hvyCIqVzKkztmc22b+IqvwcUrpSLHDJq+9w1zMyT kzxA== X-Gm-Message-State: APf1xPAARbXRZ/gs7IUzpznNnD5yr07tNaq9C0ztS3fvesdKlpSPkz7o ZodQKZ/DcuCDjp0Y7GHARxYWTw== X-Received: by 2002:a17:902:2803:: with SMTP id e3-v6mr16411484plb.238.1519790278309; Tue, 27 Feb 2018 19:57:58 -0800 (PST) Received: from localhost.localdomain (176.122.172.82.16clouds.com. [176.122.172.82]) by smtp.gmail.com with ESMTPSA id q17sm739911pgt.7.2018.02.27.19.57.51 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 27 Feb 2018 19:57:57 -0800 (PST) From: Alex Shi <alex.shi@linaro.org> To: Marc Zyngier <marc.zyngier@arm.com>, Will Deacon <will.deacon@arm.com>, Ard Biesheuvel <ard.biesheuvel@linaro.org>, Catalin Marinas <catalin.marinas@arm.com>, stable@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: Alex Shi <alex.shi@linaro.org> Subject: [PATCH 04/29] arm64: mm: Add arm64_kernel_unmapped_at_el0 helper Date: Wed, 28 Feb 2018 11:56:26 +0800 Message-Id: <1519790211-16582-5-git-send-email-alex.shi@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1519790211-16582-1-git-send-email-alex.shi@linaro.org> References: <1519790211-16582-1-git-send-email-alex.shi@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org |
Series |
arm meltdown fix backporting review for lts 4.9
|
expand
|
diff --git a/arch/arm64/include/asm/mmu.h b/arch/arm64/include/asm/mmu.h index 49924e5..279e75b 100644 --- a/arch/arm64/include/asm/mmu.h +++ b/arch/arm64/include/asm/mmu.h @@ -18,6 +18,8 @@ #define USER_ASID_FLAG (UL(1) << 48) +#ifndef __ASSEMBLY__ + typedef struct { atomic64_t id; void *vdso; @@ -30,6 +32,11 @@ typedef struct { */ #define ASID(mm) ((mm)->context.id.counter & 0xffff) +static inline bool arm64_kernel_unmapped_at_el0(void) +{ + return IS_ENABLED(CONFIG_UNMAP_KERNEL_AT_EL0); +} + extern void paging_init(void); extern void bootmem_init(void); extern void __iomem *early_io_map(phys_addr_t phys, unsigned long virt); @@ -39,4 +46,5 @@ extern void create_pgd_mapping(struct mm_struct *mm, phys_addr_t phys, pgprot_t prot, bool allow_block_mappings); extern void *fixmap_remap_fdt(phys_addr_t dt_phys); +#endif /* !__ASSEMBLY__ */ #endif