Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp4028646ybp; Mon, 7 Oct 2019 01:57:03 -0700 (PDT) X-Google-Smtp-Source: APXvYqyrNUYMq+6D9kaOEC3yBRlGLOmgUOL00sTP748EdsDIzaY4fsJPH4EDV6tY0mMhzsc5F9cx X-Received: by 2002:a05:6402:68c:: with SMTP id f12mr27678469edy.299.1570438623621; Mon, 07 Oct 2019 01:57:03 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1570438623; cv=none; d=google.com; s=arc-20160816; b=f/AYDAhgH5zhcBupy/9yO4WDZYk4Cp1gKQxzo0wDFVyxlUio5UKYbu7V5GYoEbdN0x AiE+qH1XjrCjIWZ1Zgp191CbL/sx9iaEMO8b22n9N2hcxqHvw6fo4ymEUxvUKPWBSuf5 GubLcTRRaxoStW/b5HDcTAS6cZhlOYvwUPOhlC/hRjuLpdBrQgANOwRgXmlhv2J7djJA GrlyQqUshf9HmoL5d7JeSdfYtukTFAVTYJTs2gk79uDxEpWjNqmTj6VLyqVudLQ+gx15 JWRRp3BnW6LRZmjJnUQBmNOL5qrexgGuba9Xrm1act30Qx/5k6RIc60fJZx5yAhU7WKa gqeQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=oF5jAujUKODNIkx3N+qAq7fK2yODGoDCZN8QrSoPvIM=; b=RMlNuRc+EL+akeJGcy4qLcW+JyWz1ZuAPrkmNycZhkhtgZwJ/gdYLppnZyg5/fjaZp 1yL0LEZWlSxYe+w90R/H2iJufygex4IraCguMajrpnRFgw5p1GeGwf80X0DnYmvUwzUH nwaELFxqTs5rbW9FZ1GTQBICdHuIjUaX1hfAzyxNTcQdaEB3/5piDQF0ptBsNwq7PPa2 JxbwgptPlc2RuqIXlexNYeOYNrvCU/6akEpiOycwd5cZOrSMsKGDiuShofxZZwb/tguo HbFPYgLiRpezHtISznFSCawY8BSW0L3+ePxjaipBW2EGNfO4YTGLEBGPTzhvz64yB2S5 /NgA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@rasmusvillemoes.dk header.s=google header.b=JIKEPFmb; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id gf9si1443748ejb.230.2019.10.07.01.56.40; Mon, 07 Oct 2019 01:57:03 -0700 (PDT) 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=@rasmusvillemoes.dk header.s=google header.b=JIKEPFmb; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727334AbfJGI4O (ORCPT + 99 others); Mon, 7 Oct 2019 04:56:14 -0400 Received: from mail-lj1-f196.google.com ([209.85.208.196]:44782 "EHLO mail-lj1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726969AbfJGI4O (ORCPT ); Mon, 7 Oct 2019 04:56:14 -0400 Received: by mail-lj1-f196.google.com with SMTP id m13so12680540ljj.11 for ; Mon, 07 Oct 2019 01:56:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rasmusvillemoes.dk; s=google; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=oF5jAujUKODNIkx3N+qAq7fK2yODGoDCZN8QrSoPvIM=; b=JIKEPFmbILhicqpj7J2lmB3IWsrAnubkX4o6AW64rIBaEUEmLXm79mYHxWTI1atpJR oL7BwtLnFsM1CS9ISo6frgzNJCQzkl0LNZJzgjwGUONXUSoZqRXJeLg8Wqv9BmkmA8dc drzoZIqwKPyOPOY5Zisqb/IgrqB/Xl0zIN2SE= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=oF5jAujUKODNIkx3N+qAq7fK2yODGoDCZN8QrSoPvIM=; b=Ns57a+dgJpQMzM5FkYkIaOCqHvmJ63RCOsZkv/3Oezc8IlIVlhm1/8Wcovn3Ri676v 0oXM/n7ukSm1X04ryQu7Vxew8yrv1UqVWRGuSm7l3EW26zQ4GZuyefWJQRoQAB4uZkQj fENt25Nx6nx6yOllLc+yXtAVXNhvpYXZOf314o/s1WAbaCkfeHp7r4JIBSSYAX/wX4LO 2TZVs09LlItteX9ePgVcD7+ROB9EEtDcu/argxttj91FM7R1S4HSmMX/u389SGWLWD+C YrQl1SrmfxxUQOoGYrbFYWw9k82heNKSDcnABzdjqf7dFIl/sgansYR2mVAcuutaj0ty 1mlA== X-Gm-Message-State: APjAAAVdXdqlX4+7NI+9Z+5C3YryUWJderdBXrleR3gxIqXpiEJoxK9e XOhRqcB/i27glyaaRZ6HulFAeyMzDhSllaWc X-Received: by 2002:a2e:7502:: with SMTP id q2mr17826943ljc.202.1570438571690; Mon, 07 Oct 2019 01:56:11 -0700 (PDT) Received: from [172.16.11.28] ([81.216.59.226]) by smtp.gmail.com with ESMTPSA id f6sm2665455lfl.78.2019.10.07.01.56.10 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Oct 2019 01:56:11 -0700 (PDT) Subject: Re: [PATCH 1/2] x86: mmu.h: move mm_context_t::lock member inside CONFIG_MODIFY_LDT_SYSCALL To: Rasmus Villemoes , Thomas Gleixner , Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , x86@kernel.org Cc: linux-kernel@vger.kernel.org References: <20190828193836.16791-1-linux@rasmusvillemoes.dk> From: Rasmus Villemoes Message-ID: <29e830f8-65fe-c2b9-1c3f-4359bdf8ac64@rasmusvillemoes.dk> Date: Mon, 7 Oct 2019 10:56:09 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <20190828193836.16791-1-linux@rasmusvillemoes.dk> Content-Type: text/plain; charset=windows-1252 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 28/08/2019 21.38, Rasmus Villemoes wrote: > The placement of the lock member in mm_context_t suggests that it is > used to protect the vdso* members, but AFAICT, it is only ever used > under #ifdef CONFIG_MODIFY_LDT_SYSCALL. So guarding the member by the > same config option is a cheap way to reduce sizeof(mm_struct) by 32 > bytes (only for !CONFIG_MODIFY_LDT_SYSCALL kernels, of course). Ping