From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CF5B9C433F5 for ; Wed, 23 Feb 2022 13:12:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=zzIyfFabnMt27mBe5Txu86US2CUmXA4JSwmRnpQ5bcQ=; b=FETCj8z7dSeFBB f9D5XWRv/64t0QexZaeMxrYnHLZYz6Zz/gqowyjeBoi3mQVH1jOp9QzNafcyyomw2752V5P9gqV+p b2Rg9cfuRXgo2umouLhSgc+Eh/5YffJ6D+V1z+0YLHKFJtdnGGDAcMIaqtZxRiirgRVFlA9vFVinV 6Upr2xpf0WCN5qtN0tnQN9Qbk31AN0mFCz9Av65f8Is/HGdT+BeiGwMtnOtL9FTQMz6C3AyqK80yl qkpejWUJTbhF14tNhqTYkiMc8Zh6m8yPUdTCG1AkAQFItIkQ9AcmP2nUutHxOB/utYkmfTVJNre8j ESj2Mlal6SVnReWGmi6A==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nMrPi-00ENVG-IH; Wed, 23 Feb 2022 13:10:38 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nMrGX-00EKCl-9Z for linux-arm-kernel@lists.infradead.org; Wed, 23 Feb 2022 13:01:11 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id A0B34ED1; Wed, 23 Feb 2022 05:01:06 -0800 (PST) Received: from lpieralisi (e121166-lin.cambridge.arm.com [10.1.196.255]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id BF2AE3F70D; Wed, 23 Feb 2022 05:01:04 -0800 (PST) Date: Wed, 23 Feb 2022 13:00:59 +0000 From: Lorenzo Pieralisi To: Francesco Dolcini Cc: Richard Zhu , Lucas Stach , Rob Herring , Krzysztof =?utf-8?Q?Wilczy=C5=84ski?= , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Jason Liu , linux-pci@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Bjorn Helgaas , Shawn Guo Subject: Re: [PATCH v1] PCI: imx6: Handle the abort from user-space Message-ID: <20220223130059.GA28032@lpieralisi> References: <20220131075235.787432-1-francesco.dolcini@toradex.com> <20220210080050.GA7275@francesco-nb.int.toradex.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20220210080050.GA7275@francesco-nb.int.toradex.com> User-Agent: Mutt/1.9.4 (2018-02-28) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220223_050109_423628_4AA4EFC9 X-CRM114-Status: GOOD ( 20.37 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Feb 10, 2022 at 09:00:50AM +0100, Francesco Dolcini wrote: > Hello Lorenzo, > just a gently ping on this patch. > > Francesco > > On Mon, Jan 31, 2022 at 08:52:35AM +0100, Francesco Dolcini wrote: > > From: Jason Liu > > > > The driver install one hook to handle the external abort, but issue > > is that if the abort introduced from user space code, the following > > code unsigned long instr = *(unsigned long *)pc; which will created > > another data-abort(page domain fault) if CONFIG_CPU_SW_DOMAIN_PAN. > > > > The patch does not intent to use copy_from_user and then do the hack > > due to the security consideration. In fact, we can just return and > > report the external abort to user-space. Apologies for the delay in replying. This commit log should be rewritten - it is not clear. Isn't this an issue for all PCI host controllers that install a fault hook ? Is this referring to accessing config space directly from user space ? Can you explain the triggering conditions a bit better please ? Thanks, Lorenzo > > Link: https://lore.kernel.org/all/20220128082920.591115-1-francesco.dolcini@toradex.com > > Signed-off-by: Jason Liu > > Reviewed-by: Richard Zhu > > Signed-off-by: Francesco Dolcini > > Acked-by: Lucas Stach _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel