* [GIT PULL] Broadcom Device Tree changes for 4.2
@ 2015-05-13 22:34 Florian Fainelli
2015-05-13 22:34 ` [GIT PULL] Broadcom MAINTAINERS file update " Florian Fainelli
` (2 more replies)
0 siblings, 3 replies; 12+ messages in thread
From: Florian Fainelli @ 2015-05-13 22:34 UTC (permalink / raw)
To: linux-arm-kernel
The following changes since commit b787f68c36d49bb1d9236f403813641efa74a031:
Linux 4.1-rc1 (2015-04-26 17:59:10 -0700)
are available in the git repository at:
http://github.com/broadcom/stblinux tags/arm-soc/for-4.2/dts
for you to fetch changes up to 16dc3bac722252a10e396546f44135ae1b6a7ff3:
ARM: BCM5301X: Add DT for Asus RT-AC56U (2015-05-13 11:32:24 -0700)
----------------------------------------------------------------
This pull request contains the following Device Tree changes:
New devices:
- Felix adds support for the Buffalo WXR-1900DHP and adds the USB led on Buffalo
WZR-1750DHP
- Rafal adds support for the SmartRG SR400ac, Asus RT-AC68U and RT-AC56U
New peripheral support:
- Brian adds Device Tree nodes for the Broadcom NAND controller found on
BCM7xxx, BCM63138 and Cygnus SoCs
- Brian adds Device Tree nodes for the SATA AHCI and PHY controller found on
BCM7xxx
- I add the Device Tree nodes and bindings documents for bringing-up secondary
CPUs and timer/syscon-reboot on BCM63138
----------------------------------------------------------------
Brian Norris (3):
ARM: bcm7445: add NAND to DTS
ARM: bcm63138: add NAND DT support
ARM: dts: brcmstb: add nodes for SATA controller and PHY
Felix Fietkau (2):
ARM: BCM5301X: Add USB LED for Buffalo WZR-1750DHP
ARM: BCM5301X: Add DT for Buffalo WXR-1900DHP
Florian Fainelli (6):
Documentation: DT: Add Broadcom BCM63138 PMB binding
ARM: dts: BCM63xx: Add PMB busses nodes
Documentation: DT: Document SMP DT nodes and properties for BCM63138
ARM: dts: BCM63xx: Add SMP nodes and required properties
dt-bindings: Add documentation for the BCM63138 timer and syscon-reboot
ARM: dts: BCM63xx: Add timer and syscon-reboot nodes
Rafa? Mi?ecki (3):
ARM: BCM5301X: Add DT for SmartRG SR400ac
ARM: BCM5301X: Add DT for Asus RT-AC68U
ARM: BCM5301X: Add DT for Asus RT-AC56U
Ray Jui (1):
ARM: dts: cygnus: Enable NAND support for Cygnus
.../devicetree/bindings/arm/bcm/brcm,bcm63138.txt | 76 ++++++++++++
.../bindings/reset/brcm,bcm63138-pmb.txt | 19 +++
arch/arm/boot/dts/Makefile | 4 +
arch/arm/boot/dts/bcm-cygnus.dtsi | 12 ++
arch/arm/boot/dts/bcm4708-asus-rt-ac56u.dts | 96 ++++++++++++++++
arch/arm/boot/dts/bcm4708-asus-rt-ac68u.dts | 83 ++++++++++++++
arch/arm/boot/dts/bcm4708-buffalo-wzr-1750dhp.dts | 6 +
arch/arm/boot/dts/bcm4708-smartrg-sr400ac.dts | 119 +++++++++++++++++++
arch/arm/boot/dts/bcm4709-buffalo-wxr-1900dhp.dts | 127 +++++++++++++++++++++
arch/arm/boot/dts/bcm63138.dtsi | 43 +++++++
arch/arm/boot/dts/bcm7445-bcm97445svmb.dts | 23 ++++
arch/arm/boot/dts/bcm7445.dtsi | 59 ++++++++++
arch/arm/boot/dts/bcm958300k.dts | 16 +++
arch/arm/boot/dts/bcm963138dvt.dts | 12 ++
14 files changed, 695 insertions(+)
create mode 100644 Documentation/devicetree/bindings/reset/brcm,bcm63138-pmb.txt
create mode 100644 arch/arm/boot/dts/bcm4708-asus-rt-ac56u.dts
create mode 100644 arch/arm/boot/dts/bcm4708-asus-rt-ac68u.dts
create mode 100644 arch/arm/boot/dts/bcm4708-smartrg-sr400ac.dts
create mode 100644 arch/arm/boot/dts/bcm4709-buffalo-wxr-1900dhp.dts
^ permalink raw reply [flat|nested] 12+ messages in thread
* [GIT PULL] Broadcom MAINTAINERS file update for 4.2
2015-05-13 22:34 [GIT PULL] Broadcom Device Tree changes for 4.2 Florian Fainelli
@ 2015-05-13 22:34 ` Florian Fainelli
2015-05-20 15:44 ` Arnd Bergmann
2015-05-13 22:34 ` [GIT PULL] Broadcom SoC changes " Florian Fainelli
2015-05-15 15:18 ` [GIT PULL] Broadcom Device Tree " Arnd Bergmann
2 siblings, 1 reply; 12+ messages in thread
From: Florian Fainelli @ 2015-05-13 22:34 UTC (permalink / raw)
To: linux-arm-kernel
The following changes since commit 030bbdbf4c833bc69f502eae58498bc5572db736:
Linux 4.1-rc3 (2015-05-10 15:12:29 -0700)
are available in the git repository at:
http://github.com/broadcom/stblinux tags/arm-soc/for-4.2/maintainers
for you to fetch changes up to 5009a289ccb58b35425a9bc06e4f071e5ff27038:
MAINTAINERS: add brcmstb regex (2015-05-13 10:53:32 -0700)
Olof, Arnd, Kevin,
This is against 4.1-rc3 to be after the following set of changes:
d6ad446dd75ef58bd383987e35ffd90d564f8080 ("Merge tag 'arm-soc/for-4.1/maintainers' of http://github.com/broadcom/stblinux into fixes")
----------------------------------------------------------------
This pull request for the MAINTAINERS file contains the following changes:
- Brian adds a general "brcmstb" regexp to catch Broadcom Set Top Box related
changes throughout the Linux tree
----------------------------------------------------------------
Brian Norris (1):
MAINTAINERS: add brcmstb regex
MAINTAINERS | 1 +
1 file changed, 1 insertion(+)
^ permalink raw reply [flat|nested] 12+ messages in thread
* [GIT PULL] Broadcom SoC changes for 4.2
2015-05-13 22:34 [GIT PULL] Broadcom Device Tree changes for 4.2 Florian Fainelli
2015-05-13 22:34 ` [GIT PULL] Broadcom MAINTAINERS file update " Florian Fainelli
@ 2015-05-13 22:34 ` Florian Fainelli
2015-05-20 15:42 ` Arnd Bergmann
` (2 more replies)
2015-05-15 15:18 ` [GIT PULL] Broadcom Device Tree " Arnd Bergmann
2 siblings, 3 replies; 12+ messages in thread
From: Florian Fainelli @ 2015-05-13 22:34 UTC (permalink / raw)
To: linux-arm-kernel
The following changes since commit b787f68c36d49bb1d9236f403813641efa74a031:
Linux 4.1-rc1 (2015-04-26 17:59:10 -0700)
are available in the git repository at:
http://github.com/broadcom/stblinux tags/arm-soc/for-4.2/soc
for you to fetch changes up to d044ce725eea4d7b74bcb6e9e7b33996aae77f04:
ARM: BCM63xx: Add SMP support for BCM63138 (2015-05-13 09:59:07 -0700)
----------------------------------------------------------------
This pull request contains the following changes:
- BCM63138 SMP support which pulls in code to control the PMB bus, secondary CPU initialization
sequence and small changes suggested by Russell King to allow platforms to disable VFP
----------------------------------------------------------------
Florian Fainelli (5):
ARM: BCM63xx: Add Broadcom BCM63xx PMB controller helpers
ARM: BCM63xx: Add secondary CPU PMB initialization sequence
ARM: vfp: Add include guards
ARM: vfp: Add vfp_disable for problematic platforms
ARM: BCM63xx: Add SMP support for BCM63138
arch/arm/include/asm/vfp.h | 9 ++
arch/arm/mach-bcm/Makefile | 7 +-
arch/arm/mach-bcm/bcm63xx_headsmp.S | 23 ++++
arch/arm/mach-bcm/bcm63xx_pmb.c | 221 ++++++++++++++++++++++++++++++++++++
arch/arm/mach-bcm/bcm63xx_smp.c | 170 +++++++++++++++++++++++++++
arch/arm/mach-bcm/bcm63xx_smp.h | 9 ++
arch/arm/vfp/vfpmodule.c | 13 +++
include/linux/bcm63xx_pmb.h | 76 +++++++++++++
8 files changed, 527 insertions(+), 1 deletion(-)
create mode 100644 arch/arm/mach-bcm/bcm63xx_headsmp.S
create mode 100644 arch/arm/mach-bcm/bcm63xx_pmb.c
create mode 100644 arch/arm/mach-bcm/bcm63xx_smp.c
create mode 100644 arch/arm/mach-bcm/bcm63xx_smp.h
create mode 100644 include/linux/bcm63xx_pmb.h
^ permalink raw reply [flat|nested] 12+ messages in thread
* [GIT PULL] Broadcom Device Tree changes for 4.2
2015-05-13 22:34 [GIT PULL] Broadcom Device Tree changes for 4.2 Florian Fainelli
2015-05-13 22:34 ` [GIT PULL] Broadcom MAINTAINERS file update " Florian Fainelli
2015-05-13 22:34 ` [GIT PULL] Broadcom SoC changes " Florian Fainelli
@ 2015-05-15 15:18 ` Arnd Bergmann
2 siblings, 0 replies; 12+ messages in thread
From: Arnd Bergmann @ 2015-05-15 15:18 UTC (permalink / raw)
To: linux-arm-kernel
On Wednesday 13 May 2015 15:34:11 Florian Fainelli wrote:
> This pull request contains the following Device Tree changes:
>
> New devices:
>
> - Felix adds support for the Buffalo WXR-1900DHP and adds the USB led on Buffalo
> WZR-1750DHP
>
> - Rafal adds support for the SmartRG SR400ac, Asus RT-AC68U and RT-AC56U
>
> New peripheral support:
>
> - Brian adds Device Tree nodes for the Broadcom NAND controller found on
> BCM7xxx, BCM63138 and Cygnus SoCs
>
> - Brian adds Device Tree nodes for the SATA AHCI and PHY controller found on
> BCM7xxx
>
> - I add the Device Tree nodes and bindings documents for bringing-up secondary
> CPUs and timer/syscon-reboot on BCM63138
>
>
Pulled into next/dt, thanks!
Arnd
^ permalink raw reply [flat|nested] 12+ messages in thread
* [GIT PULL] Broadcom SoC changes for 4.2
2015-05-13 22:34 ` [GIT PULL] Broadcom SoC changes " Florian Fainelli
@ 2015-05-20 15:42 ` Arnd Bergmann
2015-05-20 15:43 ` Arnd Bergmann
2015-05-20 20:59 ` Arnd Bergmann
2 siblings, 0 replies; 12+ messages in thread
From: Arnd Bergmann @ 2015-05-20 15:42 UTC (permalink / raw)
To: linux-arm-kernel
On Wednesday 13 May 2015 15:34:13 Florian Fainelli wrote:
> This pull request contains the following changes:
>
> - BCM63138 SMP support which pulls in code to control the PMB bus, secondary CPU initialization
> sequence and small changes suggested by Russell King to allow platforms to disable VFP
>
> ----------------------------------------------------------------
> Florian Fainelli (5):
> ARM: BCM63xx: Add Broadcom BCM63xx PMB controller helpers
> ARM: BCM63xx: Add secondary CPU PMB initialization sequence
> ARM: vfp: Add include guards
> ARM: vfp: Add vfp_disable for problematic platforms
> ARM: BCM63xx: Add SMP support for BCM63138
>
>
Pulled into next/soc, thanks!
Arnd
^ permalink raw reply [flat|nested] 12+ messages in thread
* [GIT PULL] Broadcom SoC changes for 4.2
2015-05-13 22:34 ` [GIT PULL] Broadcom SoC changes " Florian Fainelli
2015-05-20 15:42 ` Arnd Bergmann
@ 2015-05-20 15:43 ` Arnd Bergmann
2015-05-20 20:59 ` Arnd Bergmann
2 siblings, 0 replies; 12+ messages in thread
From: Arnd Bergmann @ 2015-05-20 15:43 UTC (permalink / raw)
To: linux-arm-kernel
On Wednesday 13 May 2015 15:34:13 Florian Fainelli wrote:
> This pull request contains the following changes:
>
> - BCM63138 SMP support which pulls in code to control the PMB bus, secondary CPU initialization
> sequence and small changes suggested by Russell King to allow platforms to disable VFP
>
Pulled into next/soc now, sorry for missing it last week.
Arnd
^ permalink raw reply [flat|nested] 12+ messages in thread
* [GIT PULL] Broadcom MAINTAINERS file update for 4.2
2015-05-13 22:34 ` [GIT PULL] Broadcom MAINTAINERS file update " Florian Fainelli
@ 2015-05-20 15:44 ` Arnd Bergmann
0 siblings, 0 replies; 12+ messages in thread
From: Arnd Bergmann @ 2015-05-20 15:44 UTC (permalink / raw)
To: linux-arm-kernel
On Wednesday 13 May 2015 15:34:12 Florian Fainelli wrote:
> This pull request for the MAINTAINERS file contains the following changes:
>
> - Brian adds a general "brcmstb" regexp to catch Broadcom Set Top Box related
> changes throughout the Linux tree
>
As this does not seem urgent enough for fixes (which you confirmed on IRC),
I've put it into next/soc as well. Thanks!
Arnd
^ permalink raw reply [flat|nested] 12+ messages in thread
* [GIT PULL] Broadcom SoC changes for 4.2
2015-05-13 22:34 ` [GIT PULL] Broadcom SoC changes " Florian Fainelli
2015-05-20 15:42 ` Arnd Bergmann
2015-05-20 15:43 ` Arnd Bergmann
@ 2015-05-20 20:59 ` Arnd Bergmann
2015-05-20 21:05 ` Florian Fainelli
2 siblings, 1 reply; 12+ messages in thread
From: Arnd Bergmann @ 2015-05-20 20:59 UTC (permalink / raw)
To: linux-arm-kernel
On Wednesday 13 May 2015 15:34:13 Florian Fainelli wrote:
> arch/arm/include/asm/vfp.h | 9 ++
> arch/arm/mach-bcm/Makefile | 7 +-
> arch/arm/mach-bcm/bcm63xx_headsmp.S | 23 ++++
> arch/arm/mach-bcm/bcm63xx_pmb.c | 221 ++++++++++++++++++++++++++++++++++++
> arch/arm/mach-bcm/bcm63xx_smp.c | 170 +++++++++++++++++++++++++++
> arch/arm/mach-bcm/bcm63xx_smp.h | 9 ++
> arch/arm/vfp/vfpmodule.c | 13 +++
> include/linux/bcm63xx_pmb.h | 76 +++++++++++++
>
And taken out again, sorry.
I got a build error in include/linux/bcm63xx_pmb.h and that triggered me to take
a closer look. I tried to fix up the trivial error first, but then noticed
several other things wrong with bcm63xx_pmb.h:
- it is in include/linux/ where it clearly does not belong, as no other component
should be including it. Even the function documentation in there mentions that
one must hold the pmb_lock before calling it, and that is defined statically
arch/arm/mach-bcm/bcm63xx_pmb.c, so it's impossible for other code to use.
Just move it all into bcm63xx_pmb.c.
- the code uses __raw_readl/__raw_writel for MMIO register access, which is
broken on big-endian machines. You need to use readl_relaxed()/write_relaxed()
or readl()/writel() instead. If you use the latter, you can also avoid
introducing extra barriers.
- finally, a heads-up for the "[PATCH] ARM: v7 setup function should invalidate
L1 cache" patch that Russell submitted. I think your bcm63xx_headsmp.S
function is completely fine for now, but with his patch applied, it will
no longer be needed and you should follow up with a patch to replace it
with a direct branch to secondary_startup.
Arnd
^ permalink raw reply [flat|nested] 12+ messages in thread
* [GIT PULL] Broadcom SoC changes for 4.2
2015-05-20 20:59 ` Arnd Bergmann
@ 2015-05-20 21:05 ` Florian Fainelli
2015-05-20 21:22 ` Arnd Bergmann
0 siblings, 1 reply; 12+ messages in thread
From: Florian Fainelli @ 2015-05-20 21:05 UTC (permalink / raw)
To: linux-arm-kernel
On 20/05/15 13:59, Arnd Bergmann wrote:
> On Wednesday 13 May 2015 15:34:13 Florian Fainelli wrote:
>> arch/arm/include/asm/vfp.h | 9 ++
>> arch/arm/mach-bcm/Makefile | 7 +-
>> arch/arm/mach-bcm/bcm63xx_headsmp.S | 23 ++++
>> arch/arm/mach-bcm/bcm63xx_pmb.c | 221 ++++++++++++++++++++++++++++++++++++
>> arch/arm/mach-bcm/bcm63xx_smp.c | 170 +++++++++++++++++++++++++++
>> arch/arm/mach-bcm/bcm63xx_smp.h | 9 ++
>> arch/arm/vfp/vfpmodule.c | 13 +++
>> include/linux/bcm63xx_pmb.h | 76 +++++++++++++
>>
>
> And taken out again, sorry.
No problem, Rafal reminded me of a patch I forgot to submit earlier, so
I will take that as an opportunity to re-do this pull request.
>
> I got a build error in include/linux/bcm63xx_pmb.h and that triggered me to take
> a closer look. I tried to fix up the trivial error first, but then noticed
> several other things wrong with bcm63xx_pmb.h:
What kind of build error? Do you have it handy?
>
> - it is in include/linux/ where it clearly does not belong, as no other component
> should be including it. Even the function documentation in there mentions that
> one must hold the pmb_lock before calling it, and that is defined statically
> arch/arm/mach-bcm/bcm63xx_pmb.c, so it's impossible for other code to use.
> Just move it all into bcm63xx_pmb.c.
This header will later be used by the bcm63138 reset controller, and I
thought I had explained the reasoning behind that in either the commit
message or cover letter, I will make sure the commit message explains it.
The lock issue is not much of a problem since we do not support CPU
hotplug and the reset controller subsystem is initialized later so there
is no possibility for these two pieces of code to conflict.
>
> - the code uses __raw_readl/__raw_writel for MMIO register access, which is
> broken on big-endian machines. You need to use readl_relaxed()/write_relaxed()
> or readl()/writel() instead. If you use the latter, you can also avoid
> introducing extra barriers.
Fair point, will fix that.
>
> - finally, a heads-up for the "[PATCH] ARM: v7 setup function should invalidate
> L1 cache" patch that Russell submitted. I think your bcm63xx_headsmp.S
> function is completely fine for now, but with his patch applied, it will
> no longer be needed and you should follow up with a patch to replace it
> with a direct branch to secondary_startup.
Thanks, I will keep that in mind.
--
Florian
^ permalink raw reply [flat|nested] 12+ messages in thread
* [GIT PULL] Broadcom SoC changes for 4.2
2015-05-20 21:05 ` Florian Fainelli
@ 2015-05-20 21:22 ` Arnd Bergmann
2015-05-20 21:50 ` Florian Fainelli
0 siblings, 1 reply; 12+ messages in thread
From: Arnd Bergmann @ 2015-05-20 21:22 UTC (permalink / raw)
To: linux-arm-kernel
On Wednesday 20 May 2015 14:05:35 Florian Fainelli wrote:
> On 20/05/15 13:59, Arnd Bergmann wrote:
> > On Wednesday 13 May 2015 15:34:13 Florian Fainelli wrote:
> >> arch/arm/include/asm/vfp.h | 9 ++
> >> arch/arm/mach-bcm/Makefile | 7 +-
> >> arch/arm/mach-bcm/bcm63xx_headsmp.S | 23 ++++
> >> arch/arm/mach-bcm/bcm63xx_pmb.c | 221 ++++++++++++++++++++++++++++++++++++
> >> arch/arm/mach-bcm/bcm63xx_smp.c | 170 +++++++++++++++++++++++++++
> >> arch/arm/mach-bcm/bcm63xx_smp.h | 9 ++
> >> arch/arm/vfp/vfpmodule.c | 13 +++
> >> include/linux/bcm63xx_pmb.h | 76 +++++++++++++
> >>
> >
> > And taken out again, sorry.
>
> No problem, Rafal reminded me of a patch I forgot to submit earlier, so
> I will take that as an opportunity to re-do this pull request.
>
> >
> > I got a build error in include/linux/bcm63xx_pmb.h and that triggered me to take
> > a closer look. I tried to fix up the trivial error first, but then noticed
> > several other things wrong with bcm63xx_pmb.h:
>
> What kind of build error? Do you have it handy?
I sent it to you on IRC earlier, here is the full error log:
/git/arm-soc/include/linux/bcm63xx_pmb.h: In function '__bpcm_do_op':
/git/arm-soc/include/linux/bcm63xx_pmb.h:39:12: error: 'EIO' undeclared (first use in this function)
return -EIO;
^
/git/arm-soc/include/linux/bcm63xx_pmb.h:39:12: note: each undeclared identifier is reported only once for each function it appears in
/git/arm-soc/include/linux/bcm63xx_pmb.h:42:12: error: 'ETIMEDOUT' undeclared (first use in this function)
return -ETIMEDOUT;
^
In file included from /git/arm-soc/arch/arm/mach-bcm/bcm63xx_pmb.c:15:0:
/git/arm-soc/include/linux/bcm63xx_pmb.h:48:1: warning: control reaches end of non-void function [-Wreturn-type]
This is fixed by including linux/errno.h in the header.
> > - it is in include/linux/ where it clearly does not belong, as no other component
> > should be including it. Even the function documentation in there mentions that
> > one must hold the pmb_lock before calling it, and that is defined statically
> > arch/arm/mach-bcm/bcm63xx_pmb.c, so it's impossible for other code to use.
> > Just move it all into bcm63xx_pmb.c.
>
> This header will later be used by the bcm63138 reset controller, and I
> thought I had explained the reasoning behind that in either the commit
> message or cover letter, I will make sure the commit message explains it.
I see. I still think it's a bit rude to place this header in the top-level
include/linux directory though. I realize there are a lot of other headers
like this, but I'm trying not to add too many more.
Maybe a lesser evil would be to put the reset driver into
arch/arm/mach-bcm/bcm63xx_pmb.c as well?
How big is it? And is there anything else besides that driver which would
need these functions?
> The lock issue is not much of a problem since we do not support CPU
> hotplug and the reset controller subsystem is initialized later so there
> is no possibility for these two pieces of code to conflict.
Ok
Arnd
^ permalink raw reply [flat|nested] 12+ messages in thread
* [GIT PULL] Broadcom SoC changes for 4.2
2015-05-20 21:22 ` Arnd Bergmann
@ 2015-05-20 21:50 ` Florian Fainelli
2015-05-20 22:02 ` Arnd Bergmann
0 siblings, 1 reply; 12+ messages in thread
From: Florian Fainelli @ 2015-05-20 21:50 UTC (permalink / raw)
To: linux-arm-kernel
On 20/05/15 14:22, Arnd Bergmann wrote:
> On Wednesday 20 May 2015 14:05:35 Florian Fainelli wrote:
>> On 20/05/15 13:59, Arnd Bergmann wrote:
>>> On Wednesday 13 May 2015 15:34:13 Florian Fainelli wrote:
>>>> arch/arm/include/asm/vfp.h | 9 ++
>>>> arch/arm/mach-bcm/Makefile | 7 +-
>>>> arch/arm/mach-bcm/bcm63xx_headsmp.S | 23 ++++
>>>> arch/arm/mach-bcm/bcm63xx_pmb.c | 221 ++++++++++++++++++++++++++++++++++++
>>>> arch/arm/mach-bcm/bcm63xx_smp.c | 170 +++++++++++++++++++++++++++
>>>> arch/arm/mach-bcm/bcm63xx_smp.h | 9 ++
>>>> arch/arm/vfp/vfpmodule.c | 13 +++
>>>> include/linux/bcm63xx_pmb.h | 76 +++++++++++++
>>>>
>>>
>>> And taken out again, sorry.
>>
>> No problem, Rafal reminded me of a patch I forgot to submit earlier, so
>> I will take that as an opportunity to re-do this pull request.
>>
>>>
>>> I got a build error in include/linux/bcm63xx_pmb.h and that triggered me to take
>>> a closer look. I tried to fix up the trivial error first, but then noticed
>>> several other things wrong with bcm63xx_pmb.h:
>>
>> What kind of build error? Do you have it handy?
>
> I sent it to you on IRC earlier, here is the full error log:
>
> /git/arm-soc/include/linux/bcm63xx_pmb.h: In function '__bpcm_do_op':
> /git/arm-soc/include/linux/bcm63xx_pmb.h:39:12: error: 'EIO' undeclared (first use in this function)
> return -EIO;
> ^
> /git/arm-soc/include/linux/bcm63xx_pmb.h:39:12: note: each undeclared identifier is reported only once for each function it appears in
> /git/arm-soc/include/linux/bcm63xx_pmb.h:42:12: error: 'ETIMEDOUT' undeclared (first use in this function)
> return -ETIMEDOUT;
> ^
> In file included from /git/arm-soc/arch/arm/mach-bcm/bcm63xx_pmb.c:15:0:
> /git/arm-soc/include/linux/bcm63xx_pmb.h:48:1: warning: control reaches end of non-void function [-Wreturn-type]
>
> This is fixed by including linux/errno.h in the header.
Yes, thanks I just reproduced it, not sure how I could have missed that
before...
>
>>> - it is in include/linux/ where it clearly does not belong, as no other component
>>> should be including it. Even the function documentation in there mentions that
>>> one must hold the pmb_lock before calling it, and that is defined statically
>>> arch/arm/mach-bcm/bcm63xx_pmb.c, so it's impossible for other code to use.
>>> Just move it all into bcm63xx_pmb.c.
>>
>> This header will later be used by the bcm63138 reset controller, and I
>> thought I had explained the reasoning behind that in either the commit
>> message or cover letter, I will make sure the commit message explains it.
>
> I see. I still think it's a bit rude to place this header in the top-level
> include/linux directory though. I realize there are a lot of other headers
> like this, but I'm trying not to add too many more.
Would a lesser evil be to create include/linux/resets/ and place this
header file there?
>
> Maybe a lesser evil would be to put the reset driver into
> arch/arm/mach-bcm/bcm63xx_pmb.c as well?
>
> How big is it? And is there anything else besides that driver which would
> need these functions?
It is going to be (once feature complete) as big as
arch/arm/mach-bcm/bcm63xx_pmb.c except that it will also have to inspect
the client asking for the reset, e.g: the reset procedure for the SATA
block is a little different than the one for the PCIe PHY, or integrated
Ethernet switch, or USB controlers...
The way we power on a secondary CPU is code that is not shared with how
other on-chip peripherals are powered on, hence the idea behind the
separation.
>
>> The lock issue is not much of a problem since we do not support CPU
>> hotplug and the reset controller subsystem is initialized later so there
>> is no possibility for these two pieces of code to conflict.
>
> Ok
>
> Arnd
>
--
Florian
^ permalink raw reply [flat|nested] 12+ messages in thread
* [GIT PULL] Broadcom SoC changes for 4.2
2015-05-20 21:50 ` Florian Fainelli
@ 2015-05-20 22:02 ` Arnd Bergmann
0 siblings, 0 replies; 12+ messages in thread
From: Arnd Bergmann @ 2015-05-20 22:02 UTC (permalink / raw)
To: linux-arm-kernel
On Wednesday 20 May 2015 14:50:37 Florian Fainelli wrote:
> >>> - it is in include/linux/ where it clearly does not belong, as no other component
> >>> should be including it. Even the function documentation in there mentions that
> >>> one must hold the pmb_lock before calling it, and that is defined statically
> >>> arch/arm/mach-bcm/bcm63xx_pmb.c, so it's impossible for other code to use.
> >>> Just move it all into bcm63xx_pmb.c.
> >>
> >> This header will later be used by the bcm63138 reset controller, and I
> >> thought I had explained the reasoning behind that in either the commit
> >> message or cover letter, I will make sure the commit message explains it.
> >
> > I see. I still think it's a bit rude to place this header in the top-level
> > include/linux directory though. I realize there are a lot of other headers
> > like this, but I'm trying not to add too many more.
>
> Would a lesser evil be to create include/linux/resets/ and place this
> header file there?
I've also thought about that. It would certainly help.
> > Maybe a lesser evil would be to put the reset driver into
> > arch/arm/mach-bcm/bcm63xx_pmb.c as well?
> >
> > How big is it? And is there anything else besides that driver which would
> > need these functions?
>
> It is going to be (once feature complete) as big as
> arch/arm/mach-bcm/bcm63xx_pmb.c except that it will also have to inspect
> the client asking for the reset, e.g: the reset procedure for the SATA
> block is a little different than the one for the PCIe PHY, or integrated
> Ethernet switch, or USB controlers...
>
> The way we power on a secondary CPU is code that is not shared with how
> other on-chip peripherals are powered on, hence the idea behind the
> separation.
Ok, I see. Let's start with the include/linux/resets/ approach then.
Yet another idea would be to expose the read/write interface here
as a regmap and find a way to share that. That way, you could move
a large part of bcm63xx_pmb.c and bcm63xx_pmb.h into the reset
driver and just have one interface to get the regmap, like we do
for syscon devices. It would still need a single function declaration
though.
Arnd
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2015-05-20 22:02 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-05-13 22:34 [GIT PULL] Broadcom Device Tree changes for 4.2 Florian Fainelli
2015-05-13 22:34 ` [GIT PULL] Broadcom MAINTAINERS file update " Florian Fainelli
2015-05-20 15:44 ` Arnd Bergmann
2015-05-13 22:34 ` [GIT PULL] Broadcom SoC changes " Florian Fainelli
2015-05-20 15:42 ` Arnd Bergmann
2015-05-20 15:43 ` Arnd Bergmann
2015-05-20 20:59 ` Arnd Bergmann
2015-05-20 21:05 ` Florian Fainelli
2015-05-20 21:22 ` Arnd Bergmann
2015-05-20 21:50 ` Florian Fainelli
2015-05-20 22:02 ` Arnd Bergmann
2015-05-15 15:18 ` [GIT PULL] Broadcom Device Tree " Arnd Bergmann
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.