From patchwork Mon Oct 15 15:31:59 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Long X-Patchwork-Id: 148855 Delivered-To: patches@linaro.org Received: by 2002:a2e:8595:0:0:0:0:0 with SMTP id b21-v6csp3933767lji; Mon, 15 Oct 2018 08:32:26 -0700 (PDT) X-Received: by 2002:ac8:33d6:: with SMTP id d22-v6mr16422216qtb.313.1539617546725; Mon, 15 Oct 2018 08:32:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539617546; cv=none; d=google.com; s=arc-20160816; b=T7un+WFlvV6SMfDnNqMpfVdzkjA95S/RcWSKTQtn+faQa2bi2JH4pl/33YMGnROcv3 1hpOkxAu7CZzKM/Biw9iGUNZ5U+0tjzZ9/DIF28EO6YxxYt6v1E2P87fULTtF/pd7M9/ xqMeIVOSxy0fKI0TbAcIFehAIZGlpO/deULZjAkIGPE51dv19+mtX1VuKIbn/q/G4WDX 06aEC6AYqeFxdzWZ4UjHJF32BKPZH/tTmGi28/bBHrrkvTbTfis1fB1DiApeEaKwAfMK BC+ONI2L+krT2kaBkjTNYfnWejnY18PwlNMfwxqnbzeCBTFsN/1urawdJZ2k2/hbOEGR JvWA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=Jk/8JjrwqCQQ9d7/yKmimwgykzqXDFqUVF4LDZjbIG0=; b=cs9w5xifOteP1CKeQT53wFKMr/wfQ/9VSGS+SwVi4XOmz39yLvITO5NhrXIXcG4Xfg xxtOv099Rn7fwdw+MX88Fgvf+wNH+Y/ZMB0w4H+vM/EglTtk1OmrGFAuNRURGbS4+pcf M7s2C1zirgcEsXUDUP0on64k1zgx0S5CP7ssgIXvW46YCcL+xhZ0ZfK1JjZJRtlNRzTK NByAxe01aNf+D0vCbwuOLMCszEZvuMRj8rI92MB9Zc9i/yTS+p4dVBZKasaZEIdsPuQz +KC/GghVd1DoqNqb2bW1QjFWFMigrDi9x7vMNjuWrPfGoO5hk59TFfL5kkAdINjMAGO4 A64w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hNJgBCFU; spf=pass (google.com: domain of dave.long@linaro.org designates 209.85.220.65 as permitted sender) smtp.mailfrom=dave.long@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id 11-v6sor6464090qkz.22.2018.10.15.08.32.26 for (Google Transport Security); Mon, 15 Oct 2018 08:32:26 -0700 (PDT) Received-SPF: pass (google.com: domain of dave.long@linaro.org designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hNJgBCFU; spf=pass (google.com: domain of dave.long@linaro.org designates 209.85.220.65 as permitted sender) smtp.mailfrom=dave.long@linaro.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org 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=Jk/8JjrwqCQQ9d7/yKmimwgykzqXDFqUVF4LDZjbIG0=; b=hNJgBCFUiQEnKbjKQxiHkpb6kRgudo0AZN/juXCWR7yg9UFZoJHwTywCqamPPC+pba 7il30tEzZvicBzVgs73Qi5nX34XuEC0ZtHLySy5+nrtw73MoAugfMa3HMlcWdJTHBp+f u+S3wmjV7NPCwdIGh4gnXTfcIK4LVlbUVik50= 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=Jk/8JjrwqCQQ9d7/yKmimwgykzqXDFqUVF4LDZjbIG0=; b=GeLM2ev75EKiAXDToTRfJvPgkUIHhgaKUoCdZtThxCTVvA0pXPHcSmbvmPbUoVFOG0 6BsCwUrMxk65LA7CRlFOVNphrTWRv5AxLh4Ieczj230eMSCK6zbpWbJWhjR8OFpOUIsH cOCm3m+YU+Sl7Tj+aTSX5cSYifDTf7jOK86sGZX+jOjHj55rQ+j/AnT5TkIcFsk3t/YF +IF1M5U48w1kSwLVAa0Gq07bWoHJcq2IXtXjqo65kchVIu87z4z9oYSTE2AM0fsIMr3H zsNpY7rZWrnmhtUnEIUe5thQfneLrjCCjYjBvae1WFgmA1finTafNe153vb1ADIHMlWH +BDw== X-Gm-Message-State: ABuFfoioYE5OcIpk+5OLeLOUjO4ZDExDIIPsvf2wpa7pO85sbcqZV8nj BJuJj7AtfhbLK7ubOsYmCvfxFCMq X-Google-Smtp-Source: ACcGV61qMdpPglI9Fj9Kcgf59Ymq2Dr/sBVeZWYwKGr3HnqWdA9vqCyAjPsbGEwHlaDzgeZ2KxN5UA== X-Received: by 2002:a37:f8c:: with SMTP id 12-v6mr16649847qkp.224.1539617546352; Mon, 15 Oct 2018 08:32:26 -0700 (PDT) Return-Path: Received: from localhost.localdomain ([72.71.243.63]) by smtp.googlemail.com with ESMTPSA id g82-v6sm10087768qkh.24.2018.10.15.08.32.25 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 15 Oct 2018 08:32:25 -0700 (PDT) From: David Long To: , Russell King - ARM Linux , Florian Fainelli , Tony Lindgren , Marc Zyngier , Mark Rutland Cc: Greg KH , Mark Brown Subject: [PATCH 4.14 05/24] ARM: spectre: add Kconfig symbol for CPUs vulnerable to Spectre Date: Mon, 15 Oct 2018 11:31:59 -0400 Message-Id: <1539617538-22328-6-git-send-email-dave.long@linaro.org> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1539617538-22328-1-git-send-email-dave.long@linaro.org> References: <1539617538-22328-1-git-send-email-dave.long@linaro.org> From: Russell King Commit c58d237d0852a57fde9bc2c310972e8f4e3d155d upstream. Add a Kconfig symbol for CPUs which are vulnerable to the Spectre attacks. Signed-off-by: Russell King Reviewed-by: Florian Fainelli Boot-tested-by: Tony Lindgren Reviewed-by: Tony Lindgren Acked-by: Marc Zyngier Signed-off-by: David A. Long --- arch/arm/mm/Kconfig | 4 ++++ 1 file changed, 4 insertions(+) -- 2.5.0 diff --git a/arch/arm/mm/Kconfig b/arch/arm/mm/Kconfig index fd9077a..575e11d 100644 --- a/arch/arm/mm/Kconfig +++ b/arch/arm/mm/Kconfig @@ -415,6 +415,7 @@ config CPU_V7 select CPU_CP15_MPU if !MMU select CPU_HAS_ASID if MMU select CPU_PABRT_V7 + select CPU_SPECTRE if MMU select CPU_THUMB_CAPABLE select CPU_TLB_V7 if MMU @@ -826,6 +827,9 @@ config CPU_BPREDICT_DISABLE help Say Y here to disable branch prediction. If unsure, say N. +config CPU_SPECTRE + bool + config TLS_REG_EMUL bool select NEED_KUSER_HELPERS