Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp1010652imj; Thu, 7 Feb 2019 15:56:22 -0800 (PST) X-Google-Smtp-Source: AHgI3Ib6pXyH0/NpMYjTQ5Kh1OTizqyM28u6w7HG7Dee02DRzVv16P9ZA/QiK6aYT0WI0BKl5XVS X-Received: by 2002:aa7:8101:: with SMTP id b1mr12464602pfi.148.1549583782302; Thu, 07 Feb 2019 15:56:22 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549583782; cv=none; d=google.com; s=arc-20160816; b=qq85N2JNLa++AYTPuWvbrBvlqKZu9KxxNhzboSyMLdetypNBG5yuhNnyk95zS54ayZ mFs1dGoS3gXTfCAZlPOtLKSa3FJYuougM2FoIxdRETgPqkns/Bm2nSJXxYZSuuH9KiU2 5TRSDDQnXh6v6tSfnMvw4vASZIBAlCqgmUenMsaVMeaCQsDPCg7sRBFz+pcuMm64nH3H sxtDHdNSQixoqFmXJfzQx3r29JoJy0iACSbZj41rIgqMrxbPG4Ti4bQGKYJR2FO3bJjt osyOt2NURDNREMp8+WY+P1Zx8WPmMUaC3itwJQZIiICdVfnw0JO45a1biX7crRMOr89I sMJA== 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:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=QMradZ8y8bj4nP1jg/AeFwYhEQ1GVuc8QuX5QQgsHpc=; b=fhpEhrBeSB6k+enIQ+6y5U5c77dYhGUa6719VLsLDuHtHymJrx0oU6YOb1AUZmLzSG r32bxr+VtWGxlG5f+VMF028t6lNC5BRfYtujBh6snn9rnbnLTOxOZAK1am5S5a4ln/TL +zp8hQ6hUwCxO8WnQcWpZa8AB1vdddBTY7qIt5jVfkpfO9+yjU2mVT2BsDTzqGg9zpAa 3fhaBkuULSujiIURrmVZv4ZB3MfrsXtnJ/xXOpqeVQmjyWn46cTbtgEwMnlU3B8ic+uO F1oI+72UY5E4OjKLMUVG5qH/Zb1qb+V9wQGsDrcWQTDIECCJp+PJUqh1DpRo5RvCOfZ/ wt+g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=nduG4CPS; 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=chromium.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e17si395000pgv.452.2019.02.07.15.56.06; Thu, 07 Feb 2019 15:56:22 -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=@chromium.org header.s=google header.b=nduG4CPS; 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=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726844AbfBGXzu (ORCPT + 99 others); Thu, 7 Feb 2019 18:55:50 -0500 Received: from mail-it1-f194.google.com ([209.85.166.194]:36492 "EHLO mail-it1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726650AbfBGXzu (ORCPT ); Thu, 7 Feb 2019 18:55:50 -0500 Received: by mail-it1-f194.google.com with SMTP id c9so4709147itj.1 for ; Thu, 07 Feb 2019 15:55:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=QMradZ8y8bj4nP1jg/AeFwYhEQ1GVuc8QuX5QQgsHpc=; b=nduG4CPS5kfR2KxTCsaUmPZ8azuN/6/pOvCpH5S96naFwJed4RZa6P7N4ns9Q93SRe sqFDMqp54k3wdIe3n47Z1awOej9wyUGobIqgrAOtorM8onUXpHaEnDiuEQ3GAInVPXsG xE2wnuyw6xYZKc9YfBzizRTfwjbvoBZX2ay3w= 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:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=QMradZ8y8bj4nP1jg/AeFwYhEQ1GVuc8QuX5QQgsHpc=; b=SWycnCNm+u3YOoVUthCe3498vqzWneh4bijSkuw39d9BoYh2Rk0AYZfni9xwKJeqpw tr3FePE4ovJW+b9o3kZO1xgBsDbpUBWeYT8TDhXW3bDCAnjfJUZg4i5L19eCENt7vwOZ OZ07ijxvldUiy0NUZjJ5gXw17A0y8l246Xj4nttTyIM4Ig092AX3TRPMrC+uA6g88JQo 5pvcN4y8tUsFgizkFlWiLnTKeClBe/rovxfgl/xTxaRJPKwyipJ8hTIc+WjOyAWzMqIT 8mVD816rTKZc0Qa5aZXJb2pnVJ9jldlvJ52Lj6veD+5LmNM+1qNXz0YRfoy6UgFsvzb6 0c9Q== X-Gm-Message-State: AHQUAuaxKqXDMiZ3ok9CQOIv1CXZQxz//tAP1Q+GqWsZqlZM6TdhixVw I01afC+yY8hi/sejmZ7KTYb0cuXXrb0= X-Received: by 2002:a05:660c:4c5:: with SMTP id v5mr2823860itk.104.1549583749019; Thu, 07 Feb 2019 15:55:49 -0800 (PST) Received: from mail-it1-f181.google.com (mail-it1-f181.google.com. [209.85.166.181]) by smtp.gmail.com with ESMTPSA id q5sm218921ioh.22.2019.02.07.15.55.47 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 07 Feb 2019 15:55:47 -0800 (PST) Received: by mail-it1-f181.google.com with SMTP id c9so4708982itj.1 for ; Thu, 07 Feb 2019 15:55:47 -0800 (PST) X-Received: by 2002:a5e:a60f:: with SMTP id q15mr5385992ioi.140.1549583746746; Thu, 07 Feb 2019 15:55:46 -0800 (PST) MIME-Version: 1.0 References: <20190131192533.34130-1-thgarnie@chromium.org> <20190131192533.34130-3-thgarnie@chromium.org> <20190207121729.GE2414@zn.tnic> <20190207171145.GH2414@zn.tnic> In-Reply-To: <20190207171145.GH2414@zn.tnic> From: Thomas Garnier Date: Thu, 7 Feb 2019 15:55:35 -0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v6 02/27] x86: Use symbol name in jump table for PIE support To: Borislav Petkov Cc: Kernel Hardening , Kristen Carlson Accardi , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , "the arch/x86 maintainers" , "Peter Zijlstra (Intel)" , Ard Biesheuvel , Nadav Amit , Masahiro Yamada , LKML Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Feb 7, 2019 at 9:11 AM Borislav Petkov wrote: > > On Thu, Feb 07, 2019 at 09:04:45AM -0800, Thomas Garnier wrote: > > I assume that's an optimisation done by gcc later. > > So why is that change even needed? Where does it break? > > > The P modifier in the documentation does state that it is used to > > generate PIC code. > > The documentation says: > > "If used for a function, print the PLT suffix and generate PIC code. For > example, emit foo@PLT instead of =E2=80=99foo=E2=80=99 for the function f= oo()." > > when you use %P for a function. Which is not how it is used here. I did more checks about that. I think Ard's patch to make jump label relative actually fixed the issue I had with them. Thanks for spotting this, I will do additional checks and look at removing this change. > > -- > Regards/Gruss, > Boris. > > Good mailing practices for 400: avoid top-posting and trim the reply.