Received: by 2002:a05:7412:bbc7:b0:fc:a2b0:25d7 with SMTP id kh7csp1015508rdb; Fri, 2 Feb 2024 10:40:46 -0800 (PST) X-Google-Smtp-Source: AGHT+IFKwtyd1jPEsix1KGEXLvcb2sGVbixwu5YINSEl5uFXzvHARCgLkeq03e/KkBihqV/R/3N2 X-Received: by 2002:a17:90b:94e:b0:296:40cb:8d41 with SMTP id dw14-20020a17090b094e00b0029640cb8d41mr2401875pjb.7.1706899245879; Fri, 02 Feb 2024 10:40:45 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706899245; cv=pass; d=google.com; s=arc-20160816; b=OhXkNqlscndGjFi3xLoW2nCFcXAN+uAnnYcsq9CSzgE06hW0t6xf6vCqrwxJa/Ricz sRLoQJW85iqeVmk9LnfWk4Ez3ZLp46n7jdROoJaBeN7OuQ7hS/zlHsQWAJkuf+3xc5/y iAkA/XqZMo+VFyoYfbMmzxXRaHm2aAWT6TEwr9e9VSQ/H0ljXEX7+olmqvD81EAJceo8 FG8kBqOuV3lyN1tdR+naIvDMst9jnBZJYulDF0mzDIO2ECoRCyG7lNhIRyeNFIjsycnU oqMrdLZjSc8Hq4cpYPXYYMJlCxZczCvZjdFtt0q/ZYVBB/b7gcrwvSH3Twam38arte6c cUxg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :dkim-signature; bh=EK/oD0i1K4QS8LEPg1LGpWmJwJIYuOve/SpbccIVK8M=; fh=RgnBDkJ9ZoXUkWbx+Opq3avW+jjo8jrL7zaa32lnpaA=; b=G217+Va0eCCJPLP5k7okWtfSPTNoWx5zOD75DYBc46gmQvcYNp1Ks8H8oTnao7bnw9 BpotpOUrRE0PR9kJE9Qwj4rUPOs5bANtj++DgkrKJWx0JtYZH/KM7Rm1S84sk5b+TNze KIQmcybef+gXD8Lcc5sjwBFwxtTOTBmLW+euNh5eanaEU9/1T1EivstV95HkPqQbNbSk fFHTKGr5bWoO/AV+kRCOt+40pm39BcpEBI/Mi/TcBdAWkkXH3A2Tzld60lp86EsF/Yhl 7sRPjFvNtclfq5pppI61GcwBDZRCrI3+kQ3NMwm3aWjW9a1of68OcHf8IPr3ZUriJtt2 IcEQ==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b=IHeB54CF; arc=pass (i=1 spf=pass spfdomain=linuxfoundation.org dkim=pass dkdomain=linux-foundation.org); spf=pass (google.com: domain of linux-kernel+bounces-50348-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-50348-linux.lists.archive=gmail.com@vger.kernel.org" X-Forwarded-Encrypted: i=1; AJvYcCU0cXwtPMcrvK561MELkkhjS6gB/utK0JnnZqZA4s1uTrsuOSh2+iwb9TNgvLWqEPtw7FvKInBGVlvR/KzFlsaJOdS+HxOpe9eqmwOk6g== Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id ls13-20020a17090b350d00b00290cd7ee938si335817pjb.38.2024.02.02.10.40.45 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 02 Feb 2024 10:40:45 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-50348-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=google header.b=IHeB54CF; arc=pass (i=1 spf=pass spfdomain=linuxfoundation.org dkim=pass dkdomain=linux-foundation.org); spf=pass (google.com: domain of linux-kernel+bounces-50348-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-50348-linux.lists.archive=gmail.com@vger.kernel.org" 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 sv.mirrors.kernel.org (Postfix) with ESMTPS id 8812228115D for ; Fri, 2 Feb 2024 18:40:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0C0F0152E01; Fri, 2 Feb 2024 18:39:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b="IHeB54CF" Received: from mail-lf1-f45.google.com (mail-lf1-f45.google.com [209.85.167.45]) (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 1C4B7152DF3 for ; Fri, 2 Feb 2024 18:39:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.45 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706899175; cv=none; b=JUu4Ex25vTDmNsA9wILQ63nDamvbpTjD9hSCK4olHEOvFGdrGdB2rVgw7c5SH72xXGxXq3OLcdnzt+PFnW53f4I8tUpWXCnI4ItL/QLY5mtC4Yg1DuLIkJbEqMkD6oS2V8Fu6NsU4dyzjaPmch67lpNHpkb5e9Dof4jR6clB898= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706899175; c=relaxed/simple; bh=6vtu3x2Y1jccAeEZW/cOuVCyNA6GUN7mxte5g1lUOrk=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=MLKrwcO7RXxdyQ6nl+Ao7jQIAb54EIaFtuDiNLirkAu1kK8j2DcnTK7uUloz2lPNMAfHh1E6c9zulODxke/yWaxv1lIHi/mchunFj4BZIONeK0g2fc8Vb5fBj1dfQNhS4zpTrg8CtIri0n4yJVxoiDt6i472FaZy+OSNu77HXa0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org; spf=pass smtp.mailfrom=linuxfoundation.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b=IHeB54CF; arc=none smtp.client-ip=209.85.167.45 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=linux-foundation.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linuxfoundation.org Received: by mail-lf1-f45.google.com with SMTP id 2adb3069b0e04-50eac018059so2971130e87.0 for ; Fri, 02 Feb 2024 10:39:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux-foundation.org; s=google; t=1706899171; x=1707503971; darn=vger.kernel.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=EK/oD0i1K4QS8LEPg1LGpWmJwJIYuOve/SpbccIVK8M=; b=IHeB54CFUk2Pu6lD2GAj8loMeIw5OHB3CUVpXRt/zRmhwMpktRKIlzjd0TGGAQWQCQ Lys1/NvYHNrxHr/aZc2m9O3yaQERM66FEpZEHbGHLGv08Q+OTc1a3JnBUak8NXPz8o2O EhC2n2Bt+Kf0bkekEtuOGGOMSb0/k+M0stkGc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1706899171; x=1707503971; h=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=EK/oD0i1K4QS8LEPg1LGpWmJwJIYuOve/SpbccIVK8M=; b=PuZPu2H8nO/AcPaT0NErDrkgJczOKCbTc06ya+6J5JaLiVNaC6W5c3vp8MXeNrO+YT om15WGvZnZVR4M9WPCHCS5/J1V1oYPhXG5THhPxdkWXjTWZ+Bi3N+QPc6CH4Q0I4NDSg BSrF78YC+HJcSeN7Ushsc3qtHs8yOB7tw/lw27nQ3bdL2OMyITfVjKlQ3P/0zQIrvq// cKUP7y3CIeu4vzhinJ71t7XkJeEAM8qVfyIfn8AQem5wddfobrYuh3R1O3129ViAtsro bQ2O0BPUvWiUnZNwg7vFjfRI7Kht8QR5iUcd4xWeoR/hFN5yxya3u/29Lam8RFfCOd18 IZlQ== X-Gm-Message-State: AOJu0Yx7/lnFuB7uHLZ3I2vnxtZnoLaIDTPMoHOh23EZRvqO2wMJcx6O XJtnk6ufXw9kyCMLLiGDoGuD+w4gJxxCavvZjlwZXzHZSYiNBFHaGY2jFpJ8P8kyaY47d5h+DIo GHObDmg== X-Received: by 2002:ac2:562f:0:b0:511:1ed7:61b9 with SMTP id b15-20020ac2562f000000b005111ed761b9mr1861797lff.39.1706899170774; Fri, 02 Feb 2024 10:39:30 -0800 (PST) X-Forwarded-Encrypted: i=0; AJvYcCXPXntYQMr8umIjPTygZH1M4yVhzpd23xnwEJXrruV0ncs9ypiNg+4IxTwxvySETchukT+OUJJnwHrDwWRMXQkWwQ5go9706VHg4XXJ Received: from mail-lj1-f181.google.com (mail-lj1-f181.google.com. [209.85.208.181]) by smtp.gmail.com with ESMTPSA id dw12-20020a0565122c8c00b005113dfe177asm62646lfb.304.2024.02.02.10.39.30 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 02 Feb 2024 10:39:30 -0800 (PST) Received: by mail-lj1-f181.google.com with SMTP id 38308e7fff4ca-2d07ffa0a9cso15353791fa.2 for ; Fri, 02 Feb 2024 10:39:30 -0800 (PST) X-Received: by 2002:a2e:8882:0:b0:2d0:8225:919d with SMTP id k2-20020a2e8882000000b002d08225919dmr1794857lji.21.1706899169784; Fri, 02 Feb 2024 10:39:29 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20240202-exception_ip-v2-0-e6894d5ce705@flygoat.com> In-Reply-To: <20240202-exception_ip-v2-0-e6894d5ce705@flygoat.com> From: Linus Torvalds Date: Fri, 2 Feb 2024 10:39:13 -0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v2 0/3] Handle delay slot for extable lookup To: Jiaxun Yang Cc: Oleg Nesterov , Thomas Bogendoerfer , Andrew Morton , Ben Hutchings , linux-arch@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mips@vger.kernel.org, linux-mm@kvack.org, Xi Ruoyao Content-Type: text/plain; charset="UTF-8" On Fri, 2 Feb 2024 at 04:30, Jiaxun Yang wrote: > > ptrace: Introduce exception_ip arch hook > MIPS: Clear Cause.BD in instruction_pointer_set > mm/memory: Use exception ip to search exception tables Just to clarify: does that second patch fix the problem that __isa_exception_epc() does a __get_user()? Because that mm/memory.c use of "exception_ip()" most definitely cannot take a page fault. So if MIPS cannot do that whole exception IP thing without potentially touching user space, I do worry that we might just have to add a #ifndef __MIPS__ around this all. Possibly somehow limited to just the microMIPS/MIPS16e case in Kconfig instead? Linus