Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp4328820pxb; Sun, 14 Feb 2021 06:45:46 -0800 (PST) X-Google-Smtp-Source: ABdhPJxYev051lNXjsbgVwOfedIidt5zOpwWhZjRxEvUhorOs1vxCUqUY8OWucxb3NkWpFowwlpB X-Received: by 2002:a17:907:3e06:: with SMTP id hp6mr11770216ejc.254.1613313946712; Sun, 14 Feb 2021 06:45:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1613313946; cv=none; d=google.com; s=arc-20160816; b=mUp/lzri3tcQuera8QL1yaNW7tIPq6Cx+IymcDocW9YN14TgpTXWW6bVV0is+zpmh7 fXk2l0jv2vGZ/erpUOwMwpOVSJY6pscPJJvVTznb7zy8by0p1eFSrhteG1KD7rjfeIyO dOVnsRecRheuU6nc1zkGxEuYfsWsGaooJfUjaMTeLKu/gLLR5ystwRGS2YJcMWoTRNgF 5gADgk7jIBmWOPEG6WqJcF3TgOqjfWJi7HvKitN3gjQ88f7p48tTK/6FwwWBYnal58zw XiiWxQ5cjnSjniPgaR1TC6yixpKhs98a6CeORWgolvdojPLv/ySY6ZbnnF3LNu910BI4 OCyA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:reply-to :in-reply-to:references:mime-version:dkim-signature; bh=9wPjYm6KxTX2zA0MH0f3YcudN64OMfQGI54X5pgP9Fo=; b=DkUhvUj/b5uDpi/6nasVw0SCMca1bqj8P7mgtsiqcqLKwVvsqp5GYju0rb8A3Y596c ZRvD+y5+r02TW8Xe49s3qAkUUBWMAs8pS8R+6YBjvUSG0jyF1xizmYQuf47Fsty/DdEZ YhueJgoseym6GDySfg2yXMuIuzxCOfPMXE3mvWyy7vyQq/n2qfPxEj+Sb5c4VxiTFTT2 4mGPBFehLf0qh61K2Qh1aDvGa7pH2tCZY6z4IhYGZtL+OeCq3aem59rQsLdb2KxDtSAy 9t5RlwLDAiiy//8Us+S412t8RQadEQ/sGzTYdJsqSAQAD2TdtsCeVlUbZevv9E9fmZxT HGfg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="sj/et1DR"; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d24si9887059edt.102.2021.02.14.06.44.58; Sun, 14 Feb 2021 06:45:46 -0800 (PST) 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=@gmail.com header.s=20161025 header.b="sj/et1DR"; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229793AbhBNOnf (ORCPT + 99 others); Sun, 14 Feb 2021 09:43:35 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60784 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229758AbhBNOne (ORCPT ); Sun, 14 Feb 2021 09:43:34 -0500 Received: from mail-io1-xd29.google.com (mail-io1-xd29.google.com [IPv6:2607:f8b0:4864:20::d29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E4AEBC061574 for ; Sun, 14 Feb 2021 06:42:53 -0800 (PST) Received: by mail-io1-xd29.google.com with SMTP id q7so4313006iob.0 for ; Sun, 14 Feb 2021 06:42:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:reply-to:from:date:message-id :subject:to:cc; bh=9wPjYm6KxTX2zA0MH0f3YcudN64OMfQGI54X5pgP9Fo=; b=sj/et1DRuCHieziSQrAaf9mTgilPpc8iOKZn+7L0jzpjbkjyuh7MYkzj+eYcdbxXA3 5oU9dGzGbLBe7oQoKWf99aRJUZ1DoJzr7gfeFXbZPE6rsPsf3jBCjoHaNO1DWvoJREPt nvXvK15UccF93OH2xU79IyxDCMoRbc5pJQFswTONuTmdLnw2LAnx484z2cBHnD0eTbmw 0F012eu5Nr7HTp9pWNOKH95z49JBAnn5U5qwvof56yZNwIQ+zoqIhiIS1AUlgRUoae5a I2R6Fmnl9QNRqFpyLQ6EMaDWt4owNad0f/ENiLCqQcyecKi58r1LrxcDHA3FkPIAjMcI ZUcA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:reply-to :from:date:message-id:subject:to:cc; bh=9wPjYm6KxTX2zA0MH0f3YcudN64OMfQGI54X5pgP9Fo=; b=TeuRINF02pYnzLUs5m0aMc1cSyaV1S+fpplGqzCrs3dQtfJ1TAIK4oTRuDaAZFXEEl iGDAkl34O2w/IFiu/CI1ZvWtRFPn4cb6eDkf8FxzKVJ0k0ROAQQKbcKTRMyCnEYXGQTC subyu9YSKx+edSDz/Jq3OIgynHPUppp7laYiaYunJ+1PpgR9tUKUiNZkc2ymZTnsVjfb +Iw+xcv5+JgAoHFapU8ITT9NgeAib+7sC/PcUFRTrQK+Dgsb0Q93hO1GmyzU/93WRwHD CLxvsYhjz57rLpHBNekACY96GsNg9hCtzv85KT5vj0rd0A1naVdz520pJEvmOktURPg/ 5W7A== X-Gm-Message-State: AOAM530Wvg20i0hitzCzjZCjvPVIlncItGAnb4FIDcJiIqqEOj37Qkm+ fuGk6HmJ0TdC5bEZ/lp4XbxPUxLZvRCZtJxt6nU= X-Received: by 2002:a05:6638:2694:: with SMTP id o20mr11523155jat.132.1613313773262; Sun, 14 Feb 2021 06:42:53 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: Reply-To: sedat.dilek@gmail.com From: Sedat Dilek Date: Sun, 14 Feb 2021 15:42:44 +0100 Message-ID: Subject: Re: [PATCH v2 0/2] Clean up x86_32 stackprotector To: Andy Lutomirski Cc: x86@kernel.org, LKML , Nick Desaulniers , Sean Christopherson , Brian Gerst , Joerg Roedel Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Feb 13, 2021 at 8:19 PM Andy Lutomirski wrote: > > x86_32 stackprotector is a maintenance nightmare. Clean it up. This > disables stackprotector on x86_32 on GCC 8.1 and on all clang > versions. Some clang people are cc'd. > > Changes from v1: > - Changelog fixes. > - Comment fixes (mostly from Sean). > - Fix the !SMP case. > > Andy Lutomirski (2): > x86/stackprotector/32: Make the canary into a regular percpu variable > x86/entry/32: Remove leftover macros after stackprotector cleanups > Happy Valentine's Day, I have no rose or pralines for you, Andy :-). First, I tried to apply your patchset on top of which has shown some conflicts. AFAICS it conflicts with (or more precisely with the recent "Merge branch 'x86/paravirt' into x86/entry"). Just wanna let you know. I have tested this on Debian/testing AMD64 (x86 64bit) with LLVM/Clang v12.0.0-rc1 and my custom patchset. Means compile-tested and booted into bare metal and checked build-log and dmesg-log for warnings. So far nothing scary. Feel free to give credits like a Tested-by if you like. ( Roses and pralines are welcome, too, hahaha :-). ) Icecold and sunshiny Greetings from North-West Germany, - Sedat - > arch/x86/Kconfig | 7 +- > arch/x86/Makefile | 8 ++ > arch/x86/entry/entry_32.S | 95 +---------------------- > arch/x86/include/asm/processor.h | 15 +--- > arch/x86/include/asm/ptrace.h | 5 +- > arch/x86/include/asm/segment.h | 30 ++----- > arch/x86/include/asm/stackprotector.h | 79 ++++--------------- > arch/x86/include/asm/suspend_32.h | 6 +- > arch/x86/kernel/asm-offsets_32.c | 5 -- > arch/x86/kernel/cpu/common.c | 5 +- > arch/x86/kernel/doublefault_32.c | 4 +- > arch/x86/kernel/head_32.S | 18 +---- > arch/x86/kernel/setup_percpu.c | 1 - > arch/x86/kernel/tls.c | 8 +- > arch/x86/kvm/svm/svm.c | 10 +-- > arch/x86/lib/insn-eval.c | 4 - > arch/x86/platform/pvh/head.S | 14 ---- > arch/x86/power/cpu.c | 6 +- > arch/x86/xen/enlighten_pv.c | 1 - > scripts/gcc-x86_32-has-stack-protector.sh | 6 +- > 20 files changed, 62 insertions(+), 265 deletions(-) > > -- > 2.29.2 >