Received: by 2002:a05:7412:b995:b0:f9:9502:5bb8 with SMTP id it21csp7236884rdb; Wed, 3 Jan 2024 08:52:49 -0800 (PST) X-Google-Smtp-Source: AGHT+IHNbxevELfFZc/pvMzuPe896mbMgcC0mk8XCcn5n/qPriyJdKfdLwHz60/gD/7if4+ghrya X-Received: by 2002:a05:6358:2491:b0:174:ea03:3a75 with SMTP id m17-20020a056358249100b00174ea033a75mr21266855rwc.34.1704300769703; Wed, 03 Jan 2024 08:52:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1704300769; cv=none; d=google.com; s=arc-20160816; b=rDV3HCUkUpX9vHjuwr8vvqO5NT/pexrD0mvbnXS1H1IwyYU9kjLQI0fL0zqJYqPzt6 pIEnlFgz4AiDat3lK5ozRJDA477WpR2VBuuUHwysOz/bjdCz5F8mxuCucei1GR1GLzgv ZnQd+cMtEPy8LbhLqPb+J+3rtKojYYp2NX7ARRRcwaYiFR8qQLzywW4SfXxp2dDDlsz5 H3GGZow7mzg+vAzE3ZhNvP3hkJ0GJvSy1KJ5vUQhou55HCo6LLINabN9cJJVh3g0hi1v L5QBSnwrwZ+TPJyCaRxtSC7U4nIMSWKcQtNUD6EZaHkyzhR/A7V5Jis/Af/E8cKD1tsB kaHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:list-unsubscribe:list-subscribe :list-id:precedence:dkim-signature; bh=g8qj9LLTaa3LyoC7NJsfeCbrmfVY1SENx7bd1fNAz/o=; fh=zrF+tQIpofuFi4Gcfhk9zOuNzl1KgjgSH2KOkZqrTo4=; b=NIDvTD0eVqkItlEkp4wXOKYbmjdTCG28f/lK27BUfO+i9LCT8KapV17ZbAyZ22fDOX YMc+Ipmg037zjRZcU4Dwo/HW+a8I6jIKuHycTC3ghFq6MN74q2Gw4aYisHwtgm1whiFn COYsqFIZnbs7tnPnNqfHcOyWaZoZAxXoeJklj9y63xqeeReVyA6+k872zJi9ruvyiKGZ +PP+RGmyAGTrwu3ZQG/ynkTBkGnobv52o6PslMf3tR8ZzpBUEJhaqbl46D8WIr9lAkrq ZblG5pjyAt09kbLTWXQCCsApY/WC8+eWkBGwiJkltQv5ldbXujzD++6Ybx0H/Sk4sRlt aH2g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=B26drKpT; spf=pass (google.com: domain of linux-kernel+bounces-15773-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-15773-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id bs128-20020a632886000000b005cdbeb8228dsi21281370pgb.433.2024.01.03.08.52.49 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Jan 2024 08:52:49 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-15773-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20230601 header.b=B26drKpT; spf=pass (google.com: domain of linux-kernel+bounces-15773-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-15773-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 233B8B23B8B for ; Wed, 3 Jan 2024 16:51:20 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id A2B121C6A3; Wed, 3 Jan 2024 16:50:38 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="B26drKpT" X-Original-To: linux-kernel@vger.kernel.org Received: from mail-wr1-f49.google.com (mail-wr1-f49.google.com [209.85.221.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 6B5721C68E for ; Wed, 3 Jan 2024 16:50:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=google.com Received: by mail-wr1-f49.google.com with SMTP id ffacd0b85a97d-3366ddd1eddso10278279f8f.0 for ; Wed, 03 Jan 2024 08:50:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1704300634; x=1704905434; darn=vger.kernel.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=g8qj9LLTaa3LyoC7NJsfeCbrmfVY1SENx7bd1fNAz/o=; b=B26drKpTpsehMjGux6bg03PkS4t+xfLRMpnaYfE56XW9DdcRiOFRsCbyqu6FUMtzSE ko6QsVtfoc4rBjwn8tDxe1hl4cY9s8lUZFIjVZZAcTqBsd6gnTgGuZhhm9s0TjoS8lap 9GejGrNZtAXWV149D5uzio42RduVyeEgFkI6uxYS7OTyg0wjW/f+I8y41dl9c89IpYoF /6PgyLPVy4M2uWDmwyX65O2xZsqr2EA3neBWbiKBfUoF//1+cHV3UoOu0PdstOvzCq31 qNOO9iLVd485ohzzhS9maLKJ2PjldQZRyIbLR4XAT8ErD7OxDbXfXd4xzDsLDY61XM1T 6UqQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1704300634; x=1704905434; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=g8qj9LLTaa3LyoC7NJsfeCbrmfVY1SENx7bd1fNAz/o=; b=dg4RifUzZGJBp8FQxqXnKAUb7/fMynuMvTOjPjPyQYQy1yIj7zW8jyPyl1hb0gp3VE w0t3Eb9AfHagWdYg3UEcXFYuSE0+73cJLBfM17GjGNPRgw4SEZ4S4DIrxzsYuA7bS0e1 domBcT2fPe044BAO2FdcRVj1AjvHEoMfcxq82yZiTt7SqvuOFJtWCKBMlt0NDlgYUKw7 PfnWBXmBwd7prsqrIkSLkA9cgZq/cRAJ1o7F4t+nRjkqU0NHUaNlBm3Wt4T/mEDZkNMM 5u48kq1pCtzNiZCn247vvaTzHctD0dE0nJPWQsPmLueCM8d8IANBdBUUwm1dI54KDEpp kj9Q== X-Gm-Message-State: AOJu0YxoSvcv8Qx5/w6fNO3IjUJQfQ3ZAfMmo0XGlvi+z4JOHlj48Vdd nPCEWJGerDk1Kxmh4Ofj7pOqlwT+z1hx73eE2VQju8/sfmCP X-Received: by 2002:adf:ef05:0:b0:336:5493:c8fa with SMTP id e5-20020adfef05000000b003365493c8famr5056173wro.60.1704300634270; Wed, 03 Jan 2024 08:50:34 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20231227-syscall32-v1-1-9621140d33bd@google.com> <20231227233444.GH1674809@ZenIV> <20231228004550.GJ1674809@ZenIV> In-Reply-To: <20231228004550.GJ1674809@ZenIV> From: Nick Desaulniers Date: Wed, 3 Jan 2024 08:50:19 -0800 Message-ID: Subject: Re: [PATCH] x86/syscalls: shrink entry/syscall_32.i via IWYU To: Al Viro Cc: Tanzir Hasan , Andy Lutomirski , Thomas Gleixner , Ingo Molnar , Borislav Petkov , Dave Hansen , x86@kernel.org, "H. Peter Anvin" , linux-kernel@vger.kernel.org, Nick Desaulniers Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable On Wed, Dec 27, 2023 at 4:45=E2=80=AFPM Al Viro w= rote: > > On Wed, Dec 27, 2023 at 11:34:44PM +0000, Al Viro wrote: > > > That's _it_. The same goes for syscall_64.c and syscall_x32.c. > > Oh, and lose the __visible/asmlinkage junk in there - none of that > > stuff is used from asm these days. See the patch below - > > Untested But Should Work(tm): > > Unfortunately, there's this in kernel/trace/trace_syscalls.c: > > unsigned long __init __weak arch_syscall_addr(int nr) > { > return (unsigned long)sys_call_table[nr]; > } > > How is that supposed to work for anything biarch? Including > amd64 with CONFIG_COMPAT enabled? commit f431b634f24d ("tracing/syscalls: Allow archs to ignore tracing compat syscalls") added a comment block about ARCH_TRACE_IGNORE_COMPAT_SYSCALLS, which is defined for x86 in arch/x86/include/asm/ftrace.h. The implementation of arch_syscall_addr for mips is quite complex; dependent on quite a few different configs. --=20 Thanks, ~Nick Desaulniers