All of lore.kernel.org
 help / color / mirror / Atom feed
* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-12 13:27 ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-12 13:27 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: Sudeep.KarkadaNagesha, Viresh Kumar, rob.herring, Olof Johansson,
	linux-pm, linux-arm-kernel, linux-kernel

The following changes since commit d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:

  Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)

are available in the git repository at:

  git://linux-arm.org/linux-skn.git cpu_of_node

for you to fetch changes up to 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:

  cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes
(2013-08-12 10:22:29 +0100)

----------------------------------------------------------------
Sudeep KarkadaNagesha (16):
  of: add support for retrieving cpu node for a given logical cpu index
  ARM: DT/kernel: define ARM specific arch_match_cpu_phys_id
  driver/core: cpu: initialize of_node in cpu's device struture
  of/device: add helper to get cpu device node from logical cpu index
  ARM: topology: remove hwid/MPIDR dependency from cpu_capacity
  ARM: mvebu: remove device tree parsing for cpu nodes
  drivers/bus: arm-cci: avoid parsing DT for cpu device nodes
  cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes
  cpufreq: highbank-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: spear-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: arm_big_little: remove device tree parsing for cpu nodes
  cpufreq: maple-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: pmac64-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes

 arch/arm/kernel/devtree.c           |  5 +++++
 arch/arm/kernel/topology.c          | 61
+++++++++++++++++++------------------------------------------
 arch/arm/mach-imx/mach-imx6q.c      |  3 +--
 arch/arm/mach-mvebu/platsmp.c       | 52
++++++++++++++++++++++++----------------------------
 drivers/base/cpu.c                  |  2 ++
 drivers/bus/arm-cci.c               | 28 +++++++---------------------
 drivers/cpufreq/arm_big_little_dt.c | 40
++++++++++++++--------------------------
 drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++-------------------
 drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------
 drivers/cpufreq/imx6q-cpufreq.c     |  4 +---
 drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++---
 drivers/cpufreq/maple-cpufreq.c     | 23 +++--------------------
 drivers/cpufreq/pmac32-cpufreq.c    |  5 +++--
 drivers/cpufreq/pmac64-cpufreq.c    | 47
+++++++++++------------------------------------
 drivers/cpufreq/spear-cpufreq.c     |  4 ++--
 drivers/of/base.c                   | 73
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 include/linux/cpu.h                 |  1 +
 include/linux/of.h                  |  6 ++++++
 include/linux/of_device.h           | 15 +++++++++++++++
 19 files changed, 202 insertions(+), 216 deletions(-)


PS: This patch series is reviewed and acknowledged @

v1: https://lkml.org/lkml/2013/7/15/128
v2: https://lkml.org/lkml/2013/7/17/341
v3: https://lkml.org/lkml/2013/7/22/219



^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-12 13:27 ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-12 13:27 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: Sudeep.KarkadaNagesha, Viresh Kumar, rob.herring, Olof Johansson,
	linux-pm, linux-arm-kernel, linux-kernel

The following changes since commit d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:

  Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)

are available in the git repository at:

  git://linux-arm.org/linux-skn.git cpu_of_node

for you to fetch changes up to 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:

  cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes
(2013-08-12 10:22:29 +0100)

----------------------------------------------------------------
Sudeep KarkadaNagesha (16):
  of: add support for retrieving cpu node for a given logical cpu index
  ARM: DT/kernel: define ARM specific arch_match_cpu_phys_id
  driver/core: cpu: initialize of_node in cpu's device struture
  of/device: add helper to get cpu device node from logical cpu index
  ARM: topology: remove hwid/MPIDR dependency from cpu_capacity
  ARM: mvebu: remove device tree parsing for cpu nodes
  drivers/bus: arm-cci: avoid parsing DT for cpu device nodes
  cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes
  cpufreq: highbank-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: spear-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: arm_big_little: remove device tree parsing for cpu nodes
  cpufreq: maple-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: pmac64-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes

 arch/arm/kernel/devtree.c           |  5 +++++
 arch/arm/kernel/topology.c          | 61
+++++++++++++++++++------------------------------------------
 arch/arm/mach-imx/mach-imx6q.c      |  3 +--
 arch/arm/mach-mvebu/platsmp.c       | 52
++++++++++++++++++++++++----------------------------
 drivers/base/cpu.c                  |  2 ++
 drivers/bus/arm-cci.c               | 28 +++++++---------------------
 drivers/cpufreq/arm_big_little_dt.c | 40
++++++++++++++--------------------------
 drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++-------------------
 drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------
 drivers/cpufreq/imx6q-cpufreq.c     |  4 +---
 drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++---
 drivers/cpufreq/maple-cpufreq.c     | 23 +++--------------------
 drivers/cpufreq/pmac32-cpufreq.c    |  5 +++--
 drivers/cpufreq/pmac64-cpufreq.c    | 47
+++++++++++------------------------------------
 drivers/cpufreq/spear-cpufreq.c     |  4 ++--
 drivers/of/base.c                   | 73
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 include/linux/cpu.h                 |  1 +
 include/linux/of.h                  |  6 ++++++
 include/linux/of_device.h           | 15 +++++++++++++++
 19 files changed, 202 insertions(+), 216 deletions(-)


PS: This patch series is reviewed and acknowledged @

v1: https://lkml.org/lkml/2013/7/15/128
v2: https://lkml.org/lkml/2013/7/17/341
v3: https://lkml.org/lkml/2013/7/22/219

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-12 13:27 ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-12 13:27 UTC (permalink / raw)
  To: linux-arm-kernel

The following changes since commit d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:

  Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)

are available in the git repository at:

  git://linux-arm.org/linux-skn.git cpu_of_node

for you to fetch changes up to 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:

  cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes
(2013-08-12 10:22:29 +0100)

----------------------------------------------------------------
Sudeep KarkadaNagesha (16):
  of: add support for retrieving cpu node for a given logical cpu index
  ARM: DT/kernel: define ARM specific arch_match_cpu_phys_id
  driver/core: cpu: initialize of_node in cpu's device struture
  of/device: add helper to get cpu device node from logical cpu index
  ARM: topology: remove hwid/MPIDR dependency from cpu_capacity
  ARM: mvebu: remove device tree parsing for cpu nodes
  drivers/bus: arm-cci: avoid parsing DT for cpu device nodes
  cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes
  cpufreq: highbank-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: spear-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: arm_big_little: remove device tree parsing for cpu nodes
  cpufreq: maple-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: pmac64-cpufreq: remove device tree parsing for cpu nodes
  cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes

 arch/arm/kernel/devtree.c           |  5 +++++
 arch/arm/kernel/topology.c          | 61
+++++++++++++++++++------------------------------------------
 arch/arm/mach-imx/mach-imx6q.c      |  3 +--
 arch/arm/mach-mvebu/platsmp.c       | 52
++++++++++++++++++++++++----------------------------
 drivers/base/cpu.c                  |  2 ++
 drivers/bus/arm-cci.c               | 28 +++++++---------------------
 drivers/cpufreq/arm_big_little_dt.c | 40
++++++++++++++--------------------------
 drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++-------------------
 drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------
 drivers/cpufreq/imx6q-cpufreq.c     |  4 +---
 drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++---
 drivers/cpufreq/maple-cpufreq.c     | 23 +++--------------------
 drivers/cpufreq/pmac32-cpufreq.c    |  5 +++--
 drivers/cpufreq/pmac64-cpufreq.c    | 47
+++++++++++------------------------------------
 drivers/cpufreq/spear-cpufreq.c     |  4 ++--
 drivers/of/base.c                   | 73
+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 include/linux/cpu.h                 |  1 +
 include/linux/of.h                  |  6 ++++++
 include/linux/of_device.h           | 15 +++++++++++++++
 19 files changed, 202 insertions(+), 216 deletions(-)


PS: This patch series is reviewed and acknowledged @

v1: https://lkml.org/lkml/2013/7/15/128
v2: https://lkml.org/lkml/2013/7/17/341
v3: https://lkml.org/lkml/2013/7/22/219

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-12 13:27 ` Sudeep KarkadaNagesha
  (?)
@ 2013-08-13 13:00   ` Rafael J. Wysocki
  -1 siblings, 0 replies; 79+ messages in thread
From: Rafael J. Wysocki @ 2013-08-13 13:00 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: Viresh Kumar, rob.herring, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel

On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
> The following changes since commit d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
> 
>   Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
> 
> are available in the git repository at:
> 
>   git://linux-arm.org/linux-skn.git cpu_of_node
> 
> for you to fetch changes up to 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
> 
>   cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes
> (2013-08-12 10:22:29 +0100)
> 
> ----------------------------------------------------------------
> Sudeep KarkadaNagesha (16):
>   of: add support for retrieving cpu node for a given logical cpu index
>   ARM: DT/kernel: define ARM specific arch_match_cpu_phys_id
>   driver/core: cpu: initialize of_node in cpu's device struture
>   of/device: add helper to get cpu device node from logical cpu index
>   ARM: topology: remove hwid/MPIDR dependency from cpu_capacity
>   ARM: mvebu: remove device tree parsing for cpu nodes
>   drivers/bus: arm-cci: avoid parsing DT for cpu device nodes
>   cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes
>   cpufreq: highbank-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: spear-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: arm_big_little: remove device tree parsing for cpu nodes
>   cpufreq: maple-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: pmac64-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes
> 
>  arch/arm/kernel/devtree.c           |  5 +++++
>  arch/arm/kernel/topology.c          | 61
> +++++++++++++++++++------------------------------------------
>  arch/arm/mach-imx/mach-imx6q.c      |  3 +--
>  arch/arm/mach-mvebu/platsmp.c       | 52
> ++++++++++++++++++++++++----------------------------
>  drivers/base/cpu.c                  |  2 ++
>  drivers/bus/arm-cci.c               | 28 +++++++---------------------
>  drivers/cpufreq/arm_big_little_dt.c | 40
> ++++++++++++++--------------------------
>  drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++-------------------
>  drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------
>  drivers/cpufreq/imx6q-cpufreq.c     |  4 +---
>  drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++---
>  drivers/cpufreq/maple-cpufreq.c     | 23 +++--------------------
>  drivers/cpufreq/pmac32-cpufreq.c    |  5 +++--
>  drivers/cpufreq/pmac64-cpufreq.c    | 47
> +++++++++++------------------------------------
>  drivers/cpufreq/spear-cpufreq.c     |  4 ++--
>  drivers/of/base.c                   | 73
> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  include/linux/cpu.h                 |  1 +
>  include/linux/of.h                  |  6 ++++++
>  include/linux/of_device.h           | 15 +++++++++++++++
>  19 files changed, 202 insertions(+), 216 deletions(-)
> 
> 
> PS: This patch series is reviewed and acknowledged @
> 
> v1: https://lkml.org/lkml/2013/7/15/128
> v2: https://lkml.org/lkml/2013/7/17/341
> v3: https://lkml.org/lkml/2013/7/22/219

Pulled, thanks!


^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 13:00   ` Rafael J. Wysocki
  0 siblings, 0 replies; 79+ messages in thread
From: Rafael J. Wysocki @ 2013-08-13 13:00 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: Viresh Kumar, rob.herring, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel

On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
> The following changes since commit d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
> 
>   Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
> 
> are available in the git repository at:
> 
>   git://linux-arm.org/linux-skn.git cpu_of_node
> 
> for you to fetch changes up to 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
> 
>   cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes
> (2013-08-12 10:22:29 +0100)
> 
> ----------------------------------------------------------------
> Sudeep KarkadaNagesha (16):
>   of: add support for retrieving cpu node for a given logical cpu index
>   ARM: DT/kernel: define ARM specific arch_match_cpu_phys_id
>   driver/core: cpu: initialize of_node in cpu's device struture
>   of/device: add helper to get cpu device node from logical cpu index
>   ARM: topology: remove hwid/MPIDR dependency from cpu_capacity
>   ARM: mvebu: remove device tree parsing for cpu nodes
>   drivers/bus: arm-cci: avoid parsing DT for cpu device nodes
>   cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes
>   cpufreq: highbank-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: spear-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: arm_big_little: remove device tree parsing for cpu nodes
>   cpufreq: maple-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: pmac64-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes
> 
>  arch/arm/kernel/devtree.c           |  5 +++++
>  arch/arm/kernel/topology.c          | 61
> +++++++++++++++++++------------------------------------------
>  arch/arm/mach-imx/mach-imx6q.c      |  3 +--
>  arch/arm/mach-mvebu/platsmp.c       | 52
> ++++++++++++++++++++++++----------------------------
>  drivers/base/cpu.c                  |  2 ++
>  drivers/bus/arm-cci.c               | 28 +++++++---------------------
>  drivers/cpufreq/arm_big_little_dt.c | 40
> ++++++++++++++--------------------------
>  drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++-------------------
>  drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------
>  drivers/cpufreq/imx6q-cpufreq.c     |  4 +---
>  drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++---
>  drivers/cpufreq/maple-cpufreq.c     | 23 +++--------------------
>  drivers/cpufreq/pmac32-cpufreq.c    |  5 +++--
>  drivers/cpufreq/pmac64-cpufreq.c    | 47
> +++++++++++------------------------------------
>  drivers/cpufreq/spear-cpufreq.c     |  4 ++--
>  drivers/of/base.c                   | 73
> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  include/linux/cpu.h                 |  1 +
>  include/linux/of.h                  |  6 ++++++
>  include/linux/of_device.h           | 15 +++++++++++++++
>  19 files changed, 202 insertions(+), 216 deletions(-)
> 
> 
> PS: This patch series is reviewed and acknowledged @
> 
> v1: https://lkml.org/lkml/2013/7/15/128
> v2: https://lkml.org/lkml/2013/7/17/341
> v3: https://lkml.org/lkml/2013/7/22/219

Pulled, thanks!


^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 13:00   ` Rafael J. Wysocki
  0 siblings, 0 replies; 79+ messages in thread
From: Rafael J. Wysocki @ 2013-08-13 13:00 UTC (permalink / raw)
  To: linux-arm-kernel

On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
> The following changes since commit d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
> 
>   Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
> 
> are available in the git repository at:
> 
>   git://linux-arm.org/linux-skn.git cpu_of_node
> 
> for you to fetch changes up to 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
> 
>   cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes
> (2013-08-12 10:22:29 +0100)
> 
> ----------------------------------------------------------------
> Sudeep KarkadaNagesha (16):
>   of: add support for retrieving cpu node for a given logical cpu index
>   ARM: DT/kernel: define ARM specific arch_match_cpu_phys_id
>   driver/core: cpu: initialize of_node in cpu's device struture
>   of/device: add helper to get cpu device node from logical cpu index
>   ARM: topology: remove hwid/MPIDR dependency from cpu_capacity
>   ARM: mvebu: remove device tree parsing for cpu nodes
>   drivers/bus: arm-cci: avoid parsing DT for cpu device nodes
>   cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes
>   cpufreq: highbank-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: spear-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: arm_big_little: remove device tree parsing for cpu nodes
>   cpufreq: maple-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: pmac64-cpufreq: remove device tree parsing for cpu nodes
>   cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes
> 
>  arch/arm/kernel/devtree.c           |  5 +++++
>  arch/arm/kernel/topology.c          | 61
> +++++++++++++++++++------------------------------------------
>  arch/arm/mach-imx/mach-imx6q.c      |  3 +--
>  arch/arm/mach-mvebu/platsmp.c       | 52
> ++++++++++++++++++++++++----------------------------
>  drivers/base/cpu.c                  |  2 ++
>  drivers/bus/arm-cci.c               | 28 +++++++---------------------
>  drivers/cpufreq/arm_big_little_dt.c | 40
> ++++++++++++++--------------------------
>  drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++-------------------
>  drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------
>  drivers/cpufreq/imx6q-cpufreq.c     |  4 +---
>  drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++---
>  drivers/cpufreq/maple-cpufreq.c     | 23 +++--------------------
>  drivers/cpufreq/pmac32-cpufreq.c    |  5 +++--
>  drivers/cpufreq/pmac64-cpufreq.c    | 47
> +++++++++++------------------------------------
>  drivers/cpufreq/spear-cpufreq.c     |  4 ++--
>  drivers/of/base.c                   | 73
> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>  include/linux/cpu.h                 |  1 +
>  include/linux/of.h                  |  6 ++++++
>  include/linux/of_device.h           | 15 +++++++++++++++
>  19 files changed, 202 insertions(+), 216 deletions(-)
> 
> 
> PS: This patch series is reviewed and acknowledged @
> 
> v1: https://lkml.org/lkml/2013/7/15/128
> v2: https://lkml.org/lkml/2013/7/17/341
> v3: https://lkml.org/lkml/2013/7/22/219

Pulled, thanks!

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 13:00   ` Rafael J. Wysocki
  (?)
  (?)
@ 2013-08-13 15:40     ` Sudeep KarkadaNagesha
  -1 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-13 15:40 UTC (permalink / raw)
  To: Rafael J. Wysocki, rob.herring, Benjamin Herrenschmidt, linuxppc-dev
  Cc: Sudeep KarkadaNagesha, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

Adding PowerPC list

On 13/08/13 14:00, Rafael J. Wysocki wrote:
> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>> The following changes since commit
>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>> 
>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>> 
>> are available in the git repository at:
>> 
>> git://linux-arm.org/linux-skn.git cpu_of_node
>> 
>> for you to fetch changes up to
>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>> 
>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>> (2013-08-12 10:22:29 +0100)
>> 
>> ---------------------------------------------------------------- 
>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>> cpu's device struture of/device: add helper to get cpu device node
>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>> nodes
>> 
>> arch/arm/kernel/devtree.c           |  5 +++++ 
>> arch/arm/kernel/topology.c          | 61 
>> +++++++++++++++++++------------------------------------------ 
>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>> arch/arm/mach-mvebu/platsmp.c       | 52 
>> ++++++++++++++++++++++++---------------------------- 
>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>> | 28 +++++++--------------------- 
>> drivers/cpufreq/arm_big_little_dt.c | 40 
>> ++++++++++++++-------------------------- 
>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>> +++++++++++------------------------------------ 
>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>> | 73 
>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>
>> 
include/linux/cpu.h                 |  1 +
>> include/linux/of.h                  |  6 ++++++ 
>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>> changed, 202 insertions(+), 216 deletions(-)
>> 
>> 
>> PS: This patch series is reviewed and acknowledged @
>> 
>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>> https://lkml.org/lkml/2013/7/17/341 v3:
>> https://lkml.org/lkml/2013/7/22/219
> 
> Pulled, thanks!
> 
Hi Rob, Rafael,

On 13/08/13 15:16, kbuild test robot wrote:> tree:
git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
bleeding-edge
> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
> support for retrieving cpu node for a given logical cpu index
> config: make ARCH=powerpc allmodconfig
> 
> All error/warnings:
> 
> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
> from include/linux/kvm_host.h:30, from
> arch/powerpc/kernel/asm-offsets.c:53:
> include/linux/of.h:269:28: error: conflicting types for
>'of_get_cpu_node'
> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
> included from include/linux/of.h:139:0, from
> arch/powerpc/include/asm/kvm_para.h:26, from
> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
> from include/linux/kvm_host.h:30, from
> arch/powerpc/kernel/asm-offsets.c:53: 
> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
> of 'of_get_cpu_node' was here
> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
> Target `__build' not remade because of errors. make[1]: ***
> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
> errors. make: *** [sub-make] Error 2
> 

There seems to be conflict in the new function "of_get_cpu_node" added.
PowerPC also defines the same function name. Further microblaze and
openrisc declares it(can be removed) but doesn't define it.
To fix this:
1. I can rename the newly added function to something different like
   `of_get_cpunode` or
2. If of_* namespace should be used by only OF/FDT and not by any
   architecture specific code, then the arch specific version can be
   renamed to some thing like arch_of_get_cpu_node.
   Also most of the calls to arch specific function can be moved to
   generic code.

Let me know your thoughts.

Regards,
Sudeep


^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 15:40     ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-13 15:40 UTC (permalink / raw)
  To: Rafael J. Wysocki, rob.herring, Benjamin Herrenschmidt, linuxppc-dev
  Cc: Sudeep KarkadaNagesha, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

Adding PowerPC list

On 13/08/13 14:00, Rafael J. Wysocki wrote:
> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>> The following changes since commit
>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>> 
>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>> 
>> are available in the git repository at:
>> 
>> git://linux-arm.org/linux-skn.git cpu_of_node
>> 
>> for you to fetch changes up to
>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>> 
>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>> (2013-08-12 10:22:29 +0100)
>> 
>> ---------------------------------------------------------------- 
>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>> cpu's device struture of/device: add helper to get cpu device node
>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>> nodes
>> 
>> arch/arm/kernel/devtree.c           |  5 +++++ 
>> arch/arm/kernel/topology.c          | 61 
>> +++++++++++++++++++------------------------------------------ 
>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>> arch/arm/mach-mvebu/platsmp.c       | 52 
>> ++++++++++++++++++++++++---------------------------- 
>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>> | 28 +++++++--------------------- 
>> drivers/cpufreq/arm_big_little_dt.c | 40 
>> ++++++++++++++-------------------------- 
>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>> +++++++++++------------------------------------ 
>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>> | 73 
>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>
>> 
include/linux/cpu.h                 |  1 +
>> include/linux/of.h                  |  6 ++++++ 
>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>> changed, 202 insertions(+), 216 deletions(-)
>> 
>> 
>> PS: This patch series is reviewed and acknowledged @
>> 
>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>> https://lkml.org/lkml/2013/7/17/341 v3:
>> https://lkml.org/lkml/2013/7/22/219
> 
> Pulled, thanks!
> 
Hi Rob, Rafael,

On 13/08/13 15:16, kbuild test robot wrote:> tree:
git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
bleeding-edge
> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
> support for retrieving cpu node for a given logical cpu index
> config: make ARCH=powerpc allmodconfig
> 
> All error/warnings:
> 
> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
> from include/linux/kvm_host.h:30, from
> arch/powerpc/kernel/asm-offsets.c:53:
> include/linux/of.h:269:28: error: conflicting types for
>'of_get_cpu_node'
> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
> included from include/linux/of.h:139:0, from
> arch/powerpc/include/asm/kvm_para.h:26, from
> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
> from include/linux/kvm_host.h:30, from
> arch/powerpc/kernel/asm-offsets.c:53: 
> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
> of 'of_get_cpu_node' was here
> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
> Target `__build' not remade because of errors. make[1]: ***
> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
> errors. make: *** [sub-make] Error 2
> 

There seems to be conflict in the new function "of_get_cpu_node" added.
PowerPC also defines the same function name. Further microblaze and
openrisc declares it(can be removed) but doesn't define it.
To fix this:
1. I can rename the newly added function to something different like
   `of_get_cpunode` or
2. If of_* namespace should be used by only OF/FDT and not by any
   architecture specific code, then the arch specific version can be
   renamed to some thing like arch_of_get_cpu_node.
   Also most of the calls to arch specific function can be moved to
   generic code.

Let me know your thoughts.

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 15:40     ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-13 15:40 UTC (permalink / raw)
  To: Rafael J. Wysocki, rob.herring, Benjamin Herrenschmidt, linuxppc-dev
  Cc: devicetree, linux-pm, Sudeep KarkadaNagesha, Viresh Kumar,
	linux-kernel, Olof Johansson, linux-arm-kernel

Adding PowerPC list

On 13/08/13 14:00, Rafael J. Wysocki wrote:
> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>> The following changes since commit
>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>=20
>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>=20
>> are available in the git repository at:
>>=20
>> git://linux-arm.org/linux-skn.git cpu_of_node
>>=20
>> for you to fetch changes up to
>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>=20
>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes=20
>> (2013-08-12 10:22:29 +0100)
>>=20
>> ----------------------------------------------------------------=20
>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>> cpu's device struture of/device: add helper to get cpu device node
>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes=20
>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes=20
>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes=20
>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>> nodes
>>=20
>> arch/arm/kernel/devtree.c           |  5 +++++=20
>> arch/arm/kernel/topology.c          | 61=20
>> +++++++++++++++++++------------------------------------------=20
>> arch/arm/mach-imx/mach-imx6q.c      |  3 +--=20
>> arch/arm/mach-mvebu/platsmp.c       | 52=20
>> ++++++++++++++++++++++++----------------------------=20
>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>> | 28 +++++++---------------------=20
>> drivers/cpufreq/arm_big_little_dt.c | 40=20
>> ++++++++++++++--------------------------=20
>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++-------------------=20
>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------=20
>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +---=20
>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++---=20
>> drivers/cpufreq/maple-cpufreq.c     | 23 +++--------------------=20
>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++--=20
>> drivers/cpufreq/pmac64-cpufreq.c    | 47=20
>> +++++++++++------------------------------------=20
>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>> | 73=20
>> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++=
+
>>
>>=20
include/linux/cpu.h                 |  1 +
>> include/linux/of.h                  |  6 ++++++=20
>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>> changed, 202 insertions(+), 216 deletions(-)
>>=20
>>=20
>> PS: This patch series is reviewed and acknowledged @
>>=20
>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>> https://lkml.org/lkml/2013/7/17/341 v3:
>> https://lkml.org/lkml/2013/7/22/219
>=20
> Pulled, thanks!
>=20
Hi Rob, Rafael,

On 13/08/13 15:16, kbuild test robot wrote:> tree:
git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
bleeding-edge
> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
> support for retrieving cpu node for a given logical cpu index
> config: make ARCH=3Dpowerpc allmodconfig
>=20
> All error/warnings:
>=20
> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,=20
> from include/linux/kvm_host.h:30, from
> arch/powerpc/kernel/asm-offsets.c:53:
> include/linux/of.h:269:28: error: conflicting types for
>'of_get_cpu_node'
> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
> included from include/linux/of.h:139:0, from
> arch/powerpc/include/asm/kvm_para.h:26, from
> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,=20
> from include/linux/kvm_host.h:30, from
> arch/powerpc/kernel/asm-offsets.c:53:=20
> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
> of 'of_get_cpu_node' was here
> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);=20
> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
> Target `__build' not remade because of errors. make[1]: ***
> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
> errors. make: *** [sub-make] Error 2
>=20

There seems to be conflict in the new function "of_get_cpu_node" added.
PowerPC also defines the same function name. Further microblaze and
openrisc declares it(can be removed) but doesn't define it.
To fix this:
1. I can rename the newly added function to something different like
   `of_get_cpunode` or
2. If of_* namespace should be used by only OF/FDT and not by any
   architecture specific code, then the arch specific version can be
   renamed to some thing like arch_of_get_cpu_node.
   Also most of the calls to arch specific function can be moved to
   generic code.

Let me know your thoughts.

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 15:40     ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-13 15:40 UTC (permalink / raw)
  To: linux-arm-kernel

Adding PowerPC list

On 13/08/13 14:00, Rafael J. Wysocki wrote:
> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>> The following changes since commit
>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>> 
>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>> 
>> are available in the git repository at:
>> 
>> git://linux-arm.org/linux-skn.git cpu_of_node
>> 
>> for you to fetch changes up to
>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>> 
>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>> (2013-08-12 10:22:29 +0100)
>> 
>> ---------------------------------------------------------------- 
>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>> cpu's device struture of/device: add helper to get cpu device node
>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>> nodes
>> 
>> arch/arm/kernel/devtree.c           |  5 +++++ 
>> arch/arm/kernel/topology.c          | 61 
>> +++++++++++++++++++------------------------------------------ 
>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>> arch/arm/mach-mvebu/platsmp.c       | 52 
>> ++++++++++++++++++++++++---------------------------- 
>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>> | 28 +++++++--------------------- 
>> drivers/cpufreq/arm_big_little_dt.c | 40 
>> ++++++++++++++-------------------------- 
>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>> +++++++++++------------------------------------ 
>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>> | 73 
>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>
>> 
include/linux/cpu.h                 |  1 +
>> include/linux/of.h                  |  6 ++++++ 
>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>> changed, 202 insertions(+), 216 deletions(-)
>> 
>> 
>> PS: This patch series is reviewed and acknowledged @
>> 
>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>> https://lkml.org/lkml/2013/7/17/341 v3:
>> https://lkml.org/lkml/2013/7/22/219
> 
> Pulled, thanks!
> 
Hi Rob, Rafael,

On 13/08/13 15:16, kbuild test robot wrote:> tree:
git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
bleeding-edge
> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
> support for retrieving cpu node for a given logical cpu index
> config: make ARCH=powerpc allmodconfig
> 
> All error/warnings:
> 
> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
> from include/linux/kvm_host.h:30, from
> arch/powerpc/kernel/asm-offsets.c:53:
> include/linux/of.h:269:28: error: conflicting types for
>'of_get_cpu_node'
> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
> included from include/linux/of.h:139:0, from
> arch/powerpc/include/asm/kvm_para.h:26, from
> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
> from include/linux/kvm_host.h:30, from
> arch/powerpc/kernel/asm-offsets.c:53: 
> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
> of 'of_get_cpu_node' was here
> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
> Target `__build' not remade because of errors. make[1]: ***
> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
> errors. make: *** [sub-make] Error 2
> 

There seems to be conflict in the new function "of_get_cpu_node" added.
PowerPC also defines the same function name. Further microblaze and
openrisc declares it(can be removed) but doesn't define it.
To fix this:
1. I can rename the newly added function to something different like
   `of_get_cpunode` or
2. If of_* namespace should be used by only OF/FDT and not by any
   architecture specific code, then the arch specific version can be
   renamed to some thing like arch_of_get_cpu_node.
   Also most of the calls to arch specific function can be moved to
   generic code.

Let me know your thoughts.

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 15:40     ` Sudeep KarkadaNagesha
  (?)
  (?)
@ 2013-08-13 18:29       ` Sudeep KarkadaNagesha
  -1 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-13 18:29 UTC (permalink / raw)
  To: Benjamin Herrenschmidt, linuxppc-dev
  Cc: Sudeep KarkadaNagesha, Rafael J. Wysocki, rob.herring,
	Viresh Kumar, Olof Johansson, linux-pm, linux-arm-kernel,
	linux-kernel, devicetree

On 13/08/13 16:40, Sudeep KarkadaNagesha wrote:
> Adding PowerPC list
> 
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>
>>> for you to fetch changes up to
>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>
>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>>> (2013-08-12 10:22:29 +0100)
>>>
>>> ---------------------------------------------------------------- 
>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>> cpu's device struture of/device: add helper to get cpu device node
>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>> nodes
>>>
>>> arch/arm/kernel/devtree.c           |  5 +++++ 
>>> arch/arm/kernel/topology.c          | 61 
>>> +++++++++++++++++++------------------------------------------ 
>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>>> arch/arm/mach-mvebu/platsmp.c       | 52 
>>> ++++++++++++++++++++++++---------------------------- 
>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>> | 28 +++++++--------------------- 
>>> drivers/cpufreq/arm_big_little_dt.c | 40 
>>> ++++++++++++++-------------------------- 
>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>>> +++++++++++------------------------------------ 
>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>> | 73 
>>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>>
>>>
> include/linux/cpu.h                 |  1 +
>>> include/linux/of.h                  |  6 ++++++ 
>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>> changed, 202 insertions(+), 216 deletions(-)
>>>
>>>
>>> PS: This patch series is reviewed and acknowledged @
>>>
>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>> https://lkml.org/lkml/2013/7/22/219
>>
>> Pulled, thanks!
>>
> Hi Rob, Rafael,
> 
> On 13/08/13 15:16, kbuild test robot wrote:> tree:
> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
> bleeding-edge
>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>> support for retrieving cpu node for a given logical cpu index
>> config: make ARCH=powerpc allmodconfig
>>
>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>> 'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53: 
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
> 
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.
> To fix this:
> 1. I can rename the newly added function to something different like
>    `of_get_cpunode` or
> 2. If of_* namespace should be used by only OF/FDT and not by any
>    architecture specific code, then the arch specific version can be
>    renamed to some thing like arch_of_get_cpu_node.
>    Also most of the calls to arch specific function can be moved to
>    generic code.
> 
> Let me know your thoughts.

Hi Benjamin,

I don't understand completely the use of ibm,ppc-interrupt-server#s and
its implications on generic of_get_cpu_node implementation.
I see the PPC specific definition of of_get_cpu_node uses thread id only
in 2 instances. Based on that, I have tried to move all the other
instances to use generic definition.

Let me know if the idea is correct.

---->8--------

diff --git a/arch/powerpc/include/asm/prom.h
b/arch/powerpc/include/asm/prom.h
index 42ee294..b48bbfe 100644
--- a/arch/powerpc/include/asm/prom.h
+++ b/arch/powerpc/include/asm/prom.h
@@ -44,7 +44,7 @@ void of_parse_dma_window(struct device_node *dn, const
void *dma_window_prop,
 extern void kdump_move_device_tree(void);

 /* CPU OF node matching */
-struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
+struct device_node *arch_of_get_cpu_node_by_tid(int cpu, unsigned int
*thread);

 #ifdef CONFIG_NUMA
 extern int of_node_to_nid(struct device_node *device);
diff --git a/arch/powerpc/kernel/cacheinfo.c
b/arch/powerpc/kernel/cacheinfo.c
index 9262cf2..c60eef9 100644
--- a/arch/powerpc/kernel/cacheinfo.c
+++ b/arch/powerpc/kernel/cacheinfo.c
@@ -434,7 +434,7 @@ static struct cache
*cache_chain_instantiate(unsigned int cpu_id)

 	pr_debug("creating cache object(s) for CPU %i\n", cpu_id);

-	cpu_node = of_get_cpu_node(cpu_id, NULL);
+	cpu_node = of_get_cpu_node(cpu_id);
 	WARN_ONCE(!cpu_node, "no OF node found for CPU %i\n", cpu_id);
 	if (!cpu_node)
 		goto out;
@@ -764,7 +764,7 @@ static struct cache *cache_lookup_by_cpu(unsigned
int cpu_id)
 	struct device_node *cpu_node;
 	struct cache *cache;

-	cpu_node = of_get_cpu_node(cpu_id, NULL);
+	cpu_node = of_get_cpu_node(cpu_id);
 	WARN_ONCE(!cpu_node, "no OF node found for CPU %i\n", cpu_id);
 	if (!cpu_node)
 		return NULL;
diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c
index af09e32..fe48a70 100644
--- a/arch/powerpc/kernel/prom.c
+++ b/arch/powerpc/kernel/prom.c
@@ -33,6 +33,7 @@
 #include <linux/irq.h>
 #include <linux/memblock.h>
 #include <linux/of.h>
+#include <linux/cpu.h>

 #include <asm/prom.h>
 #include <asm/rtas.h>
@@ -834,15 +835,23 @@ static int __init prom_reconfig_setup(void)
 __initcall(prom_reconfig_setup);
 #endif

+bool arch_match_cpu_phys_id(int cpu, u64 phys_id)
+{
+	return phys_id == get_hard_smp_processor_id(cpu);
+}
+
 /* Find the device node for a given logical cpu number, also returns
the cpu
  * local thread number (index in ibm,interrupt-server#s) if relevant and
  * asked for (non NULL)
  */
-struct device_node *of_get_cpu_node(int cpu, unsigned int *thread)
+struct device_node *arch_of_get_cpunode_by_tid(int cpu, unsigned int
*thread)
 {
 	int hardid;
 	struct device_node *np;

+	if (thread == NULL)
+		return of_get_cpu_node(cpu);
+
 	hardid = get_hard_smp_processor_id(cpu);

 	for_each_node_by_type(np, "cpu") {
@@ -855,14 +864,9 @@ struct device_node *of_get_cpu_node(int cpu,
unsigned int *thread)
 		intserv = of_get_property(np, "ibm,ppc-interrupt-server#s",
 				&plen);
 		if (intserv == NULL) {
-			const u32 *reg = of_get_property(np, "reg", NULL);
-			if (reg == NULL)
-				continue;
-			if (*reg == hardid) {
-				if (thread)
-					*thread = 0;
-				return np;
-			}
+			np = of_get_cpu_node(cpu);
+			*thread = 0;
+			return np;
 		} else {
 			plen /= sizeof(u32);
 			for (t = 0; t < plen; t++) {
@@ -876,7 +880,6 @@ struct device_node *of_get_cpu_node(int cpu,
unsigned int *thread)
 	}
 	return NULL;
 }
-EXPORT_SYMBOL(of_get_cpu_node);

 #if defined(CONFIG_DEBUG_FS) && defined(DEBUG)
 static struct debugfs_blob_wrapper flat_dt_blob;
diff --git a/arch/powerpc/kernel/smp.c b/arch/powerpc/kernel/smp.c
index 38b0ba6..cc0e3a27 100644
--- a/arch/powerpc/kernel/smp.c
+++ b/arch/powerpc/kernel/smp.c
@@ -560,7 +560,7 @@ int cpu_to_core_id(int cpu)
 	const int *reg;
 	int id = -1;

-	np = of_get_cpu_node(cpu, NULL);
+	np = of_get_cpu_node(cpu);
 	if (!np)
 		goto out;

@@ -598,7 +598,7 @@ static struct device_node *cpu_to_l2cache(int cpu)
 	if (!cpu_present(cpu))
 		return NULL;

-	np = of_get_cpu_node(cpu, NULL);
+	np = of_get_cpu_node(cpu);
 	if (np == NULL)
 		return NULL;

diff --git a/arch/powerpc/mm/numa.c b/arch/powerpc/mm/numa.c
index 5850798..4b06158 100644
--- a/arch/powerpc/mm/numa.c
+++ b/arch/powerpc/mm/numa.c
@@ -520,7 +520,7 @@ static int of_drconf_to_nid_single(struct
of_drconf_cell *drmem,
 static int numa_setup_cpu(unsigned long lcpu)
 {
 	int nid = 0;
-	struct device_node *cpu = of_get_cpu_node(lcpu, NULL);
+	struct device_node *cpu = of_get_cpu_node(lcpu);

 	if (!cpu) {
 		WARN_ON(1);
@@ -699,7 +699,7 @@ static int __init parse_numa_properties(void)
 		struct device_node *cpu;
 		int nid;

-		cpu = of_get_cpu_node(i, NULL);
+		cpu = of_get_cpu_node(i);
 		BUG_ON(!cpu);
 		nid = of_node_to_nid_single(cpu);
 		of_node_put(cpu);
diff --git a/arch/powerpc/platforms/44x/currituck.c
b/arch/powerpc/platforms/44x/currituck.c
index 7f1b71a..84eb64e 100644
--- a/arch/powerpc/platforms/44x/currituck.c
+++ b/arch/powerpc/platforms/44x/currituck.c
@@ -98,7 +98,7 @@ static void smp_ppc47x_setup_cpu(int cpu)

 static int smp_ppc47x_kick_cpu(int cpu)
 {
-	struct device_node *cpunode = of_get_cpu_node(cpu, NULL);
+	struct device_node *cpunode = of_get_cpu_node(cpu);
 	const u64 *spin_table_addr_prop;
 	u32 *spin_table;
 	extern void start_secondary_47x(void);
diff --git a/arch/powerpc/platforms/44x/iss4xx.c
b/arch/powerpc/platforms/44x/iss4xx.c
index 4241bc8..8195456 100644
--- a/arch/powerpc/platforms/44x/iss4xx.c
+++ b/arch/powerpc/platforms/44x/iss4xx.c
@@ -88,7 +88,7 @@ static void smp_iss4xx_setup_cpu(int cpu)

 static int smp_iss4xx_kick_cpu(int cpu)
 {
-	struct device_node *cpunode = of_get_cpu_node(cpu, NULL);
+	struct device_node *cpunode = of_get_cpu_node(cpu);
 	const u64 *spin_table_addr_prop;
 	u32 *spin_table;
 	extern void start_secondary_47x(void);
diff --git a/arch/powerpc/platforms/85xx/smp.c
b/arch/powerpc/platforms/85xx/smp.c
index 5ced4f5..e32c532 100644
--- a/arch/powerpc/platforms/85xx/smp.c
+++ b/arch/powerpc/platforms/85xx/smp.c
@@ -156,7 +156,7 @@ static int smp_85xx_kick_cpu(int nr)

 	pr_debug("smp_85xx_kick_cpu: kick CPU #%d\n", nr);

-	np = of_get_cpu_node(nr, NULL);
+	np = of_get_cpu_node(nr);
 	cpu_rel_addr = of_get_property(np, "cpu-release-addr", NULL);

 	if (cpu_rel_addr == NULL) {
diff --git a/arch/powerpc/platforms/cell/cbe_regs.c
b/arch/powerpc/platforms/cell/cbe_regs.c
index 1428d58..a055b74 100644
--- a/arch/powerpc/platforms/cell/cbe_regs.c
+++ b/arch/powerpc/platforms/cell/cbe_regs.c
@@ -182,7 +182,7 @@ static struct device_node *cbe_get_be_node(int cpu_id)
 			return np;

 		for (i=0; i<len; i++)
-			if (of_find_node_by_phandle(cpu_handle[i]) ==
of_get_cpu_node(cpu_id, NULL))
+			if (of_find_node_by_phandle(cpu_handle[i]) == of_get_cpu_node(cpu_id))
 				return np;
 	}

@@ -240,7 +240,8 @@ void __init cbe_regs_init(void)

 	/* Build local fast map of CPUs */
 	for_each_possible_cpu(i) {
-		cbe_thread_map[i].cpu_node = of_get_cpu_node(i, &thread_id);
+		cbe_thread_map[i].cpu_node =
+				arch_of_get_cpunode_by_tid(i, &thread_id);
 		cbe_thread_map[i].be_node = cbe_get_be_node(i);
 		cbe_thread_map[i].thread_id = thread_id;
 	}
diff --git a/arch/powerpc/platforms/wsp/ics.c
b/arch/powerpc/platforms/wsp/ics.c
index 2d3b1dd..b83bc2e 100644
--- a/arch/powerpc/platforms/wsp/ics.c
+++ b/arch/powerpc/platforms/wsp/ics.c
@@ -137,7 +137,7 @@ void cpus_on_chip(int chip_id, cpumask_t *mask,
cpumask_t *ret)

 	cpumask_clear(ret);
 	for_each_cpu(cpu, mask) {
-		cpu_dn = of_get_cpu_node(cpu, NULL);
+		cpu_dn = of_get_cpu_node(cpu);
 		if (!cpu_dn)
 			continue;

@@ -649,7 +649,7 @@ static void __init wsp_ics_set_default_server(void)
 	u32 hwid;

 	/* Find the server number for the boot cpu. */
-	np = of_get_cpu_node(boot_cpuid, NULL);
+	np = of_get_cpu_node(boot_cpuid);
 	BUG_ON(!np);

 	hwid = get_hard_smp_processor_id(boot_cpuid);
diff --git a/arch/powerpc/platforms/wsp/smp.c
b/arch/powerpc/platforms/wsp/smp.c
index 332a18b..2abe794 100644
--- a/arch/powerpc/platforms/wsp/smp.c
+++ b/arch/powerpc/platforms/wsp/smp.c
@@ -40,7 +40,7 @@ int smp_a2_kick_cpu(int nr)
 	if (nr < 0 || nr >= NR_CPUS)
 		return -ENOENT;

-	np = of_get_cpu_node(nr, &thr_idx);
+	np = arch_of_get_cpunode_by_tid(nr, &thr_idx);
 	if (!np)
 		return -ENODEV;

diff --git a/arch/powerpc/platforms/wsp/wsp.c
b/arch/powerpc/platforms/wsp/wsp.c
index d25cc96..43a17a2 100644
--- a/arch/powerpc/platforms/wsp/wsp.c
+++ b/arch/powerpc/platforms/wsp/wsp.c
@@ -90,7 +90,7 @@ void wsp_halt(void)
 	struct device_node *mine;
 	struct device_node *me;

-	me = of_get_cpu_node(smp_processor_id(), NULL);
+	me = of_get_cpu_node(smp_processor_id());
 	mine = scom_find_parent(me);

 	/* This will halt all the A2s but not power off the chip */
diff --git a/arch/powerpc/sysdev/xics/xics-common.c
b/arch/powerpc/sysdev/xics/xics-common.c
index 9049d9f..d16082f 100644
--- a/arch/powerpc/sysdev/xics/xics-common.c
+++ b/arch/powerpc/sysdev/xics/xics-common.c
@@ -53,7 +53,7 @@ void xics_update_irq_servers(void)
 	u32 hcpuid;

 	/* Find the server numbers for the boot cpu. */
-	np = of_get_cpu_node(boot_cpuid, NULL);
+	np = of_get_cpu_node(boot_cpuid);
 	BUG_ON(!np);

 	hcpuid = get_hard_smp_processor_id(boot_cpuid);
diff --git a/drivers/cpufreq/pasemi-cpufreq.c
b/drivers/cpufreq/pasemi-cpufreq.c
index b704da4..692755f 100644
--- a/drivers/cpufreq/pasemi-cpufreq.c
+++ b/drivers/cpufreq/pasemi-cpufreq.c
@@ -149,7 +149,7 @@ static int pas_cpufreq_cpu_init(struct
cpufreq_policy *policy)
 	struct device_node *cpu, *dn;
 	int err = -ENODEV;

-	cpu = of_get_cpu_node(policy->cpu, NULL);
+	cpu = of_get_cpu_node(policy->cpu);

 	if (!cpu)
 		goto out;
diff --git a/drivers/cpufreq/ppc-corenet-cpufreq.c
b/drivers/cpufreq/ppc-corenet-cpufreq.c
index 3cae452..64fb70a 100644
--- a/drivers/cpufreq/ppc-corenet-cpufreq.c
+++ b/drivers/cpufreq/ppc-corenet-cpufreq.c
@@ -150,7 +150,7 @@ static int corenet_cpufreq_cpu_init(struct
cpufreq_policy *policy)
 	struct cpu_data *data;
 	unsigned int cpu = policy->cpu;

-	np = of_get_cpu_node(cpu, NULL);
+	np = of_get_cpu_node(cpu);
 	if (!np)
 		return -ENODEV;

diff --git a/drivers/cpufreq/ppc_cbe_cpufreq.c
b/drivers/cpufreq/ppc_cbe_cpufreq.c
index 5936f8d..0700445 100644
--- a/drivers/cpufreq/ppc_cbe_cpufreq.c
+++ b/drivers/cpufreq/ppc_cbe_cpufreq.c
@@ -75,7 +75,7 @@ static int cbe_cpufreq_cpu_init(struct cpufreq_policy
*policy)
 	int i, cur_pmode;
 	struct device_node *cpu;

-	cpu = of_get_cpu_node(policy->cpu, NULL);
+	cpu = of_get_cpu_node(policy->cpu);

 	if (!cpu)
 		return -ENODEV;









^ permalink raw reply related	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 18:29       ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-13 18:29 UTC (permalink / raw)
  To: Benjamin Herrenschmidt, linuxppc-dev
  Cc: Sudeep KarkadaNagesha, Rafael J. Wysocki, rob.herring,
	Viresh Kumar, Olof Johansson, linux-pm, linux-arm-kernel,
	linux-kernel, devicetree

On 13/08/13 16:40, Sudeep KarkadaNagesha wrote:
> Adding PowerPC list
> 
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>
>>> for you to fetch changes up to
>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>
>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>>> (2013-08-12 10:22:29 +0100)
>>>
>>> ---------------------------------------------------------------- 
>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>> cpu's device struture of/device: add helper to get cpu device node
>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>> nodes
>>>
>>> arch/arm/kernel/devtree.c           |  5 +++++ 
>>> arch/arm/kernel/topology.c          | 61 
>>> +++++++++++++++++++------------------------------------------ 
>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>>> arch/arm/mach-mvebu/platsmp.c       | 52 
>>> ++++++++++++++++++++++++---------------------------- 
>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>> | 28 +++++++--------------------- 
>>> drivers/cpufreq/arm_big_little_dt.c | 40 
>>> ++++++++++++++-------------------------- 
>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>>> +++++++++++------------------------------------ 
>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>> | 73 
>>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>>
>>>
> include/linux/cpu.h                 |  1 +
>>> include/linux/of.h                  |  6 ++++++ 
>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>> changed, 202 insertions(+), 216 deletions(-)
>>>
>>>
>>> PS: This patch series is reviewed and acknowledged @
>>>
>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>> https://lkml.org/lkml/2013/7/22/219
>>
>> Pulled, thanks!
>>
> Hi Rob, Rafael,
> 
> On 13/08/13 15:16, kbuild test robot wrote:> tree:
> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
> bleeding-edge
>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>> support for retrieving cpu node for a given logical cpu index
>> config: make ARCH=powerpc allmodconfig
>>
>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>> 'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53: 
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
> 
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.
> To fix this:
> 1. I can rename the newly added function to something different like
>    `of_get_cpunode` or
> 2. If of_* namespace should be used by only OF/FDT and not by any
>    architecture specific code, then the arch specific version can be
>    renamed to some thing like arch_of_get_cpu_node.
>    Also most of the calls to arch specific function can be moved to
>    generic code.
> 
> Let me know your thoughts.

Hi Benjamin,

I don't understand completely the use of ibm,ppc-interrupt-server#s and
its implications on generic of_get_cpu_node implementation.
I see the PPC specific definition of of_get_cpu_node uses thread id only
in 2 instances. Based on that, I have tried to move all the other
instances to use generic definition.

Let me know if the idea is correct.

---->8--------

diff --git a/arch/powerpc/include/asm/prom.h
b/arch/powerpc/include/asm/prom.h
index 42ee294..b48bbfe 100644
--- a/arch/powerpc/include/asm/prom.h
+++ b/arch/powerpc/include/asm/prom.h
@@ -44,7 +44,7 @@ void of_parse_dma_window(struct device_node *dn, const
void *dma_window_prop,
 extern void kdump_move_device_tree(void);

 /* CPU OF node matching */
-struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
+struct device_node *arch_of_get_cpu_node_by_tid(int cpu, unsigned int
*thread);

 #ifdef CONFIG_NUMA
 extern int of_node_to_nid(struct device_node *device);
diff --git a/arch/powerpc/kernel/cacheinfo.c
b/arch/powerpc/kernel/cacheinfo.c
index 9262cf2..c60eef9 100644
--- a/arch/powerpc/kernel/cacheinfo.c
+++ b/arch/powerpc/kernel/cacheinfo.c
@@ -434,7 +434,7 @@ static struct cache
*cache_chain_instantiate(unsigned int cpu_id)

 	pr_debug("creating cache object(s) for CPU %i\n", cpu_id);

-	cpu_node = of_get_cpu_node(cpu_id, NULL);
+	cpu_node = of_get_cpu_node(cpu_id);
 	WARN_ONCE(!cpu_node, "no OF node found for CPU %i\n", cpu_id);
 	if (!cpu_node)
 		goto out;
@@ -764,7 +764,7 @@ static struct cache *cache_lookup_by_cpu(unsigned
int cpu_id)
 	struct device_node *cpu_node;
 	struct cache *cache;

-	cpu_node = of_get_cpu_node(cpu_id, NULL);
+	cpu_node = of_get_cpu_node(cpu_id);
 	WARN_ONCE(!cpu_node, "no OF node found for CPU %i\n", cpu_id);
 	if (!cpu_node)
 		return NULL;
diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c
index af09e32..fe48a70 100644
--- a/arch/powerpc/kernel/prom.c
+++ b/arch/powerpc/kernel/prom.c
@@ -33,6 +33,7 @@
 #include <linux/irq.h>
 #include <linux/memblock.h>
 #include <linux/of.h>
+#include <linux/cpu.h>

 #include <asm/prom.h>
 #include <asm/rtas.h>
@@ -834,15 +835,23 @@ static int __init prom_reconfig_setup(void)
 __initcall(prom_reconfig_setup);
 #endif

+bool arch_match_cpu_phys_id(int cpu, u64 phys_id)
+{
+	return phys_id == get_hard_smp_processor_id(cpu);
+}
+
 /* Find the device node for a given logical cpu number, also returns
the cpu
  * local thread number (index in ibm,interrupt-server#s) if relevant and
  * asked for (non NULL)
  */
-struct device_node *of_get_cpu_node(int cpu, unsigned int *thread)
+struct device_node *arch_of_get_cpunode_by_tid(int cpu, unsigned int
*thread)
 {
 	int hardid;
 	struct device_node *np;

+	if (thread == NULL)
+		return of_get_cpu_node(cpu);
+
 	hardid = get_hard_smp_processor_id(cpu);

 	for_each_node_by_type(np, "cpu") {
@@ -855,14 +864,9 @@ struct device_node *of_get_cpu_node(int cpu,
unsigned int *thread)
 		intserv = of_get_property(np, "ibm,ppc-interrupt-server#s",
 				&plen);
 		if (intserv == NULL) {
-			const u32 *reg = of_get_property(np, "reg", NULL);
-			if (reg == NULL)
-				continue;
-			if (*reg == hardid) {
-				if (thread)
-					*thread = 0;
-				return np;
-			}
+			np = of_get_cpu_node(cpu);
+			*thread = 0;
+			return np;
 		} else {
 			plen /= sizeof(u32);
 			for (t = 0; t < plen; t++) {
@@ -876,7 +880,6 @@ struct device_node *of_get_cpu_node(int cpu,
unsigned int *thread)
 	}
 	return NULL;
 }
-EXPORT_SYMBOL(of_get_cpu_node);

 #if defined(CONFIG_DEBUG_FS) && defined(DEBUG)
 static struct debugfs_blob_wrapper flat_dt_blob;
diff --git a/arch/powerpc/kernel/smp.c b/arch/powerpc/kernel/smp.c
index 38b0ba6..cc0e3a27 100644
--- a/arch/powerpc/kernel/smp.c
+++ b/arch/powerpc/kernel/smp.c
@@ -560,7 +560,7 @@ int cpu_to_core_id(int cpu)
 	const int *reg;
 	int id = -1;

-	np = of_get_cpu_node(cpu, NULL);
+	np = of_get_cpu_node(cpu);
 	if (!np)
 		goto out;

@@ -598,7 +598,7 @@ static struct device_node *cpu_to_l2cache(int cpu)
 	if (!cpu_present(cpu))
 		return NULL;

-	np = of_get_cpu_node(cpu, NULL);
+	np = of_get_cpu_node(cpu);
 	if (np == NULL)
 		return NULL;

diff --git a/arch/powerpc/mm/numa.c b/arch/powerpc/mm/numa.c
index 5850798..4b06158 100644
--- a/arch/powerpc/mm/numa.c
+++ b/arch/powerpc/mm/numa.c
@@ -520,7 +520,7 @@ static int of_drconf_to_nid_single(struct
of_drconf_cell *drmem,
 static int numa_setup_cpu(unsigned long lcpu)
 {
 	int nid = 0;
-	struct device_node *cpu = of_get_cpu_node(lcpu, NULL);
+	struct device_node *cpu = of_get_cpu_node(lcpu);

 	if (!cpu) {
 		WARN_ON(1);
@@ -699,7 +699,7 @@ static int __init parse_numa_properties(void)
 		struct device_node *cpu;
 		int nid;

-		cpu = of_get_cpu_node(i, NULL);
+		cpu = of_get_cpu_node(i);
 		BUG_ON(!cpu);
 		nid = of_node_to_nid_single(cpu);
 		of_node_put(cpu);
diff --git a/arch/powerpc/platforms/44x/currituck.c
b/arch/powerpc/platforms/44x/currituck.c
index 7f1b71a..84eb64e 100644
--- a/arch/powerpc/platforms/44x/currituck.c
+++ b/arch/powerpc/platforms/44x/currituck.c
@@ -98,7 +98,7 @@ static void smp_ppc47x_setup_cpu(int cpu)

 static int smp_ppc47x_kick_cpu(int cpu)
 {
-	struct device_node *cpunode = of_get_cpu_node(cpu, NULL);
+	struct device_node *cpunode = of_get_cpu_node(cpu);
 	const u64 *spin_table_addr_prop;
 	u32 *spin_table;
 	extern void start_secondary_47x(void);
diff --git a/arch/powerpc/platforms/44x/iss4xx.c
b/arch/powerpc/platforms/44x/iss4xx.c
index 4241bc8..8195456 100644
--- a/arch/powerpc/platforms/44x/iss4xx.c
+++ b/arch/powerpc/platforms/44x/iss4xx.c
@@ -88,7 +88,7 @@ static void smp_iss4xx_setup_cpu(int cpu)

 static int smp_iss4xx_kick_cpu(int cpu)
 {
-	struct device_node *cpunode = of_get_cpu_node(cpu, NULL);
+	struct device_node *cpunode = of_get_cpu_node(cpu);
 	const u64 *spin_table_addr_prop;
 	u32 *spin_table;
 	extern void start_secondary_47x(void);
diff --git a/arch/powerpc/platforms/85xx/smp.c
b/arch/powerpc/platforms/85xx/smp.c
index 5ced4f5..e32c532 100644
--- a/arch/powerpc/platforms/85xx/smp.c
+++ b/arch/powerpc/platforms/85xx/smp.c
@@ -156,7 +156,7 @@ static int smp_85xx_kick_cpu(int nr)

 	pr_debug("smp_85xx_kick_cpu: kick CPU #%d\n", nr);

-	np = of_get_cpu_node(nr, NULL);
+	np = of_get_cpu_node(nr);
 	cpu_rel_addr = of_get_property(np, "cpu-release-addr", NULL);

 	if (cpu_rel_addr == NULL) {
diff --git a/arch/powerpc/platforms/cell/cbe_regs.c
b/arch/powerpc/platforms/cell/cbe_regs.c
index 1428d58..a055b74 100644
--- a/arch/powerpc/platforms/cell/cbe_regs.c
+++ b/arch/powerpc/platforms/cell/cbe_regs.c
@@ -182,7 +182,7 @@ static struct device_node *cbe_get_be_node(int cpu_id)
 			return np;

 		for (i=0; i<len; i++)
-			if (of_find_node_by_phandle(cpu_handle[i]) ==
of_get_cpu_node(cpu_id, NULL))
+			if (of_find_node_by_phandle(cpu_handle[i]) == of_get_cpu_node(cpu_id))
 				return np;
 	}

@@ -240,7 +240,8 @@ void __init cbe_regs_init(void)

 	/* Build local fast map of CPUs */
 	for_each_possible_cpu(i) {
-		cbe_thread_map[i].cpu_node = of_get_cpu_node(i, &thread_id);
+		cbe_thread_map[i].cpu_node =
+				arch_of_get_cpunode_by_tid(i, &thread_id);
 		cbe_thread_map[i].be_node = cbe_get_be_node(i);
 		cbe_thread_map[i].thread_id = thread_id;
 	}
diff --git a/arch/powerpc/platforms/wsp/ics.c
b/arch/powerpc/platforms/wsp/ics.c
index 2d3b1dd..b83bc2e 100644
--- a/arch/powerpc/platforms/wsp/ics.c
+++ b/arch/powerpc/platforms/wsp/ics.c
@@ -137,7 +137,7 @@ void cpus_on_chip(int chip_id, cpumask_t *mask,
cpumask_t *ret)

 	cpumask_clear(ret);
 	for_each_cpu(cpu, mask) {
-		cpu_dn = of_get_cpu_node(cpu, NULL);
+		cpu_dn = of_get_cpu_node(cpu);
 		if (!cpu_dn)
 			continue;

@@ -649,7 +649,7 @@ static void __init wsp_ics_set_default_server(void)
 	u32 hwid;

 	/* Find the server number for the boot cpu. */
-	np = of_get_cpu_node(boot_cpuid, NULL);
+	np = of_get_cpu_node(boot_cpuid);
 	BUG_ON(!np);

 	hwid = get_hard_smp_processor_id(boot_cpuid);
diff --git a/arch/powerpc/platforms/wsp/smp.c
b/arch/powerpc/platforms/wsp/smp.c
index 332a18b..2abe794 100644
--- a/arch/powerpc/platforms/wsp/smp.c
+++ b/arch/powerpc/platforms/wsp/smp.c
@@ -40,7 +40,7 @@ int smp_a2_kick_cpu(int nr)
 	if (nr < 0 || nr >= NR_CPUS)
 		return -ENOENT;

-	np = of_get_cpu_node(nr, &thr_idx);
+	np = arch_of_get_cpunode_by_tid(nr, &thr_idx);
 	if (!np)
 		return -ENODEV;

diff --git a/arch/powerpc/platforms/wsp/wsp.c
b/arch/powerpc/platforms/wsp/wsp.c
index d25cc96..43a17a2 100644
--- a/arch/powerpc/platforms/wsp/wsp.c
+++ b/arch/powerpc/platforms/wsp/wsp.c
@@ -90,7 +90,7 @@ void wsp_halt(void)
 	struct device_node *mine;
 	struct device_node *me;

-	me = of_get_cpu_node(smp_processor_id(), NULL);
+	me = of_get_cpu_node(smp_processor_id());
 	mine = scom_find_parent(me);

 	/* This will halt all the A2s but not power off the chip */
diff --git a/arch/powerpc/sysdev/xics/xics-common.c
b/arch/powerpc/sysdev/xics/xics-common.c
index 9049d9f..d16082f 100644
--- a/arch/powerpc/sysdev/xics/xics-common.c
+++ b/arch/powerpc/sysdev/xics/xics-common.c
@@ -53,7 +53,7 @@ void xics_update_irq_servers(void)
 	u32 hcpuid;

 	/* Find the server numbers for the boot cpu. */
-	np = of_get_cpu_node(boot_cpuid, NULL);
+	np = of_get_cpu_node(boot_cpuid);
 	BUG_ON(!np);

 	hcpuid = get_hard_smp_processor_id(boot_cpuid);
diff --git a/drivers/cpufreq/pasemi-cpufreq.c
b/drivers/cpufreq/pasemi-cpufreq.c
index b704da4..692755f 100644
--- a/drivers/cpufreq/pasemi-cpufreq.c
+++ b/drivers/cpufreq/pasemi-cpufreq.c
@@ -149,7 +149,7 @@ static int pas_cpufreq_cpu_init(struct
cpufreq_policy *policy)
 	struct device_node *cpu, *dn;
 	int err = -ENODEV;

-	cpu = of_get_cpu_node(policy->cpu, NULL);
+	cpu = of_get_cpu_node(policy->cpu);

 	if (!cpu)
 		goto out;
diff --git a/drivers/cpufreq/ppc-corenet-cpufreq.c
b/drivers/cpufreq/ppc-corenet-cpufreq.c
index 3cae452..64fb70a 100644
--- a/drivers/cpufreq/ppc-corenet-cpufreq.c
+++ b/drivers/cpufreq/ppc-corenet-cpufreq.c
@@ -150,7 +150,7 @@ static int corenet_cpufreq_cpu_init(struct
cpufreq_policy *policy)
 	struct cpu_data *data;
 	unsigned int cpu = policy->cpu;

-	np = of_get_cpu_node(cpu, NULL);
+	np = of_get_cpu_node(cpu);
 	if (!np)
 		return -ENODEV;

diff --git a/drivers/cpufreq/ppc_cbe_cpufreq.c
b/drivers/cpufreq/ppc_cbe_cpufreq.c
index 5936f8d..0700445 100644
--- a/drivers/cpufreq/ppc_cbe_cpufreq.c
+++ b/drivers/cpufreq/ppc_cbe_cpufreq.c
@@ -75,7 +75,7 @@ static int cbe_cpufreq_cpu_init(struct cpufreq_policy
*policy)
 	int i, cur_pmode;
 	struct device_node *cpu;

-	cpu = of_get_cpu_node(policy->cpu, NULL);
+	cpu = of_get_cpu_node(policy->cpu);

 	if (!cpu)
 		return -ENODEV;

^ permalink raw reply related	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 18:29       ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-13 18:29 UTC (permalink / raw)
  To: Benjamin Herrenschmidt, linuxppc-dev
  Cc: devicetree, linux-pm, Sudeep KarkadaNagesha, Viresh Kumar,
	linux-kernel, rob.herring, Rafael J. Wysocki, Olof Johansson,
	linux-arm-kernel

On 13/08/13 16:40, Sudeep KarkadaNagesha wrote:
> Adding PowerPC list
>=20
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>
>>> for you to fetch changes up to
>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>
>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes=20
>>> (2013-08-12 10:22:29 +0100)
>>>
>>> ----------------------------------------------------------------=20
>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>> cpu's device struture of/device: add helper to get cpu device node
>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes=20
>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes=20
>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes=20
>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>> nodes
>>>
>>> arch/arm/kernel/devtree.c           |  5 +++++=20
>>> arch/arm/kernel/topology.c          | 61=20
>>> +++++++++++++++++++------------------------------------------=20
>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +--=20
>>> arch/arm/mach-mvebu/platsmp.c       | 52=20
>>> ++++++++++++++++++++++++----------------------------=20
>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>> | 28 +++++++---------------------=20
>>> drivers/cpufreq/arm_big_little_dt.c | 40=20
>>> ++++++++++++++--------------------------=20
>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++-------------------=20
>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------=20
>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +---=20
>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++---=20
>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++--------------------=20
>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++--=20
>>> drivers/cpufreq/pmac64-cpufreq.c    | 47=20
>>> +++++++++++------------------------------------=20
>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>> | 73=20
>>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++=
++
>>>
>>>
> include/linux/cpu.h                 |  1 +
>>> include/linux/of.h                  |  6 ++++++=20
>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>> changed, 202 insertions(+), 216 deletions(-)
>>>
>>>
>>> PS: This patch series is reviewed and acknowledged @
>>>
>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>> https://lkml.org/lkml/2013/7/22/219
>>
>> Pulled, thanks!
>>
> Hi Rob, Rafael,
>=20
> On 13/08/13 15:16, kbuild test robot wrote:> tree:
> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
> bleeding-edge
>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>> support for retrieving cpu node for a given logical cpu index
>> config: make ARCH=3Dpowerpc allmodconfig
>>
>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,=20
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>> 'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,=20
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:=20
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);=20
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
>=20
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.
> To fix this:
> 1. I can rename the newly added function to something different like
>    `of_get_cpunode` or
> 2. If of_* namespace should be used by only OF/FDT and not by any
>    architecture specific code, then the arch specific version can be
>    renamed to some thing like arch_of_get_cpu_node.
>    Also most of the calls to arch specific function can be moved to
>    generic code.
>=20
> Let me know your thoughts.

Hi Benjamin,

I don't understand completely the use of ibm,ppc-interrupt-server#s and
its implications on generic of_get_cpu_node implementation.
I see the PPC specific definition of of_get_cpu_node uses thread id only
in 2 instances. Based on that, I have tried to move all the other
instances to use generic definition.

Let me know if the idea is correct.

---->8--------

diff --git a/arch/powerpc/include/asm/prom.h
b/arch/powerpc/include/asm/prom.h
index 42ee294..b48bbfe 100644
--- a/arch/powerpc/include/asm/prom.h
+++ b/arch/powerpc/include/asm/prom.h
@@ -44,7 +44,7 @@ void of_parse_dma_window(struct device_node *dn, const
void *dma_window_prop,
 extern void kdump_move_device_tree(void);

 /* CPU OF node matching */
-struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
+struct device_node *arch_of_get_cpu_node_by_tid(int cpu, unsigned int
*thread);

 #ifdef CONFIG_NUMA
 extern int of_node_to_nid(struct device_node *device);
diff --git a/arch/powerpc/kernel/cacheinfo.c
b/arch/powerpc/kernel/cacheinfo.c
index 9262cf2..c60eef9 100644
--- a/arch/powerpc/kernel/cacheinfo.c
+++ b/arch/powerpc/kernel/cacheinfo.c
@@ -434,7 +434,7 @@ static struct cache
*cache_chain_instantiate(unsigned int cpu_id)

 =09pr_debug("creating cache object(s) for CPU %i\n", cpu_id);

-=09cpu_node =3D of_get_cpu_node(cpu_id, NULL);
+=09cpu_node =3D of_get_cpu_node(cpu_id);
 =09WARN_ONCE(!cpu_node, "no OF node found for CPU %i\n", cpu_id);
 =09if (!cpu_node)
 =09=09goto out;
@@ -764,7 +764,7 @@ static struct cache *cache_lookup_by_cpu(unsigned
int cpu_id)
 =09struct device_node *cpu_node;
 =09struct cache *cache;

-=09cpu_node =3D of_get_cpu_node(cpu_id, NULL);
+=09cpu_node =3D of_get_cpu_node(cpu_id);
 =09WARN_ONCE(!cpu_node, "no OF node found for CPU %i\n", cpu_id);
 =09if (!cpu_node)
 =09=09return NULL;
diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c
index af09e32..fe48a70 100644
--- a/arch/powerpc/kernel/prom.c
+++ b/arch/powerpc/kernel/prom.c
@@ -33,6 +33,7 @@
 #include <linux/irq.h>
 #include <linux/memblock.h>
 #include <linux/of.h>
+#include <linux/cpu.h>

 #include <asm/prom.h>
 #include <asm/rtas.h>
@@ -834,15 +835,23 @@ static int __init prom_reconfig_setup(void)
 __initcall(prom_reconfig_setup);
 #endif

+bool arch_match_cpu_phys_id(int cpu, u64 phys_id)
+{
+=09return phys_id =3D=3D get_hard_smp_processor_id(cpu);
+}
+
 /* Find the device node for a given logical cpu number, also returns
the cpu
  * local thread number (index in ibm,interrupt-server#s) if relevant and
  * asked for (non NULL)
  */
-struct device_node *of_get_cpu_node(int cpu, unsigned int *thread)
+struct device_node *arch_of_get_cpunode_by_tid(int cpu, unsigned int
*thread)
 {
 =09int hardid;
 =09struct device_node *np;

+=09if (thread =3D=3D NULL)
+=09=09return of_get_cpu_node(cpu);
+
 =09hardid =3D get_hard_smp_processor_id(cpu);

 =09for_each_node_by_type(np, "cpu") {
@@ -855,14 +864,9 @@ struct device_node *of_get_cpu_node(int cpu,
unsigned int *thread)
 =09=09intserv =3D of_get_property(np, "ibm,ppc-interrupt-server#s",
 =09=09=09=09&plen);
 =09=09if (intserv =3D=3D NULL) {
-=09=09=09const u32 *reg =3D of_get_property(np, "reg", NULL);
-=09=09=09if (reg =3D=3D NULL)
-=09=09=09=09continue;
-=09=09=09if (*reg =3D=3D hardid) {
-=09=09=09=09if (thread)
-=09=09=09=09=09*thread =3D 0;
-=09=09=09=09return np;
-=09=09=09}
+=09=09=09np =3D of_get_cpu_node(cpu);
+=09=09=09*thread =3D 0;
+=09=09=09return np;
 =09=09} else {
 =09=09=09plen /=3D sizeof(u32);
 =09=09=09for (t =3D 0; t < plen; t++) {
@@ -876,7 +880,6 @@ struct device_node *of_get_cpu_node(int cpu,
unsigned int *thread)
 =09}
 =09return NULL;
 }
-EXPORT_SYMBOL(of_get_cpu_node);

 #if defined(CONFIG_DEBUG_FS) && defined(DEBUG)
 static struct debugfs_blob_wrapper flat_dt_blob;
diff --git a/arch/powerpc/kernel/smp.c b/arch/powerpc/kernel/smp.c
index 38b0ba6..cc0e3a27 100644
--- a/arch/powerpc/kernel/smp.c
+++ b/arch/powerpc/kernel/smp.c
@@ -560,7 +560,7 @@ int cpu_to_core_id(int cpu)
 =09const int *reg;
 =09int id =3D -1;

-=09np =3D of_get_cpu_node(cpu, NULL);
+=09np =3D of_get_cpu_node(cpu);
 =09if (!np)
 =09=09goto out;

@@ -598,7 +598,7 @@ static struct device_node *cpu_to_l2cache(int cpu)
 =09if (!cpu_present(cpu))
 =09=09return NULL;

-=09np =3D of_get_cpu_node(cpu, NULL);
+=09np =3D of_get_cpu_node(cpu);
 =09if (np =3D=3D NULL)
 =09=09return NULL;

diff --git a/arch/powerpc/mm/numa.c b/arch/powerpc/mm/numa.c
index 5850798..4b06158 100644
--- a/arch/powerpc/mm/numa.c
+++ b/arch/powerpc/mm/numa.c
@@ -520,7 +520,7 @@ static int of_drconf_to_nid_single(struct
of_drconf_cell *drmem,
 static int numa_setup_cpu(unsigned long lcpu)
 {
 =09int nid =3D 0;
-=09struct device_node *cpu =3D of_get_cpu_node(lcpu, NULL);
+=09struct device_node *cpu =3D of_get_cpu_node(lcpu);

 =09if (!cpu) {
 =09=09WARN_ON(1);
@@ -699,7 +699,7 @@ static int __init parse_numa_properties(void)
 =09=09struct device_node *cpu;
 =09=09int nid;

-=09=09cpu =3D of_get_cpu_node(i, NULL);
+=09=09cpu =3D of_get_cpu_node(i);
 =09=09BUG_ON(!cpu);
 =09=09nid =3D of_node_to_nid_single(cpu);
 =09=09of_node_put(cpu);
diff --git a/arch/powerpc/platforms/44x/currituck.c
b/arch/powerpc/platforms/44x/currituck.c
index 7f1b71a..84eb64e 100644
--- a/arch/powerpc/platforms/44x/currituck.c
+++ b/arch/powerpc/platforms/44x/currituck.c
@@ -98,7 +98,7 @@ static void smp_ppc47x_setup_cpu(int cpu)

 static int smp_ppc47x_kick_cpu(int cpu)
 {
-=09struct device_node *cpunode =3D of_get_cpu_node(cpu, NULL);
+=09struct device_node *cpunode =3D of_get_cpu_node(cpu);
 =09const u64 *spin_table_addr_prop;
 =09u32 *spin_table;
 =09extern void start_secondary_47x(void);
diff --git a/arch/powerpc/platforms/44x/iss4xx.c
b/arch/powerpc/platforms/44x/iss4xx.c
index 4241bc8..8195456 100644
--- a/arch/powerpc/platforms/44x/iss4xx.c
+++ b/arch/powerpc/platforms/44x/iss4xx.c
@@ -88,7 +88,7 @@ static void smp_iss4xx_setup_cpu(int cpu)

 static int smp_iss4xx_kick_cpu(int cpu)
 {
-=09struct device_node *cpunode =3D of_get_cpu_node(cpu, NULL);
+=09struct device_node *cpunode =3D of_get_cpu_node(cpu);
 =09const u64 *spin_table_addr_prop;
 =09u32 *spin_table;
 =09extern void start_secondary_47x(void);
diff --git a/arch/powerpc/platforms/85xx/smp.c
b/arch/powerpc/platforms/85xx/smp.c
index 5ced4f5..e32c532 100644
--- a/arch/powerpc/platforms/85xx/smp.c
+++ b/arch/powerpc/platforms/85xx/smp.c
@@ -156,7 +156,7 @@ static int smp_85xx_kick_cpu(int nr)

 =09pr_debug("smp_85xx_kick_cpu: kick CPU #%d\n", nr);

-=09np =3D of_get_cpu_node(nr, NULL);
+=09np =3D of_get_cpu_node(nr);
 =09cpu_rel_addr =3D of_get_property(np, "cpu-release-addr", NULL);

 =09if (cpu_rel_addr =3D=3D NULL) {
diff --git a/arch/powerpc/platforms/cell/cbe_regs.c
b/arch/powerpc/platforms/cell/cbe_regs.c
index 1428d58..a055b74 100644
--- a/arch/powerpc/platforms/cell/cbe_regs.c
+++ b/arch/powerpc/platforms/cell/cbe_regs.c
@@ -182,7 +182,7 @@ static struct device_node *cbe_get_be_node(int cpu_id)
 =09=09=09return np;

 =09=09for (i=3D0; i<len; i++)
-=09=09=09if (of_find_node_by_phandle(cpu_handle[i]) =3D=3D
of_get_cpu_node(cpu_id, NULL))
+=09=09=09if (of_find_node_by_phandle(cpu_handle[i]) =3D=3D of_get_cpu_node=
(cpu_id))
 =09=09=09=09return np;
 =09}

@@ -240,7 +240,8 @@ void __init cbe_regs_init(void)

 =09/* Build local fast map of CPUs */
 =09for_each_possible_cpu(i) {
-=09=09cbe_thread_map[i].cpu_node =3D of_get_cpu_node(i, &thread_id);
+=09=09cbe_thread_map[i].cpu_node =3D
+=09=09=09=09arch_of_get_cpunode_by_tid(i, &thread_id);
 =09=09cbe_thread_map[i].be_node =3D cbe_get_be_node(i);
 =09=09cbe_thread_map[i].thread_id =3D thread_id;
 =09}
diff --git a/arch/powerpc/platforms/wsp/ics.c
b/arch/powerpc/platforms/wsp/ics.c
index 2d3b1dd..b83bc2e 100644
--- a/arch/powerpc/platforms/wsp/ics.c
+++ b/arch/powerpc/platforms/wsp/ics.c
@@ -137,7 +137,7 @@ void cpus_on_chip(int chip_id, cpumask_t *mask,
cpumask_t *ret)

 =09cpumask_clear(ret);
 =09for_each_cpu(cpu, mask) {
-=09=09cpu_dn =3D of_get_cpu_node(cpu, NULL);
+=09=09cpu_dn =3D of_get_cpu_node(cpu);
 =09=09if (!cpu_dn)
 =09=09=09continue;

@@ -649,7 +649,7 @@ static void __init wsp_ics_set_default_server(void)
 =09u32 hwid;

 =09/* Find the server number for the boot cpu. */
-=09np =3D of_get_cpu_node(boot_cpuid, NULL);
+=09np =3D of_get_cpu_node(boot_cpuid);
 =09BUG_ON(!np);

 =09hwid =3D get_hard_smp_processor_id(boot_cpuid);
diff --git a/arch/powerpc/platforms/wsp/smp.c
b/arch/powerpc/platforms/wsp/smp.c
index 332a18b..2abe794 100644
--- a/arch/powerpc/platforms/wsp/smp.c
+++ b/arch/powerpc/platforms/wsp/smp.c
@@ -40,7 +40,7 @@ int smp_a2_kick_cpu(int nr)
 =09if (nr < 0 || nr >=3D NR_CPUS)
 =09=09return -ENOENT;

-=09np =3D of_get_cpu_node(nr, &thr_idx);
+=09np =3D arch_of_get_cpunode_by_tid(nr, &thr_idx);
 =09if (!np)
 =09=09return -ENODEV;

diff --git a/arch/powerpc/platforms/wsp/wsp.c
b/arch/powerpc/platforms/wsp/wsp.c
index d25cc96..43a17a2 100644
--- a/arch/powerpc/platforms/wsp/wsp.c
+++ b/arch/powerpc/platforms/wsp/wsp.c
@@ -90,7 +90,7 @@ void wsp_halt(void)
 =09struct device_node *mine;
 =09struct device_node *me;

-=09me =3D of_get_cpu_node(smp_processor_id(), NULL);
+=09me =3D of_get_cpu_node(smp_processor_id());
 =09mine =3D scom_find_parent(me);

 =09/* This will halt all the A2s but not power off the chip */
diff --git a/arch/powerpc/sysdev/xics/xics-common.c
b/arch/powerpc/sysdev/xics/xics-common.c
index 9049d9f..d16082f 100644
--- a/arch/powerpc/sysdev/xics/xics-common.c
+++ b/arch/powerpc/sysdev/xics/xics-common.c
@@ -53,7 +53,7 @@ void xics_update_irq_servers(void)
 =09u32 hcpuid;

 =09/* Find the server numbers for the boot cpu. */
-=09np =3D of_get_cpu_node(boot_cpuid, NULL);
+=09np =3D of_get_cpu_node(boot_cpuid);
 =09BUG_ON(!np);

 =09hcpuid =3D get_hard_smp_processor_id(boot_cpuid);
diff --git a/drivers/cpufreq/pasemi-cpufreq.c
b/drivers/cpufreq/pasemi-cpufreq.c
index b704da4..692755f 100644
--- a/drivers/cpufreq/pasemi-cpufreq.c
+++ b/drivers/cpufreq/pasemi-cpufreq.c
@@ -149,7 +149,7 @@ static int pas_cpufreq_cpu_init(struct
cpufreq_policy *policy)
 =09struct device_node *cpu, *dn;
 =09int err =3D -ENODEV;

-=09cpu =3D of_get_cpu_node(policy->cpu, NULL);
+=09cpu =3D of_get_cpu_node(policy->cpu);

 =09if (!cpu)
 =09=09goto out;
diff --git a/drivers/cpufreq/ppc-corenet-cpufreq.c
b/drivers/cpufreq/ppc-corenet-cpufreq.c
index 3cae452..64fb70a 100644
--- a/drivers/cpufreq/ppc-corenet-cpufreq.c
+++ b/drivers/cpufreq/ppc-corenet-cpufreq.c
@@ -150,7 +150,7 @@ static int corenet_cpufreq_cpu_init(struct
cpufreq_policy *policy)
 =09struct cpu_data *data;
 =09unsigned int cpu =3D policy->cpu;

-=09np =3D of_get_cpu_node(cpu, NULL);
+=09np =3D of_get_cpu_node(cpu);
 =09if (!np)
 =09=09return -ENODEV;

diff --git a/drivers/cpufreq/ppc_cbe_cpufreq.c
b/drivers/cpufreq/ppc_cbe_cpufreq.c
index 5936f8d..0700445 100644
--- a/drivers/cpufreq/ppc_cbe_cpufreq.c
+++ b/drivers/cpufreq/ppc_cbe_cpufreq.c
@@ -75,7 +75,7 @@ static int cbe_cpufreq_cpu_init(struct cpufreq_policy
*policy)
 =09int i, cur_pmode;
 =09struct device_node *cpu;

-=09cpu =3D of_get_cpu_node(policy->cpu, NULL);
+=09cpu =3D of_get_cpu_node(policy->cpu);

 =09if (!cpu)
 =09=09return -ENODEV;

^ permalink raw reply related	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 18:29       ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-13 18:29 UTC (permalink / raw)
  To: linux-arm-kernel

On 13/08/13 16:40, Sudeep KarkadaNagesha wrote:
> Adding PowerPC list
> 
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>
>>> for you to fetch changes up to
>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>
>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>>> (2013-08-12 10:22:29 +0100)
>>>
>>> ---------------------------------------------------------------- 
>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>> cpu's device struture of/device: add helper to get cpu device node
>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>> nodes
>>>
>>> arch/arm/kernel/devtree.c           |  5 +++++ 
>>> arch/arm/kernel/topology.c          | 61 
>>> +++++++++++++++++++------------------------------------------ 
>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>>> arch/arm/mach-mvebu/platsmp.c       | 52 
>>> ++++++++++++++++++++++++---------------------------- 
>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>> | 28 +++++++--------------------- 
>>> drivers/cpufreq/arm_big_little_dt.c | 40 
>>> ++++++++++++++-------------------------- 
>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>>> +++++++++++------------------------------------ 
>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>> | 73 
>>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>>
>>>
> include/linux/cpu.h                 |  1 +
>>> include/linux/of.h                  |  6 ++++++ 
>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>> changed, 202 insertions(+), 216 deletions(-)
>>>
>>>
>>> PS: This patch series is reviewed and acknowledged @
>>>
>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>> https://lkml.org/lkml/2013/7/22/219
>>
>> Pulled, thanks!
>>
> Hi Rob, Rafael,
> 
> On 13/08/13 15:16, kbuild test robot wrote:> tree:
> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
> bleeding-edge
>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>> support for retrieving cpu node for a given logical cpu index
>> config: make ARCH=powerpc allmodconfig
>>
>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>> 'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53: 
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
> 
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.
> To fix this:
> 1. I can rename the newly added function to something different like
>    `of_get_cpunode` or
> 2. If of_* namespace should be used by only OF/FDT and not by any
>    architecture specific code, then the arch specific version can be
>    renamed to some thing like arch_of_get_cpu_node.
>    Also most of the calls to arch specific function can be moved to
>    generic code.
> 
> Let me know your thoughts.

Hi Benjamin,

I don't understand completely the use of ibm,ppc-interrupt-server#s and
its implications on generic of_get_cpu_node implementation.
I see the PPC specific definition of of_get_cpu_node uses thread id only
in 2 instances. Based on that, I have tried to move all the other
instances to use generic definition.

Let me know if the idea is correct.

---->8--------

diff --git a/arch/powerpc/include/asm/prom.h
b/arch/powerpc/include/asm/prom.h
index 42ee294..b48bbfe 100644
--- a/arch/powerpc/include/asm/prom.h
+++ b/arch/powerpc/include/asm/prom.h
@@ -44,7 +44,7 @@ void of_parse_dma_window(struct device_node *dn, const
void *dma_window_prop,
 extern void kdump_move_device_tree(void);

 /* CPU OF node matching */
-struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
+struct device_node *arch_of_get_cpu_node_by_tid(int cpu, unsigned int
*thread);

 #ifdef CONFIG_NUMA
 extern int of_node_to_nid(struct device_node *device);
diff --git a/arch/powerpc/kernel/cacheinfo.c
b/arch/powerpc/kernel/cacheinfo.c
index 9262cf2..c60eef9 100644
--- a/arch/powerpc/kernel/cacheinfo.c
+++ b/arch/powerpc/kernel/cacheinfo.c
@@ -434,7 +434,7 @@ static struct cache
*cache_chain_instantiate(unsigned int cpu_id)

 	pr_debug("creating cache object(s) for CPU %i\n", cpu_id);

-	cpu_node = of_get_cpu_node(cpu_id, NULL);
+	cpu_node = of_get_cpu_node(cpu_id);
 	WARN_ONCE(!cpu_node, "no OF node found for CPU %i\n", cpu_id);
 	if (!cpu_node)
 		goto out;
@@ -764,7 +764,7 @@ static struct cache *cache_lookup_by_cpu(unsigned
int cpu_id)
 	struct device_node *cpu_node;
 	struct cache *cache;

-	cpu_node = of_get_cpu_node(cpu_id, NULL);
+	cpu_node = of_get_cpu_node(cpu_id);
 	WARN_ONCE(!cpu_node, "no OF node found for CPU %i\n", cpu_id);
 	if (!cpu_node)
 		return NULL;
diff --git a/arch/powerpc/kernel/prom.c b/arch/powerpc/kernel/prom.c
index af09e32..fe48a70 100644
--- a/arch/powerpc/kernel/prom.c
+++ b/arch/powerpc/kernel/prom.c
@@ -33,6 +33,7 @@
 #include <linux/irq.h>
 #include <linux/memblock.h>
 #include <linux/of.h>
+#include <linux/cpu.h>

 #include <asm/prom.h>
 #include <asm/rtas.h>
@@ -834,15 +835,23 @@ static int __init prom_reconfig_setup(void)
 __initcall(prom_reconfig_setup);
 #endif

+bool arch_match_cpu_phys_id(int cpu, u64 phys_id)
+{
+	return phys_id == get_hard_smp_processor_id(cpu);
+}
+
 /* Find the device node for a given logical cpu number, also returns
the cpu
  * local thread number (index in ibm,interrupt-server#s) if relevant and
  * asked for (non NULL)
  */
-struct device_node *of_get_cpu_node(int cpu, unsigned int *thread)
+struct device_node *arch_of_get_cpunode_by_tid(int cpu, unsigned int
*thread)
 {
 	int hardid;
 	struct device_node *np;

+	if (thread == NULL)
+		return of_get_cpu_node(cpu);
+
 	hardid = get_hard_smp_processor_id(cpu);

 	for_each_node_by_type(np, "cpu") {
@@ -855,14 +864,9 @@ struct device_node *of_get_cpu_node(int cpu,
unsigned int *thread)
 		intserv = of_get_property(np, "ibm,ppc-interrupt-server#s",
 				&plen);
 		if (intserv == NULL) {
-			const u32 *reg = of_get_property(np, "reg", NULL);
-			if (reg == NULL)
-				continue;
-			if (*reg == hardid) {
-				if (thread)
-					*thread = 0;
-				return np;
-			}
+			np = of_get_cpu_node(cpu);
+			*thread = 0;
+			return np;
 		} else {
 			plen /= sizeof(u32);
 			for (t = 0; t < plen; t++) {
@@ -876,7 +880,6 @@ struct device_node *of_get_cpu_node(int cpu,
unsigned int *thread)
 	}
 	return NULL;
 }
-EXPORT_SYMBOL(of_get_cpu_node);

 #if defined(CONFIG_DEBUG_FS) && defined(DEBUG)
 static struct debugfs_blob_wrapper flat_dt_blob;
diff --git a/arch/powerpc/kernel/smp.c b/arch/powerpc/kernel/smp.c
index 38b0ba6..cc0e3a27 100644
--- a/arch/powerpc/kernel/smp.c
+++ b/arch/powerpc/kernel/smp.c
@@ -560,7 +560,7 @@ int cpu_to_core_id(int cpu)
 	const int *reg;
 	int id = -1;

-	np = of_get_cpu_node(cpu, NULL);
+	np = of_get_cpu_node(cpu);
 	if (!np)
 		goto out;

@@ -598,7 +598,7 @@ static struct device_node *cpu_to_l2cache(int cpu)
 	if (!cpu_present(cpu))
 		return NULL;

-	np = of_get_cpu_node(cpu, NULL);
+	np = of_get_cpu_node(cpu);
 	if (np == NULL)
 		return NULL;

diff --git a/arch/powerpc/mm/numa.c b/arch/powerpc/mm/numa.c
index 5850798..4b06158 100644
--- a/arch/powerpc/mm/numa.c
+++ b/arch/powerpc/mm/numa.c
@@ -520,7 +520,7 @@ static int of_drconf_to_nid_single(struct
of_drconf_cell *drmem,
 static int numa_setup_cpu(unsigned long lcpu)
 {
 	int nid = 0;
-	struct device_node *cpu = of_get_cpu_node(lcpu, NULL);
+	struct device_node *cpu = of_get_cpu_node(lcpu);

 	if (!cpu) {
 		WARN_ON(1);
@@ -699,7 +699,7 @@ static int __init parse_numa_properties(void)
 		struct device_node *cpu;
 		int nid;

-		cpu = of_get_cpu_node(i, NULL);
+		cpu = of_get_cpu_node(i);
 		BUG_ON(!cpu);
 		nid = of_node_to_nid_single(cpu);
 		of_node_put(cpu);
diff --git a/arch/powerpc/platforms/44x/currituck.c
b/arch/powerpc/platforms/44x/currituck.c
index 7f1b71a..84eb64e 100644
--- a/arch/powerpc/platforms/44x/currituck.c
+++ b/arch/powerpc/platforms/44x/currituck.c
@@ -98,7 +98,7 @@ static void smp_ppc47x_setup_cpu(int cpu)

 static int smp_ppc47x_kick_cpu(int cpu)
 {
-	struct device_node *cpunode = of_get_cpu_node(cpu, NULL);
+	struct device_node *cpunode = of_get_cpu_node(cpu);
 	const u64 *spin_table_addr_prop;
 	u32 *spin_table;
 	extern void start_secondary_47x(void);
diff --git a/arch/powerpc/platforms/44x/iss4xx.c
b/arch/powerpc/platforms/44x/iss4xx.c
index 4241bc8..8195456 100644
--- a/arch/powerpc/platforms/44x/iss4xx.c
+++ b/arch/powerpc/platforms/44x/iss4xx.c
@@ -88,7 +88,7 @@ static void smp_iss4xx_setup_cpu(int cpu)

 static int smp_iss4xx_kick_cpu(int cpu)
 {
-	struct device_node *cpunode = of_get_cpu_node(cpu, NULL);
+	struct device_node *cpunode = of_get_cpu_node(cpu);
 	const u64 *spin_table_addr_prop;
 	u32 *spin_table;
 	extern void start_secondary_47x(void);
diff --git a/arch/powerpc/platforms/85xx/smp.c
b/arch/powerpc/platforms/85xx/smp.c
index 5ced4f5..e32c532 100644
--- a/arch/powerpc/platforms/85xx/smp.c
+++ b/arch/powerpc/platforms/85xx/smp.c
@@ -156,7 +156,7 @@ static int smp_85xx_kick_cpu(int nr)

 	pr_debug("smp_85xx_kick_cpu: kick CPU #%d\n", nr);

-	np = of_get_cpu_node(nr, NULL);
+	np = of_get_cpu_node(nr);
 	cpu_rel_addr = of_get_property(np, "cpu-release-addr", NULL);

 	if (cpu_rel_addr == NULL) {
diff --git a/arch/powerpc/platforms/cell/cbe_regs.c
b/arch/powerpc/platforms/cell/cbe_regs.c
index 1428d58..a055b74 100644
--- a/arch/powerpc/platforms/cell/cbe_regs.c
+++ b/arch/powerpc/platforms/cell/cbe_regs.c
@@ -182,7 +182,7 @@ static struct device_node *cbe_get_be_node(int cpu_id)
 			return np;

 		for (i=0; i<len; i++)
-			if (of_find_node_by_phandle(cpu_handle[i]) ==
of_get_cpu_node(cpu_id, NULL))
+			if (of_find_node_by_phandle(cpu_handle[i]) == of_get_cpu_node(cpu_id))
 				return np;
 	}

@@ -240,7 +240,8 @@ void __init cbe_regs_init(void)

 	/* Build local fast map of CPUs */
 	for_each_possible_cpu(i) {
-		cbe_thread_map[i].cpu_node = of_get_cpu_node(i, &thread_id);
+		cbe_thread_map[i].cpu_node =
+				arch_of_get_cpunode_by_tid(i, &thread_id);
 		cbe_thread_map[i].be_node = cbe_get_be_node(i);
 		cbe_thread_map[i].thread_id = thread_id;
 	}
diff --git a/arch/powerpc/platforms/wsp/ics.c
b/arch/powerpc/platforms/wsp/ics.c
index 2d3b1dd..b83bc2e 100644
--- a/arch/powerpc/platforms/wsp/ics.c
+++ b/arch/powerpc/platforms/wsp/ics.c
@@ -137,7 +137,7 @@ void cpus_on_chip(int chip_id, cpumask_t *mask,
cpumask_t *ret)

 	cpumask_clear(ret);
 	for_each_cpu(cpu, mask) {
-		cpu_dn = of_get_cpu_node(cpu, NULL);
+		cpu_dn = of_get_cpu_node(cpu);
 		if (!cpu_dn)
 			continue;

@@ -649,7 +649,7 @@ static void __init wsp_ics_set_default_server(void)
 	u32 hwid;

 	/* Find the server number for the boot cpu. */
-	np = of_get_cpu_node(boot_cpuid, NULL);
+	np = of_get_cpu_node(boot_cpuid);
 	BUG_ON(!np);

 	hwid = get_hard_smp_processor_id(boot_cpuid);
diff --git a/arch/powerpc/platforms/wsp/smp.c
b/arch/powerpc/platforms/wsp/smp.c
index 332a18b..2abe794 100644
--- a/arch/powerpc/platforms/wsp/smp.c
+++ b/arch/powerpc/platforms/wsp/smp.c
@@ -40,7 +40,7 @@ int smp_a2_kick_cpu(int nr)
 	if (nr < 0 || nr >= NR_CPUS)
 		return -ENOENT;

-	np = of_get_cpu_node(nr, &thr_idx);
+	np = arch_of_get_cpunode_by_tid(nr, &thr_idx);
 	if (!np)
 		return -ENODEV;

diff --git a/arch/powerpc/platforms/wsp/wsp.c
b/arch/powerpc/platforms/wsp/wsp.c
index d25cc96..43a17a2 100644
--- a/arch/powerpc/platforms/wsp/wsp.c
+++ b/arch/powerpc/platforms/wsp/wsp.c
@@ -90,7 +90,7 @@ void wsp_halt(void)
 	struct device_node *mine;
 	struct device_node *me;

-	me = of_get_cpu_node(smp_processor_id(), NULL);
+	me = of_get_cpu_node(smp_processor_id());
 	mine = scom_find_parent(me);

 	/* This will halt all the A2s but not power off the chip */
diff --git a/arch/powerpc/sysdev/xics/xics-common.c
b/arch/powerpc/sysdev/xics/xics-common.c
index 9049d9f..d16082f 100644
--- a/arch/powerpc/sysdev/xics/xics-common.c
+++ b/arch/powerpc/sysdev/xics/xics-common.c
@@ -53,7 +53,7 @@ void xics_update_irq_servers(void)
 	u32 hcpuid;

 	/* Find the server numbers for the boot cpu. */
-	np = of_get_cpu_node(boot_cpuid, NULL);
+	np = of_get_cpu_node(boot_cpuid);
 	BUG_ON(!np);

 	hcpuid = get_hard_smp_processor_id(boot_cpuid);
diff --git a/drivers/cpufreq/pasemi-cpufreq.c
b/drivers/cpufreq/pasemi-cpufreq.c
index b704da4..692755f 100644
--- a/drivers/cpufreq/pasemi-cpufreq.c
+++ b/drivers/cpufreq/pasemi-cpufreq.c
@@ -149,7 +149,7 @@ static int pas_cpufreq_cpu_init(struct
cpufreq_policy *policy)
 	struct device_node *cpu, *dn;
 	int err = -ENODEV;

-	cpu = of_get_cpu_node(policy->cpu, NULL);
+	cpu = of_get_cpu_node(policy->cpu);

 	if (!cpu)
 		goto out;
diff --git a/drivers/cpufreq/ppc-corenet-cpufreq.c
b/drivers/cpufreq/ppc-corenet-cpufreq.c
index 3cae452..64fb70a 100644
--- a/drivers/cpufreq/ppc-corenet-cpufreq.c
+++ b/drivers/cpufreq/ppc-corenet-cpufreq.c
@@ -150,7 +150,7 @@ static int corenet_cpufreq_cpu_init(struct
cpufreq_policy *policy)
 	struct cpu_data *data;
 	unsigned int cpu = policy->cpu;

-	np = of_get_cpu_node(cpu, NULL);
+	np = of_get_cpu_node(cpu);
 	if (!np)
 		return -ENODEV;

diff --git a/drivers/cpufreq/ppc_cbe_cpufreq.c
b/drivers/cpufreq/ppc_cbe_cpufreq.c
index 5936f8d..0700445 100644
--- a/drivers/cpufreq/ppc_cbe_cpufreq.c
+++ b/drivers/cpufreq/ppc_cbe_cpufreq.c
@@ -75,7 +75,7 @@ static int cbe_cpufreq_cpu_init(struct cpufreq_policy
*policy)
 	int i, cur_pmode;
 	struct device_node *cpu;

-	cpu = of_get_cpu_node(policy->cpu, NULL);
+	cpu = of_get_cpu_node(policy->cpu);

 	if (!cpu)
 		return -ENODEV;

^ permalink raw reply related	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 15:40     ` Sudeep KarkadaNagesha
  (?)
  (?)
@ 2013-08-13 18:37       ` Michal Simek
  -1 siblings, 0 replies; 79+ messages in thread
From: Michal Simek @ 2013-08-13 18:37 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: Rafael J. Wysocki, rob.herring, Benjamin Herrenschmidt,
	linuxppc-dev, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

[-- Attachment #1: Type: text/plain, Size: 5976 bytes --]

On 08/13/2013 05:40 PM, Sudeep KarkadaNagesha wrote:
> Adding PowerPC list
> 
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>
>>> for you to fetch changes up to
>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>
>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>>> (2013-08-12 10:22:29 +0100)
>>>
>>> ---------------------------------------------------------------- 
>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>> cpu's device struture of/device: add helper to get cpu device node
>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>> nodes
>>>
>>> arch/arm/kernel/devtree.c           |  5 +++++ 
>>> arch/arm/kernel/topology.c          | 61 
>>> +++++++++++++++++++------------------------------------------ 
>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>>> arch/arm/mach-mvebu/platsmp.c       | 52 
>>> ++++++++++++++++++++++++---------------------------- 
>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>> | 28 +++++++--------------------- 
>>> drivers/cpufreq/arm_big_little_dt.c | 40 
>>> ++++++++++++++-------------------------- 
>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>>> +++++++++++------------------------------------ 
>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>> | 73 
>>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>>
>>>
> include/linux/cpu.h                 |  1 +
>>> include/linux/of.h                  |  6 ++++++ 
>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>> changed, 202 insertions(+), 216 deletions(-)
>>>
>>>
>>> PS: This patch series is reviewed and acknowledged @
>>>
>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>> https://lkml.org/lkml/2013/7/22/219
>>
>> Pulled, thanks!
>>
> Hi Rob, Rafael,
> 
> On 13/08/13 15:16, kbuild test robot wrote:> tree:
> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
> bleeding-edge
>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>> support for retrieving cpu node for a given logical cpu index
>> config: make ARCH=powerpc allmodconfig
>>
>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>> 'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53: 
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
> 
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.

Feel free to remove it for Microblaze.
There was probably any reason why it was there.
Or maybe no reason and it was just there because Microblaze
was based on powerpc code.

Thanks,
Michal

-- 
Michal Simek, Ing. (M.Eng), OpenPGP -> KeyID: FE3D1F91
w: www.monstr.eu p: +42-0-721842854
Maintainer of Linux kernel - Microblaze cpu - http://www.monstr.eu/fdt/
Maintainer of Linux kernel - Xilinx Zynq ARM architecture
Microblaze U-BOOT custodian and responsible for u-boot arm zynq platform



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 263 bytes --]

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 18:37       ` Michal Simek
  0 siblings, 0 replies; 79+ messages in thread
From: Michal Simek @ 2013-08-13 18:37 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: Rafael J. Wysocki, rob.herring, Benjamin Herrenschmidt,
	linuxppc-dev, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

[-- Attachment #1: Type: text/plain, Size: 5976 bytes --]

On 08/13/2013 05:40 PM, Sudeep KarkadaNagesha wrote:
> Adding PowerPC list
> 
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>
>>> for you to fetch changes up to
>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>
>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>>> (2013-08-12 10:22:29 +0100)
>>>
>>> ---------------------------------------------------------------- 
>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>> cpu's device struture of/device: add helper to get cpu device node
>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>> nodes
>>>
>>> arch/arm/kernel/devtree.c           |  5 +++++ 
>>> arch/arm/kernel/topology.c          | 61 
>>> +++++++++++++++++++------------------------------------------ 
>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>>> arch/arm/mach-mvebu/platsmp.c       | 52 
>>> ++++++++++++++++++++++++---------------------------- 
>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>> | 28 +++++++--------------------- 
>>> drivers/cpufreq/arm_big_little_dt.c | 40 
>>> ++++++++++++++-------------------------- 
>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>>> +++++++++++------------------------------------ 
>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>> | 73 
>>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>>
>>>
> include/linux/cpu.h                 |  1 +
>>> include/linux/of.h                  |  6 ++++++ 
>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>> changed, 202 insertions(+), 216 deletions(-)
>>>
>>>
>>> PS: This patch series is reviewed and acknowledged @
>>>
>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>> https://lkml.org/lkml/2013/7/22/219
>>
>> Pulled, thanks!
>>
> Hi Rob, Rafael,
> 
> On 13/08/13 15:16, kbuild test robot wrote:> tree:
> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
> bleeding-edge
>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>> support for retrieving cpu node for a given logical cpu index
>> config: make ARCH=powerpc allmodconfig
>>
>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>> 'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53: 
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
> 
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.

Feel free to remove it for Microblaze.
There was probably any reason why it was there.
Or maybe no reason and it was just there because Microblaze
was based on powerpc code.

Thanks,
Michal

-- 
Michal Simek, Ing. (M.Eng), OpenPGP -> KeyID: FE3D1F91
w: www.monstr.eu p: +42-0-721842854
Maintainer of Linux kernel - Microblaze cpu - http://www.monstr.eu/fdt/
Maintainer of Linux kernel - Xilinx Zynq ARM architecture
Microblaze U-BOOT custodian and responsible for u-boot arm zynq platform



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 263 bytes --]

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 18:37       ` Michal Simek
  0 siblings, 0 replies; 79+ messages in thread
From: Michal Simek @ 2013-08-13 18:37 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: devicetree, linux-pm, linux-kernel, rob.herring,
	Rafael J. Wysocki, Viresh Kumar, Olof Johansson, linuxppc-dev,
	linux-arm-kernel

[-- Attachment #1: Type: text/plain, Size: 5976 bytes --]

On 08/13/2013 05:40 PM, Sudeep KarkadaNagesha wrote:
> Adding PowerPC list
> 
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>
>>> for you to fetch changes up to
>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>
>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>>> (2013-08-12 10:22:29 +0100)
>>>
>>> ---------------------------------------------------------------- 
>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>> cpu's device struture of/device: add helper to get cpu device node
>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>> nodes
>>>
>>> arch/arm/kernel/devtree.c           |  5 +++++ 
>>> arch/arm/kernel/topology.c          | 61 
>>> +++++++++++++++++++------------------------------------------ 
>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>>> arch/arm/mach-mvebu/platsmp.c       | 52 
>>> ++++++++++++++++++++++++---------------------------- 
>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>> | 28 +++++++--------------------- 
>>> drivers/cpufreq/arm_big_little_dt.c | 40 
>>> ++++++++++++++-------------------------- 
>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>>> +++++++++++------------------------------------ 
>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>> | 73 
>>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>>
>>>
> include/linux/cpu.h                 |  1 +
>>> include/linux/of.h                  |  6 ++++++ 
>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>> changed, 202 insertions(+), 216 deletions(-)
>>>
>>>
>>> PS: This patch series is reviewed and acknowledged @
>>>
>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>> https://lkml.org/lkml/2013/7/22/219
>>
>> Pulled, thanks!
>>
> Hi Rob, Rafael,
> 
> On 13/08/13 15:16, kbuild test robot wrote:> tree:
> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
> bleeding-edge
>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>> support for retrieving cpu node for a given logical cpu index
>> config: make ARCH=powerpc allmodconfig
>>
>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>> 'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53: 
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
> 
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.

Feel free to remove it for Microblaze.
There was probably any reason why it was there.
Or maybe no reason and it was just there because Microblaze
was based on powerpc code.

Thanks,
Michal

-- 
Michal Simek, Ing. (M.Eng), OpenPGP -> KeyID: FE3D1F91
w: www.monstr.eu p: +42-0-721842854
Maintainer of Linux kernel - Microblaze cpu - http://www.monstr.eu/fdt/
Maintainer of Linux kernel - Xilinx Zynq ARM architecture
Microblaze U-BOOT custodian and responsible for u-boot arm zynq platform



[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 263 bytes --]

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 18:37       ` Michal Simek
  0 siblings, 0 replies; 79+ messages in thread
From: Michal Simek @ 2013-08-13 18:37 UTC (permalink / raw)
  To: linux-arm-kernel

On 08/13/2013 05:40 PM, Sudeep KarkadaNagesha wrote:
> Adding PowerPC list
> 
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>
>>> for you to fetch changes up to
>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>
>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>>> (2013-08-12 10:22:29 +0100)
>>>
>>> ---------------------------------------------------------------- 
>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>> cpu's device struture of/device: add helper to get cpu device node
>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>> nodes
>>>
>>> arch/arm/kernel/devtree.c           |  5 +++++ 
>>> arch/arm/kernel/topology.c          | 61 
>>> +++++++++++++++++++------------------------------------------ 
>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>>> arch/arm/mach-mvebu/platsmp.c       | 52 
>>> ++++++++++++++++++++++++---------------------------- 
>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>> | 28 +++++++--------------------- 
>>> drivers/cpufreq/arm_big_little_dt.c | 40 
>>> ++++++++++++++-------------------------- 
>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>>> +++++++++++------------------------------------ 
>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>> | 73 
>>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>>
>>>
> include/linux/cpu.h                 |  1 +
>>> include/linux/of.h                  |  6 ++++++ 
>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>> changed, 202 insertions(+), 216 deletions(-)
>>>
>>>
>>> PS: This patch series is reviewed and acknowledged @
>>>
>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>> https://lkml.org/lkml/2013/7/22/219
>>
>> Pulled, thanks!
>>
> Hi Rob, Rafael,
> 
> On 13/08/13 15:16, kbuild test robot wrote:> tree:
> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
> bleeding-edge
>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>> support for retrieving cpu node for a given logical cpu index
>> config: make ARCH=powerpc allmodconfig
>>
>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>> 'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53: 
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
> 
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.

Feel free to remove it for Microblaze.
There was probably any reason why it was there.
Or maybe no reason and it was just there because Microblaze
was based on powerpc code.

Thanks,
Michal

-- 
Michal Simek, Ing. (M.Eng), OpenPGP -> KeyID: FE3D1F91
w: www.monstr.eu p: +42-0-721842854
Maintainer of Linux kernel - Microblaze cpu - http://www.monstr.eu/fdt/
Maintainer of Linux kernel - Xilinx Zynq ARM architecture
Microblaze U-BOOT custodian and responsible for u-boot arm zynq platform


-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 263 bytes
Desc: OpenPGP digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20130813/31f0a81b/attachment.sig>

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 15:40     ` Sudeep KarkadaNagesha
  (?)
  (?)
@ 2013-08-13 18:44       ` Rob Herring
  -1 siblings, 0 replies; 79+ messages in thread
From: Rob Herring @ 2013-08-13 18:44 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: Rafael J. Wysocki, rob.herring, Benjamin Herrenschmidt,
	linuxppc-dev, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
<Sudeep.KarkadaNagesha@arm.com> wrote:
> Adding PowerPC list
>
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node

[snip]

>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>>'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
>
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.
> To fix this:
> 1. I can rename the newly added function to something different like
>    `of_get_cpunode` or
> 2. If of_* namespace should be used by only OF/FDT and not by any
>    architecture specific code, then the arch specific version can be
>    renamed to some thing like arch_of_get_cpu_node.
>    Also most of the calls to arch specific function can be moved to
>    generic code.
>
> Let me know your thoughts.

It is up to Rafael if he is willing/able to rebase his tree, but I
would drop this series until this is sorted out. I think the new
common function should be and can be generalized to work for powerpc.
It would need to make reg property optional and pass in the device
node to the arch specific function.

A short term solution would be just to make the function "#ifndef CONFIG_PPC".

Rob

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 18:44       ` Rob Herring
  0 siblings, 0 replies; 79+ messages in thread
From: Rob Herring @ 2013-08-13 18:44 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: Rafael J. Wysocki, rob.herring, Benjamin Herrenschmidt,
	linuxppc-dev, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
<Sudeep.KarkadaNagesha@arm.com> wrote:
> Adding PowerPC list
>
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node

[snip]

>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>>'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
>
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.
> To fix this:
> 1. I can rename the newly added function to something different like
>    `of_get_cpunode` or
> 2. If of_* namespace should be used by only OF/FDT and not by any
>    architecture specific code, then the arch specific version can be
>    renamed to some thing like arch_of_get_cpu_node.
>    Also most of the calls to arch specific function can be moved to
>    generic code.
>
> Let me know your thoughts.

It is up to Rafael if he is willing/able to rebase his tree, but I
would drop this series until this is sorted out. I think the new
common function should be and can be generalized to work for powerpc.
It would need to make reg property optional and pass in the device
node to the arch specific function.

A short term solution would be just to make the function "#ifndef CONFIG_PPC".

Rob

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 18:44       ` Rob Herring
  0 siblings, 0 replies; 79+ messages in thread
From: Rob Herring @ 2013-08-13 18:44 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: devicetree, linux-pm, linux-kernel, rob.herring,
	Rafael J. Wysocki, Viresh Kumar, Olof Johansson, linuxppc-dev,
	linux-arm-kernel

On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
<Sudeep.KarkadaNagesha@arm.com> wrote:
> Adding PowerPC list
>
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node

[snip]

>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>>'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
>
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.
> To fix this:
> 1. I can rename the newly added function to something different like
>    `of_get_cpunode` or
> 2. If of_* namespace should be used by only OF/FDT and not by any
>    architecture specific code, then the arch specific version can be
>    renamed to some thing like arch_of_get_cpu_node.
>    Also most of the calls to arch specific function can be moved to
>    generic code.
>
> Let me know your thoughts.

It is up to Rafael if he is willing/able to rebase his tree, but I
would drop this series until this is sorted out. I think the new
common function should be and can be generalized to work for powerpc.
It would need to make reg property optional and pass in the device
node to the arch specific function.

A short term solution would be just to make the function "#ifndef CONFIG_PPC".

Rob

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 18:44       ` Rob Herring
  0 siblings, 0 replies; 79+ messages in thread
From: Rob Herring @ 2013-08-13 18:44 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
<Sudeep.KarkadaNagesha@arm.com> wrote:
> Adding PowerPC list
>
> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>> The following changes since commit
>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>
>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>
>>> are available in the git repository at:
>>>
>>> git://linux-arm.org/linux-skn.git cpu_of_node

[snip]

>> All error/warnings:
>>
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> include/linux/of.h:269:28: error: conflicting types for
>>'of_get_cpu_node'
>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>> included from include/linux/of.h:139:0, from
>> arch/powerpc/include/asm/kvm_para.h:26, from
>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>> from include/linux/kvm_host.h:30, from
>> arch/powerpc/kernel/asm-offsets.c:53:
>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>> of 'of_get_cpu_node' was here
>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>> Target `__build' not remade because of errors. make[1]: ***
>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>> errors. make: *** [sub-make] Error 2
>>
>
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.
> To fix this:
> 1. I can rename the newly added function to something different like
>    `of_get_cpunode` or
> 2. If of_* namespace should be used by only OF/FDT and not by any
>    architecture specific code, then the arch specific version can be
>    renamed to some thing like arch_of_get_cpu_node.
>    Also most of the calls to arch specific function can be moved to
>    generic code.
>
> Let me know your thoughts.

It is up to Rafael if he is willing/able to rebase his tree, but I
would drop this series until this is sorted out. I think the new
common function should be and can be generalized to work for powerpc.
It would need to make reg property optional and pass in the device
node to the arch specific function.

A short term solution would be just to make the function "#ifndef CONFIG_PPC".

Rob

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 18:44       ` Rob Herring
  (?)
  (?)
@ 2013-08-13 19:45         ` Rafael J. Wysocki
  -1 siblings, 0 replies; 79+ messages in thread
From: Rafael J. Wysocki @ 2013-08-13 19:45 UTC (permalink / raw)
  To: Rob Herring
  Cc: Sudeep KarkadaNagesha, rob.herring, Benjamin Herrenschmidt,
	linuxppc-dev, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

On Tuesday, August 13, 2013 01:44:23 PM Rob Herring wrote:
> On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
> <Sudeep.KarkadaNagesha@arm.com> wrote:
> > Adding PowerPC list
> >
> > On 13/08/13 14:00, Rafael J. Wysocki wrote:
> >> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
> >>> The following changes since commit
> >>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
> >>>
> >>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
> >>>
> >>> are available in the git repository at:
> >>>
> >>> git://linux-arm.org/linux-skn.git cpu_of_node
> 
> [snip]
> 
> >> All error/warnings:
> >>
> >> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> >> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> >> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> >> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> >> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
> >> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
> >> from include/linux/kvm_host.h:30, from
> >> arch/powerpc/kernel/asm-offsets.c:53:
> >> include/linux/of.h:269:28: error: conflicting types for
> >>'of_get_cpu_node'
> >> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
> >> included from include/linux/of.h:139:0, from
> >> arch/powerpc/include/asm/kvm_para.h:26, from
> >> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
> >> from include/linux/kvm_host.h:30, from
> >> arch/powerpc/kernel/asm-offsets.c:53:
> >> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
> >> of 'of_get_cpu_node' was here
> >> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
> >> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
> >> Target `__build' not remade because of errors. make[1]: ***
> >> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
> >> errors. make: *** [sub-make] Error 2
> >>
> >
> > There seems to be conflict in the new function "of_get_cpu_node" added.
> > PowerPC also defines the same function name. Further microblaze and
> > openrisc declares it(can be removed) but doesn't define it.
> > To fix this:
> > 1. I can rename the newly added function to something different like
> >    `of_get_cpunode` or
> > 2. If of_* namespace should be used by only OF/FDT and not by any
> >    architecture specific code, then the arch specific version can be
> >    renamed to some thing like arch_of_get_cpu_node.
> >    Also most of the calls to arch specific function can be moved to
> >    generic code.
> >
> > Let me know your thoughts.
> 
> It is up to Rafael if he is willing/able to rebase his tree, but I
> would drop this series until this is sorted out.

Yeah, I've just done that.

> I think the new common function should be and can be generalized to work for
> powerpc.
> It would need to make reg property optional and pass in the device
> node to the arch specific function.
> 
> A short term solution would be just to make the function "#ifndef CONFIG_PPC".

I wouldn't do that, it's almost guaranteed to be messy going forward.

I'd go for 1 above personally.

Thanks,
Rafael


^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 19:45         ` Rafael J. Wysocki
  0 siblings, 0 replies; 79+ messages in thread
From: Rafael J. Wysocki @ 2013-08-13 19:45 UTC (permalink / raw)
  To: Rob Herring
  Cc: Sudeep KarkadaNagesha, rob.herring, Benjamin Herrenschmidt,
	linuxppc-dev, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

On Tuesday, August 13, 2013 01:44:23 PM Rob Herring wrote:
> On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
> <Sudeep.KarkadaNagesha@arm.com> wrote:
> > Adding PowerPC list
> >
> > On 13/08/13 14:00, Rafael J. Wysocki wrote:
> >> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
> >>> The following changes since commit
> >>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
> >>>
> >>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
> >>>
> >>> are available in the git repository at:
> >>>
> >>> git://linux-arm.org/linux-skn.git cpu_of_node
> 
> [snip]
> 
> >> All error/warnings:
> >>
> >> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> >> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> >> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> >> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> >> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
> >> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
> >> from include/linux/kvm_host.h:30, from
> >> arch/powerpc/kernel/asm-offsets.c:53:
> >> include/linux/of.h:269:28: error: conflicting types for
> >>'of_get_cpu_node'
> >> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
> >> included from include/linux/of.h:139:0, from
> >> arch/powerpc/include/asm/kvm_para.h:26, from
> >> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
> >> from include/linux/kvm_host.h:30, from
> >> arch/powerpc/kernel/asm-offsets.c:53:
> >> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
> >> of 'of_get_cpu_node' was here
> >> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
> >> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
> >> Target `__build' not remade because of errors. make[1]: ***
> >> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
> >> errors. make: *** [sub-make] Error 2
> >>
> >
> > There seems to be conflict in the new function "of_get_cpu_node" added.
> > PowerPC also defines the same function name. Further microblaze and
> > openrisc declares it(can be removed) but doesn't define it.
> > To fix this:
> > 1. I can rename the newly added function to something different like
> >    `of_get_cpunode` or
> > 2. If of_* namespace should be used by only OF/FDT and not by any
> >    architecture specific code, then the arch specific version can be
> >    renamed to some thing like arch_of_get_cpu_node.
> >    Also most of the calls to arch specific function can be moved to
> >    generic code.
> >
> > Let me know your thoughts.
> 
> It is up to Rafael if he is willing/able to rebase his tree, but I
> would drop this series until this is sorted out.

Yeah, I've just done that.

> I think the new common function should be and can be generalized to work for
> powerpc.
> It would need to make reg property optional and pass in the device
> node to the arch specific function.
> 
> A short term solution would be just to make the function "#ifndef CONFIG_PPC".

I wouldn't do that, it's almost guaranteed to be messy going forward.

I'd go for 1 above personally.

Thanks,
Rafael


^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 19:45         ` Rafael J. Wysocki
  0 siblings, 0 replies; 79+ messages in thread
From: Rafael J. Wysocki @ 2013-08-13 19:45 UTC (permalink / raw)
  To: Rob Herring
  Cc: devicetree, linux-pm, Sudeep KarkadaNagesha, linux-kernel,
	rob.herring, Viresh Kumar, Olof Johansson, linuxppc-dev,
	linux-arm-kernel

On Tuesday, August 13, 2013 01:44:23 PM Rob Herring wrote:
> On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
> <Sudeep.KarkadaNagesha@arm.com> wrote:
> > Adding PowerPC list
> >
> > On 13/08/13 14:00, Rafael J. Wysocki wrote:
> >> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
> >>> The following changes since commit
> >>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
> >>>
> >>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
> >>>
> >>> are available in the git repository at:
> >>>
> >>> git://linux-arm.org/linux-skn.git cpu_of_node
> 
> [snip]
> 
> >> All error/warnings:
> >>
> >> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> >> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> >> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> >> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> >> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
> >> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
> >> from include/linux/kvm_host.h:30, from
> >> arch/powerpc/kernel/asm-offsets.c:53:
> >> include/linux/of.h:269:28: error: conflicting types for
> >>'of_get_cpu_node'
> >> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
> >> included from include/linux/of.h:139:0, from
> >> arch/powerpc/include/asm/kvm_para.h:26, from
> >> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
> >> from include/linux/kvm_host.h:30, from
> >> arch/powerpc/kernel/asm-offsets.c:53:
> >> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
> >> of 'of_get_cpu_node' was here
> >> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
> >> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
> >> Target `__build' not remade because of errors. make[1]: ***
> >> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
> >> errors. make: *** [sub-make] Error 2
> >>
> >
> > There seems to be conflict in the new function "of_get_cpu_node" added.
> > PowerPC also defines the same function name. Further microblaze and
> > openrisc declares it(can be removed) but doesn't define it.
> > To fix this:
> > 1. I can rename the newly added function to something different like
> >    `of_get_cpunode` or
> > 2. If of_* namespace should be used by only OF/FDT and not by any
> >    architecture specific code, then the arch specific version can be
> >    renamed to some thing like arch_of_get_cpu_node.
> >    Also most of the calls to arch specific function can be moved to
> >    generic code.
> >
> > Let me know your thoughts.
> 
> It is up to Rafael if he is willing/able to rebase his tree, but I
> would drop this series until this is sorted out.

Yeah, I've just done that.

> I think the new common function should be and can be generalized to work for
> powerpc.
> It would need to make reg property optional and pass in the device
> node to the arch specific function.
> 
> A short term solution would be just to make the function "#ifndef CONFIG_PPC".

I wouldn't do that, it's almost guaranteed to be messy going forward.

I'd go for 1 above personally.

Thanks,
Rafael

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 19:45         ` Rafael J. Wysocki
  0 siblings, 0 replies; 79+ messages in thread
From: Rafael J. Wysocki @ 2013-08-13 19:45 UTC (permalink / raw)
  To: linux-arm-kernel

On Tuesday, August 13, 2013 01:44:23 PM Rob Herring wrote:
> On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
> <Sudeep.KarkadaNagesha@arm.com> wrote:
> > Adding PowerPC list
> >
> > On 13/08/13 14:00, Rafael J. Wysocki wrote:
> >> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
> >>> The following changes since commit
> >>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
> >>>
> >>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
> >>>
> >>> are available in the git repository at:
> >>>
> >>> git://linux-arm.org/linux-skn.git cpu_of_node
> 
> [snip]
> 
> >> All error/warnings:
> >>
> >> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> >> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> >> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
> >> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
> >> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
> >> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
> >> from include/linux/kvm_host.h:30, from
> >> arch/powerpc/kernel/asm-offsets.c:53:
> >> include/linux/of.h:269:28: error: conflicting types for
> >>'of_get_cpu_node'
> >> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
> >> included from include/linux/of.h:139:0, from
> >> arch/powerpc/include/asm/kvm_para.h:26, from
> >> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
> >> from include/linux/kvm_host.h:30, from
> >> arch/powerpc/kernel/asm-offsets.c:53:
> >> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
> >> of 'of_get_cpu_node' was here
> >> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
> >> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
> >> Target `__build' not remade because of errors. make[1]: ***
> >> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
> >> errors. make: *** [sub-make] Error 2
> >>
> >
> > There seems to be conflict in the new function "of_get_cpu_node" added.
> > PowerPC also defines the same function name. Further microblaze and
> > openrisc declares it(can be removed) but doesn't define it.
> > To fix this:
> > 1. I can rename the newly added function to something different like
> >    `of_get_cpunode` or
> > 2. If of_* namespace should be used by only OF/FDT and not by any
> >    architecture specific code, then the arch specific version can be
> >    renamed to some thing like arch_of_get_cpu_node.
> >    Also most of the calls to arch specific function can be moved to
> >    generic code.
> >
> > Let me know your thoughts.
> 
> It is up to Rafael if he is willing/able to rebase his tree, but I
> would drop this series until this is sorted out.

Yeah, I've just done that.

> I think the new common function should be and can be generalized to work for
> powerpc.
> It would need to make reg property optional and pass in the device
> node to the arch specific function.
> 
> A short term solution would be just to make the function "#ifndef CONFIG_PPC".

I wouldn't do that, it's almost guaranteed to be messy going forward.

I'd go for 1 above personally.

Thanks,
Rafael

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 15:40     ` Sudeep KarkadaNagesha
  (?)
@ 2013-08-13 21:03       ` Benjamin Herrenschmidt
  -1 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:03 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: Rafael J. Wysocki, rob.herring, linuxppc-dev, Viresh Kumar,
	Olof Johansson, linux-pm, linux-arm-kernel, linux-kernel,
	devicetree

On Tue, 2013-08-13 at 16:40 +0100, Sudeep KarkadaNagesha wrote:
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.
> To fix this:
> 1. I can rename the newly added function to something different like
>    `of_get_cpunode` or
> 2. If of_* namespace should be used by only OF/FDT and not by any
>    architecture specific code, then the arch specific version can be
>    renamed to some thing like arch_of_get_cpu_node.
>    Also most of the calls to arch specific function can be moved to
>    generic code.
> 
> Let me know your thoughts.

What is your new function about ? Does it perform the same job as the
one in powerpc ? If yes, make sure you have the same signature and
either copy the powerpc one over to a generic place or make the generic
one weak if you don't want the powerpc thread counting logic.

Cheers,
Ben.



^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 21:03       ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:03 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: devicetree, linux-pm, Viresh Kumar, linux-kernel, rob.herring,
	Rafael J. Wysocki, Olof Johansson, linuxppc-dev,
	linux-arm-kernel

On Tue, 2013-08-13 at 16:40 +0100, Sudeep KarkadaNagesha wrote:
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.
> To fix this:
> 1. I can rename the newly added function to something different like
>    `of_get_cpunode` or
> 2. If of_* namespace should be used by only OF/FDT and not by any
>    architecture specific code, then the arch specific version can be
>    renamed to some thing like arch_of_get_cpu_node.
>    Also most of the calls to arch specific function can be moved to
>    generic code.
> 
> Let me know your thoughts.

What is your new function about ? Does it perform the same job as the
one in powerpc ? If yes, make sure you have the same signature and
either copy the powerpc one over to a generic place or make the generic
one weak if you don't want the powerpc thread counting logic.

Cheers,
Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 21:03       ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:03 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, 2013-08-13 at 16:40 +0100, Sudeep KarkadaNagesha wrote:
> There seems to be conflict in the new function "of_get_cpu_node" added.
> PowerPC also defines the same function name. Further microblaze and
> openrisc declares it(can be removed) but doesn't define it.
> To fix this:
> 1. I can rename the newly added function to something different like
>    `of_get_cpunode` or
> 2. If of_* namespace should be used by only OF/FDT and not by any
>    architecture specific code, then the arch specific version can be
>    renamed to some thing like arch_of_get_cpu_node.
>    Also most of the calls to arch specific function can be moved to
>    generic code.
> 
> Let me know your thoughts.

What is your new function about ? Does it perform the same job as the
one in powerpc ? If yes, make sure you have the same signature and
either copy the powerpc one over to a generic place or make the generic
one weak if you don't want the powerpc thread counting logic.

Cheers,
Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 18:29       ` Sudeep KarkadaNagesha
  (?)
@ 2013-08-13 21:07         ` Benjamin Herrenschmidt
  -1 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:07 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: linuxppc-dev, Rafael J. Wysocki, rob.herring, Viresh Kumar,
	Olof Johansson, linux-pm, linux-arm-kernel, linux-kernel,
	devicetree

On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
> I don't understand completely the use of ibm,ppc-interrupt-server#s and
> its implications on generic of_get_cpu_node implementation.
> I see the PPC specific definition of of_get_cpu_node uses thread id only
> in 2 instances. Based on that, I have tried to move all the other
> instances to use generic definition.
> 
> Let me know if the idea is correct.

No. The device-tree historically only represents cores, not HW threads, so
it makes sense to retrieve also the thread number corresponding to the CPU.

However, the mechanism to represent HW threads in the device-tree is currently
somewhat platform specific (the ibm,ppc-interrupt-server#s).

So what you could do for now is:

 - Have a generic version that always returns 0 as the thread, which is weak

 - powerpc keeps its own implementation

 - Start a discussion on the bindings (if not already there) to define threads
in a better way at which point the generic function can be updated.

Cheers,
Ben.



^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 21:07         ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:07 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: devicetree, linux-pm, Viresh Kumar, linux-kernel, rob.herring,
	Rafael J. Wysocki, Olof Johansson, linuxppc-dev,
	linux-arm-kernel

On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
> I don't understand completely the use of ibm,ppc-interrupt-server#s and
> its implications on generic of_get_cpu_node implementation.
> I see the PPC specific definition of of_get_cpu_node uses thread id only
> in 2 instances. Based on that, I have tried to move all the other
> instances to use generic definition.
> 
> Let me know if the idea is correct.

No. The device-tree historically only represents cores, not HW threads, so
it makes sense to retrieve also the thread number corresponding to the CPU.

However, the mechanism to represent HW threads in the device-tree is currently
somewhat platform specific (the ibm,ppc-interrupt-server#s).

So what you could do for now is:

 - Have a generic version that always returns 0 as the thread, which is weak

 - powerpc keeps its own implementation

 - Start a discussion on the bindings (if not already there) to define threads
in a better way at which point the generic function can be updated.

Cheers,
Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 21:07         ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:07 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
> I don't understand completely the use of ibm,ppc-interrupt-server#s and
> its implications on generic of_get_cpu_node implementation.
> I see the PPC specific definition of of_get_cpu_node uses thread id only
> in 2 instances. Based on that, I have tried to move all the other
> instances to use generic definition.
> 
> Let me know if the idea is correct.

No. The device-tree historically only represents cores, not HW threads, so
it makes sense to retrieve also the thread number corresponding to the CPU.

However, the mechanism to represent HW threads in the device-tree is currently
somewhat platform specific (the ibm,ppc-interrupt-server#s).

So what you could do for now is:

 - Have a generic version that always returns 0 as the thread, which is weak

 - powerpc keeps its own implementation

 - Start a discussion on the bindings (if not already there) to define threads
in a better way at which point the generic function can be updated.

Cheers,
Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 18:44       ` Rob Herring
  (?)
@ 2013-08-13 21:08         ` Benjamin Herrenschmidt
  -1 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:08 UTC (permalink / raw)
  To: Rob Herring
  Cc: Sudeep KarkadaNagesha, Rafael J. Wysocki, rob.herring,
	linuxppc-dev, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

On Tue, 2013-08-13 at 13:44 -0500, Rob Herring wrote:
> It is up to Rafael if he is willing/able to rebase his tree, but I
> would drop this series until this is sorted out. I think the new
> common function should be and can be generalized to work for powerpc.
> It would need to make reg property optional and pass in the device
> node to the arch specific function.
> 
> A short term solution would be just to make the function "#ifndef
> CONFIG_PPC".

Please, no ifdef's with different signatures. Let's agree on the
prototype first (ie, thread output argument) and make the generic
one weak.

Cheers,
Ben.



^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 21:08         ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:08 UTC (permalink / raw)
  To: Rob Herring
  Cc: devicetree, linux-pm, Sudeep KarkadaNagesha, Viresh Kumar,
	linux-kernel, rob.herring, Rafael J. Wysocki, Olof Johansson,
	linuxppc-dev, linux-arm-kernel

On Tue, 2013-08-13 at 13:44 -0500, Rob Herring wrote:
> It is up to Rafael if he is willing/able to rebase his tree, but I
> would drop this series until this is sorted out. I think the new
> common function should be and can be generalized to work for powerpc.
> It would need to make reg property optional and pass in the device
> node to the arch specific function.
> 
> A short term solution would be just to make the function "#ifndef
> CONFIG_PPC".

Please, no ifdef's with different signatures. Let's agree on the
prototype first (ie, thread output argument) and make the generic
one weak.

Cheers,
Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 21:08         ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:08 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, 2013-08-13 at 13:44 -0500, Rob Herring wrote:
> It is up to Rafael if he is willing/able to rebase his tree, but I
> would drop this series until this is sorted out. I think the new
> common function should be and can be generalized to work for powerpc.
> It would need to make reg property optional and pass in the device
> node to the arch specific function.
> 
> A short term solution would be just to make the function "#ifndef
> CONFIG_PPC".

Please, no ifdef's with different signatures. Let's agree on the
prototype first (ie, thread output argument) and make the generic
one weak.

Cheers,
Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 19:45         ` Rafael J. Wysocki
  (?)
  (?)
@ 2013-08-13 21:09           ` Benjamin Herrenschmidt
  -1 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:09 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: Rob Herring, Sudeep KarkadaNagesha, rob.herring, linuxppc-dev,
	Viresh Kumar, Olof Johansson, linux-pm, linux-arm-kernel,
	linux-kernel, devicetree

On Tue, 2013-08-13 at 21:45 +0200, Rafael J. Wysocki wrote:
> 
> I'd go for 1 above personally.

Yuck no. Two functions with roughly the same name and the same purpose
differing only by an underscore just because one can't take 5mn to
reconcile the new one with the old one ? No way.

Ben.



^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 21:09           ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:09 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: devicetree, linux-pm, Sudeep KarkadaNagesha, Viresh Kumar,
	linux-kernel, rob.herring, Olof Johansson, linuxppc-dev,
	linux-arm-kernel

On Tue, 2013-08-13 at 21:45 +0200, Rafael J. Wysocki wrote:
> 
> I'd go for 1 above personally.

Yuck no. Two functions with roughly the same name and the same purpose
differing only by an underscore just because one can't take 5mn to
reconcile the new one with the old one ? No way.

Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 21:09           ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:09 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: devicetree, linux-pm, Sudeep KarkadaNagesha, Viresh Kumar,
	linux-kernel, rob.herring, Rob Herring, Olof Johansson,
	linuxppc-dev, linux-arm-kernel

On Tue, 2013-08-13 at 21:45 +0200, Rafael J. Wysocki wrote:
> 
> I'd go for 1 above personally.

Yuck no. Two functions with roughly the same name and the same purpose
differing only by an underscore just because one can't take 5mn to
reconcile the new one with the old one ? No way.

Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-13 21:09           ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-13 21:09 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, 2013-08-13 at 21:45 +0200, Rafael J. Wysocki wrote:
> 
> I'd go for 1 above personally.

Yuck no. Two functions with roughly the same name and the same purpose
differing only by an underscore just because one can't take 5mn to
reconcile the new one with the old one ? No way.

Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 18:37       ` Michal Simek
  (?)
  (?)
@ 2013-08-14  8:41         ` Sudeep KarkadaNagesha
  -1 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14  8:41 UTC (permalink / raw)
  To: monstr
  Cc: Sudeep KarkadaNagesha, Rafael J. Wysocki, rob.herring,
	Benjamin Herrenschmidt, linuxppc-dev, Viresh Kumar,
	Olof Johansson, linux-pm, linux-arm-kernel, linux-kernel,
	devicetree

On 13/08/13 19:37, Michal Simek wrote:
> On 08/13/2013 05:40 PM, Sudeep KarkadaNagesha wrote:
>> Adding PowerPC list
>>
>> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>>> The following changes since commit
>>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>>
>>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>>
>>>> are available in the git repository at:
>>>>
>>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>>
>>>> for you to fetch changes up to
>>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>>
>>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>>>> (2013-08-12 10:22:29 +0100)
>>>>
>>>> ---------------------------------------------------------------- 
>>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>>> cpu's device struture of/device: add helper to get cpu device node
>>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>>> nodes
>>>>
>>>> arch/arm/kernel/devtree.c           |  5 +++++ 
>>>> arch/arm/kernel/topology.c          | 61 
>>>> +++++++++++++++++++------------------------------------------ 
>>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>>>> arch/arm/mach-mvebu/platsmp.c       | 52 
>>>> ++++++++++++++++++++++++---------------------------- 
>>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>>> | 28 +++++++--------------------- 
>>>> drivers/cpufreq/arm_big_little_dt.c | 40 
>>>> ++++++++++++++-------------------------- 
>>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>>>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>>>> +++++++++++------------------------------------ 
>>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>>> | 73 
>>>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>>>
>>>>
>> include/linux/cpu.h                 |  1 +
>>>> include/linux/of.h                  |  6 ++++++ 
>>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>>> changed, 202 insertions(+), 216 deletions(-)
>>>>
>>>>
>>>> PS: This patch series is reviewed and acknowledged @
>>>>
>>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>>> https://lkml.org/lkml/2013/7/22/219
>>>
>>> Pulled, thanks!
>>>
>> Hi Rob, Rafael,
>>
>> On 13/08/13 15:16, kbuild test robot wrote:> tree:
>> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
>> bleeding-edge
>>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>>> support for retrieving cpu node for a given logical cpu index
>>> config: make ARCH=powerpc allmodconfig
>>>
>>> All error/warnings:
>>>
>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>>> from include/linux/kvm_host.h:30, from
>>> arch/powerpc/kernel/asm-offsets.c:53:
>>> include/linux/of.h:269:28: error: conflicting types for
>>> 'of_get_cpu_node'
>>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>>> included from include/linux/of.h:139:0, from
>>> arch/powerpc/include/asm/kvm_para.h:26, from
>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>>> from include/linux/kvm_host.h:30, from
>>> arch/powerpc/kernel/asm-offsets.c:53: 
>>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>>> of 'of_get_cpu_node' was here
>>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
>>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>>> Target `__build' not remade because of errors. make[1]: ***
>>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>>> errors. make: *** [sub-make] Error 2
>>>
>>
>> There seems to be conflict in the new function "of_get_cpu_node" added.
>> PowerPC also defines the same function name. Further microblaze and
>> openrisc declares it(can be removed) but doesn't define it.
> 
> Feel free to remove it for Microblaze.
> There was probably any reason why it was there.
> Or maybe no reason and it was just there because Microblaze
> was based on powerpc code.
>

Thanks Michal, will remove it.

Regards,
Sudeep



^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14  8:41         ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14  8:41 UTC (permalink / raw)
  To: monstr
  Cc: Sudeep KarkadaNagesha, Rafael J. Wysocki, rob.herring,
	Benjamin Herrenschmidt, linuxppc-dev, Viresh Kumar,
	Olof Johansson, linux-pm, linux-arm-kernel, linux-kernel,
	devicetree

On 13/08/13 19:37, Michal Simek wrote:
> On 08/13/2013 05:40 PM, Sudeep KarkadaNagesha wrote:
>> Adding PowerPC list
>>
>> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>>> The following changes since commit
>>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>>
>>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>>
>>>> are available in the git repository at:
>>>>
>>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>>
>>>> for you to fetch changes up to
>>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>>
>>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>>>> (2013-08-12 10:22:29 +0100)
>>>>
>>>> ---------------------------------------------------------------- 
>>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>>> cpu's device struture of/device: add helper to get cpu device node
>>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>>> nodes
>>>>
>>>> arch/arm/kernel/devtree.c           |  5 +++++ 
>>>> arch/arm/kernel/topology.c          | 61 
>>>> +++++++++++++++++++------------------------------------------ 
>>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>>>> arch/arm/mach-mvebu/platsmp.c       | 52 
>>>> ++++++++++++++++++++++++---------------------------- 
>>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>>> | 28 +++++++--------------------- 
>>>> drivers/cpufreq/arm_big_little_dt.c | 40 
>>>> ++++++++++++++-------------------------- 
>>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>>>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>>>> +++++++++++------------------------------------ 
>>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>>> | 73 
>>>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>>>
>>>>
>> include/linux/cpu.h                 |  1 +
>>>> include/linux/of.h                  |  6 ++++++ 
>>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>>> changed, 202 insertions(+), 216 deletions(-)
>>>>
>>>>
>>>> PS: This patch series is reviewed and acknowledged @
>>>>
>>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>>> https://lkml.org/lkml/2013/7/22/219
>>>
>>> Pulled, thanks!
>>>
>> Hi Rob, Rafael,
>>
>> On 13/08/13 15:16, kbuild test robot wrote:> tree:
>> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
>> bleeding-edge
>>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>>> support for retrieving cpu node for a given logical cpu index
>>> config: make ARCH=powerpc allmodconfig
>>>
>>> All error/warnings:
>>>
>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>>> from include/linux/kvm_host.h:30, from
>>> arch/powerpc/kernel/asm-offsets.c:53:
>>> include/linux/of.h:269:28: error: conflicting types for
>>> 'of_get_cpu_node'
>>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>>> included from include/linux/of.h:139:0, from
>>> arch/powerpc/include/asm/kvm_para.h:26, from
>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>>> from include/linux/kvm_host.h:30, from
>>> arch/powerpc/kernel/asm-offsets.c:53: 
>>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>>> of 'of_get_cpu_node' was here
>>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
>>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>>> Target `__build' not remade because of errors. make[1]: ***
>>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>>> errors. make: *** [sub-make] Error 2
>>>
>>
>> There seems to be conflict in the new function "of_get_cpu_node" added.
>> PowerPC also defines the same function name. Further microblaze and
>> openrisc declares it(can be removed) but doesn't define it.
> 
> Feel free to remove it for Microblaze.
> There was probably any reason why it was there.
> Or maybe no reason and it was just there because Microblaze
> was based on powerpc code.
>

Thanks Michal, will remove it.

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14  8:41         ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14  8:41 UTC (permalink / raw)
  To: monstr
  Cc: devicetree, linux-pm, Sudeep KarkadaNagesha, Viresh Kumar,
	linux-kernel, rob.herring, Rafael J. Wysocki, Olof Johansson,
	linuxppc-dev, linux-arm-kernel

On 13/08/13 19:37, Michal Simek wrote:
> On 08/13/2013 05:40 PM, Sudeep KarkadaNagesha wrote:
>> Adding PowerPC list
>>
>> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>>> The following changes since commit
>>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>>
>>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>>
>>>> are available in the git repository at:
>>>>
>>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>>
>>>> for you to fetch changes up to
>>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>>
>>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes=20
>>>> (2013-08-12 10:22:29 +0100)
>>>>
>>>> ----------------------------------------------------------------=20
>>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>>> cpu's device struture of/device: add helper to get cpu device node
>>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes=20
>>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes=20
>>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes=20
>>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>>> nodes
>>>>
>>>> arch/arm/kernel/devtree.c           |  5 +++++=20
>>>> arch/arm/kernel/topology.c          | 61=20
>>>> +++++++++++++++++++------------------------------------------=20
>>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +--=20
>>>> arch/arm/mach-mvebu/platsmp.c       | 52=20
>>>> ++++++++++++++++++++++++----------------------------=20
>>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>>> | 28 +++++++---------------------=20
>>>> drivers/cpufreq/arm_big_little_dt.c | 40=20
>>>> ++++++++++++++--------------------------=20
>>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++-------------------=20
>>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------=20
>>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +---=20
>>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++---=20
>>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++--------------------=20
>>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++--=20
>>>> drivers/cpufreq/pmac64-cpufreq.c    | 47=20
>>>> +++++++++++------------------------------------=20
>>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>>> | 73=20
>>>> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++=
+++
>>>>
>>>>
>> include/linux/cpu.h                 |  1 +
>>>> include/linux/of.h                  |  6 ++++++=20
>>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>>> changed, 202 insertions(+), 216 deletions(-)
>>>>
>>>>
>>>> PS: This patch series is reviewed and acknowledged @
>>>>
>>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>>> https://lkml.org/lkml/2013/7/22/219
>>>
>>> Pulled, thanks!
>>>
>> Hi Rob, Rafael,
>>
>> On 13/08/13 15:16, kbuild test robot wrote:> tree:
>> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
>> bleeding-edge
>>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>>> support for retrieving cpu node for a given logical cpu index
>>> config: make ARCH=3Dpowerpc allmodconfig
>>>
>>> All error/warnings:
>>>
>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,=20
>>> from include/linux/kvm_host.h:30, from
>>> arch/powerpc/kernel/asm-offsets.c:53:
>>> include/linux/of.h:269:28: error: conflicting types for
>>> 'of_get_cpu_node'
>>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>>> included from include/linux/of.h:139:0, from
>>> arch/powerpc/include/asm/kvm_para.h:26, from
>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,=20
>>> from include/linux/kvm_host.h:30, from
>>> arch/powerpc/kernel/asm-offsets.c:53:=20
>>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>>> of 'of_get_cpu_node' was here
>>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);=20
>>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>>> Target `__build' not remade because of errors. make[1]: ***
>>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>>> errors. make: *** [sub-make] Error 2
>>>
>>
>> There seems to be conflict in the new function "of_get_cpu_node" added.
>> PowerPC also defines the same function name. Further microblaze and
>> openrisc declares it(can be removed) but doesn't define it.
>=20
> Feel free to remove it for Microblaze.
> There was probably any reason why it was there.
> Or maybe no reason and it was just there because Microblaze
> was based on powerpc code.
>

Thanks Michal, will remove it.

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14  8:41         ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14  8:41 UTC (permalink / raw)
  To: linux-arm-kernel

On 13/08/13 19:37, Michal Simek wrote:
> On 08/13/2013 05:40 PM, Sudeep KarkadaNagesha wrote:
>> Adding PowerPC list
>>
>> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>>> The following changes since commit
>>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>>
>>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>>
>>>> are available in the git repository at:
>>>>
>>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>>>
>>>> for you to fetch changes up to
>>>> 9e9e26dde91f22635c87d0e45f3938b5ded96f0d:
>>>>
>>>> cpufreq: pmac32-cpufreq: remove device tree parsing for cpu nodes 
>>>> (2013-08-12 10:22:29 +0100)
>>>>
>>>> ---------------------------------------------------------------- 
>>>> Sudeep KarkadaNagesha (16): of: add support for retrieving cpu node
>>>> for a given logical cpu index ARM: DT/kernel: define ARM specific
>>>> arch_match_cpu_phys_id driver/core: cpu: initialize of_node in
>>>> cpu's device struture of/device: add helper to get cpu device node
>>>> from logical cpu index ARM: topology: remove hwid/MPIDR dependency
>>>> from cpu_capacity ARM: mvebu: remove device tree parsing for cpu
>>>> nodes drivers/bus: arm-cci: avoid parsing DT for cpu device nodes 
>>>> cpufreq: imx6q-cpufreq: remove device tree parsing for cpu nodes 
>>>> cpufreq: cpufreq-cpu0: remove device tree parsing for cpu nodes 
>>>> cpufreq: highbank-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: spear-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: kirkwood-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: arm_big_little: remove device tree parsing for cpu
>>>> nodes cpufreq: maple-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: pmac64-cpufreq: remove device tree parsing for cpu
>>>> nodes cpufreq: pmac32-cpufreq: remove device tree parsing for cpu
>>>> nodes
>>>>
>>>> arch/arm/kernel/devtree.c           |  5 +++++ 
>>>> arch/arm/kernel/topology.c          | 61 
>>>> +++++++++++++++++++------------------------------------------ 
>>>> arch/arm/mach-imx/mach-imx6q.c      |  3 +-- 
>>>> arch/arm/mach-mvebu/platsmp.c       | 52 
>>>> ++++++++++++++++++++++++---------------------------- 
>>>> drivers/base/cpu.c                  |  2 ++ drivers/bus/arm-cci.c
>>>> | 28 +++++++--------------------- 
>>>> drivers/cpufreq/arm_big_little_dt.c | 40 
>>>> ++++++++++++++-------------------------- 
>>>> drivers/cpufreq/cpufreq-cpu0.c      | 23 ++++------------------- 
>>>> drivers/cpufreq/highbank-cpufreq.c  | 18 ++++++------------ 
>>>> drivers/cpufreq/imx6q-cpufreq.c     |  4 +--- 
>>>> drivers/cpufreq/kirkwood-cpufreq.c  |  8 +++++--- 
>>>> drivers/cpufreq/maple-cpufreq.c     | 23 +++-------------------- 
>>>> drivers/cpufreq/pmac32-cpufreq.c    |  5 +++-- 
>>>> drivers/cpufreq/pmac64-cpufreq.c    | 47 
>>>> +++++++++++------------------------------------ 
>>>> drivers/cpufreq/spear-cpufreq.c     |  4 ++-- drivers/of/base.c
>>>> | 73 
>>>> +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>>>
>>>>
>> include/linux/cpu.h                 |  1 +
>>>> include/linux/of.h                  |  6 ++++++ 
>>>> include/linux/of_device.h           | 15 +++++++++++++++ 19 files
>>>> changed, 202 insertions(+), 216 deletions(-)
>>>>
>>>>
>>>> PS: This patch series is reviewed and acknowledged @
>>>>
>>>> v1: https://lkml.org/lkml/2013/7/15/128 v2:
>>>> https://lkml.org/lkml/2013/7/17/341 v3:
>>>> https://lkml.org/lkml/2013/7/22/219
>>>
>>> Pulled, thanks!
>>>
>> Hi Rob, Rafael,
>>
>> On 13/08/13 15:16, kbuild test robot wrote:> tree:
>> git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
>> bleeding-edge
>>> head:   0d4bcb5dc7d3040c0ce7572ea30ab9e5d9455bfa commit:
>>> 7939ff8d991de2c0b15064e76ee549a6df5ae67f [151/204] of: add
>>> support for retrieving cpu node for a given logical cpu index
>>> config: make ARCH=powerpc allmodconfig
>>>
>>> All error/warnings:
>>>
>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>>> from include/linux/kvm_host.h:30, from
>>> arch/powerpc/kernel/asm-offsets.c:53:
>>> include/linux/of.h:269:28: error: conflicting types for
>>> 'of_get_cpu_node'
>>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>>> included from include/linux/of.h:139:0, from
>>> arch/powerpc/include/asm/kvm_para.h:26, from
>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4, 
>>> from include/linux/kvm_host.h:30, from
>>> arch/powerpc/kernel/asm-offsets.c:53: 
>>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>>> of 'of_get_cpu_node' was here
>>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread); 
>>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>>> Target `__build' not remade because of errors. make[1]: ***
>>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>>> errors. make: *** [sub-make] Error 2
>>>
>>
>> There seems to be conflict in the new function "of_get_cpu_node" added.
>> PowerPC also defines the same function name. Further microblaze and
>> openrisc declares it(can be removed) but doesn't define it.
> 
> Feel free to remove it for Microblaze.
> There was probably any reason why it was there.
> Or maybe no reason and it was just there because Microblaze
> was based on powerpc code.
>

Thanks Michal, will remove it.

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 19:45         ` Rafael J. Wysocki
  (?)
  (?)
@ 2013-08-14  9:23           ` Sudeep KarkadaNagesha
  -1 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14  9:23 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: Rob Herring, Sudeep KarkadaNagesha, rob.herring,
	Benjamin Herrenschmidt, linuxppc-dev, Viresh Kumar,
	Olof Johansson, linux-pm, linux-arm-kernel, linux-kernel,
	devicetree

On 13/08/13 20:45, Rafael J. Wysocki wrote:
> On Tuesday, August 13, 2013 01:44:23 PM Rob Herring wrote:
>> On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
>> <Sudeep.KarkadaNagesha@arm.com> wrote:
>>> Adding PowerPC list
>>>
>>> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>>>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>>>> The following changes since commit
>>>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>>>
>>>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>>>
>>>>> are available in the git repository at:
>>>>>
>>>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>
>> [snip]
>>
>>>> All error/warnings:
>>>>
>>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>>>> from include/linux/kvm_host.h:30, from
>>>> arch/powerpc/kernel/asm-offsets.c:53:
>>>> include/linux/of.h:269:28: error: conflicting types for
>>>> 'of_get_cpu_node'
>>>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>>>> included from include/linux/of.h:139:0, from
>>>> arch/powerpc/include/asm/kvm_para.h:26, from
>>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>>>> from include/linux/kvm_host.h:30, from
>>>> arch/powerpc/kernel/asm-offsets.c:53:
>>>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>>>> of 'of_get_cpu_node' was here
>>>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
>>>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>>>> Target `__build' not remade because of errors. make[1]: ***
>>>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>>>> errors. make: *** [sub-make] Error 2
>>>>
>>>
>>> There seems to be conflict in the new function "of_get_cpu_node" added.
>>> PowerPC also defines the same function name. Further microblaze and
>>> openrisc declares it(can be removed) but doesn't define it.
>>> To fix this:
>>> 1. I can rename the newly added function to something different like
>>>    `of_get_cpunode` or
>>> 2. If of_* namespace should be used by only OF/FDT and not by any
>>>    architecture specific code, then the arch specific version can be
>>>    renamed to some thing like arch_of_get_cpu_node.
>>>    Also most of the calls to arch specific function can be moved to
>>>    generic code.
>>>
>>> Let me know your thoughts.
>>
>> It is up to Rafael if he is willing/able to rebase his tree, but I
>> would drop this series until this is sorted out.
> 
> Yeah, I've just done that.
> 
Thanks Rafael, sorry for the trouble. I didn't expect of_* name-space to
be used in ARCH specific code.

>> I think the new common function should be and can be generalized to work for
>> powerpc.
>> It would need to make reg property optional and pass in the device
>> node to the arch specific function.
>>
>> A short term solution would be just to make the function "#ifndef CONFIG_PPC".
> 
> I wouldn't do that, it's almost guaranteed to be messy going forward.
> 
> I'd go for 1 above personally.

Even though it's easier approach, I would go for fixing PPC and converge
at generic of_get_cpu_node implementation if possible.

Regards,
Sudeep




^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14  9:23           ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14  9:23 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: Rob Herring, Sudeep KarkadaNagesha, rob.herring,
	Benjamin Herrenschmidt, linuxppc-dev, Viresh Kumar,
	Olof Johansson, linux-pm, linux-arm-kernel, linux-kernel,
	devicetree

On 13/08/13 20:45, Rafael J. Wysocki wrote:
> On Tuesday, August 13, 2013 01:44:23 PM Rob Herring wrote:
>> On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
>> <Sudeep.KarkadaNagesha@arm.com> wrote:
>>> Adding PowerPC list
>>>
>>> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>>>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>>>> The following changes since commit
>>>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>>>
>>>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>>>
>>>>> are available in the git repository at:
>>>>>
>>>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>
>> [snip]
>>
>>>> All error/warnings:
>>>>
>>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>>>> from include/linux/kvm_host.h:30, from
>>>> arch/powerpc/kernel/asm-offsets.c:53:
>>>> include/linux/of.h:269:28: error: conflicting types for
>>>> 'of_get_cpu_node'
>>>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>>>> included from include/linux/of.h:139:0, from
>>>> arch/powerpc/include/asm/kvm_para.h:26, from
>>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>>>> from include/linux/kvm_host.h:30, from
>>>> arch/powerpc/kernel/asm-offsets.c:53:
>>>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>>>> of 'of_get_cpu_node' was here
>>>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
>>>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>>>> Target `__build' not remade because of errors. make[1]: ***
>>>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>>>> errors. make: *** [sub-make] Error 2
>>>>
>>>
>>> There seems to be conflict in the new function "of_get_cpu_node" added.
>>> PowerPC also defines the same function name. Further microblaze and
>>> openrisc declares it(can be removed) but doesn't define it.
>>> To fix this:
>>> 1. I can rename the newly added function to something different like
>>>    `of_get_cpunode` or
>>> 2. If of_* namespace should be used by only OF/FDT and not by any
>>>    architecture specific code, then the arch specific version can be
>>>    renamed to some thing like arch_of_get_cpu_node.
>>>    Also most of the calls to arch specific function can be moved to
>>>    generic code.
>>>
>>> Let me know your thoughts.
>>
>> It is up to Rafael if he is willing/able to rebase his tree, but I
>> would drop this series until this is sorted out.
> 
> Yeah, I've just done that.
> 
Thanks Rafael, sorry for the trouble. I didn't expect of_* name-space to
be used in ARCH specific code.

>> I think the new common function should be and can be generalized to work for
>> powerpc.
>> It would need to make reg property optional and pass in the device
>> node to the arch specific function.
>>
>> A short term solution would be just to make the function "#ifndef CONFIG_PPC".
> 
> I wouldn't do that, it's almost guaranteed to be messy going forward.
> 
> I'd go for 1 above personally.

Even though it's easier approach, I would go for fixing PPC and converge
at generic of_get_cpu_node implementation if possible.

Regards,
Sudeep




^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14  9:23           ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14  9:23 UTC (permalink / raw)
  To: Rafael J. Wysocki
  Cc: devicetree, linux-pm, Sudeep KarkadaNagesha, linux-kernel,
	rob.herring, Rob Herring, Viresh Kumar, Olof Johansson,
	linuxppc-dev, linux-arm-kernel

On 13/08/13 20:45, Rafael J. Wysocki wrote:
> On Tuesday, August 13, 2013 01:44:23 PM Rob Herring wrote:
>> On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
>> <Sudeep.KarkadaNagesha@arm.com> wrote:
>>> Adding PowerPC list
>>>
>>> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>>>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>>>> The following changes since commit
>>>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>>>
>>>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>>>
>>>>> are available in the git repository at:
>>>>>
>>>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>
>> [snip]
>>
>>>> All error/warnings:
>>>>
>>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>>>> from include/linux/kvm_host.h:30, from
>>>> arch/powerpc/kernel/asm-offsets.c:53:
>>>> include/linux/of.h:269:28: error: conflicting types for
>>>> 'of_get_cpu_node'
>>>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>>>> included from include/linux/of.h:139:0, from
>>>> arch/powerpc/include/asm/kvm_para.h:26, from
>>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>>>> from include/linux/kvm_host.h:30, from
>>>> arch/powerpc/kernel/asm-offsets.c:53:
>>>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>>>> of 'of_get_cpu_node' was here
>>>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
>>>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>>>> Target `__build' not remade because of errors. make[1]: ***
>>>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>>>> errors. make: *** [sub-make] Error 2
>>>>
>>>
>>> There seems to be conflict in the new function "of_get_cpu_node" added.
>>> PowerPC also defines the same function name. Further microblaze and
>>> openrisc declares it(can be removed) but doesn't define it.
>>> To fix this:
>>> 1. I can rename the newly added function to something different like
>>>    `of_get_cpunode` or
>>> 2. If of_* namespace should be used by only OF/FDT and not by any
>>>    architecture specific code, then the arch specific version can be
>>>    renamed to some thing like arch_of_get_cpu_node.
>>>    Also most of the calls to arch specific function can be moved to
>>>    generic code.
>>>
>>> Let me know your thoughts.
>>
>> It is up to Rafael if he is willing/able to rebase his tree, but I
>> would drop this series until this is sorted out.
>=20
> Yeah, I've just done that.
>=20
Thanks Rafael, sorry for the trouble. I didn't expect of_* name-space to
be used in ARCH specific code.

>> I think the new common function should be and can be generalized to work=
 for
>> powerpc.
>> It would need to make reg property optional and pass in the device
>> node to the arch specific function.
>>
>> A short term solution would be just to make the function "#ifndef CONFIG=
_PPC".
>=20
> I wouldn't do that, it's almost guaranteed to be messy going forward.
>=20
> I'd go for 1 above personally.

Even though it's easier approach, I would go for fixing PPC and converge
at generic of_get_cpu_node implementation if possible.

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14  9:23           ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14  9:23 UTC (permalink / raw)
  To: linux-arm-kernel

On 13/08/13 20:45, Rafael J. Wysocki wrote:
> On Tuesday, August 13, 2013 01:44:23 PM Rob Herring wrote:
>> On Tue, Aug 13, 2013 at 10:40 AM, Sudeep KarkadaNagesha
>> <Sudeep.KarkadaNagesha@arm.com> wrote:
>>> Adding PowerPC list
>>>
>>> On 13/08/13 14:00, Rafael J. Wysocki wrote:
>>>> On Monday, August 12, 2013 02:27:47 PM Sudeep KarkadaNagesha wrote:
>>>>> The following changes since commit
>>>>> d4e4ab86bcba5a72779c43dc1459f71fea3d89c8:
>>>>>
>>>>> Linux 3.11-rc5 (2013-08-11 18:04:20 -0700)
>>>>>
>>>>> are available in the git repository at:
>>>>>
>>>>> git://linux-arm.org/linux-skn.git cpu_of_node
>>
>> [snip]
>>
>>>> All error/warnings:
>>>>
>>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>>> warning: (MPC836x_RDK && MTD_NAND_FSL_ELBC && MTD_NAND_FSL_UPM)
>>>> selects FSL_LBC which has unmet direct dependencies (FSL_SOC)
>>>> In file included from arch/powerpc/include/asm/kvm_para.h:26:0, from
>>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>>>> from include/linux/kvm_host.h:30, from
>>>> arch/powerpc/kernel/asm-offsets.c:53:
>>>> include/linux/of.h:269:28: error: conflicting types for
>>>> 'of_get_cpu_node'
>>>> extern struct device_node *of_get_cpu_node(int cpu); ^ In file
>>>> included from include/linux/of.h:139:0, from
>>>> arch/powerpc/include/asm/kvm_para.h:26, from
>>>> include/uapi/linux/kvm_para.h:26, from include/linux/kvm_para.h:4,
>>>> from include/linux/kvm_host.h:30, from
>>>> arch/powerpc/kernel/asm-offsets.c:53:
>>>> arch/powerpc/include/asm/prom.h:47:21: note: previous declaration
>>>> of 'of_get_cpu_node' was here
>>>> struct device_node *of_get_cpu_node(int cpu, unsigned int *thread);
>>>> ^ make[2]: *** [arch/powerpc/kernel/asm-offsets.s] Error 1 make[2]:
>>>> Target `__build' not remade because of errors. make[1]: ***
>>>> [prepare0] Error 2 make[1]: Target `prepare' not remade because of
>>>> errors. make: *** [sub-make] Error 2
>>>>
>>>
>>> There seems to be conflict in the new function "of_get_cpu_node" added.
>>> PowerPC also defines the same function name. Further microblaze and
>>> openrisc declares it(can be removed) but doesn't define it.
>>> To fix this:
>>> 1. I can rename the newly added function to something different like
>>>    `of_get_cpunode` or
>>> 2. If of_* namespace should be used by only OF/FDT and not by any
>>>    architecture specific code, then the arch specific version can be
>>>    renamed to some thing like arch_of_get_cpu_node.
>>>    Also most of the calls to arch specific function can be moved to
>>>    generic code.
>>>
>>> Let me know your thoughts.
>>
>> It is up to Rafael if he is willing/able to rebase his tree, but I
>> would drop this series until this is sorted out.
> 
> Yeah, I've just done that.
> 
Thanks Rafael, sorry for the trouble. I didn't expect of_* name-space to
be used in ARCH specific code.

>> I think the new common function should be and can be generalized to work for
>> powerpc.
>> It would need to make reg property optional and pass in the device
>> node to the arch specific function.
>>
>> A short term solution would be just to make the function "#ifndef CONFIG_PPC".
> 
> I wouldn't do that, it's almost guaranteed to be messy going forward.
> 
> I'd go for 1 above personally.

Even though it's easier approach, I would go for fixing PPC and converge
at generic of_get_cpu_node implementation if possible.

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-13 21:07         ` Benjamin Herrenschmidt
  (?)
  (?)
@ 2013-08-14 10:01           ` Sudeep KarkadaNagesha
  -1 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 10:01 UTC (permalink / raw)
  To: Benjamin Herrenschmidt
  Cc: Sudeep KarkadaNagesha, linuxppc-dev, Rafael J. Wysocki,
	rob.herring, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>> I don't understand completely the use of ibm,ppc-interrupt-server#s and
>> its implications on generic of_get_cpu_node implementation.
>> I see the PPC specific definition of of_get_cpu_node uses thread id only
>> in 2 instances. Based on that, I have tried to move all the other
>> instances to use generic definition.
>>
>> Let me know if the idea is correct.
> 
> No. The device-tree historically only represents cores, not HW threads, so
> it makes sense to retrieve also the thread number corresponding to the CPU.
> 
Ok

> However, the mechanism to represent HW threads in the device-tree is currently
> somewhat platform specific (the ibm,ppc-interrupt-server#s).
I see most of the callers pass NULL to thread id argument except 2
instances in entire tree. If that's the case why can't we move to use
generic of_get_cpu_node in most of those cases and have PPC specific
implementation for the ones using thread id.

> 
> So what you could do for now is:
> 
>  - Have a generic version that always returns 0 as the thread, which is weak
I would prefer to move to generic of_get_cpu_node where ever possible
and rename the function that takes thread id rather than making generic
one weak.

> 
>  - powerpc keeps its own implementation
How about only in cases where it needs thread_id.

> 
>  - Start a discussion on the bindings (if not already there) to define threads
> in a better way at which point the generic function can be updated.
> 
I am not sure if we need to define any new bindings. Excerpts from ePAPR
(v1.1):
"3.7.1 General Properties of CPU nodes
The value of "reg" is a <prop-encoded-array> that defines a unique
CPU/thread id for the CPU/threads represented by the CPU node.
If a CPU supports more than one thread (i.e. multiple streams of
execution) the reg property is an array with 1 element per thread. The
#address-cells on the /cpus node specifies how many cells each element
of the array takes. Software can determine the number of threads by
dividing the size of reg by the parent node's #address-cells."

And this is exactly in agreement to what's implemented in the generic
of_get_cpu_node:

for_each_child_of_node(cpus, cpun) {
        if (of_node_cmp(cpun->type, "cpu"))
                continue;
        cell = of_get_property(cpun, "reg", &prop_len);
        if (!cell) {
                pr_warn("%s: missing reg property\n", cpun->full_name);
                continue;
        }
        prop_len /= sizeof(*cell);
        while (prop_len) {
                hwid = of_read_number(cell, ac);
                prop_len -= ac;
                if (arch_match_cpu_phys_id(cpu, hwid))
                        return cpun;
        }
}

Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
which we can have PPC specific wrapper above the generic one i.e. get
the cpu node and then parse for thread id under custom property.

Let me know your thoughts.

Regards,
Sudeep




^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 10:01           ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 10:01 UTC (permalink / raw)
  To: Benjamin Herrenschmidt
  Cc: Sudeep KarkadaNagesha, linuxppc-dev, Rafael J. Wysocki,
	rob.herring, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>> I don't understand completely the use of ibm,ppc-interrupt-server#s and
>> its implications on generic of_get_cpu_node implementation.
>> I see the PPC specific definition of of_get_cpu_node uses thread id only
>> in 2 instances. Based on that, I have tried to move all the other
>> instances to use generic definition.
>>
>> Let me know if the idea is correct.
> 
> No. The device-tree historically only represents cores, not HW threads, so
> it makes sense to retrieve also the thread number corresponding to the CPU.
> 
Ok

> However, the mechanism to represent HW threads in the device-tree is currently
> somewhat platform specific (the ibm,ppc-interrupt-server#s).
I see most of the callers pass NULL to thread id argument except 2
instances in entire tree. If that's the case why can't we move to use
generic of_get_cpu_node in most of those cases and have PPC specific
implementation for the ones using thread id.

> 
> So what you could do for now is:
> 
>  - Have a generic version that always returns 0 as the thread, which is weak
I would prefer to move to generic of_get_cpu_node where ever possible
and rename the function that takes thread id rather than making generic
one weak.

> 
>  - powerpc keeps its own implementation
How about only in cases where it needs thread_id.

> 
>  - Start a discussion on the bindings (if not already there) to define threads
> in a better way at which point the generic function can be updated.
> 
I am not sure if we need to define any new bindings. Excerpts from ePAPR
(v1.1):
"3.7.1 General Properties of CPU nodes
The value of "reg" is a <prop-encoded-array> that defines a unique
CPU/thread id for the CPU/threads represented by the CPU node.
If a CPU supports more than one thread (i.e. multiple streams of
execution) the reg property is an array with 1 element per thread. The
#address-cells on the /cpus node specifies how many cells each element
of the array takes. Software can determine the number of threads by
dividing the size of reg by the parent node's #address-cells."

And this is exactly in agreement to what's implemented in the generic
of_get_cpu_node:

for_each_child_of_node(cpus, cpun) {
        if (of_node_cmp(cpun->type, "cpu"))
                continue;
        cell = of_get_property(cpun, "reg", &prop_len);
        if (!cell) {
                pr_warn("%s: missing reg property\n", cpun->full_name);
                continue;
        }
        prop_len /= sizeof(*cell);
        while (prop_len) {
                hwid = of_read_number(cell, ac);
                prop_len -= ac;
                if (arch_match_cpu_phys_id(cpu, hwid))
                        return cpun;
        }
}

Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
which we can have PPC specific wrapper above the generic one i.e. get
the cpu node and then parse for thread id under custom property.

Let me know your thoughts.

Regards,
Sudeep




^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 10:01           ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 10:01 UTC (permalink / raw)
  To: Benjamin Herrenschmidt
  Cc: devicetree, linux-pm, Sudeep KarkadaNagesha, Viresh Kumar,
	linux-kernel, rob.herring, Rafael J. Wysocki, Olof Johansson,
	linuxppc-dev, linux-arm-kernel

On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>> I don't understand completely the use of ibm,ppc-interrupt-server#s and
>> its implications on generic of_get_cpu_node implementation.
>> I see the PPC specific definition of of_get_cpu_node uses thread id only
>> in 2 instances. Based on that, I have tried to move all the other
>> instances to use generic definition.
>>
>> Let me know if the idea is correct.
>=20
> No. The device-tree historically only represents cores, not HW threads, s=
o
> it makes sense to retrieve also the thread number corresponding to the CP=
U.
>=20
Ok

> However, the mechanism to represent HW threads in the device-tree is curr=
ently
> somewhat platform specific (the ibm,ppc-interrupt-server#s).
I see most of the callers pass NULL to thread id argument except 2
instances in entire tree. If that's the case why can't we move to use
generic of_get_cpu_node in most of those cases and have PPC specific
implementation for the ones using thread id.

>=20
> So what you could do for now is:
>=20
>  - Have a generic version that always returns 0 as the thread, which is w=
eak
I would prefer to move to generic of_get_cpu_node where ever possible
and rename the function that takes thread id rather than making generic
one weak.

>=20
>  - powerpc keeps its own implementation
How about only in cases where it needs thread_id.

>=20
>  - Start a discussion on the bindings (if not already there) to define th=
reads
> in a better way at which point the generic function can be updated.
>=20
I am not sure if we need to define any new bindings. Excerpts from ePAPR
(v1.1):
"3.7.1 General Properties of CPU nodes
The value of "reg" is a <prop-encoded-array> that defines a unique
CPU/thread id for the CPU/threads represented by the CPU node.
If a CPU supports more than one thread (i.e. multiple streams of
execution) the reg property is an array with 1 element per thread. The
#address-cells on the /cpus node specifies how many cells each element
of the array takes. Software can determine the number of threads by
dividing the size of reg by the parent node's #address-cells."

And this is exactly in agreement to what's implemented in the generic
of_get_cpu_node:

for_each_child_of_node(cpus, cpun) {
        if (of_node_cmp(cpun->type, "cpu"))
                continue;
        cell =3D of_get_property(cpun, "reg", &prop_len);
        if (!cell) {
                pr_warn("%s: missing reg property\n", cpun->full_name);
                continue;
        }
        prop_len /=3D sizeof(*cell);
        while (prop_len) {
                hwid =3D of_read_number(cell, ac);
                prop_len -=3D ac;
                if (arch_match_cpu_phys_id(cpu, hwid))
                        return cpun;
        }
}

Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
which we can have PPC specific wrapper above the generic one i.e. get
the cpu node and then parse for thread id under custom property.

Let me know your thoughts.

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 10:01           ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 10:01 UTC (permalink / raw)
  To: linux-arm-kernel

On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>> I don't understand completely the use of ibm,ppc-interrupt-server#s and
>> its implications on generic of_get_cpu_node implementation.
>> I see the PPC specific definition of of_get_cpu_node uses thread id only
>> in 2 instances. Based on that, I have tried to move all the other
>> instances to use generic definition.
>>
>> Let me know if the idea is correct.
> 
> No. The device-tree historically only represents cores, not HW threads, so
> it makes sense to retrieve also the thread number corresponding to the CPU.
> 
Ok

> However, the mechanism to represent HW threads in the device-tree is currently
> somewhat platform specific (the ibm,ppc-interrupt-server#s).
I see most of the callers pass NULL to thread id argument except 2
instances in entire tree. If that's the case why can't we move to use
generic of_get_cpu_node in most of those cases and have PPC specific
implementation for the ones using thread id.

> 
> So what you could do for now is:
> 
>  - Have a generic version that always returns 0 as the thread, which is weak
I would prefer to move to generic of_get_cpu_node where ever possible
and rename the function that takes thread id rather than making generic
one weak.

> 
>  - powerpc keeps its own implementation
How about only in cases where it needs thread_id.

> 
>  - Start a discussion on the bindings (if not already there) to define threads
> in a better way at which point the generic function can be updated.
> 
I am not sure if we need to define any new bindings. Excerpts from ePAPR
(v1.1):
"3.7.1 General Properties of CPU nodes
The value of "reg" is a <prop-encoded-array> that defines a unique
CPU/thread id for the CPU/threads represented by the CPU node.
If a CPU supports more than one thread (i.e. multiple streams of
execution) the reg property is an array with 1 element per thread. The
#address-cells on the /cpus node specifies how many cells each element
of the array takes. Software can determine the number of threads by
dividing the size of reg by the parent node's #address-cells."

And this is exactly in agreement to what's implemented in the generic
of_get_cpu_node:

for_each_child_of_node(cpus, cpun) {
        if (of_node_cmp(cpun->type, "cpu"))
                continue;
        cell = of_get_property(cpun, "reg", &prop_len);
        if (!cell) {
                pr_warn("%s: missing reg property\n", cpun->full_name);
                continue;
        }
        prop_len /= sizeof(*cell);
        while (prop_len) {
                hwid = of_read_number(cell, ac);
                prop_len -= ac;
                if (arch_match_cpu_phys_id(cpu, hwid))
                        return cpun;
        }
}

Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
which we can have PPC specific wrapper above the generic one i.e. get
the cpu node and then parse for thread id under custom property.

Let me know your thoughts.

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-14 10:01           ` Sudeep KarkadaNagesha
  (?)
@ 2013-08-14 11:37             ` Benjamin Herrenschmidt
  -1 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-14 11:37 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: linuxppc-dev, Rafael J. Wysocki, rob.herring, Viresh Kumar,
	Olof Johansson, linux-pm, linux-arm-kernel, linux-kernel,
	devicetree

On Wed, 2013-08-14 at 11:01 +0100, Sudeep KarkadaNagesha wrote:
> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s",
> for
> which we can have PPC specific wrapper above the generic one i.e. get
> the cpu node and then parse for thread id under custom property.

A wrapper is wrong. I don't want to have to have all ppc callers to use
a different function.

As I said, just make a generic one that returns a thread ID, ie, same
signature as the powerpc one. Make it weak, we can override it in
powerpc-land, or we can move the ibm,ppc-interrupt-server#s handling
into the generic one, it won't hurt, but leave the thread_id return
there, it doesn't hurt it will come in handy in a few cases without
causing code duplication.

Cheers,
Ben.


^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 11:37             ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-14 11:37 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: devicetree, linux-pm, Viresh Kumar, linux-kernel, rob.herring,
	Rafael J. Wysocki, Olof Johansson, linuxppc-dev,
	linux-arm-kernel

On Wed, 2013-08-14 at 11:01 +0100, Sudeep KarkadaNagesha wrote:
> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s",
> for
> which we can have PPC specific wrapper above the generic one i.e. get
> the cpu node and then parse for thread id under custom property.

A wrapper is wrong. I don't want to have to have all ppc callers to use
a different function.

As I said, just make a generic one that returns a thread ID, ie, same
signature as the powerpc one. Make it weak, we can override it in
powerpc-land, or we can move the ibm,ppc-interrupt-server#s handling
into the generic one, it won't hurt, but leave the thread_id return
there, it doesn't hurt it will come in handy in a few cases without
causing code duplication.

Cheers,
Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 11:37             ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-14 11:37 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, 2013-08-14 at 11:01 +0100, Sudeep KarkadaNagesha wrote:
> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s",
> for
> which we can have PPC specific wrapper above the generic one i.e. get
> the cpu node and then parse for thread id under custom property.

A wrapper is wrong. I don't want to have to have all ppc callers to use
a different function.

As I said, just make a generic one that returns a thread ID, ie, same
signature as the powerpc one. Make it weak, we can override it in
powerpc-land, or we can move the ibm,ppc-interrupt-server#s handling
into the generic one, it won't hurt, but leave the thread_id return
there, it doesn't hurt it will come in handy in a few cases without
causing code duplication.

Cheers,
Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-14 10:01           ` Sudeep KarkadaNagesha
  (?)
  (?)
@ 2013-08-14 12:53             ` Rob Herring
  -1 siblings, 0 replies; 79+ messages in thread
From: Rob Herring @ 2013-08-14 12:53 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha, Benjamin Herrenschmidt
  Cc: linuxppc-dev, Rafael J. Wysocki, Viresh Kumar, Olof Johansson,
	linux-pm, linux-arm-kernel, linux-kernel, devicetree

On 08/14/2013 05:01 AM, Sudeep KarkadaNagesha wrote:
> On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
>> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>>> I don't understand completely the use of ibm,ppc-interrupt-server#s and
>>> its implications on generic of_get_cpu_node implementation.
>>> I see the PPC specific definition of of_get_cpu_node uses thread id only
>>> in 2 instances. Based on that, I have tried to move all the other
>>> instances to use generic definition.
>>>
>>> Let me know if the idea is correct.
>>
>> No. The device-tree historically only represents cores, not HW threads, so
>> it makes sense to retrieve also the thread number corresponding to the CPU.
>>
> Ok
> 
>> However, the mechanism to represent HW threads in the device-tree is currently
>> somewhat platform specific (the ibm,ppc-interrupt-server#s).
> I see most of the callers pass NULL to thread id argument except 2
> instances in entire tree. If that's the case why can't we move to use
> generic of_get_cpu_node in most of those cases and have PPC specific
> implementation for the ones using thread id.
> 
>>
>> So what you could do for now is:
>>
>>  - Have a generic version that always returns 0 as the thread, which is weak
> I would prefer to move to generic of_get_cpu_node where ever possible
> and rename the function that takes thread id rather than making generic
> one weak.
> 
>>
>>  - powerpc keeps its own implementation
> How about only in cases where it needs thread_id.
> 
>>
>>  - Start a discussion on the bindings (if not already there) to define threads
>> in a better way at which point the generic function can be updated.
>>
> I am not sure if we need to define any new bindings. Excerpts from ePAPR
> (v1.1):
> "3.7.1 General Properties of CPU nodes
> The value of "reg" is a <prop-encoded-array> that defines a unique
> CPU/thread id for the CPU/threads represented by the CPU node.
> If a CPU supports more than one thread (i.e. multiple streams of
> execution) the reg property is an array with 1 element per thread. The
> #address-cells on the /cpus node specifies how many cells each element
> of the array takes. Software can determine the number of threads by
> dividing the size of reg by the parent node's #address-cells."
> 
> And this is exactly in agreement to what's implemented in the generic
> of_get_cpu_node:
> 
> for_each_child_of_node(cpus, cpun) {
>         if (of_node_cmp(cpun->type, "cpu"))
>                 continue;
>         cell = of_get_property(cpun, "reg", &prop_len);
>         if (!cell) {
>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>                 continue;
>         }
>         prop_len /= sizeof(*cell);
>         while (prop_len) {
>                 hwid = of_read_number(cell, ac);
>                 prop_len -= ac;
>                 if (arch_match_cpu_phys_id(cpu, hwid))
>                         return cpun;
>         }
> }

How about something like this:

for_each_child_of_node(cpus, cpun) {
        if (of_node_cmp(cpun->type, "cpu"))
                continue;

	if (arch_of_get_cpu_node(cpun, thread))
		return cpun;

        cell = of_get_property(cpun, "reg", &prop_len);
        if (!cell) {
                pr_warn("%s: missing reg property\n", cpun->full_name);
                continue;
        }
        prop_len /= sizeof(*cell);
        while (prop_len) {
                hwid = of_read_number(cell, ac);
                prop_len -= ac;
                if (arch_match_cpu_phys_id(cpu, hwid))
       	                return cpun;
        }
}

For PPC:

arch_of_get_cpu_node()
{
        const u32 *intserv;
        unsigned int plen, t;

        /* Check for ibm,ppc-interrupt-server#s. */
        intserv = of_get_property(np, "ibm,ppc-interrupt-server#s",
                                &plen);
        if (!intserv)
		return false;

	hardid = get_hard_smp_processor_id(cpu);

        plen /= sizeof(u32);
        for (t = 0; t < plen; t++) {
                 if (hardid == intserv[t]) {
                         if (thread)
                                  *thread = t;
                         return true;
                 }
        }
	return false;
}

> 
> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
> which we can have PPC specific wrapper above the generic one i.e. get
> the cpu node and then parse for thread id under custom property.
> 
> Let me know your thoughts.
> 
> Regards,
> Sudeep
> 
> 
> 


^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 12:53             ` Rob Herring
  0 siblings, 0 replies; 79+ messages in thread
From: Rob Herring @ 2013-08-14 12:53 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha, Benjamin Herrenschmidt
  Cc: linuxppc-dev, Rafael J. Wysocki, Viresh Kumar, Olof Johansson,
	linux-pm, linux-arm-kernel, linux-kernel, devicetree

On 08/14/2013 05:01 AM, Sudeep KarkadaNagesha wrote:
> On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
>> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>>> I don't understand completely the use of ibm,ppc-interrupt-server#s and
>>> its implications on generic of_get_cpu_node implementation.
>>> I see the PPC specific definition of of_get_cpu_node uses thread id only
>>> in 2 instances. Based on that, I have tried to move all the other
>>> instances to use generic definition.
>>>
>>> Let me know if the idea is correct.
>>
>> No. The device-tree historically only represents cores, not HW threads, so
>> it makes sense to retrieve also the thread number corresponding to the CPU.
>>
> Ok
> 
>> However, the mechanism to represent HW threads in the device-tree is currently
>> somewhat platform specific (the ibm,ppc-interrupt-server#s).
> I see most of the callers pass NULL to thread id argument except 2
> instances in entire tree. If that's the case why can't we move to use
> generic of_get_cpu_node in most of those cases and have PPC specific
> implementation for the ones using thread id.
> 
>>
>> So what you could do for now is:
>>
>>  - Have a generic version that always returns 0 as the thread, which is weak
> I would prefer to move to generic of_get_cpu_node where ever possible
> and rename the function that takes thread id rather than making generic
> one weak.
> 
>>
>>  - powerpc keeps its own implementation
> How about only in cases where it needs thread_id.
> 
>>
>>  - Start a discussion on the bindings (if not already there) to define threads
>> in a better way at which point the generic function can be updated.
>>
> I am not sure if we need to define any new bindings. Excerpts from ePAPR
> (v1.1):
> "3.7.1 General Properties of CPU nodes
> The value of "reg" is a <prop-encoded-array> that defines a unique
> CPU/thread id for the CPU/threads represented by the CPU node.
> If a CPU supports more than one thread (i.e. multiple streams of
> execution) the reg property is an array with 1 element per thread. The
> #address-cells on the /cpus node specifies how many cells each element
> of the array takes. Software can determine the number of threads by
> dividing the size of reg by the parent node's #address-cells."
> 
> And this is exactly in agreement to what's implemented in the generic
> of_get_cpu_node:
> 
> for_each_child_of_node(cpus, cpun) {
>         if (of_node_cmp(cpun->type, "cpu"))
>                 continue;
>         cell = of_get_property(cpun, "reg", &prop_len);
>         if (!cell) {
>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>                 continue;
>         }
>         prop_len /= sizeof(*cell);
>         while (prop_len) {
>                 hwid = of_read_number(cell, ac);
>                 prop_len -= ac;
>                 if (arch_match_cpu_phys_id(cpu, hwid))
>                         return cpun;
>         }
> }

How about something like this:

for_each_child_of_node(cpus, cpun) {
        if (of_node_cmp(cpun->type, "cpu"))
                continue;

	if (arch_of_get_cpu_node(cpun, thread))
		return cpun;

        cell = of_get_property(cpun, "reg", &prop_len);
        if (!cell) {
                pr_warn("%s: missing reg property\n", cpun->full_name);
                continue;
        }
        prop_len /= sizeof(*cell);
        while (prop_len) {
                hwid = of_read_number(cell, ac);
                prop_len -= ac;
                if (arch_match_cpu_phys_id(cpu, hwid))
       	                return cpun;
        }
}

For PPC:

arch_of_get_cpu_node()
{
        const u32 *intserv;
        unsigned int plen, t;

        /* Check for ibm,ppc-interrupt-server#s. */
        intserv = of_get_property(np, "ibm,ppc-interrupt-server#s",
                                &plen);
        if (!intserv)
		return false;

	hardid = get_hard_smp_processor_id(cpu);

        plen /= sizeof(u32);
        for (t = 0; t < plen; t++) {
                 if (hardid == intserv[t]) {
                         if (thread)
                                  *thread = t;
                         return true;
                 }
        }
	return false;
}

> 
> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
> which we can have PPC specific wrapper above the generic one i.e. get
> the cpu node and then parse for thread id under custom property.
> 
> Let me know your thoughts.
> 
> Regards,
> Sudeep
> 
> 
> 

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 12:53             ` Rob Herring
  0 siblings, 0 replies; 79+ messages in thread
From: Rob Herring @ 2013-08-14 12:53 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha, Benjamin Herrenschmidt
  Cc: devicetree, linux-pm, Viresh Kumar, linux-kernel,
	Rafael J. Wysocki, Olof Johansson, linuxppc-dev,
	linux-arm-kernel

On 08/14/2013 05:01 AM, Sudeep KarkadaNagesha wrote:
> On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
>> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>>> I don't understand completely the use of ibm,ppc-interrupt-server#s and
>>> its implications on generic of_get_cpu_node implementation.
>>> I see the PPC specific definition of of_get_cpu_node uses thread id only
>>> in 2 instances. Based on that, I have tried to move all the other
>>> instances to use generic definition.
>>>
>>> Let me know if the idea is correct.
>>
>> No. The device-tree historically only represents cores, not HW threads, so
>> it makes sense to retrieve also the thread number corresponding to the CPU.
>>
> Ok
> 
>> However, the mechanism to represent HW threads in the device-tree is currently
>> somewhat platform specific (the ibm,ppc-interrupt-server#s).
> I see most of the callers pass NULL to thread id argument except 2
> instances in entire tree. If that's the case why can't we move to use
> generic of_get_cpu_node in most of those cases and have PPC specific
> implementation for the ones using thread id.
> 
>>
>> So what you could do for now is:
>>
>>  - Have a generic version that always returns 0 as the thread, which is weak
> I would prefer to move to generic of_get_cpu_node where ever possible
> and rename the function that takes thread id rather than making generic
> one weak.
> 
>>
>>  - powerpc keeps its own implementation
> How about only in cases where it needs thread_id.
> 
>>
>>  - Start a discussion on the bindings (if not already there) to define threads
>> in a better way at which point the generic function can be updated.
>>
> I am not sure if we need to define any new bindings. Excerpts from ePAPR
> (v1.1):
> "3.7.1 General Properties of CPU nodes
> The value of "reg" is a <prop-encoded-array> that defines a unique
> CPU/thread id for the CPU/threads represented by the CPU node.
> If a CPU supports more than one thread (i.e. multiple streams of
> execution) the reg property is an array with 1 element per thread. The
> #address-cells on the /cpus node specifies how many cells each element
> of the array takes. Software can determine the number of threads by
> dividing the size of reg by the parent node's #address-cells."
> 
> And this is exactly in agreement to what's implemented in the generic
> of_get_cpu_node:
> 
> for_each_child_of_node(cpus, cpun) {
>         if (of_node_cmp(cpun->type, "cpu"))
>                 continue;
>         cell = of_get_property(cpun, "reg", &prop_len);
>         if (!cell) {
>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>                 continue;
>         }
>         prop_len /= sizeof(*cell);
>         while (prop_len) {
>                 hwid = of_read_number(cell, ac);
>                 prop_len -= ac;
>                 if (arch_match_cpu_phys_id(cpu, hwid))
>                         return cpun;
>         }
> }

How about something like this:

for_each_child_of_node(cpus, cpun) {
        if (of_node_cmp(cpun->type, "cpu"))
                continue;

	if (arch_of_get_cpu_node(cpun, thread))
		return cpun;

        cell = of_get_property(cpun, "reg", &prop_len);
        if (!cell) {
                pr_warn("%s: missing reg property\n", cpun->full_name);
                continue;
        }
        prop_len /= sizeof(*cell);
        while (prop_len) {
                hwid = of_read_number(cell, ac);
                prop_len -= ac;
                if (arch_match_cpu_phys_id(cpu, hwid))
       	                return cpun;
        }
}

For PPC:

arch_of_get_cpu_node()
{
        const u32 *intserv;
        unsigned int plen, t;

        /* Check for ibm,ppc-interrupt-server#s. */
        intserv = of_get_property(np, "ibm,ppc-interrupt-server#s",
                                &plen);
        if (!intserv)
		return false;

	hardid = get_hard_smp_processor_id(cpu);

        plen /= sizeof(u32);
        for (t = 0; t < plen; t++) {
                 if (hardid == intserv[t]) {
                         if (thread)
                                  *thread = t;
                         return true;
                 }
        }
	return false;
}

> 
> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
> which we can have PPC specific wrapper above the generic one i.e. get
> the cpu node and then parse for thread id under custom property.
> 
> Let me know your thoughts.
> 
> Regards,
> Sudeep
> 
> 
> 

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 12:53             ` Rob Herring
  0 siblings, 0 replies; 79+ messages in thread
From: Rob Herring @ 2013-08-14 12:53 UTC (permalink / raw)
  To: linux-arm-kernel

On 08/14/2013 05:01 AM, Sudeep KarkadaNagesha wrote:
> On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
>> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>>> I don't understand completely the use of ibm,ppc-interrupt-server#s and
>>> its implications on generic of_get_cpu_node implementation.
>>> I see the PPC specific definition of of_get_cpu_node uses thread id only
>>> in 2 instances. Based on that, I have tried to move all the other
>>> instances to use generic definition.
>>>
>>> Let me know if the idea is correct.
>>
>> No. The device-tree historically only represents cores, not HW threads, so
>> it makes sense to retrieve also the thread number corresponding to the CPU.
>>
> Ok
> 
>> However, the mechanism to represent HW threads in the device-tree is currently
>> somewhat platform specific (the ibm,ppc-interrupt-server#s).
> I see most of the callers pass NULL to thread id argument except 2
> instances in entire tree. If that's the case why can't we move to use
> generic of_get_cpu_node in most of those cases and have PPC specific
> implementation for the ones using thread id.
> 
>>
>> So what you could do for now is:
>>
>>  - Have a generic version that always returns 0 as the thread, which is weak
> I would prefer to move to generic of_get_cpu_node where ever possible
> and rename the function that takes thread id rather than making generic
> one weak.
> 
>>
>>  - powerpc keeps its own implementation
> How about only in cases where it needs thread_id.
> 
>>
>>  - Start a discussion on the bindings (if not already there) to define threads
>> in a better way at which point the generic function can be updated.
>>
> I am not sure if we need to define any new bindings. Excerpts from ePAPR
> (v1.1):
> "3.7.1 General Properties of CPU nodes
> The value of "reg" is a <prop-encoded-array> that defines a unique
> CPU/thread id for the CPU/threads represented by the CPU node.
> If a CPU supports more than one thread (i.e. multiple streams of
> execution) the reg property is an array with 1 element per thread. The
> #address-cells on the /cpus node specifies how many cells each element
> of the array takes. Software can determine the number of threads by
> dividing the size of reg by the parent node's #address-cells."
> 
> And this is exactly in agreement to what's implemented in the generic
> of_get_cpu_node:
> 
> for_each_child_of_node(cpus, cpun) {
>         if (of_node_cmp(cpun->type, "cpu"))
>                 continue;
>         cell = of_get_property(cpun, "reg", &prop_len);
>         if (!cell) {
>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>                 continue;
>         }
>         prop_len /= sizeof(*cell);
>         while (prop_len) {
>                 hwid = of_read_number(cell, ac);
>                 prop_len -= ac;
>                 if (arch_match_cpu_phys_id(cpu, hwid))
>                         return cpun;
>         }
> }

How about something like this:

for_each_child_of_node(cpus, cpun) {
        if (of_node_cmp(cpun->type, "cpu"))
                continue;

	if (arch_of_get_cpu_node(cpun, thread))
		return cpun;

        cell = of_get_property(cpun, "reg", &prop_len);
        if (!cell) {
                pr_warn("%s: missing reg property\n", cpun->full_name);
                continue;
        }
        prop_len /= sizeof(*cell);
        while (prop_len) {
                hwid = of_read_number(cell, ac);
                prop_len -= ac;
                if (arch_match_cpu_phys_id(cpu, hwid))
       	                return cpun;
        }
}

For PPC:

arch_of_get_cpu_node()
{
        const u32 *intserv;
        unsigned int plen, t;

        /* Check for ibm,ppc-interrupt-server#s. */
        intserv = of_get_property(np, "ibm,ppc-interrupt-server#s",
                                &plen);
        if (!intserv)
		return false;

	hardid = get_hard_smp_processor_id(cpu);

        plen /= sizeof(u32);
        for (t = 0; t < plen; t++) {
                 if (hardid == intserv[t]) {
                         if (thread)
                                  *thread = t;
                         return true;
                 }
        }
	return false;
}

> 
> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
> which we can have PPC specific wrapper above the generic one i.e. get
> the cpu node and then parse for thread id under custom property.
> 
> Let me know your thoughts.
> 
> Regards,
> Sudeep
> 
> 
> 

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-14 11:37             ` Benjamin Herrenschmidt
  (?)
  (?)
@ 2013-08-14 13:21               ` Sudeep KarkadaNagesha
  -1 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 13:21 UTC (permalink / raw)
  To: Benjamin Herrenschmidt
  Cc: Sudeep KarkadaNagesha, linuxppc-dev, Rafael J. Wysocki,
	rob.herring, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

On 14/08/13 12:37, Benjamin Herrenschmidt wrote:
> On Wed, 2013-08-14 at 11:01 +0100, Sudeep KarkadaNagesha wrote:
>> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s",
>> for
>> which we can have PPC specific wrapper above the generic one i.e. get
>> the cpu node and then parse for thread id under custom property.
> 
> A wrapper is wrong. I don't want to have to have all ppc callers to use
> a different function.
Ok.

On the side note the main intention of this patch series[1] is to avoid
calling of_get_cpu_node function once CPU devices are registered. It
initialises the of_node in all the cpu devices using this function when
registering the CPU device. It can be retrieved from cpu_dev->of_node.
So direct users of of_get_cpu_node can be reduced to avoid unnecessary
parsing of DT to find cpu node.

> 
> As I said, just make a generic one that returns a thread ID, ie, same
> signature as the powerpc one. Make it weak, we can override it in
> powerpc-land,
IMO, making generic definition which adhere to the ePAPR specification
as weak is not so clean.

> or we can move the ibm,ppc-interrupt-server#s handling
> into the generic one, it won't hurt, but leave the thread_id return
> there, it doesn't hurt it will come in handy in a few cases without
> causing code duplication.
> 

IMO moving of handling ibm,ppc-interrupt-server#s to generic code under
#ifdef CONFIG_PPC seems to be cleaner approach than weak definitation.

As per my understanding each thread is a different logical cpu.
Each logical cpu is mapped to unique physical id(either present in reg
field or legacy ibm,ppc-interrupt-server#s field). So given a logical
cpu id we can get the cpu node corresponding to it.
Looking @ smp_setup_cpu_maps in arch/powerpc/kernel/setup-common.c
and the comment in the same file: "This implementation only supports
power of 2 number of threads.." the thread id id is implicit in the
logical cpu id. Do we need to fetch that from DT ?

Regards,
Sudeep

[1] https://lkml.org/lkml/2013/7/22/219


^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 13:21               ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 13:21 UTC (permalink / raw)
  To: Benjamin Herrenschmidt
  Cc: Sudeep KarkadaNagesha, linuxppc-dev, Rafael J. Wysocki,
	rob.herring, Viresh Kumar, Olof Johansson, linux-pm,
	linux-arm-kernel, linux-kernel, devicetree

On 14/08/13 12:37, Benjamin Herrenschmidt wrote:
> On Wed, 2013-08-14 at 11:01 +0100, Sudeep KarkadaNagesha wrote:
>> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s",
>> for
>> which we can have PPC specific wrapper above the generic one i.e. get
>> the cpu node and then parse for thread id under custom property.
> 
> A wrapper is wrong. I don't want to have to have all ppc callers to use
> a different function.
Ok.

On the side note the main intention of this patch series[1] is to avoid
calling of_get_cpu_node function once CPU devices are registered. It
initialises the of_node in all the cpu devices using this function when
registering the CPU device. It can be retrieved from cpu_dev->of_node.
So direct users of of_get_cpu_node can be reduced to avoid unnecessary
parsing of DT to find cpu node.

> 
> As I said, just make a generic one that returns a thread ID, ie, same
> signature as the powerpc one. Make it weak, we can override it in
> powerpc-land,
IMO, making generic definition which adhere to the ePAPR specification
as weak is not so clean.

> or we can move the ibm,ppc-interrupt-server#s handling
> into the generic one, it won't hurt, but leave the thread_id return
> there, it doesn't hurt it will come in handy in a few cases without
> causing code duplication.
> 

IMO moving of handling ibm,ppc-interrupt-server#s to generic code under
#ifdef CONFIG_PPC seems to be cleaner approach than weak definitation.

As per my understanding each thread is a different logical cpu.
Each logical cpu is mapped to unique physical id(either present in reg
field or legacy ibm,ppc-interrupt-server#s field). So given a logical
cpu id we can get the cpu node corresponding to it.
Looking @ smp_setup_cpu_maps in arch/powerpc/kernel/setup-common.c
and the comment in the same file: "This implementation only supports
power of 2 number of threads.." the thread id id is implicit in the
logical cpu id. Do we need to fetch that from DT ?

Regards,
Sudeep

[1] https://lkml.org/lkml/2013/7/22/219


^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 13:21               ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 13:21 UTC (permalink / raw)
  To: Benjamin Herrenschmidt
  Cc: devicetree, linux-pm, Sudeep KarkadaNagesha, Viresh Kumar,
	linux-kernel, rob.herring, Rafael J. Wysocki, Olof Johansson,
	linuxppc-dev, linux-arm-kernel

On 14/08/13 12:37, Benjamin Herrenschmidt wrote:
> On Wed, 2013-08-14 at 11:01 +0100, Sudeep KarkadaNagesha wrote:
>> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s",
>> for
>> which we can have PPC specific wrapper above the generic one i.e. get
>> the cpu node and then parse for thread id under custom property.
>=20
> A wrapper is wrong. I don't want to have to have all ppc callers to use
> a different function.
Ok.

On the side note the main intention of this patch series[1] is to avoid
calling of_get_cpu_node function once CPU devices are registered. It
initialises the of_node in all the cpu devices using this function when
registering the CPU device. It can be retrieved from cpu_dev->of_node.
So direct users of of_get_cpu_node can be reduced to avoid unnecessary
parsing of DT to find cpu node.

>=20
> As I said, just make a generic one that returns a thread ID, ie, same
> signature as the powerpc one. Make it weak, we can override it in
> powerpc-land,
IMO, making generic definition which adhere to the ePAPR specification
as weak is not so clean.

> or we can move the ibm,ppc-interrupt-server#s handling
> into the generic one, it won't hurt, but leave the thread_id return
> there, it doesn't hurt it will come in handy in a few cases without
> causing code duplication.
>=20

IMO moving of handling ibm,ppc-interrupt-server#s to generic code under
#ifdef CONFIG_PPC seems to be cleaner approach than weak definitation.

As per my understanding each thread is a different logical cpu.
Each logical cpu is mapped to unique physical id(either present in reg
field or legacy ibm,ppc-interrupt-server#s field). So given a logical
cpu id we can get the cpu node corresponding to it.
Looking @ smp_setup_cpu_maps in arch/powerpc/kernel/setup-common.c
and the comment in the same file: "This implementation only supports
power of 2 number of threads.." the thread id id is implicit in the
logical cpu id. Do we need to fetch that from DT ?

Regards,
Sudeep

[1] https://lkml.org/lkml/2013/7/22/219

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 13:21               ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 13:21 UTC (permalink / raw)
  To: linux-arm-kernel

On 14/08/13 12:37, Benjamin Herrenschmidt wrote:
> On Wed, 2013-08-14 at 11:01 +0100, Sudeep KarkadaNagesha wrote:
>> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s",
>> for
>> which we can have PPC specific wrapper above the generic one i.e. get
>> the cpu node and then parse for thread id under custom property.
> 
> A wrapper is wrong. I don't want to have to have all ppc callers to use
> a different function.
Ok.

On the side note the main intention of this patch series[1] is to avoid
calling of_get_cpu_node function once CPU devices are registered. It
initialises the of_node in all the cpu devices using this function when
registering the CPU device. It can be retrieved from cpu_dev->of_node.
So direct users of of_get_cpu_node can be reduced to avoid unnecessary
parsing of DT to find cpu node.

> 
> As I said, just make a generic one that returns a thread ID, ie, same
> signature as the powerpc one. Make it weak, we can override it in
> powerpc-land,
IMO, making generic definition which adhere to the ePAPR specification
as weak is not so clean.

> or we can move the ibm,ppc-interrupt-server#s handling
> into the generic one, it won't hurt, but leave the thread_id return
> there, it doesn't hurt it will come in handy in a few cases without
> causing code duplication.
> 

IMO moving of handling ibm,ppc-interrupt-server#s to generic code under
#ifdef CONFIG_PPC seems to be cleaner approach than weak definitation.

As per my understanding each thread is a different logical cpu.
Each logical cpu is mapped to unique physical id(either present in reg
field or legacy ibm,ppc-interrupt-server#s field). So given a logical
cpu id we can get the cpu node corresponding to it.
Looking @ smp_setup_cpu_maps in arch/powerpc/kernel/setup-common.c
and the comment in the same file: "This implementation only supports
power of 2 number of threads.." the thread id id is implicit in the
logical cpu id. Do we need to fetch that from DT ?

Regards,
Sudeep

[1] https://lkml.org/lkml/2013/7/22/219

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-14 12:53             ` Rob Herring
  (?)
  (?)
@ 2013-08-14 13:27               ` Sudeep KarkadaNagesha
  -1 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 13:27 UTC (permalink / raw)
  To: Rob Herring, Benjamin Herrenschmidt
  Cc: Sudeep KarkadaNagesha, linuxppc-dev, Rafael J. Wysocki,
	Viresh Kumar, Olof Johansson, linux-pm, linux-arm-kernel,
	linux-kernel, devicetree

On 14/08/13 13:53, Rob Herring wrote:
> On 08/14/2013 05:01 AM, Sudeep KarkadaNagesha wrote:
>> On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
>>> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>>>> I don't understand completely the use of ibm,ppc-interrupt-server#s and
>>>> its implications on generic of_get_cpu_node implementation.
>>>> I see the PPC specific definition of of_get_cpu_node uses thread id only
>>>> in 2 instances. Based on that, I have tried to move all the other
>>>> instances to use generic definition.
>>>>
>>>> Let me know if the idea is correct.
>>>
>>> No. The device-tree historically only represents cores, not HW threads, so
>>> it makes sense to retrieve also the thread number corresponding to the CPU.
>>>
>> Ok
>>
>>> However, the mechanism to represent HW threads in the device-tree is currently
>>> somewhat platform specific (the ibm,ppc-interrupt-server#s).
>> I see most of the callers pass NULL to thread id argument except 2
>> instances in entire tree. If that's the case why can't we move to use
>> generic of_get_cpu_node in most of those cases and have PPC specific
>> implementation for the ones using thread id.
>>
>>>
>>> So what you could do for now is:
>>>
>>>  - Have a generic version that always returns 0 as the thread, which is weak
>> I would prefer to move to generic of_get_cpu_node where ever possible
>> and rename the function that takes thread id rather than making generic
>> one weak.
>>
>>>
>>>  - powerpc keeps its own implementation
>> How about only in cases where it needs thread_id.
>>
>>>
>>>  - Start a discussion on the bindings (if not already there) to define threads
>>> in a better way at which point the generic function can be updated.
>>>
>> I am not sure if we need to define any new bindings. Excerpts from ePAPR
>> (v1.1):
>> "3.7.1 General Properties of CPU nodes
>> The value of "reg" is a <prop-encoded-array> that defines a unique
>> CPU/thread id for the CPU/threads represented by the CPU node.
>> If a CPU supports more than one thread (i.e. multiple streams of
>> execution) the reg property is an array with 1 element per thread. The
>> #address-cells on the /cpus node specifies how many cells each element
>> of the array takes. Software can determine the number of threads by
>> dividing the size of reg by the parent node's #address-cells."
>>
>> And this is exactly in agreement to what's implemented in the generic
>> of_get_cpu_node:
>>
>> for_each_child_of_node(cpus, cpun) {
>>         if (of_node_cmp(cpun->type, "cpu"))
>>                 continue;
>>         cell = of_get_property(cpun, "reg", &prop_len);
>>         if (!cell) {
>>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>>                 continue;
>>         }
>>         prop_len /= sizeof(*cell);
>>         while (prop_len) {
>>                 hwid = of_read_number(cell, ac);
>>                 prop_len -= ac;
>>                 if (arch_match_cpu_phys_id(cpu, hwid))
>>                         return cpun;
>>         }
>> }
> 
> How about something like this:
> 
> for_each_child_of_node(cpus, cpun) {
>         if (of_node_cmp(cpun->type, "cpu"))
>                 continue;
> 
> 	if (arch_of_get_cpu_node(cpun, thread))
> 		return cpun;
> 
>         cell = of_get_property(cpun, "reg", &prop_len);
>         if (!cell) {
>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>                 continue;
>         }
>         prop_len /= sizeof(*cell);
>         while (prop_len) {
>                 hwid = of_read_number(cell, ac);
>                 prop_len -= ac;
>                 if (arch_match_cpu_phys_id(cpu, hwid))
>        	                return cpun;
>         }
> }
> 
> For PPC:
> 
> arch_of_get_cpu_node()
> {
>         const u32 *intserv;
>         unsigned int plen, t;
> 
>         /* Check for ibm,ppc-interrupt-server#s. */
>         intserv = of_get_property(np, "ibm,ppc-interrupt-server#s",
>                                 &plen);
>         if (!intserv)
> 		return false;
> 
> 	hardid = get_hard_smp_processor_id(cpu);
> 
>         plen /= sizeof(u32);
>         for (t = 0; t < plen; t++) {
>                  if (hardid == intserv[t]) {
>                          if (thread)
>                                   *thread = t;
>                          return true;
>                  }
>         }
> 	return false;
> }
> 

Sorry responded to earlier mail before seeing this. This approach looks
good, but we still need to have thread id as argument which should be fine.

But as per my understanding on how logical cpu<->hard proccessor id is
setup, the thread_id is implicit in the logical cpu id making it
unnecessary to depend on DT each time.

Regards,
Sudeep

>>
>> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
>> which we can have PPC specific wrapper above the generic one i.e. get
>> the cpu node and then parse for thread id under custom property.
>>
>> Let me know your thoughts.
>>
>> Regards,
>> Sudeep
>>
>>
>>
> 
> 



^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 13:27               ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 13:27 UTC (permalink / raw)
  To: Rob Herring, Benjamin Herrenschmidt
  Cc: Sudeep KarkadaNagesha, linuxppc-dev, Rafael J. Wysocki,
	Viresh Kumar, Olof Johansson, linux-pm, linux-arm-kernel,
	linux-kernel, devicetree

On 14/08/13 13:53, Rob Herring wrote:
> On 08/14/2013 05:01 AM, Sudeep KarkadaNagesha wrote:
>> On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
>>> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>>>> I don't understand completely the use of ibm,ppc-interrupt-server#s and
>>>> its implications on generic of_get_cpu_node implementation.
>>>> I see the PPC specific definition of of_get_cpu_node uses thread id only
>>>> in 2 instances. Based on that, I have tried to move all the other
>>>> instances to use generic definition.
>>>>
>>>> Let me know if the idea is correct.
>>>
>>> No. The device-tree historically only represents cores, not HW threads, so
>>> it makes sense to retrieve also the thread number corresponding to the CPU.
>>>
>> Ok
>>
>>> However, the mechanism to represent HW threads in the device-tree is currently
>>> somewhat platform specific (the ibm,ppc-interrupt-server#s).
>> I see most of the callers pass NULL to thread id argument except 2
>> instances in entire tree. If that's the case why can't we move to use
>> generic of_get_cpu_node in most of those cases and have PPC specific
>> implementation for the ones using thread id.
>>
>>>
>>> So what you could do for now is:
>>>
>>>  - Have a generic version that always returns 0 as the thread, which is weak
>> I would prefer to move to generic of_get_cpu_node where ever possible
>> and rename the function that takes thread id rather than making generic
>> one weak.
>>
>>>
>>>  - powerpc keeps its own implementation
>> How about only in cases where it needs thread_id.
>>
>>>
>>>  - Start a discussion on the bindings (if not already there) to define threads
>>> in a better way at which point the generic function can be updated.
>>>
>> I am not sure if we need to define any new bindings. Excerpts from ePAPR
>> (v1.1):
>> "3.7.1 General Properties of CPU nodes
>> The value of "reg" is a <prop-encoded-array> that defines a unique
>> CPU/thread id for the CPU/threads represented by the CPU node.
>> If a CPU supports more than one thread (i.e. multiple streams of
>> execution) the reg property is an array with 1 element per thread. The
>> #address-cells on the /cpus node specifies how many cells each element
>> of the array takes. Software can determine the number of threads by
>> dividing the size of reg by the parent node's #address-cells."
>>
>> And this is exactly in agreement to what's implemented in the generic
>> of_get_cpu_node:
>>
>> for_each_child_of_node(cpus, cpun) {
>>         if (of_node_cmp(cpun->type, "cpu"))
>>                 continue;
>>         cell = of_get_property(cpun, "reg", &prop_len);
>>         if (!cell) {
>>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>>                 continue;
>>         }
>>         prop_len /= sizeof(*cell);
>>         while (prop_len) {
>>                 hwid = of_read_number(cell, ac);
>>                 prop_len -= ac;
>>                 if (arch_match_cpu_phys_id(cpu, hwid))
>>                         return cpun;
>>         }
>> }
> 
> How about something like this:
> 
> for_each_child_of_node(cpus, cpun) {
>         if (of_node_cmp(cpun->type, "cpu"))
>                 continue;
> 
> 	if (arch_of_get_cpu_node(cpun, thread))
> 		return cpun;
> 
>         cell = of_get_property(cpun, "reg", &prop_len);
>         if (!cell) {
>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>                 continue;
>         }
>         prop_len /= sizeof(*cell);
>         while (prop_len) {
>                 hwid = of_read_number(cell, ac);
>                 prop_len -= ac;
>                 if (arch_match_cpu_phys_id(cpu, hwid))
>        	                return cpun;
>         }
> }
> 
> For PPC:
> 
> arch_of_get_cpu_node()
> {
>         const u32 *intserv;
>         unsigned int plen, t;
> 
>         /* Check for ibm,ppc-interrupt-server#s. */
>         intserv = of_get_property(np, "ibm,ppc-interrupt-server#s",
>                                 &plen);
>         if (!intserv)
> 		return false;
> 
> 	hardid = get_hard_smp_processor_id(cpu);
> 
>         plen /= sizeof(u32);
>         for (t = 0; t < plen; t++) {
>                  if (hardid == intserv[t]) {
>                          if (thread)
>                                   *thread = t;
>                          return true;
>                  }
>         }
> 	return false;
> }
> 

Sorry responded to earlier mail before seeing this. This approach looks
good, but we still need to have thread id as argument which should be fine.

But as per my understanding on how logical cpu<->hard proccessor id is
setup, the thread_id is implicit in the logical cpu id making it
unnecessary to depend on DT each time.

Regards,
Sudeep

>>
>> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
>> which we can have PPC specific wrapper above the generic one i.e. get
>> the cpu node and then parse for thread id under custom property.
>>
>> Let me know your thoughts.
>>
>> Regards,
>> Sudeep
>>
>>
>>
> 
> 



^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 13:27               ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 13:27 UTC (permalink / raw)
  To: Rob Herring, Benjamin Herrenschmidt
  Cc: devicetree, linux-pm, Sudeep KarkadaNagesha, Viresh Kumar,
	linux-kernel, Rafael J. Wysocki, Olof Johansson, linuxppc-dev,
	linux-arm-kernel

On 14/08/13 13:53, Rob Herring wrote:
> On 08/14/2013 05:01 AM, Sudeep KarkadaNagesha wrote:
>> On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
>>> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>>>> I don't understand completely the use of ibm,ppc-interrupt-server#s an=
d
>>>> its implications on generic of_get_cpu_node implementation.
>>>> I see the PPC specific definition of of_get_cpu_node uses thread id on=
ly
>>>> in 2 instances. Based on that, I have tried to move all the other
>>>> instances to use generic definition.
>>>>
>>>> Let me know if the idea is correct.
>>>
>>> No. The device-tree historically only represents cores, not HW threads,=
 so
>>> it makes sense to retrieve also the thread number corresponding to the =
CPU.
>>>
>> Ok
>>
>>> However, the mechanism to represent HW threads in the device-tree is cu=
rrently
>>> somewhat platform specific (the ibm,ppc-interrupt-server#s).
>> I see most of the callers pass NULL to thread id argument except 2
>> instances in entire tree. If that's the case why can't we move to use
>> generic of_get_cpu_node in most of those cases and have PPC specific
>> implementation for the ones using thread id.
>>
>>>
>>> So what you could do for now is:
>>>
>>>  - Have a generic version that always returns 0 as the thread, which is=
 weak
>> I would prefer to move to generic of_get_cpu_node where ever possible
>> and rename the function that takes thread id rather than making generic
>> one weak.
>>
>>>
>>>  - powerpc keeps its own implementation
>> How about only in cases where it needs thread_id.
>>
>>>
>>>  - Start a discussion on the bindings (if not already there) to define =
threads
>>> in a better way at which point the generic function can be updated.
>>>
>> I am not sure if we need to define any new bindings. Excerpts from ePAPR
>> (v1.1):
>> "3.7.1 General Properties of CPU nodes
>> The value of "reg" is a <prop-encoded-array> that defines a unique
>> CPU/thread id for the CPU/threads represented by the CPU node.
>> If a CPU supports more than one thread (i.e. multiple streams of
>> execution) the reg property is an array with 1 element per thread. The
>> #address-cells on the /cpus node specifies how many cells each element
>> of the array takes. Software can determine the number of threads by
>> dividing the size of reg by the parent node's #address-cells."
>>
>> And this is exactly in agreement to what's implemented in the generic
>> of_get_cpu_node:
>>
>> for_each_child_of_node(cpus, cpun) {
>>         if (of_node_cmp(cpun->type, "cpu"))
>>                 continue;
>>         cell =3D of_get_property(cpun, "reg", &prop_len);
>>         if (!cell) {
>>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>>                 continue;
>>         }
>>         prop_len /=3D sizeof(*cell);
>>         while (prop_len) {
>>                 hwid =3D of_read_number(cell, ac);
>>                 prop_len -=3D ac;
>>                 if (arch_match_cpu_phys_id(cpu, hwid))
>>                         return cpun;
>>         }
>> }
>=20
> How about something like this:
>=20
> for_each_child_of_node(cpus, cpun) {
>         if (of_node_cmp(cpun->type, "cpu"))
>                 continue;
>=20
> =09if (arch_of_get_cpu_node(cpun, thread))
> =09=09return cpun;
>=20
>         cell =3D of_get_property(cpun, "reg", &prop_len);
>         if (!cell) {
>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>                 continue;
>         }
>         prop_len /=3D sizeof(*cell);
>         while (prop_len) {
>                 hwid =3D of_read_number(cell, ac);
>                 prop_len -=3D ac;
>                 if (arch_match_cpu_phys_id(cpu, hwid))
>        =09                return cpun;
>         }
> }
>=20
> For PPC:
>=20
> arch_of_get_cpu_node()
> {
>         const u32 *intserv;
>         unsigned int plen, t;
>=20
>         /* Check for ibm,ppc-interrupt-server#s. */
>         intserv =3D of_get_property(np, "ibm,ppc-interrupt-server#s",
>                                 &plen);
>         if (!intserv)
> =09=09return false;
>=20
> =09hardid =3D get_hard_smp_processor_id(cpu);
>=20
>         plen /=3D sizeof(u32);
>         for (t =3D 0; t < plen; t++) {
>                  if (hardid =3D=3D intserv[t]) {
>                          if (thread)
>                                   *thread =3D t;
>                          return true;
>                  }
>         }
> =09return false;
> }
>=20

Sorry responded to earlier mail before seeing this. This approach looks
good, but we still need to have thread id as argument which should be fine.

But as per my understanding on how logical cpu<->hard proccessor id is
setup, the thread_id is implicit in the logical cpu id making it
unnecessary to depend on DT each time.

Regards,
Sudeep

>>
>> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
>> which we can have PPC specific wrapper above the generic one i.e. get
>> the cpu node and then parse for thread id under custom property.
>>
>> Let me know your thoughts.
>>
>> Regards,
>> Sudeep
>>
>>
>>
>=20
>=20

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 13:27               ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-14 13:27 UTC (permalink / raw)
  To: linux-arm-kernel

On 14/08/13 13:53, Rob Herring wrote:
> On 08/14/2013 05:01 AM, Sudeep KarkadaNagesha wrote:
>> On 13/08/13 22:07, Benjamin Herrenschmidt wrote:
>>> On Tue, 2013-08-13 at 19:29 +0100, Sudeep KarkadaNagesha wrote:
>>>> I don't understand completely the use of ibm,ppc-interrupt-server#s and
>>>> its implications on generic of_get_cpu_node implementation.
>>>> I see the PPC specific definition of of_get_cpu_node uses thread id only
>>>> in 2 instances. Based on that, I have tried to move all the other
>>>> instances to use generic definition.
>>>>
>>>> Let me know if the idea is correct.
>>>
>>> No. The device-tree historically only represents cores, not HW threads, so
>>> it makes sense to retrieve also the thread number corresponding to the CPU.
>>>
>> Ok
>>
>>> However, the mechanism to represent HW threads in the device-tree is currently
>>> somewhat platform specific (the ibm,ppc-interrupt-server#s).
>> I see most of the callers pass NULL to thread id argument except 2
>> instances in entire tree. If that's the case why can't we move to use
>> generic of_get_cpu_node in most of those cases and have PPC specific
>> implementation for the ones using thread id.
>>
>>>
>>> So what you could do for now is:
>>>
>>>  - Have a generic version that always returns 0 as the thread, which is weak
>> I would prefer to move to generic of_get_cpu_node where ever possible
>> and rename the function that takes thread id rather than making generic
>> one weak.
>>
>>>
>>>  - powerpc keeps its own implementation
>> How about only in cases where it needs thread_id.
>>
>>>
>>>  - Start a discussion on the bindings (if not already there) to define threads
>>> in a better way at which point the generic function can be updated.
>>>
>> I am not sure if we need to define any new bindings. Excerpts from ePAPR
>> (v1.1):
>> "3.7.1 General Properties of CPU nodes
>> The value of "reg" is a <prop-encoded-array> that defines a unique
>> CPU/thread id for the CPU/threads represented by the CPU node.
>> If a CPU supports more than one thread (i.e. multiple streams of
>> execution) the reg property is an array with 1 element per thread. The
>> #address-cells on the /cpus node specifies how many cells each element
>> of the array takes. Software can determine the number of threads by
>> dividing the size of reg by the parent node's #address-cells."
>>
>> And this is exactly in agreement to what's implemented in the generic
>> of_get_cpu_node:
>>
>> for_each_child_of_node(cpus, cpun) {
>>         if (of_node_cmp(cpun->type, "cpu"))
>>                 continue;
>>         cell = of_get_property(cpun, "reg", &prop_len);
>>         if (!cell) {
>>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>>                 continue;
>>         }
>>         prop_len /= sizeof(*cell);
>>         while (prop_len) {
>>                 hwid = of_read_number(cell, ac);
>>                 prop_len -= ac;
>>                 if (arch_match_cpu_phys_id(cpu, hwid))
>>                         return cpun;
>>         }
>> }
> 
> How about something like this:
> 
> for_each_child_of_node(cpus, cpun) {
>         if (of_node_cmp(cpun->type, "cpu"))
>                 continue;
> 
> 	if (arch_of_get_cpu_node(cpun, thread))
> 		return cpun;
> 
>         cell = of_get_property(cpun, "reg", &prop_len);
>         if (!cell) {
>                 pr_warn("%s: missing reg property\n", cpun->full_name);
>                 continue;
>         }
>         prop_len /= sizeof(*cell);
>         while (prop_len) {
>                 hwid = of_read_number(cell, ac);
>                 prop_len -= ac;
>                 if (arch_match_cpu_phys_id(cpu, hwid))
>        	                return cpun;
>         }
> }
> 
> For PPC:
> 
> arch_of_get_cpu_node()
> {
>         const u32 *intserv;
>         unsigned int plen, t;
> 
>         /* Check for ibm,ppc-interrupt-server#s. */
>         intserv = of_get_property(np, "ibm,ppc-interrupt-server#s",
>                                 &plen);
>         if (!intserv)
> 		return false;
> 
> 	hardid = get_hard_smp_processor_id(cpu);
> 
>         plen /= sizeof(u32);
>         for (t = 0; t < plen; t++) {
>                  if (hardid == intserv[t]) {
>                          if (thread)
>                                   *thread = t;
>                          return true;
>                  }
>         }
> 	return false;
> }
> 

Sorry responded to earlier mail before seeing this. This approach looks
good, but we still need to have thread id as argument which should be fine.

But as per my understanding on how logical cpu<->hard proccessor id is
setup, the thread_id is implicit in the logical cpu id making it
unnecessary to depend on DT each time.

Regards,
Sudeep

>>
>> Yes this doesn't cover the historical "ibm,ppc-interrupt-server#s", for
>> which we can have PPC specific wrapper above the generic one i.e. get
>> the cpu node and then parse for thread id under custom property.
>>
>> Let me know your thoughts.
>>
>> Regards,
>> Sudeep
>>
>>
>>
> 
> 

^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-14 13:21               ` Sudeep KarkadaNagesha
  (?)
@ 2013-08-14 22:57                 ` Benjamin Herrenschmidt
  -1 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-14 22:57 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: linuxppc-dev, Rafael J. Wysocki, rob.herring, Viresh Kumar,
	Olof Johansson, linux-pm, linux-arm-kernel, linux-kernel,
	devicetree

On Wed, 2013-08-14 at 14:21 +0100, Sudeep KarkadaNagesha wrote:
> IMO moving of handling ibm,ppc-interrupt-server#s to generic code
> under
> #ifdef CONFIG_PPC seems to be cleaner approach than weak definitation.
> 
> As per my understanding each thread is a different logical cpu.
> Each logical cpu is mapped to unique physical id(either present in reg
> field or legacy ibm,ppc-interrupt-server#s field). So given a logical
> cpu id we can get the cpu node corresponding to it.
> Looking @ smp_setup_cpu_maps in arch/powerpc/kernel/setup-common.c
> and the comment in the same file: "This implementation only supports
> power of 2 number of threads.." the thread id id is implicit in the
> logical cpu id. Do we need to fetch that from DT ?

I don't want those parsing routines to make those assumptions. We have
changed our logical numbering in the past and may again.

Cheers,
Ben.



^ permalink raw reply	[flat|nested] 79+ messages in thread

* Re: [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 22:57                 ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-14 22:57 UTC (permalink / raw)
  To: Sudeep KarkadaNagesha
  Cc: devicetree, linux-pm, Viresh Kumar, linux-kernel, rob.herring,
	Rafael J. Wysocki, Olof Johansson, linuxppc-dev,
	linux-arm-kernel

On Wed, 2013-08-14 at 14:21 +0100, Sudeep KarkadaNagesha wrote:
> IMO moving of handling ibm,ppc-interrupt-server#s to generic code
> under
> #ifdef CONFIG_PPC seems to be cleaner approach than weak definitation.
> 
> As per my understanding each thread is a different logical cpu.
> Each logical cpu is mapped to unique physical id(either present in reg
> field or legacy ibm,ppc-interrupt-server#s field). So given a logical
> cpu id we can get the cpu node corresponding to it.
> Looking @ smp_setup_cpu_maps in arch/powerpc/kernel/setup-common.c
> and the comment in the same file: "This implementation only supports
> power of 2 number of threads.." the thread id id is implicit in the
> logical cpu id. Do we need to fetch that from DT ?

I don't want those parsing routines to make those assumptions. We have
changed our logical numbering in the past and may again.

Cheers,
Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-14 22:57                 ` Benjamin Herrenschmidt
  0 siblings, 0 replies; 79+ messages in thread
From: Benjamin Herrenschmidt @ 2013-08-14 22:57 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, 2013-08-14 at 14:21 +0100, Sudeep KarkadaNagesha wrote:
> IMO moving of handling ibm,ppc-interrupt-server#s to generic code
> under
> #ifdef CONFIG_PPC seems to be cleaner approach than weak definitation.
> 
> As per my understanding each thread is a different logical cpu.
> Each logical cpu is mapped to unique physical id(either present in reg
> field or legacy ibm,ppc-interrupt-server#s field). So given a logical
> cpu id we can get the cpu node corresponding to it.
> Looking @ smp_setup_cpu_maps in arch/powerpc/kernel/setup-common.c
> and the comment in the same file: "This implementation only supports
> power of 2 number of threads.." the thread id id is implicit in the
> logical cpu id. Do we need to fetch that from DT ?

I don't want those parsing routines to make those assumptions. We have
changed our logical numbering in the past and may again.

Cheers,
Ben.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-12 12:41             ` Sudeep KarkadaNagesha
@ 2013-08-12 13:13               ` Rafael J. Wysocki
  2013-08-12 13:06                 ` Sudeep KarkadaNagesha
  0 siblings, 1 reply; 79+ messages in thread
From: Rafael J. Wysocki @ 2013-08-12 13:13 UTC (permalink / raw)
  To: linux-arm-kernel

On Monday, August 12, 2013 01:41:58 PM Sudeep KarkadaNagesha wrote:
> Hi Rafael,
> 
> On 12/08/13 12:51, Rafael J. Wysocki wrote:
> > On Monday, August 12, 2013 02:33:32 PM Viresh Kumar wrote:
> >> On 12 August 2013 14:24, Sudeep KarkadaNagesha
> >> <Sudeep.KarkadaNagesha@arm.com> wrote:
> >>> Can you please let which know which branch do you prefer to base the my
> >>> request on ?
> >>
> >> Unless you have any dependencies, you must rebase on latest RC..
> > 
> > Yes, preferably 3.11-rc5.
> > 
> > If there are any dependencies on linux-next material, please let me know.
> > 
> 
> It doesn't have any functional dependencies, however I just found out
> now that there's a conflict with today's linux-next branch(tag:
> next-20130812)

That's not a big deal.

Thanks,
Rafael


-- 
I speak only for myself.
Rafael J. Wysocki, Intel Open Source Technology Center.

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-12 13:13               ` Rafael J. Wysocki
@ 2013-08-12 13:06                 ` Sudeep KarkadaNagesha
  0 siblings, 0 replies; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-12 13:06 UTC (permalink / raw)
  To: linux-arm-kernel

On 12/08/13 14:13, Rafael J. Wysocki wrote:
> On Monday, August 12, 2013 01:41:58 PM Sudeep KarkadaNagesha wrote:
>> Hi Rafael,
>>
>> On 12/08/13 12:51, Rafael J. Wysocki wrote:
>>> On Monday, August 12, 2013 02:33:32 PM Viresh Kumar wrote:
>>>> On 12 August 2013 14:24, Sudeep KarkadaNagesha
>>>> <Sudeep.KarkadaNagesha@arm.com> wrote:
>>>>> Can you please let which know which branch do you prefer to base the my
>>>>> request on ?
>>>>
>>>> Unless you have any dependencies, you must rebase on latest RC..
>>>
>>> Yes, preferably 3.11-rc5.
>>>
>>> If there are any dependencies on linux-next material, please let me know.
>>>
>>
>> It doesn't have any functional dependencies, however I just found out
>> now that there's a conflict with today's linux-next branch(tag:
>> next-20130812)
> 
> That's not a big deal.
> 
Thanks Rafael, in that case I will send the pull request based on 3.11-rc5

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-12 11:51           ` Rafael J. Wysocki
@ 2013-08-12 12:41             ` Sudeep KarkadaNagesha
  2013-08-12 13:13               ` Rafael J. Wysocki
  0 siblings, 1 reply; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-12 12:41 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Rafael,

On 12/08/13 12:51, Rafael J. Wysocki wrote:
> On Monday, August 12, 2013 02:33:32 PM Viresh Kumar wrote:
>> On 12 August 2013 14:24, Sudeep KarkadaNagesha
>> <Sudeep.KarkadaNagesha@arm.com> wrote:
>>> Can you please let which know which branch do you prefer to base the my
>>> request on ?
>>
>> Unless you have any dependencies, you must rebase on latest RC..
> 
> Yes, preferably 3.11-rc5.
> 
> If there are any dependencies on linux-next material, please let me know.
> 

It doesn't have any functional dependencies, however I just found out
now that there's a conflict with today's linux-next branch(tag:
next-20130812)

Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-12  9:03         ` Viresh Kumar
@ 2013-08-12 11:51           ` Rafael J. Wysocki
  2013-08-12 12:41             ` Sudeep KarkadaNagesha
  0 siblings, 1 reply; 79+ messages in thread
From: Rafael J. Wysocki @ 2013-08-12 11:51 UTC (permalink / raw)
  To: linux-arm-kernel

On Monday, August 12, 2013 02:33:32 PM Viresh Kumar wrote:
> On 12 August 2013 14:24, Sudeep KarkadaNagesha
> <Sudeep.KarkadaNagesha@arm.com> wrote:
> > Can you please let which know which branch do you prefer to base the my
> > request on ?
> 
> Unless you have any dependencies, you must rebase on latest RC..

Yes, preferably 3.11-rc5.

If there are any dependencies on linux-next material, please let me know.

Thanks,
Rafael

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-12  8:54       ` Sudeep KarkadaNagesha
@ 2013-08-12  9:03         ` Viresh Kumar
  2013-08-12 11:51           ` Rafael J. Wysocki
  0 siblings, 1 reply; 79+ messages in thread
From: Viresh Kumar @ 2013-08-12  9:03 UTC (permalink / raw)
  To: linux-arm-kernel

On 12 August 2013 14:24, Sudeep KarkadaNagesha
<Sudeep.KarkadaNagesha@arm.com> wrote:
> Can you please let which know which branch do you prefer to base the my
> request on ?

Unless you have any dependencies, you must rebase on latest RC..

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-08 15:49     ` Sudeep KarkadaNagesha
@ 2013-08-12  8:54       ` Sudeep KarkadaNagesha
  2013-08-12  9:03         ` Viresh Kumar
  0 siblings, 1 reply; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-12  8:54 UTC (permalink / raw)
  To: linux-arm-kernel

On 08/08/13 16:49, Sudeep KarkadaNagesha wrote:
> On 08/08/13 16:27, Rob Herring wrote:
>> On Thu, Aug 8, 2013 at 9:43 AM, Sudeep KarkadaNagesha
>> <Sudeep.KarkadaNagesha@arm.com> wrote:
>>> Hi Rob,
>>>
>>> On 06/08/13 17:11, Sudeep KarkadaNagesha wrote:
>>>> Hi Rob,
>>>>
>>>> The following changes since commit c095ba7224d8edc71dcef0d655911399a8bd4a3f:
>>>>
>>>>   Linux 3.11-rc4 (2013-08-04 13:46:46 -0700)
>>>>
>>>> are available in the git repository at:
>>>>
>>>>   git://linux-arm.org/linux-skn.git cpu_ofnode_dt
>>>>
>>>> for you to fetch changes up to d7b5133478afd9e66a338d3125bc37b9a250ef66:
>>>>
>>>>   of/device: add helper to get cpu device node from logical cpu index
>>>> (2013-08-06 16:37:15 +0100)
>>>>
>>>
>>> I was not sure whom to send pull request(you or Grant).
>>> This needs to be pulled in and present in linux-next before I can send
>>> the updates in SoC and cpufreq which depends on this.
>>
>> With necessary acks, you don't need send these to 3 maintainers. I
>> would suggest you send the whole series to cpufreq maintainers to
>> merge rather than have them try to manage 2 dependent branches.
>>
>> Also, something landing in linux-next has no bearing on the process.
>> If you do have dependent branches in another tree, then you need to
>> insure with that maintainer that the branch is stable and inform the
>> 2nd maintainer of the dependency on the branch.
>>
> 
> Thanks Rob for clarifying.
> 
> Hi Rafael,
> 
> The complete series[1] was reviewed and acknowledged by appropriate
> maintainers.
> 
> Since most of the changes are CPUFreq clean-ups, would you take the
> complete series through your tree ?
> 
> On which branch(bleeding-edge or linux-next) on [2] do I need to base my
> pull request ?
Hi Rafael,

Can you please let which know which branch do you prefer to base the my
request on ?

Regards,
Sudeep

> 
> [1]
> http://archive.arm.linux.org.uk/lurker/message/20130722.113211.b5e3bc2a.fr.html
> 
> [2] git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git
> 

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-08 15:27   ` Rob Herring
@ 2013-08-08 15:49     ` Sudeep KarkadaNagesha
  2013-08-12  8:54       ` Sudeep KarkadaNagesha
  0 siblings, 1 reply; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-08 15:49 UTC (permalink / raw)
  To: linux-arm-kernel

On 08/08/13 16:27, Rob Herring wrote:
> On Thu, Aug 8, 2013 at 9:43 AM, Sudeep KarkadaNagesha
> <Sudeep.KarkadaNagesha@arm.com> wrote:
>> Hi Rob,
>>
>> On 06/08/13 17:11, Sudeep KarkadaNagesha wrote:
>>> Hi Rob,
>>>
>>> The following changes since commit c095ba7224d8edc71dcef0d655911399a8bd4a3f:
>>>
>>>   Linux 3.11-rc4 (2013-08-04 13:46:46 -0700)
>>>
>>> are available in the git repository at:
>>>
>>>   git://linux-arm.org/linux-skn.git cpu_ofnode_dt
>>>
>>> for you to fetch changes up to d7b5133478afd9e66a338d3125bc37b9a250ef66:
>>>
>>>   of/device: add helper to get cpu device node from logical cpu index
>>> (2013-08-06 16:37:15 +0100)
>>>
>>
>> I was not sure whom to send pull request(you or Grant).
>> This needs to be pulled in and present in linux-next before I can send
>> the updates in SoC and cpufreq which depends on this.
> 
> With necessary acks, you don't need send these to 3 maintainers. I
> would suggest you send the whole series to cpufreq maintainers to
> merge rather than have them try to manage 2 dependent branches.
> 
> Also, something landing in linux-next has no bearing on the process.
> If you do have dependent branches in another tree, then you need to
> insure with that maintainer that the branch is stable and inform the
> 2nd maintainer of the dependency on the branch.
> 

Thanks Rob for clarifying.

Hi Rafael,

The complete series[1] was reviewed and acknowledged by appropriate
maintainers.

Since most of the changes are CPUFreq clean-ups, would you take the
complete series through your tree ?

On which branch(bleeding-edge or linux-next) on [2] do I need to base my
pull request ?

Regards,
Sudeep

[1]
http://archive.arm.linux.org.uk/lurker/message/20130722.113211.b5e3bc2a.fr.html

[2] git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-08 14:43 ` Sudeep KarkadaNagesha
@ 2013-08-08 15:27   ` Rob Herring
  2013-08-08 15:49     ` Sudeep KarkadaNagesha
  0 siblings, 1 reply; 79+ messages in thread
From: Rob Herring @ 2013-08-08 15:27 UTC (permalink / raw)
  To: linux-arm-kernel

On Thu, Aug 8, 2013 at 9:43 AM, Sudeep KarkadaNagesha
<Sudeep.KarkadaNagesha@arm.com> wrote:
> Hi Rob,
>
> On 06/08/13 17:11, Sudeep KarkadaNagesha wrote:
>> Hi Rob,
>>
>> The following changes since commit c095ba7224d8edc71dcef0d655911399a8bd4a3f:
>>
>>   Linux 3.11-rc4 (2013-08-04 13:46:46 -0700)
>>
>> are available in the git repository at:
>>
>>   git://linux-arm.org/linux-skn.git cpu_ofnode_dt
>>
>> for you to fetch changes up to d7b5133478afd9e66a338d3125bc37b9a250ef66:
>>
>>   of/device: add helper to get cpu device node from logical cpu index
>> (2013-08-06 16:37:15 +0100)
>>
>
> I was not sure whom to send pull request(you or Grant).
> This needs to be pulled in and present in linux-next before I can send
> the updates in SoC and cpufreq which depends on this.

With necessary acks, you don't need send these to 3 maintainers. I
would suggest you send the whole series to cpufreq maintainers to
merge rather than have them try to manage 2 dependent branches.

Also, something landing in linux-next has no bearing on the process.
If you do have dependent branches in another tree, then you need to
insure with that maintainer that the branch is stable and inform the
2nd maintainer of the dependency on the branch.

Rob

>
> Regards,
> Sudeep
>
>> ----------------------------------------------------------------
>> Sudeep KarkadaNagesha (4):
>>    of: add support for retrieving cpu node for a given logical cpu index
>>    ARM: DT/kernel: define ARM specific arch_match_cpu_phys_id
>>    driver/core: cpu: initialize of_node in cpu's device struture
>>    of/device: add helper to get cpu device node from logical cpu index
>>
>>  arch/arm/kernel/devtree.c |  5 +++++
>>  drivers/base/cpu.c        |  2 ++
>>  drivers/of/base.c         | 73 ++++++++++++++++++++++++++++++
>>  include/linux/cpu.h       |  1 +
>>  include/linux/of.h        |  6 ++++++
>>  include/linux/of_device.h | 15 +++++++++++++++
>>  6 files changed, 102 insertions(+)
>>
>> PS: This is DT part of the patch series reviewed and acknowledged @
>>
>> v1:
>> http://archive.arm.linux.org.uk/lurker/message/20130715.102201.dfb8e04e.fr.html
>> v2:
>> http://archive.arm.linux.org.uk/lurker/message/20130717.140609.07fa6237.fr.html
>> v3:
>> http://archive.arm.linux.org.uk/lurker/message/20130722.113211.b5e3bc2a.fr.html
>>
>>
>> Regards,
>> Sudeep
>>
>
>

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
  2013-08-06 16:11 Sudeep KarkadaNagesha
@ 2013-08-08 14:43 ` Sudeep KarkadaNagesha
  2013-08-08 15:27   ` Rob Herring
  0 siblings, 1 reply; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-08 14:43 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Rob,

On 06/08/13 17:11, Sudeep KarkadaNagesha wrote:
> Hi Rob,
> 
> The following changes since commit c095ba7224d8edc71dcef0d655911399a8bd4a3f:
> 
>   Linux 3.11-rc4 (2013-08-04 13:46:46 -0700)
> 
> are available in the git repository at:
> 
>   git://linux-arm.org/linux-skn.git cpu_ofnode_dt
> 
> for you to fetch changes up to d7b5133478afd9e66a338d3125bc37b9a250ef66:
> 
>   of/device: add helper to get cpu device node from logical cpu index
> (2013-08-06 16:37:15 +0100)
> 

I was not sure whom to send pull request(you or Grant).
This needs to be pulled in and present in linux-next before I can send
the updates in SoC and cpufreq which depends on this.

Regards,
Sudeep

> ----------------------------------------------------------------
> Sudeep KarkadaNagesha (4):
>    of: add support for retrieving cpu node for a given logical cpu index
>    ARM: DT/kernel: define ARM specific arch_match_cpu_phys_id
>    driver/core: cpu: initialize of_node in cpu's device struture
>    of/device: add helper to get cpu device node from logical cpu index
> 
>  arch/arm/kernel/devtree.c |  5 +++++
>  drivers/base/cpu.c        |  2 ++
>  drivers/of/base.c         | 73 ++++++++++++++++++++++++++++++
>  include/linux/cpu.h       |  1 +
>  include/linux/of.h        |  6 ++++++
>  include/linux/of_device.h | 15 +++++++++++++++
>  6 files changed, 102 insertions(+)
> 
> PS: This is DT part of the patch series reviewed and acknowledged @
> 
> v1:
> http://archive.arm.linux.org.uk/lurker/message/20130715.102201.dfb8e04e.fr.html
> v2:
> http://archive.arm.linux.org.uk/lurker/message/20130717.140609.07fa6237.fr.html
> v3:
> http://archive.arm.linux.org.uk/lurker/message/20130722.113211.b5e3bc2a.fr.html
> 
> 
> Regards,
> Sudeep
> 

^ permalink raw reply	[flat|nested] 79+ messages in thread

* [GIT PULL] DT/core: cpu_ofnode updates for v3.12
@ 2013-08-06 16:11 Sudeep KarkadaNagesha
  2013-08-08 14:43 ` Sudeep KarkadaNagesha
  0 siblings, 1 reply; 79+ messages in thread
From: Sudeep KarkadaNagesha @ 2013-08-06 16:11 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Rob,

The following changes since commit c095ba7224d8edc71dcef0d655911399a8bd4a3f:

  Linux 3.11-rc4 (2013-08-04 13:46:46 -0700)

are available in the git repository at:

  git://linux-arm.org/linux-skn.git cpu_ofnode_dt

for you to fetch changes up to d7b5133478afd9e66a338d3125bc37b9a250ef66:

  of/device: add helper to get cpu device node from logical cpu index
(2013-08-06 16:37:15 +0100)

----------------------------------------------------------------
Sudeep KarkadaNagesha (4):
   of: add support for retrieving cpu node for a given logical cpu index
   ARM: DT/kernel: define ARM specific arch_match_cpu_phys_id
   driver/core: cpu: initialize of_node in cpu's device struture
   of/device: add helper to get cpu device node from logical cpu index

 arch/arm/kernel/devtree.c |  5 +++++
 drivers/base/cpu.c        |  2 ++
 drivers/of/base.c         | 73 ++++++++++++++++++++++++++++++
 include/linux/cpu.h       |  1 +
 include/linux/of.h        |  6 ++++++
 include/linux/of_device.h | 15 +++++++++++++++
 6 files changed, 102 insertions(+)

PS: This is DT part of the patch series reviewed and acknowledged @

v1:
http://archive.arm.linux.org.uk/lurker/message/20130715.102201.dfb8e04e.fr.html
v2:
http://archive.arm.linux.org.uk/lurker/message/20130717.140609.07fa6237.fr.html
v3:
http://archive.arm.linux.org.uk/lurker/message/20130722.113211.b5e3bc2a.fr.html


Regards,
Sudeep

^ permalink raw reply	[flat|nested] 79+ messages in thread

end of thread, other threads:[~2013-08-14 22:58 UTC | newest]

Thread overview: 79+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-08-12 13:27 [GIT PULL] DT/core: cpu_ofnode updates for v3.12 Sudeep KarkadaNagesha
2013-08-12 13:27 ` Sudeep KarkadaNagesha
2013-08-12 13:27 ` Sudeep KarkadaNagesha
2013-08-13 13:00 ` Rafael J. Wysocki
2013-08-13 13:00   ` Rafael J. Wysocki
2013-08-13 13:00   ` Rafael J. Wysocki
2013-08-13 15:40   ` Sudeep KarkadaNagesha
2013-08-13 15:40     ` Sudeep KarkadaNagesha
2013-08-13 15:40     ` Sudeep KarkadaNagesha
2013-08-13 15:40     ` Sudeep KarkadaNagesha
2013-08-13 18:29     ` Sudeep KarkadaNagesha
2013-08-13 18:29       ` Sudeep KarkadaNagesha
2013-08-13 18:29       ` Sudeep KarkadaNagesha
2013-08-13 18:29       ` Sudeep KarkadaNagesha
2013-08-13 21:07       ` Benjamin Herrenschmidt
2013-08-13 21:07         ` Benjamin Herrenschmidt
2013-08-13 21:07         ` Benjamin Herrenschmidt
2013-08-14 10:01         ` Sudeep KarkadaNagesha
2013-08-14 10:01           ` Sudeep KarkadaNagesha
2013-08-14 10:01           ` Sudeep KarkadaNagesha
2013-08-14 10:01           ` Sudeep KarkadaNagesha
2013-08-14 11:37           ` Benjamin Herrenschmidt
2013-08-14 11:37             ` Benjamin Herrenschmidt
2013-08-14 11:37             ` Benjamin Herrenschmidt
2013-08-14 13:21             ` Sudeep KarkadaNagesha
2013-08-14 13:21               ` Sudeep KarkadaNagesha
2013-08-14 13:21               ` Sudeep KarkadaNagesha
2013-08-14 13:21               ` Sudeep KarkadaNagesha
2013-08-14 22:57               ` Benjamin Herrenschmidt
2013-08-14 22:57                 ` Benjamin Herrenschmidt
2013-08-14 22:57                 ` Benjamin Herrenschmidt
2013-08-14 12:53           ` Rob Herring
2013-08-14 12:53             ` Rob Herring
2013-08-14 12:53             ` Rob Herring
2013-08-14 12:53             ` Rob Herring
2013-08-14 13:27             ` Sudeep KarkadaNagesha
2013-08-14 13:27               ` Sudeep KarkadaNagesha
2013-08-14 13:27               ` Sudeep KarkadaNagesha
2013-08-14 13:27               ` Sudeep KarkadaNagesha
2013-08-13 18:37     ` Michal Simek
2013-08-13 18:37       ` Michal Simek
2013-08-13 18:37       ` Michal Simek
2013-08-13 18:37       ` Michal Simek
2013-08-14  8:41       ` Sudeep KarkadaNagesha
2013-08-14  8:41         ` Sudeep KarkadaNagesha
2013-08-14  8:41         ` Sudeep KarkadaNagesha
2013-08-14  8:41         ` Sudeep KarkadaNagesha
2013-08-13 18:44     ` Rob Herring
2013-08-13 18:44       ` Rob Herring
2013-08-13 18:44       ` Rob Herring
2013-08-13 18:44       ` Rob Herring
2013-08-13 19:45       ` Rafael J. Wysocki
2013-08-13 19:45         ` Rafael J. Wysocki
2013-08-13 19:45         ` Rafael J. Wysocki
2013-08-13 19:45         ` Rafael J. Wysocki
2013-08-13 21:09         ` Benjamin Herrenschmidt
2013-08-13 21:09           ` Benjamin Herrenschmidt
2013-08-13 21:09           ` Benjamin Herrenschmidt
2013-08-13 21:09           ` Benjamin Herrenschmidt
2013-08-14  9:23         ` Sudeep KarkadaNagesha
2013-08-14  9:23           ` Sudeep KarkadaNagesha
2013-08-14  9:23           ` Sudeep KarkadaNagesha
2013-08-14  9:23           ` Sudeep KarkadaNagesha
2013-08-13 21:08       ` Benjamin Herrenschmidt
2013-08-13 21:08         ` Benjamin Herrenschmidt
2013-08-13 21:08         ` Benjamin Herrenschmidt
2013-08-13 21:03     ` Benjamin Herrenschmidt
2013-08-13 21:03       ` Benjamin Herrenschmidt
2013-08-13 21:03       ` Benjamin Herrenschmidt
  -- strict thread matches above, loose matches on Subject: below --
2013-08-06 16:11 Sudeep KarkadaNagesha
2013-08-08 14:43 ` Sudeep KarkadaNagesha
2013-08-08 15:27   ` Rob Herring
2013-08-08 15:49     ` Sudeep KarkadaNagesha
2013-08-12  8:54       ` Sudeep KarkadaNagesha
2013-08-12  9:03         ` Viresh Kumar
2013-08-12 11:51           ` Rafael J. Wysocki
2013-08-12 12:41             ` Sudeep KarkadaNagesha
2013-08-12 13:13               ` Rafael J. Wysocki
2013-08-12 13:06                 ` Sudeep KarkadaNagesha

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.