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 X-Spam-Level: X-Spam-Status: No, score=-2.5 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_PASS, USER_AGENT_MUTT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E3A53C43381 for ; Thu, 28 Mar 2019 11:32:31 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 9D1B92075E for ; Thu, 28 Mar 2019 11:32:31 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="gmosCTbN" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9D1B92075E Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=arm.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject: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=ajp+NkgHcW8Cq3XQZzfXHpYhitM/n2AM6oI+dXCHayQ=; b=gmosCTbNIWEgyu pqCow14fXxAEkZP0wYinJbQuvsx5VTVI0g7H9oWAU55lcDPjelwPo23ckgNrQhuaBVm9flH5Ki8ul ZsInqSNg946IR3sKHSH5L4DmaXtzciVBScUgzuaz96NDos5n25rCSu0qzjan3FggZe+0zaw9rjRnZ I50EC636w2aodFLV72NYCNQqQ6vt2tRyzQM16t6/uWW4N9JsN/Ebvuc6LJwBMbeI0fvgB5sNMGO0b 92SLdpeKpzSnZ4AEgs4qEE/qnkCvHs6o+fymW7ozNN+SdJ+/u/XlmF8fB/7Q8mLT5khSjxnNyQ9uR vmd/FkDguQkFiskZfINA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1h9TGk-0005yV-OC; Thu, 28 Mar 2019 11:32:26 +0000 Received: from usa-sjc-mx-foss1.foss.arm.com ([217.140.101.70] helo=foss.arm.com) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1h9TGU-0005gV-OD for linux-arm-kernel@lists.infradead.org; Thu, 28 Mar 2019 11:32:12 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 4F5EF15AB; Thu, 28 Mar 2019 04:32:09 -0700 (PDT) Received: from red-moon (red-moon.cambridge.arm.com [10.1.197.39]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id EC4B03F59C; Thu, 28 Mar 2019 04:32:07 -0700 (PDT) Date: Thu, 28 Mar 2019 11:32:38 +0000 From: Lorenzo Pieralisi To: Kefeng Wang Subject: Re: [PATCH 1/2] ACPI/IORT: set online numa node for smmuv3 device Message-ID: <20190328113230.GA19628@red-moon> References: <20190315021940.86905-1-wangkefeng.wang@huawei.com> <20190315021940.86905-2-wangkefeng.wang@huawei.com> <20190320140016.GA8694@e107981-ln.cambridge.arm.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190328_043210_787523_C3973A5D X-CRM114-Status: GOOD ( 17.51 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: rjw@rjwysocki.net, linux-acpi@vger.kernel.org, Hanjun Guo , Sudeep Holla , Robin Murphy , linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Mar 21, 2019 at 02:08:47PM +0800, Kefeng Wang wrote: > = > On 2019/3/20 22:00, Lorenzo Pieralisi wrote: > > On Wed, Mar 20, 2019 at 11:41:18AM +0000, Robin Murphy wrote: > >> On 15/03/2019 02:19, Kefeng Wang wrote: > >>> If there is only node 0 in system, but smmuv3 device is set to offline > >>> node 1, parsed from proximity domain in SMMUv3 IORT table, it will le= ad > >>> to following crash, > >> Surely that's just a firmware bug? If node 1 doesn't exist in the syst= em > >> then AFAICS if we're presented with a device claiming to be on that no= de we > >> can only assume the whole thing is bogus. Thus if we're going to work = around > >> it at all, it seems to me like we should reject the entire device rath= er > >> than just bodging it to some other node. > = > Yes, I met this oops with a wrong IORT configuration, > = > > I suspect that's the same issue this thread addressed: > > > > https://lore.kernel.org/linux-pci/CAErSpo6S0qtR42tjGZrFu4aMFFyThx1hkHTS= owTt6t3XerpHnA@mail.gmail.com/ > = > and the situation mentioned above should will trigger this issue too. > = > If the node is offline, we can just return from > arm_smmu_v3_set_proximity(),=A0 any better way to fix this? Add a return value to the set_promixity() callback and return failure on hitting the issue above, therefore terminating device creation. Thanks, Lorenzo _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel