Received: by 2002:ac0:a5b6:0:0:0:0:0 with SMTP id m51-v6csp5412686imm; Tue, 19 Jun 2018 09:59:39 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKPcb67B0zv2usbe07PuhQy9xGP66Dfq9dAeUHn6YcbThjnRPVvN0a2AWfBdB/lIgjfrDx/ X-Received: by 2002:a62:904c:: with SMTP id a73-v6mr18957539pfe.145.1529427579491; Tue, 19 Jun 2018 09:59:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1529427579; cv=none; d=google.com; s=arc-20160816; b=AFnXtwv89TYHd3L3tVeXSy+dIPU1MedDrhrAu+PkhvQebpXlQuGGXlrBxpYKsluQiF 0XrId6Y+hO0kD/8rO18CCfmv85EYozv3V1DfD3Z9FJne9YNwldSdY+BlUzEQ0JtEu3G1 WqG4smWRBbUX8vzYqvS+qCyrKpLsoMDkDMCYwNtNZVEV5/h+Z2wqrOmnuhpU7y3Ci0PU OXncV828xKxYFYKVJKFN085p8DlDNt8uKjWpyudb1dac2yW4OsYnnGM5Y9AwWavlO13k oi/dM5fIdwKrgIUp504bkl5PFS3quf9SdNWqOb5SI6JXZ6XP2CUDXItGz96AQuCvzhxG Hdgg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature :arc-authentication-results; bh=8jF6XspYLZmwRjhDhIec1qHaoXw52NMhIYwnd2WOt0A=; b=f1bDUInjKRn+xPQsTp+Gzjbmfi7Stg5THZnxruhBibukuNlSVWvr4W34Kp/tYEO/yh N/9P3q+yujBVmAP5nyzmfnNfL6aaIClvGsKxPzBF2TxrNoyihrH20VdUilzFmRyI1khs 155GmNJZ3TwNoHYjKSR3cxVocp5RAAnMWj7qbqtb9AsQGQsI0diqbVxVHpZNzRECveN8 uBia7gW+1+9O4ALW7N+yu9H0xsw5Iih9+VP88b6ne9G7j7AKo6IOW9N4L8+GhKS+hf+Z 4LFYxZ5RLTax+TOjknJ6XOb7IH5jp1sVIapjWvvMdlnFRpt9mU2wIcSiJnsCL6DU1v4K L0hA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@cisco.com header.s=iport header.b=gmvFI3gZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=cisco.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h89-v6si125198pld.378.2018.06.19.09.59.25; Tue, 19 Jun 2018 09:59:39 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@cisco.com header.s=iport header.b=gmvFI3gZ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=cisco.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1030232AbeFSQ5T (ORCPT + 99 others); Tue, 19 Jun 2018 12:57:19 -0400 Received: from alln-iport-2.cisco.com ([173.37.142.89]:43124 "EHLO alln-iport-2.cisco.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S966655AbeFSQ5S (ORCPT ); Tue, 19 Jun 2018 12:57:18 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=cisco.com; i=@cisco.com; l=2559; q=dns/txt; s=iport; t=1529427438; x=1530637038; h=subject:to:cc:references:from:message-id:date: mime-version:in-reply-to:content-transfer-encoding; bh=I4i0frt2oWmgcx9KrunCeNXhIt6iOiAZaxhL76kFwZE=; b=gmvFI3gZZcU0eCwUl+fMWjydzmXXHhBIfgqH8a/hkgMYAAfrXgOODS5Q EGneJmj2DpJrlVbny/aKPN4mBWEoPLgSp9RQk2A4ckNe4ufTFt+9E76r1 csJvdYNoUGPMCdXmSmFvauCdiVK9TT/ruPCRUYCU28hay/j6oTKSSeoc/ A=; X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: =?us-ascii?q?A0B1AgAANSlb/5pdJa1dGQEBAQEBAQE?= =?us-ascii?q?BAQEBAQcBAQEBAYNJYn8og3mUVYFXKZZzCxgLhEkCgm4hOBQBAgEBAQEBAQJ?= =?us-ascii?q?tHAyFKQEBBAEiFUEQCxgCAiYCAigvBgEMCAEBgyEBgX8PrCOCHIRbg22BYwU?= =?us-ascii?q?Ud4dJgVQ/gTOCaIMTAwKEXoJVAo0mi3kJhX2FJ4NlBogFhTgriWqHPoFYIYF?= =?us-ascii?q?SMxoIGxVIDoIogiEXiFmFXh8wAYoJK4IbAQE?= X-IronPort-AV: E=Sophos;i="5.51,243,1526342400"; d="scan'208";a="131838401" Received: from rcdn-core-3.cisco.com ([173.37.93.154]) by alln-iport-2.cisco.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 19 Jun 2018 16:57:17 +0000 Received: from [10.24.50.236] ([10.24.50.236]) by rcdn-core-3.cisco.com (8.14.5/8.14.5) with ESMTP id w5JGvF0I028583; Tue, 19 Jun 2018 16:57:15 GMT Subject: Re: [PATCH] arch: powerpc: pci-common: fix wrong return value check on phd_id To: "Guilherme G. Piccoli" , mpe@ellerman.id.au, benh@kernel.crashing.org Cc: Andrew Morton , xe-kernel@external.cisco.com, linux-kernel@vger.kernel.org, Paul Mackerras , linuxppc-dev@lists.ozlabs.org, Mauro Rodrigues , linux-pci@vger.kernel.org References: <20180618165706.42679-1-danielwa@cisco.com> From: Daniel Walker Message-ID: <6d321d8a-432d-d41d-cc08-144764d644b2@cisco.com> Date: Tue, 19 Jun 2018 09:57:15 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Content-Language: en-US X-Auto-Response-Suppress: DR, OOF, AutoReply Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 06/19/2018 09:26 AM, Guilherme G. Piccoli wrote: >> [...] >> What your doing is changing the phb_id to some transformation of "reg" for >> all platforms except which have "ibm,opal-phbid". This is what we observe. >> This is a radical altering of the prior phb_id selection before your patch. >> >> The question is, was that your intent ? We are expecting these numbers >> aren't getting altered in this way, this is why we have the patch. Your >> patch description appears to suggest you want this type of selection for >> "... pSeries and PowerNV cases)." , so I am assuming you did this by >> mistake. Also I don't see a reason to make this change for all platforms. > It was the intent - whenever we have device-tree information, the idea is to > use it to have more consistent numbering across reboots and PCI hotplugs. > The reason to change that originally is hotplugging a PCI device added > the device with a different PHB/Domain value, and network predictable naming > messed-up interfaces' names, leading to a machine without networking. Ok .. > > >> [...] >> >> We have already done this, that is how we determined your patch was changing >> the domain values. There isn't much to tell w.r.t this issue on our side, we >> are expecting the domain numbers are set a specific way and they aren't >> getting set that way. The drivers which are looking for PCI devices are not >> in kernel space, and the PCI domain values are getting taken from userspace. >> > Oh okay, I imagined it was some crazy userspace-based PCI domain scheme > that led you to report the issue - confirmed heheh > So, you expect the old behavior right? Incremental PHB numbering. > I think we could have a kernel config option to allow that, this way > you could rebuild your kernel with that option and keep the old behavior. > > This idea needs to be validated by the maintainers, or perhaps they could > propose another way to keep the old behavior to interested parties. > > [Looping linux-pci too - original thread at: > https://lists.ozlabs.org/pipermail/linuxppc-dev/2018-June/174760.html] I didn't look into changing the behavior on our side because it didn't look like the intent of the patch was to make a global change. I can take a look at changing this behavior on our side , given that this was intended by your changes. However, they're may be other platforms or drivers which depend on these numbers getting set a certain way, so there may be other userspace dependencies on these values. Daniel