All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sekhar Nori <nsekhar@ti.com>
To: David Lechner <david@lechnology.com>,
	Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>,
	<khilman@kernel.org>
Cc: <petr@barix.com>, Rob Herring <robh+dt@kernel.org>,
	Pawel Moll <pawel.moll@arm.com>,
	Mark Rutland <mark.rutland@arm.com>,
	Ian Campbell <ijc+devicetree@hellion.org.uk>,
	Kumar Gala <galak@codeaurora.org>,
	Kishon Vijay Abraham I <kishon@ti.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Alan Stern <stern@rowland.harvard.edu>, Bin Liu <b-liu@ti.com>,
	Lee Jones <lee.jones@linaro.org>, <devicetree@vger.kernel.org>,
	<linux-kernel@vger.kernel.org>, <linux-usb@vger.kernel.org>
Subject: Re: [PATCH v5 2/5] ARM: davinci: da8xx: Add CFGCHIP syscon platform declaration.
Date: Wed, 25 May 2016 16:45:08 +0530	[thread overview]
Message-ID: <5745893C.5040603@ti.com> (raw)
In-Reply-To: <57320FE6.60003@lechnology.com>

On Tuesday 10 May 2016 10:14 PM, David Lechner wrote:
> On 05/10/2016 06:26 AM, Sergei Shtylyov wrote:
>> On 5/10/2016 2:46 AM, David Lechner wrote:
>>
>>> The CFGCHIP registers are used by a number of devices, so using a syscon
>>> device to share them. The first consumer of this will by the
>>> phy-da8xx-usb
>>> driver.
>>>
>>> Signed-off-by: David Lechner <david@lechnology.com>
>> [...]
>>> diff --git a/arch/arm/mach-davinci/devices-da8xx.c
>>> b/arch/arm/mach-davinci/devices-da8xx.c
>>> index 725e693..69d11a1 100644
>>> --- a/arch/arm/mach-davinci/devices-da8xx.c
>>> +++ b/arch/arm/mach-davinci/devices-da8xx.c
>>> @@ -11,6 +11,7 @@
>>>   * (at your option) any later version.
>>>   */
>>>  #include <linux/init.h>
>>> +#include <linux/platform_data/syscon.h>
>>>  #include <linux/platform_device.h>
>>>  #include <linux/dma-contiguous.h>
>>>  #include <linux/serial_8250.h>
>>> @@ -1109,3 +1110,30 @@ int __init da850_register_sata(unsigned long
>>> refclkpn)
>>>      return platform_device_register(&da850_sata_device);
>>>  }
>>>  #endif
>>> +
>>> +static struct syscon_platform_data da8xx_cfgchip_platform_data = {
>>> +    .label    = "cfgchip",
>>> +};
>>> +
>>> +static struct resource da8xx_cfgchip_resources[] = {
>>> +    {
>>> +        .start    = DA8XX_SYSCFG0_BASE + DA8XX_CFGCHIP0_REG,
>>> +        .end    = DA8XX_SYSCFG0_BASE + DA8XX_CFGCHIP4_REG + 3,
>>> +        .flags    = IORESOURCE_MEM,
>>> +    },
>>> +};
>>> +
>>> +static struct platform_device da8xx_cfgchip_device = {
>>> +    .name    = "syscon",
>>> +    .id    = 0,
>>
>>     Again, -1.
>>
>> [...]
>>
>> MBR, Sergei
>>
> 
> I wish you would have noticed this when I first submitted it. I remember
> going back and forth about this. But it has been too long and I can't
> remember the reason why I chose to go this way.
> 
> It seems like changing it broke something with either this one or the
> phy device and I opted to keep it this way on both to be consistent. For
> example, the USB devices both use id = 0 as well even though there are
> only one of each type.

Agree with Sergei here. Can you confirm what broke exactly? I think the
USB needs to be fixed too.

Thanks,
Sekhar

WARNING: multiple messages have this Message-ID (diff)
From: Sekhar Nori <nsekhar@ti.com>
To: David Lechner <david@lechnology.com>,
	Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>,
	khilman@kernel.org
Cc: petr@barix.com, Rob Herring <robh+dt@kernel.org>,
	Pawel Moll <pawel.moll@arm.com>,
	Mark Rutland <mark.rutland@arm.com>,
	Ian Campbell <ijc+devicetree@hellion.org.uk>,
	Kumar Gala <galak@codeaurora.org>,
	Kishon Vijay Abraham I <kishon@ti.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Alan Stern <stern@rowland.harvard.edu>, Bin Liu <b-liu@ti.com>,
	Lee Jones <lee.jones@linaro.org>,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-usb@vger.kernel.org
Subject: Re: [PATCH v5 2/5] ARM: davinci: da8xx: Add CFGCHIP syscon platform declaration.
Date: Wed, 25 May 2016 16:45:08 +0530	[thread overview]
Message-ID: <5745893C.5040603@ti.com> (raw)
In-Reply-To: <57320FE6.60003@lechnology.com>

On Tuesday 10 May 2016 10:14 PM, David Lechner wrote:
> On 05/10/2016 06:26 AM, Sergei Shtylyov wrote:
>> On 5/10/2016 2:46 AM, David Lechner wrote:
>>
>>> The CFGCHIP registers are used by a number of devices, so using a syscon
>>> device to share them. The first consumer of this will by the
>>> phy-da8xx-usb
>>> driver.
>>>
>>> Signed-off-by: David Lechner <david@lechnology.com>
>> [...]
>>> diff --git a/arch/arm/mach-davinci/devices-da8xx.c
>>> b/arch/arm/mach-davinci/devices-da8xx.c
>>> index 725e693..69d11a1 100644
>>> --- a/arch/arm/mach-davinci/devices-da8xx.c
>>> +++ b/arch/arm/mach-davinci/devices-da8xx.c
>>> @@ -11,6 +11,7 @@
>>>   * (at your option) any later version.
>>>   */
>>>  #include <linux/init.h>
>>> +#include <linux/platform_data/syscon.h>
>>>  #include <linux/platform_device.h>
>>>  #include <linux/dma-contiguous.h>
>>>  #include <linux/serial_8250.h>
>>> @@ -1109,3 +1110,30 @@ int __init da850_register_sata(unsigned long
>>> refclkpn)
>>>      return platform_device_register(&da850_sata_device);
>>>  }
>>>  #endif
>>> +
>>> +static struct syscon_platform_data da8xx_cfgchip_platform_data = {
>>> +    .label    = "cfgchip",
>>> +};
>>> +
>>> +static struct resource da8xx_cfgchip_resources[] = {
>>> +    {
>>> +        .start    = DA8XX_SYSCFG0_BASE + DA8XX_CFGCHIP0_REG,
>>> +        .end    = DA8XX_SYSCFG0_BASE + DA8XX_CFGCHIP4_REG + 3,
>>> +        .flags    = IORESOURCE_MEM,
>>> +    },
>>> +};
>>> +
>>> +static struct platform_device da8xx_cfgchip_device = {
>>> +    .name    = "syscon",
>>> +    .id    = 0,
>>
>>     Again, -1.
>>
>> [...]
>>
>> MBR, Sergei
>>
> 
> I wish you would have noticed this when I first submitted it. I remember
> going back and forth about this. But it has been too long and I can't
> remember the reason why I chose to go this way.
> 
> It seems like changing it broke something with either this one or the
> phy device and I opted to keep it this way on both to be consistent. For
> example, the USB devices both use id = 0 as well even though there are
> only one of each type.

Agree with Sergei here. Can you confirm what broke exactly? I think the
USB needs to be fixed too.

Thanks,
Sekhar

  reply	other threads:[~2016-05-25 11:16 UTC|newest]

Thread overview: 35+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-09 23:46 [PATCH v5 0/5] da8xx USB PHY platform devices and clocks (was "da8xx UBS clocks") David Lechner
2016-05-09 23:46 ` David Lechner
2016-05-09 23:46 ` [PATCH v5 1/5] ARM: davinci: da8xx: add usb phy clocks David Lechner
2016-05-09 23:46   ` David Lechner
2016-05-09 23:46 ` [PATCH v5 2/5] ARM: davinci: da8xx: Add CFGCHIP syscon platform declaration David Lechner
2016-05-10 11:26   ` Sergei Shtylyov
2016-05-10 16:44     ` David Lechner
2016-05-25 11:15       ` Sekhar Nori [this message]
2016-05-25 11:15         ` Sekhar Nori
2016-06-22 17:03         ` David Lechner
2016-06-22 17:03           ` David Lechner
2016-06-22 17:07         ` David Lechner
2016-06-22 17:07           ` David Lechner
2016-06-24  6:15           ` Sekhar Nori
2016-06-24  6:15             ` Sekhar Nori
2016-06-24 16:00             ` David Lechner
2016-06-24 16:00               ` David Lechner
2016-05-09 23:46 ` [PATCH v5 3/5] ARM: davinci: da8xx: Add USB PHY " David Lechner
2016-05-09 23:46   ` David Lechner
2016-05-10 11:24   ` Sergei Shtylyov
2016-06-22 17:08     ` David Lechner
2016-06-22 17:08       ` David Lechner
2016-05-09 23:46 ` [PATCH v5 4/5] ARM: DTS: da850: Add cfgchip syscon node David Lechner
2016-05-09 23:46   ` David Lechner
2016-05-09 23:46 ` [PATCH v5 5/5] ARM: DTS: da850: Add usb phy node David Lechner
2016-05-09 23:46   ` David Lechner
2016-05-23 15:14 ` [PATCH v5 0/5] da8xx USB PHY platform devices and clocks (was "da8xx UBS clocks") David Lechner
2016-05-25 11:18   ` Sekhar Nori
2016-05-25 11:18     ` Sekhar Nori
2016-08-12 21:24     ` Kevin Hilman
2016-08-17  9:35       ` Kishon Vijay Abraham I
2016-08-17  9:35         ` Kishon Vijay Abraham I
2016-08-19 16:40         ` Kevin Hilman
2016-08-19 16:40           ` Kevin Hilman
2016-08-19 16:50           ` David Lechner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5745893C.5040603@ti.com \
    --to=nsekhar@ti.com \
    --cc=b-liu@ti.com \
    --cc=david@lechnology.com \
    --cc=devicetree@vger.kernel.org \
    --cc=galak@codeaurora.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=khilman@kernel.org \
    --cc=kishon@ti.com \
    --cc=lee.jones@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=pawel.moll@arm.com \
    --cc=petr@barix.com \
    --cc=robh+dt@kernel.org \
    --cc=sergei.shtylyov@cogentembedded.com \
    --cc=stern@rowland.harvard.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.