From patchwork Tue Jan 9 19:30:37 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "H.J. Lu" X-Patchwork-Id: 1884611 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20230601 header.b=DpfHzHoF; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=sourceware.org (client-ip=8.43.85.97; helo=server2.sourceware.org; envelope-from=libc-alpha-bounces+incoming=patchwork.ozlabs.org@sourceware.org; receiver=patchwork.ozlabs.org) Received: from server2.sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4T8gyj6TMvz1yPj for ; Wed, 10 Jan 2024 06:31:09 +1100 (AEDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 83524385C301 for ; Tue, 9 Jan 2024 19:31:07 +0000 (GMT) X-Original-To: libc-alpha@sourceware.org Delivered-To: libc-alpha@sourceware.org Received: from mail-pl1-x633.google.com (mail-pl1-x633.google.com [IPv6:2607:f8b0:4864:20::633]) by sourceware.org (Postfix) with ESMTPS id 7B6F03858407 for ; Tue, 9 Jan 2024 19:30:44 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 7B6F03858407 Authentication-Results: sourceware.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=gmail.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 7B6F03858407 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=2607:f8b0:4864:20::633 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1704828648; cv=none; b=ni/u/7uaEt3lqTbTLy4LFJ7MlQX3M7UHaE/Hj5cC0iNQxyYtSMO91EM97jgzCnfn+ouPVxfE3v8eOhnEEG6hOJGPEYwoOdkMDZYVDMgTO4nMsiMkt3i3fX+mp27Kk2jhae4wk3/7l/Dn4JJvBlYs+b9PTa7V3OEyTEsEROMTzrg= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1704828648; c=relaxed/simple; bh=+4iYUKq5m7KXskztuGR0MZVfAmi8lOx+C5HZFlAG9XI=; h=DKIM-Signature:From:To:Subject:Date:Message-ID:MIME-Version; b=Y1MhUdPBAnuFNYtvtO1Y7jKA2RaAvyYzUnaRRxIbar7XvSvEQm3gdbEhISxjdKXxuZ0tLe4zndooJlpk/c3UMW1MBY2i5hDvCyHOBbaHSyfjypXZAAmlhSyplEl1Q+PZvC7m7Gk3PulpLcXhBae+phpARFTLgiYh833FjpNrF/k= ARC-Authentication-Results: i=1; server2.sourceware.org Received: by mail-pl1-x633.google.com with SMTP id d9443c01a7336-1d3e2972f65so12001545ad.3 for ; Tue, 09 Jan 2024 11:30:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1704828643; x=1705433443; darn=sourceware.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=3Z413Jm7ih4ErG0hs66T4tfTSPLi01Jsx0Dh8cBTBp4=; b=DpfHzHoFRenHYLQN0Av2Rp+/2NvJEpR+8qyQi+3g3RnjODgAVmP/R4bxNY19PuXrp7 /NB+TT8qlGiGXk8IRzF/UL9Vb6xIC+TgL6oXM4jZfrhTK2WBD/lD565oqvREuuteID/6 maJw0IUkcvC12bU/xYy7hSp+N5n0Wz4YMgBl+FwBf3z33fAwOJ1vjQGeJ3IktjyKDBwN KYvWtuEkX0wY29OtFIQPhJuvJoqq42BP6aUZnUeE6Rh/2TJDzcuKqtakRhcIN6SuJBEY eqMFkwivoEbEdPIQi7F7nWaoPjwIHVG9T70vzfz0877K9ck3zdN9trYPgcnUSFf2/n10 e/Lw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704828643; x=1705433443; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=3Z413Jm7ih4ErG0hs66T4tfTSPLi01Jsx0Dh8cBTBp4=; b=Pr0U6TjnkPUUe1ZukSfpf4M9XtMFNA+8GM6CJcoaApy6rZkpQj6ojdyZISpeRIu6C2 Zpgu55aEpRybTp3uFgYFQe6wcUaGt+jLigd/aFuq7xabr5pm+W1D1V6SA1QTzzIQR7Y7 28rOfVFgtwBJHU04qIfWNj+iHR926FvrANqcE39DSyRDIclHvt0arqn+1fDF9N7RZ0AQ UUrblffKDQ0LzJ6nODSFJPk9AB8Q8HHiqXYLopLhasmaFEa9d3fj3z7i54/ZwgOwa1ij HobIDXXdqtCR1qf9O5d+b1I15zoWmjPk7VR4NuSUNIkU6H42QaHD87C/FRMwuXkwGRII hT6g== X-Gm-Message-State: AOJu0YzUvMKyU6HbE9eTvTvInn2KcXoEnUdg2u1c+kOpNgLXB7F5s/No Is71vAo1zaz9rgvHQ9HBJ9dhp0ILTGU= X-Google-Smtp-Source: AGHT+IHhUHEv+6G9XliAHYdSoEfHI7cI8US+sWDaH0tYFtEjNsmP1XHQnyTfiYf3NK/xJfq7JKLy5Q== X-Received: by 2002:a17:902:d2cb:b0:1d4:7e51:ff6c with SMTP id n11-20020a170902d2cb00b001d47e51ff6cmr3924798plc.121.1704828643429; Tue, 09 Jan 2024 11:30:43 -0800 (PST) Received: from gnu-cfl-3.localdomain ([172.56.169.119]) by smtp.gmail.com with ESMTPSA id jb11-20020a170903258b00b001d4752f540esm2157606plb.198.2024.01.09.11.30.43 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Jan 2024 11:30:43 -0800 (PST) Received: from gnu-cfl-3.. (localhost [IPv6:::1]) by gnu-cfl-3.localdomain (Postfix) with ESMTP id F1D87740139; Tue, 9 Jan 2024 11:30:41 -0800 (PST) From: "H.J. Lu" To: libc-alpha@sourceware.org Cc: adhemerval.zanella@linaro.org, goldstein.w.n@gmail.com Subject: [PATCH 0/4] i386: Remove remaining CET bits Date: Tue, 9 Jan 2024 11:30:37 -0800 Message-ID: <20240109193041.3987157-1-hjl.tools@gmail.com> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 X-Spam-Status: No, score=-3018.3 required=5.0 tests=BAYES_00, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, DKIM_VALID_EF, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, SPF_HELO_NONE, SPF_PASS, TXREP, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org X-BeenThere: libc-alpha@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Libc-alpha mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libc-alpha-bounces+incoming=patchwork.ozlabs.org@sourceware.org 1. Add sysdeps/i386/libc-start.h and move x86-64 shadow stack startup codes to sysdeps/x86_64/libc-start.h. 2. Move dl-cet.[ch] to x86_64 directories. 3. Move check-cet.awk to x86_64. 4. i386: Remove CET support bits. H.J. Lu (4): x86: Move x86-64 shadow stack startup codes x86-64/cet: Move dl-cet.[ch] to x86_64 directories x86-64/cet: Move check-cet.awk to x86_64 i386: Remove CET support bits sysdeps/i386/dl-machine.h | 11 +-- sysdeps/i386/dl-trampoline.S | 69 ------------------- sysdeps/i386/libc-start.h | 25 +++++++ sysdeps/unix/sysv/linux/x86/dl-cet.h | 63 ----------------- sysdeps/unix/sysv/linux/x86_64/dl-cet.h | 49 ++++++++++++- sysdeps/x86/cpu-features-offsets.sym | 2 - sysdeps/x86/cpu-features.c | 4 +- sysdeps/x86/ldsodefs.h | 1 - sysdeps/x86_64/Makefile | 4 +- sysdeps/{x86 => x86_64}/check-cet.awk | 0 sysdeps/{x86 => x86_64}/dl-cet.c | 0 sysdeps/{x86 => x86_64}/dl-procruntime.c | 2 +- sysdeps/x86_64/dl-trampoline.S | 1 + .../feature-control.h} | 0 sysdeps/x86_64/features-offsets.sym | 6 ++ sysdeps/x86_64/ldsodefs.h | 26 +++++++ sysdeps/{x86 => x86_64}/libc-start.h | 2 +- 17 files changed, 114 insertions(+), 151 deletions(-) create mode 100644 sysdeps/i386/libc-start.h delete mode 100644 sysdeps/unix/sysv/linux/x86/dl-cet.h rename sysdeps/{x86 => x86_64}/check-cet.awk (100%) rename sysdeps/{x86 => x86_64}/dl-cet.c (100%) rename sysdeps/{x86 => x86_64}/dl-procruntime.c (97%) rename sysdeps/{x86/cet-control.h => x86_64/feature-control.h} (100%) create mode 100644 sysdeps/x86_64/features-offsets.sym create mode 100644 sysdeps/x86_64/ldsodefs.h rename sysdeps/{x86 => x86_64}/libc-start.h (98%)