[{"id":1801748,"web_url":"http://patchwork.ozlabs.org/comment/1801748/","msgid":"<7753323.U3pdzOgHt3@aspire.rjw.lan>","list_archive_url":null,"date":"2017-11-08T22:27:55","subject":"Re: [RFC PATCH v10 5/7] PCI: Make pci_platform_pm_ops's callbacks\n\toptional","submitter":{"id":26536,"url":"http://patchwork.ozlabs.org/api/people/26536/","name":"Rafael J. Wysocki","email":"rjw@rjwysocki.net"},"content":"On Friday, October 27, 2017 9:26:10 AM CET Jeffy Chen wrote:\n> Allow platforms not to provide some of the pci_platform_pm_ops's\n> callbacks.\n\nSo?\n\nWhat exactly is wrong with having empty ops in there?\n\nIs it really better to have everyone do extra checks every time an op is\ninvoked even when all of the ops are present?\n\n> Also change the return value from -ENOSYS to -ENODEV for:\n> warning: drivers/pci/pci.c,594: ENOSYS means 'invalid syscall nr' and nothing else\n\nMoving stuff around and changing it at the same time is a bad idea.\n\nChange it in one patch and move it around in another one and you'll be less\nlikely to make a mistake.  Moreover, reviewing it will be easier too, IMO.\n\nThanks,\nRafael","headers":{"Return-Path":"<linux-pci-owner@vger.kernel.org>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@bilbo.ozlabs.org","Authentication-Results":"ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=vger.kernel.org\n\t(client-ip=209.132.180.67; helo=vger.kernel.org;\n\tenvelope-from=linux-pci-owner@vger.kernel.org;\n\treceiver=<UNKNOWN>)","Received":["from vger.kernel.org (vger.kernel.org [209.132.180.67])\n\tby ozlabs.org (Postfix) with ESMTP id 3yXLXv0m2yz9s7B\n\tfor <incoming@patchwork.ozlabs.org>;\n\tThu,  9 Nov 2017 09:28:15 +1100 (AEDT)","(majordomo@vger.kernel.org) by vger.kernel.org via listexpand\n\tid S1752805AbdKHW2D (ORCPT <rfc822;incoming@patchwork.ozlabs.org>);\n\tWed, 8 Nov 2017 17:28:03 -0500","from cloudserver094114.home.net.pl ([79.96.170.134]:45785 \"EHLO\n\tcloudserver094114.home.net.pl\" rhost-flags-OK-OK-OK-OK)\n\tby vger.kernel.org with ESMTP id S1751245AbdKHW2B (ORCPT\n\t<rfc822;linux-pci@vger.kernel.org>); Wed, 8 Nov 2017 17:28:01 -0500","from 79.184.254.73.ipv4.supernova.orange.pl (79.184.254.73) (HELO\n\taspire.rjw.lan)\n\tby serwer1319399.home.pl (79.96.170.134) with SMTP (IdeaSmtpServer\n\t0.82) id 257355669dd08768; Wed, 8 Nov 2017 23:27:59 +0100"],"From":"\"Rafael J. Wysocki\" <rjw@rjwysocki.net>","To":"Jeffy Chen <jeffy.chen@rock-chips.com>","Cc":"linux-kernel@vger.kernel.org, bhelgaas@google.com,\n\tlinux-pm@vger.kernel.org, tony@atomide.com,\n\tshawn.lin@rock-chips.com, briannorris@chromium.org,\n\tdianders@chromium.org, linux-pci@vger.kernel.org","Subject":"Re: [RFC PATCH v10 5/7] PCI: Make pci_platform_pm_ops's callbacks\n\toptional","Date":"Wed, 08 Nov 2017 23:27:55 +0100","Message-ID":"<7753323.U3pdzOgHt3@aspire.rjw.lan>","In-Reply-To":"<20171027072612.26565-6-jeffy.chen@rock-chips.com>","References":"<20171027072612.26565-1-jeffy.chen@rock-chips.com>\n\t<20171027072612.26565-6-jeffy.chen@rock-chips.com>","MIME-Version":"1.0","Content-Transfer-Encoding":"7Bit","Content-Type":"text/plain; charset=\"us-ascii\"","Sender":"linux-pci-owner@vger.kernel.org","Precedence":"bulk","List-ID":"<linux-pci.vger.kernel.org>","X-Mailing-List":"linux-pci@vger.kernel.org"}}]