[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <MN0PR12MB6101BB8E0F2A2CD20BD73443E27F9@MN0PR12MB6101.namprd12.prod.outlook.com>
Date: Thu, 18 May 2023 15:31:27 +0000
From: "Limonciello, Mario" <Mario.Limonciello@....com>
To: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Greg KH <greg@...ah.com>
CC: "heikki.krogerus@...ux.intel.com" <heikki.krogerus@...ux.intel.com>,
"rafael@...nel.org" <rafael@...nel.org>,
"ajayg@...dia.com" <ajayg@...dia.com>,
"linux-i2c@...r.kernel.org" <linux-i2c@...r.kernel.org>,
"linux-pm@...r.kernel.org" <linux-pm@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-usb@...r.kernel.org" <linux-usb@...r.kernel.org>,
"Quan, Evan" <Evan.Quan@....com>,
"Lazar, Lijo" <Lijo.Lazar@....com>,
"Goswami, Sanket" <Sanket.Goswami@....com>
Subject: RE: [PATCH 2/2] usb: typec: ucsi: Don't create power supplies for
dGPUs
[AMD Official Use Only - General]
> -----Original Message-----
> From: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
> Sent: Wednesday, May 17, 2023 2:14 PM
> To: Greg KH <greg@...ah.com>
> Cc: Limonciello, Mario <Mario.Limonciello@....com>;
> heikki.krogerus@...ux.intel.com; rafael@...nel.org; ajayg@...dia.com; linux-
> i2c@...r.kernel.org; linux-pm@...r.kernel.org; linux-kernel@...r.kernel.org;
> linux-usb@...r.kernel.org; Quan, Evan <Evan.Quan@....com>; Lazar, Lijo
> <Lijo.Lazar@....com>; Goswami, Sanket <Sanket.Goswami@....com>
> Subject: Re: [PATCH 2/2] usb: typec: ucsi: Don't create power supplies for
> dGPUs
>
> On Wed, May 17, 2023 at 08:58:49PM +0200, Greg KH wrote:
> > On Wed, May 17, 2023 at 08:14:13PM +0300, Andy Shevchenko wrote:
> > > On Tue, May 16, 2023 at 01:25:41PM -0500, Mario Limonciello wrote:
>
> ...
>
> > > > +static const struct property_entry dgpu_properties[] = {
> > > > + /* USB-C doesn't power the system */
> > > > + PROPERTY_ENTRY_U8("scope", POWER_SUPPLY_SCOPE_DEVICE),
> > > > + {},
> > >
> > > Comma is not needed in terminator entry.
> >
> > But it's encouraged!
>
> Why?! This might lead to the subtle mistakes going unnoticed during rebases.
> Yes, it's quite unlikely, but it might be still possible to have the empty
> entry in the middle of the array. Why should we shoot ourselves in the foot
> if we can avoid it without any effort?
>
> Hence I can say it's discouraged.
>
I tend to agree with Andy here, you should never be placing something after the
terminator entry and putting a comma there means a mistake /can/ happen.
I will pick up the tags and respin a v2 with this changed and patch 1 dropped
since it went through another tree.
Powered by blists - more mailing lists