Re: [PATCH 0/2] arm64: cpuidle: make arm_cpuidle_suspend() more efficient

2016-03-24 Thread Lorenzo Pieralisi
ween arm_cpuidle_suspend() and psci_cpu_suspend_enter() the checks that you are removing are almost the *only* code that is currently executed and this patch saves us best case 12ns per idle state entry (which is noise compared to CPU PM notifiers/FW execution time) if I am not mistaken,

Re: [PATCH] cpuidle: arm: make enter idle operation a bit more efficient

2016-03-24 Thread Lorenzo Pieralisi
On Thu, Mar 24, 2016 at 01:07:18PM +0800, Jisheng Zhang wrote: > Currently, entering idle need to check the idx every time to choose the > real entering idle routine. But this check could be avoided by pointing > the idle enter function pointer of each idle states to the routines > suitable for

Re: Question about PCI I/O space in ARM64

2016-03-24 Thread Lorenzo Pieralisi
[+ Jean] On Thu, Mar 24, 2016 at 11:14:50AM +0800, Kefeng Wang wrote: [...] > >> You need a PCI host controller driver (e.g. > >> drivers/pci/host/pci-host-generic.c) and corresponding bindings in DT or > >> ACPI. > > In our inner test, there are some board without pcie host driver(even >

[PATCH v3] PCI: ACPI: IA64: fix IO port generic range check

2016-03-21 Thread Lorenzo Pieralisi
: 3772aea7d6f3 ("ia64/PCI/ACPI: Use common ACPI resource parsing interface for host bridge") Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Bjorn Helgaas <bhelg...@google.com> Cc: Hanjun Guo <hanjun@linaro.org> Cc: Jiang Liu <jiang@linux.i

Re: [PATCH] drivers: firmware: psci: make two helper functions static

2016-03-23 Thread Lorenzo Pieralisi
On Tue, Mar 22, 2016 at 10:31:45PM +0800, Jisheng Zhang wrote: > psci_power_state_loses_context() and psci_power_state_is_valid are only > used internally now, so make them static. > > Signed-off-by: Jisheng Zhang > --- > drivers/firmware/psci.c | 4 ++-- >

Re: [PATCH] Fix NULL ptr dereference in pci_bus_assign_domain_nr() on ARM

2016-03-08 Thread Lorenzo Pieralisi
gt; > > > That's really unfortunate, when I moved code from arm64 to generic I > > did not spot this issue in the original code and carried it over, you > > summarized the reasons in the commit log so without any further ado (and > > with my apologies): > > &

Re: [PATCH] Fix NULL ptr dereference in pci_bus_assign_domain_nr() on ARM

2016-03-07 Thread Lorenzo Pieralisi
that added the generic code we're fixing. Backports of 7c674700098c > should also backport this change. That's really unfortunate, when I moved code from arm64 to generic I did not spot this issue in the original code and carried it over, you summarized the reasons in the commit log so without

Re: [PATCH V5 00/15] MMCONFIG refactoring and support for ARM64 PCI hostbridge init based on ACPI

2016-03-04 Thread Lorenzo Pieralisi
On Thu, Mar 03, 2016 at 09:24:56AM -0500, Sinan Kaya wrote: > On 3/3/2016 6:23 AM, Lorenzo Pieralisi wrote: > > x86 and IA64 claim PCI resources on boot and live with that (well, minus > > the gazillions x86 pci= parameters that change the PCI resources assignment > > one way

Re: [PATCH V5 00/15] MMCONFIG refactoring and support for ARM64 PCI hostbridge init based on ACPI

2016-03-03 Thread Lorenzo Pieralisi
[+ Yinghai] On Mon, Feb 29, 2016 at 02:03:45PM -0500, Sinan Kaya wrote: > On 2/16/2016 8:53 AM, Tomasz Nowicki wrote: > > From the functionality point of view this series might be split into the > > following logic parts: > > 1. Make MMCONFIG code arch-agnostic which allows all architectures to

Re: [PATCH 3/3] arm64: kasan: clear stale stack poison

2016-03-03 Thread Lorenzo Pieralisi
off-by: Mark Rutland <mark.rutl...@arm.com> > > Cc: Alexander Potapenko <gli...@google.com> > > Cc: Andrey Ryabinin <aryabi...@virtuozzo.com> > > Cc: Catalin Marinas <catalin.mari...@arm.com> > > Cc: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> >

Re: [PATCH V5 00/15] MMCONFIG refactoring and support for ARM64 PCI hostbridge init based on ACPI

2016-03-04 Thread Lorenzo Pieralisi
On Fri, Mar 04, 2016 at 09:52:17AM -0500, Sinan Kaya wrote: [...] > >> I could integrate the code implementing pci=realloc in patch 11 so > >> that we realloc by default all resources claimed that failed (which > >> means that bridges are resized accordingly and you won't be forced > >> to use

Re: [PATCH V4 17/23] acpi, mcfg: Add default PCI config accessors implementation and initial support for related quirks.

2016-03-02 Thread Lorenzo Pieralisi
On Mon, Feb 29, 2016 at 01:33:41PM +0530, Jayachandran Chandrashekaran Nair wrote: > On Thu, Feb 4, 2016 at 10:58 PM, Tomasz Nowicki wrote: > > We use generic accessors from access.c by default. However, we already > > know platforms that need special handling while accessing

Re: [PATCH 1/2] ARM: cpuidle: fix !cpuidle_ops[cpu].init case during init

2016-03-30 Thread Lorenzo Pieralisi
On Wed, Mar 30, 2016 at 10:09:12AM +0200, Daniel Lezcano wrote: > On 03/30/2016 09:16 AM, Jisheng Zhang wrote: > >Hi Daniel, > > [ ... ] > > Added Lorenzo and Catalin. > > >>Hi Jisheng, > >> > >>this should be handled in the arm_cpuidle_read_ops function. > >> > > > >Thanks for reviewing. After

Re: [RFC PATCH 09/11] drivers: acpi: implement acpi_dma_configure

2016-04-22 Thread Lorenzo Pieralisi
Hi Andy, On Fri, Apr 22, 2016 at 01:45:38AM +0300, Andy Shevchenko wrote: > On Thu, Apr 14, 2016 at 8:25 PM, Lorenzo Pieralisi > <lorenzo.pieral...@arm.com> wrote: > > On DT based systems, the of_dma_configure() API implements DMA configuration > > for a given device

Re: [PATCH V6 08/13] PCI: generic, thunder: update to use generic ECAM API

2016-04-29 Thread Lorenzo Pieralisi
On Thu, Apr 28, 2016 at 05:47:15PM -0400, Jon Masters wrote: [...] > >>> In general, there's no reason we can't reassign BARs, whether we're > >>> using DT, ACPI, or whatever. In many cases, systems with ACPI also > >>> assign all the BARs in firmware, and Linux doesn't reassign them > >>>

Re: [PATCH V6 09/13] pci, acpi: Support for ACPI based generic PCI host controller

2016-04-29 Thread Lorenzo Pieralisi
On Thu, Apr 28, 2016 at 04:48:00PM -0500, Bjorn Helgaas wrote: [...] > > +static int pci_acpi_setup_ecam_mapping(struct acpi_pci_root *root, > > + struct acpi_pci_generic_root_info *ri) > > +{ > > + u16 seg = root->segment; > > + u8 bus_start =

Re: [PATCH] arm64: Relocate screen_info.lfb_base on PCI BAR allocation

2016-04-29 Thread Lorenzo Pieralisi
On Thu, Apr 28, 2016 at 11:39:35PM +0200, Alexander Graf wrote: > > > On 28.04.16 20:06, Bjorn Helgaas wrote: > > On Thu, Apr 28, 2016 at 06:41:42PM +0200, Alexander Graf wrote: > >> On 04/28/2016 06:20 PM, Bjorn Helgaas wrote: > >>> On Thu, Apr 28, 2016 at 12:22:24AM +0200, Alexander Graf

Re: [PATCH V6 05/13] acpi, pci: Support IO resources when parsing PCI host bridge resources.

2016-04-27 Thread Lorenzo Pieralisi
On Wed, Apr 27, 2016 at 04:10:36PM +0100, liviu.du...@arm.com wrote: > On Wed, Apr 27, 2016 at 03:26:59PM +0100, Lorenzo Pieralisi wrote: > > On Tue, Apr 26, 2016 at 09:39:16PM -0500, Bjorn Helgaas wrote: > > > On Fri, Apr 15, 2016 at 07:06:40PM +0200, Tomasz Nowicki wrote:

Re: [PATCH V6 02/13] pci, acpi: Provide generic way to assign bus domain number.

2016-04-27 Thread Lorenzo Pieralisi
On Wed, Apr 27, 2016 at 11:44:53AM -0500, Bjorn Helgaas wrote: > On Wed, Apr 27, 2016 at 12:17:58PM +0100, Lorenzo Pieralisi wrote: > > On Tue, Apr 26, 2016 at 09:26:49PM -0500, Bjorn Helgaas wrote: > > > On Fri, Apr 15, 2016 at 07:06:37PM +0200, Tomasz Nowicki wrote: > >

Re: [PATCH V6 02/13] pci, acpi: Provide generic way to assign bus domain number.

2016-04-27 Thread Lorenzo Pieralisi
On Tue, Apr 26, 2016 at 09:26:49PM -0500, Bjorn Helgaas wrote: > On Fri, Apr 15, 2016 at 07:06:37PM +0200, Tomasz Nowicki wrote: > > As we now have valid PCI host bridge device reference we can > > introduce code that is going to find its bus domain number using > > ACPI _SEG method. > > > > Note

Re: [PATCH V6 06/13] arm64, pci, acpi: ACPI support for legacy IRQs parsing and consolidation with DT code.

2016-04-27 Thread Lorenzo Pieralisi
confined in one single arch callback that can be easily removed > > when code parsing PCI legacy IRQs is consolidated and moved to core > > PCI code. > > > > Signed-off-by: Tomasz Nowicki <t...@semihalf.com> > > Suggested-by: Lorenzo Pieralisi <lorenzo.pieral..

Re: [PATCH 3/3] ACPI: ARM64: support for ACPI_TABLE_UPGRADE

2016-05-23 Thread Lorenzo Pieralisi
On Tue, May 17, 2016 at 12:48:53PM -0400, Jon Masters wrote: > On 05/17/2016 12:44 PM, Jon Masters wrote: > > > 1). During development of a platform, it is much easier to debug > > problems with tables if you can test replacement ones without having to > > respin the firmware. In the server

Re: [RFC PATCH] Increase in idle power with schedutil

2016-05-23 Thread Lorenzo Pieralisi
On Sun, May 22, 2016 at 01:42:52PM -0700, Steve Muckle wrote: > On Sun, May 22, 2016 at 12:39:12PM +0200, Peter Zijlstra wrote: > > On Fri, May 20, 2016 at 05:53:41PM +0530, Shilpasri G Bhat wrote: > > > > > > Below are the comparisons by disabling watchdog. > > > Both schedutil and ondemand have

Re: [PATCH V7 00/11] Support for generic ACPI based PCI host controller

2016-05-23 Thread Lorenzo Pieralisi
On Fri, May 20, 2016 at 11:14:03AM +0200, Ard Biesheuvel wrote: > On 20 May 2016 at 10:40, Gabriele Paoloni wrote: > > Hi Ard > > > >> -Original Message- > >> From: Ard Biesheuvel [mailto:ard.biesheu...@linaro.org] > [...] > >> > >> Is the PCIe root complex so

Re: [PATCH V7 00/11] Support for generic ACPI based PCI host controller

2016-05-24 Thread Lorenzo Pieralisi
Hi Bjorn, On Mon, May 23, 2016 at 06:39:18PM -0500, Bjorn Helgaas wrote: [...] > On Mon, May 23, 2016 at 03:16:01PM +, Gabriele Paoloni wrote: > I don't think of ECAM support itself as a "driver". It's just a > service available to drivers, similar to OF resource parsing. > > Per PCI

Re: [PATCH V7 07/11] pci, acpi: Handle ACPI companion assignment.

2016-05-11 Thread Lorenzo Pieralisi
On Tue, May 10, 2016 at 08:37:00PM +0200, Rafael J. Wysocki wrote: > On Tue, May 10, 2016 at 5:19 PM, Tomasz Nowicki wrote: > > This patch provides a way to set the ACPI companion in PCI code. > > We define acpi_pci_set_companion() to set the ACPI companion pointer and > > call

Re: [PATCH V7 07/11] pci, acpi: Handle ACPI companion assignment.

2016-05-13 Thread Lorenzo Pieralisi
:30:51PM +0200, Rafael J. Wysocki wrote: > >>> On Wed, May 11, 2016 at 12:11 PM, Lorenzo Pieralisi > >>> <lorenzo.pieral...@arm.com> wrote: > >>> > On Tue, May 10, 2016 at 08:37:00PM +0200, Rafael J. Wysocki wrote: > >>> >> On Tue, May 10,

Re: [PATCH V7 07/11] pci, acpi: Handle ACPI companion assignment.

2016-05-12 Thread Lorenzo Pieralisi
On Wed, May 11, 2016 at 05:43:14PM -0500, Bjorn Helgaas wrote: > On Wed, May 11, 2016 at 10:30:51PM +0200, Rafael J. Wysocki wrote: > > On Wed, May 11, 2016 at 12:11 PM, Lorenzo Pieralisi > > <lorenzo.pieral...@arm.com> wrote: > > > On Tue, May 10, 2016 at 08:37:00PM

Re: [PATCH V6 09/13] pci, acpi: Support for ACPI based generic PCI host controller

2016-05-03 Thread Lorenzo Pieralisi
On Fri, Apr 29, 2016 at 11:05:34PM +0530, Jayachandran C wrote: > On Fri, Apr 29, 2016 at 2:07 PM, Lorenzo Pieralisi > <lorenzo.pieral...@arm.com> wrote: > > On Thu, Apr 28, 2016 at 04:48:00PM -0500, Bjorn Helgaas wrote: > > > > [...] > > > >> >

Re: [PATCH V6 02/13] pci, acpi: Provide generic way to assign bus domain number.

2016-05-03 Thread Lorenzo Pieralisi
On Mon, May 02, 2016 at 06:56:13PM +0530, Jayachandran C wrote: > On Mon, May 2, 2016 at 6:13 PM, Tomasz Nowicki <t...@semihalf.com> wrote: > > On 04/27/2016 01:17 PM, Lorenzo Pieralisi wrote: > >> > >> On Tue, Apr 26, 2016 at 09:26:49PM -0500, Bjorn Helgaas wrote:

Re: [PATCH V6 02/13] pci, acpi: Provide generic way to assign bus domain number.

2016-05-03 Thread Lorenzo Pieralisi
On Tue, May 03, 2016 at 07:52:52PM +0530, Jayachandran C wrote: > On Tue, May 3, 2016 at 4:32 PM, Lorenzo Pieralisi > <lorenzo.pieral...@arm.com> wrote: > > On Mon, May 02, 2016 at 06:56:13PM +0530, Jayachandran C wrote: > >> On Mon, May 2, 2016 at 6:13 PM, Tomasz Nowick

Re: [PATCH] firmware/drivers/psci: Fix unused functions when CONFIG_CPU_IDLE=n

2016-05-10 Thread Lorenzo Pieralisi
On Tue, May 10, 2016 at 09:18:49AM +0200, Daniel Lezcano wrote: > On the ARM64 architecture, when CPUIDLE is not set in the configuration, > the compilation raises a couple of warnings: > > drivers/firmware/psci.c:70:12: warning: 'psci_pd_power_off' defined but not > used [-Wunused-function] >

Re: [PATCH V6 01/13] pci, acpi, x86, ia64: Move ACPI host bridge device companion assignment to core code.

2016-05-10 Thread Lorenzo Pieralisi
On Tue, May 10, 2016 at 12:18:59AM +0200, Rafael J. Wysocki wrote: [...] > > >> diff --git a/drivers/acpi/pci_root.c b/drivers/acpi/pci_root.c > > >> index ae3fe4e..4581e0e 100644 > > >> --- a/drivers/acpi/pci_root.c > > >> +++ b/drivers/acpi/pci_root.c > > >> @@ -564,6 +564,11 @@ static int

Re: [PATCH V6 01/13] pci, acpi, x86, ia64: Move ACPI host bridge device companion assignment to core code.

2016-05-10 Thread Lorenzo Pieralisi
On Mon, May 09, 2016 at 08:53:36PM -0500, Bjorn Helgaas wrote: > On Tue, May 10, 2016 at 12:56:37AM +0200, Rafael J. Wysocki wrote: > > On Friday, April 15, 2016 07:06:36 PM Tomasz Nowicki wrote: > > > Currently we have two platforms (x86 & ia64) capable of PCI ACPI host > > > bridge

Re: [PATCH v3] ARM64: ACPI: Update documentation for latest specification version

2016-04-15 Thread Lorenzo Pieralisi
Hi Al, On Mon, Mar 28, 2016 at 06:06:42PM -0600, Al Stone wrote: > The ACPI 6.1 specification was recently released at the end of January > 2016, but the arm64 kernel documentation for the use of ACPI was written > for the 5.1 version of the spec. There were significant additions to the > spec

Re: [PATCH v3] ARM64: ACPI: Update documentation for latest specification version

2016-04-15 Thread Lorenzo Pieralisi
On Fri, Apr 15, 2016 at 10:41:02AM -0600, Al Stone wrote: > On 04/15/2016 08:37 AM, Lorenzo Pieralisi wrote: > > Hi Al, > > > > On Mon, Mar 28, 2016 at 06:06:42PM -0600, Al Stone wrote: > >> The ACPI 6.1 specification was recently released at the end of January &

Re: [PATCH] drivers: firmware: psci: add __init mark to psci_dt_cpu_init_idle

2016-04-19 Thread Lorenzo Pieralisi
On Tue, Apr 19, 2016 at 04:20:38PM +0100, Sudeep Holla wrote: > > > On 19/04/16 16:05, Lorenzo Pieralisi wrote: > >Hi Jisheng, > > > >On Tue, Mar 22, 2016 at 10:35:29PM +0800, Jisheng Zhang wrote: > >>psci_dt_cpu_init_idle() and psci_cpu_init_idle() are not ne

Re: [PATCH 0/4] ARM: cpuidle: use const and __initconst for cpuidle_ops

2016-04-19 Thread Lorenzo Pieralisi
Hi Daniel, On Fri, Mar 25, 2016 at 12:26:27PM +0100, Daniel Lezcano wrote: > On 03/22/2016 03:42 PM, Jisheng Zhang wrote: > >These trivial patches are similar as Masahiro posted in[1]. The main > >purpose is let cpuidle_ops structure be constified and replace > >"__initdata" with "__initconst". >

Re: [PATCH] drivers: firmware: psci: add __init mark to psci_dt_cpu_init_idle

2016-04-19 Thread Lorenzo Pieralisi
ated patch subject] Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> --- drivers/firmware/psci.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/firmware/psci.c b/drivers/firmware/psci.c index 6d86881..4a6a7de 100644 --- a/drivers/firmware/psci.c +++

Re: [PATCH v2 3/6] ARM: PSCI: Register with kernel restart handler

2016-04-19 Thread Lorenzo Pieralisi
so it should not even be advertised as such in the DT. This means that this priority kludge must disappear soon, what priority to assign to the PSCI reset handler remains to be seen. Are you sending this patch series via arm-soc ? If so: Acked-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com>

Re: [RFC PATCH 09/11] drivers: acpi: implement acpi_dma_configure

2016-04-18 Thread Lorenzo Pieralisi
On Fri, Apr 15, 2016 at 01:29:14PM -0500, Timur Tabi wrote: > On Thu, Apr 14, 2016 at 12:25 PM, Lorenzo Pieralisi > <lorenzo.pieral...@arm.com> wrote: > > +void acpi_dma_configure(struct device *dev, enum dev_dma_attr attr) > > +{ > > + struct iommu_ops *

Re: [PATCH RESEND] drivers: firmware: psci: drop duplicate const from psci_of_match

2016-04-20 Thread Lorenzo Pieralisi
On Tue, Mar 22, 2016 at 10:45:46PM +0800, Jisheng Zhang wrote: > This is to fix below sparse warning: > drivers/firmware/psci.c:mmm:nn: warning: duplicate const > > Signed-off-by: Jisheng Zhang > --- > drivers/firmware/psci.c | 2 +- > 1 file changed, 1 insertion(+), 1

Re: [PATCH 4/4] drivers: firmware: psci: use const and __initconst for psci_cpuidle_ops

2016-04-20 Thread Lorenzo Pieralisi
s/firmware/psci.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) Acked-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> > diff --git a/drivers/firmware/psci.c b/drivers/firmware/psci.c > index 6d86881..7d52186 100644 > --- a/drivers/firmware/psci.c > +++ b/drivers/firmware/

Re: [PATCH v2 2/4] PCI: Provide common functions for ECAM mapping

2016-04-14 Thread Lorenzo Pieralisi
On Thu, Apr 14, 2016 at 01:55:32AM -0400, Jon Masters wrote: [...] > > I will comment on the patches as soon as I have time to review > > them, I certainly would like to understand what we have to do with the > > rest of the code though (provided this series is good to go) see above. > > Right.

Re: [PATCH v4] ARM64: ACPI: Update documentation for latest specification version

2016-04-19 Thread Lorenzo Pieralisi
CPI 5.1 > specfication): > -- If PCI is supported, the MCFG (Memory mapped ConFiGuration > Table), section 5.2.6, specifically Table 5-31. > > +-- If booting without a console= kernel parameter is > + supported, the SPCR (Serial Port Console Redirection t

Re: [RFC PATCH 06/11] drivers: iommu: make of_xlate() interface DT agnostic

2016-04-19 Thread Lorenzo Pieralisi
Hi Marek, On Tue, Apr 19, 2016 at 10:28:02AM +0200, Marek Szyprowski wrote: > Hello, > > On 2016-04-14 19:25, Lorenzo Pieralisi wrote: > >On systems booting with ACPI, the IOMMU drivers require the same > >kind of id mapping carried out with a DT tree through the of_xl

[RFC PATCH 11/11] drivers: irqchip: make struct irq_fwspec generic

2016-04-14 Thread Lorenzo Pieralisi
iommu_fwspec can be converted to it too in all kernel components currently making use of it. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Joerg Roedel <j...@8bytes.org> Cc: "Rafael J. Wysocki" <r...@rjwysocki.net> Cc: Marc Zyngier <marc.zyng...@

[RFC PATCH 01/11] drivers: acpi: iort: fix struct pci_dev compiler warnings

2016-04-14 Thread Lorenzo Pieralisi
*iort_pci_get_domain(struct pci_dev *pdev, u32 req_id); This patch fixes the warnings with a struct pci_dev forward declaration in the IORT header file. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Tomasz Nowicki <t...@semihalf.com> --- include/linux/iort.h | 1 + 1 file changed,

[RFC PATCH 06/11] drivers: iommu: make of_xlate() interface DT agnostic

2016-04-14 Thread Lorenzo Pieralisi
signature so that it does not take anymore the DT specific of_phandle_args argument and replaces it with the DT agnostic iommu_fwspec one. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Matthias Brugger <matthias@gmail.com> Cc: Will Deacon <will.dea...@arm.com&

[RFC PATCH 08/11] drivers: acpi: iort: enhance mapping API

2016-04-14 Thread Lorenzo Pieralisi
. Based on prior work by Hanjun Guo <hanjun@linaro.org>. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Hanjun Guo <hanjun@linaro.org> Cc: Tomasz Nowicki <t...@semihalf.com> Cc: "Rafael J. Wysocki" <r...@rjwysoc

[RFC PATCH 03/11] drivers: iommu: add FWNODE_IOMMU fwnode type

2016-04-14 Thread Lorenzo Pieralisi
domain kernel layer, this patch adds an additional fwnode type FWNODE_IOMMU. This patch also implements a glue kernel layer that allows to allocate/free FWNODE_IOMMU fwnode_handle structures and associate them with IOMMU devices. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc:

[RFC PATCH 10/11] drivers: iommu: arm-smmu: implement ACPI probing

2016-04-14 Thread Lorenzo Pieralisi
by the kernel on boot and allows to detect and configure the ARM SMMU devices present in the system. Based on prior work by Hanjun Guo <hanjun@linaro.org>. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Will Deacon <will.dea...@arm.com> Cc: Hanjun Guo <

[RFC PATCH 05/11] drivers: iommu: arm-smmu: split probe functions into DT/generic portions

2016-04-14 Thread Lorenzo Pieralisi
so that other FW interfaces (ie ACPI) can reuse the HW probing functions and skip the DT portion accordingly. This patch implements no functional change, only code reshuffling. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Will Deacon <will.dea...@arm.com> Cc: Hanjun

[RFC PATCH 04/11] drivers: acpi: iort: introduce linker section for IORT entries probing

2016-04-14 Thread Lorenzo Pieralisi
associated with the driver specific callback is matched. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Tomasz Nowicki <t...@semihalf.com> Cc: "Rafael J. Wysocki" <r...@rjwysocki.net> Cc: Marc Zyngier <marc.zyng...@arm.com> --- drivers/acpi/iort

[RFC PATCH 02/11] drivers: acpi: iort: add support for IOMMU registration

2016-04-14 Thread Lorenzo Pieralisi
The ACPI IORT table provide entries for IOMMU (aka SMMU in ARM world) components that allow creating the kernel data structures required to probe and initialize the IOMMU devices. This patch provides support in the IORT kernel code to register IOMMU components. Signed-off-by: Lorenzo Pieralisi

[RFC PATCH 00/11] ACPI IORT ARM SMMU support

2016-04-14 Thread Lorenzo Pieralisi
arm-kernel=145675372917701=2 T.Nowicki "Introduce ACPI world to ITS irqchip" https://marc.info/?l=linux-acpi=145976009630179=2 Tested on Juno-r2 board with both DT and ACPI probing paths. Lorenzo Pieralisi (11): drivers: acpi: iort: fix struct pci_dev compiler warnings drivers: acpi: iort: a

[RFC PATCH 09/11] drivers: acpi: implement acpi_dma_configure

2016-04-14 Thread Lorenzo Pieralisi
arches. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Bjorn Helgaas <bhelg...@google.com> Cc: Robin Murphy <robin.mur...@arm.com> Cc: Tomasz Nowicki <t...@semihalf.com> Cc: Joerg Roedel <j...@8bytes.org> Cc: "Rafael J. Wysocki" <r

[RFC PATCH 07/11] drivers: iommu: arm-smmu: allow ACPI based streamid translation

2016-04-14 Thread Lorenzo Pieralisi
() callback that allows streamid translation on ACPI based ARM system. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Will Deacon <will.dea...@arm.com> Cc: Robin Murphy <robin.mur...@arm.com> --- drivers/iommu/arm-smmu.c | 16 1 file changed, 16 inserti

Re: [PATCH v3] ARM64: ACPI: Update documentation for latest specification version

2016-04-18 Thread Lorenzo Pieralisi
On Fri, Apr 15, 2016 at 11:54:08AM -0600, Al Stone wrote: [...] > > Understood, the point I wanted to make is that adding a list of methods > > in acpi_object_usage.txt ("Use as needed") is not necessarily additional > > information, you can add a pointer at ACPI specs (for that specific > >

Re: [PATCH V6 05/13] acpi, pci: Support IO resources when parsing PCI host bridge resources.

2016-04-27 Thread Lorenzo Pieralisi
On Tue, Apr 26, 2016 at 09:39:16PM -0500, Bjorn Helgaas wrote: > On Fri, Apr 15, 2016 at 07:06:40PM +0200, Tomasz Nowicki wrote: > > Platforms that have memory mapped IO port (such as ARM64) need special > > handling for PCI I/O resources. For host bridge's resource probing case > > these

Re: Why does BIOS assign memory to 16 byte BAR

2016-07-27 Thread Lorenzo Pieralisi
On Wed, Jul 27, 2016 at 06:33:29AM +, Bharat Kumar Gogada wrote: > > Your system host bridge: has resource > > pci_bus :00: root bus resource [mem 0xe010-0xefff] pci_bus > > :00: root bus resource [mem 0x6-0x7 pref] then one pci > > bridge: > > pci :00:00.0

Re: Purpose of pci_remap_iospace

2016-07-13 Thread Lorenzo Pieralisi
On Wed, Jul 13, 2016 at 03:16:21PM +, Bharat Kumar Gogada wrote: > > Subject: Re: Purpose of pci_remap_iospace > > > > On Wednesday, July 13, 2016 12:30:44 PM CEST Bharat Kumar Gogada wrote: > > > > On Wednesday, July 13, 2016 8:11:56 AM CEST Bharat Kumar Gogada > > wrote: > > > > > >

Re: Purpose of pci_remap_iospace

2016-07-14 Thread Lorenzo Pieralisi
On Thu, Jul 14, 2016 at 01:32:13PM +, Bharat Kumar Gogada wrote: [...] > Hi Lorenzo, > > I missed something in my device tree now I corrected it. > > ranges = <0x0100 0x 0xe000 0x 0xe000 0 0x0001 > //io You have not missed anything, you changed the PCI

Re: Purpose of pci_remap_iospace

2016-07-14 Thread Lorenzo Pieralisi
On Thu, Jul 14, 2016 at 03:05:40PM +, Bharat Kumar Gogada wrote: [...] > > On Thu, Jul 14, 2016 at 01:32:13PM +, Bharat Kumar Gogada wrote: > > > ranges = <0x0100 0x 0xe000 0x 0xe000 0 > > 0x0001 //io > > > > You have not missed anything, you changed the

Re: Purpose of pci_remap_iospace

2016-07-14 Thread Lorenzo Pieralisi
On Thu, Jul 14, 2016 at 05:12:01PM +0200, Arnd Bergmann wrote: > On Thursday, July 14, 2016 3:56:24 PM CEST Lorenzo Pieralisi wrote: > > On Thu, Jul 14, 2016 at 01:32:13PM +, Bharat Kumar Gogada wrote: > > > > [...] > > > > > Hi Lorenzo, > > > &

Re: [PATCH v7 7/9] acpi/arm64: Add memory-mapped timer support in GTDT driver

2016-07-14 Thread Lorenzo Pieralisi
On Thu, Jul 14, 2016 at 01:53:20AM +0800, fu@linaro.org wrote: > From: Fu Wei > > This driver adds support for parsing memory-mapped timer in GTDT: > provide a kernel APIs to parse GT Block Structure in GTDT, > export all the info by filling the struct which provided > by

Re: [RFC PATCH v3 00/13] ACPI IORT ARM SMMU v3 support

2016-07-25 Thread Lorenzo Pieralisi
On Mon, Jul 25, 2016 at 01:53:32PM +0800, Dennis Chen wrote: > Hi > On Wed, Jul 20, 2016 at 12:23:22PM +0100, Lorenzo Pieralisi wrote: > > This RFC patch series is v3 of a previous posting: > > > > https://lkml.org/lkml/2016/6/7/523 > > > > v2 -> v3 &

Re: [RFC PATCH v3 05/13] drivers: iommu: make iommu_fwspec OF agnostic

2016-07-25 Thread Lorenzo Pieralisi
On Mon, Jul 25, 2016 at 10:21:10AM -0500, Rob Herring wrote: > On Mon, Jul 25, 2016 at 10:09 AM, Robin Murphy <robin.mur...@arm.com> wrote: > > Hi Lorenzo, > > > > On 20/07/16 12:23, Lorenzo Pieralisi wrote: > >> The iommu_fwspec structure, used to hold per

Re: [RFC PATCH v3 05/13] drivers: iommu: make iommu_fwspec OF agnostic

2016-07-25 Thread Lorenzo Pieralisi
On Mon, Jul 25, 2016 at 04:09:55PM +0100, Robin Murphy wrote: > Hi Lorenzo, > > On 20/07/16 12:23, Lorenzo Pieralisi wrote: > > The iommu_fwspec structure, used to hold per device iommu configuration > > data is not OF specific and therefore can be moved to a generic &

Re: [RFC PATCH v3 05/13] drivers: iommu: make iommu_fwspec OF agnostic

2016-07-25 Thread Lorenzo Pieralisi
On Mon, Jul 25, 2016 at 04:51:00PM +0100, Robin Murphy wrote: > On 25/07/16 16:41, Lorenzo Pieralisi wrote: > [...] > >>> diff --git a/include/linux/of_iommu.h b/include/linux/of_iommu.h > >>> index 308791f..2362232 100644 > >>> --- a/include/linux/of_io

Re: [PATCH v10 0/8] acpi, clocksource: add GTDT driver and GTDT support in arm_arch_timer

2016-08-11 Thread Lorenzo Pieralisi
On Thu, Aug 11, 2016 at 06:22:03PM +0800, Fu Wei wrote: > Hi Hanjun, Tomasz, > > On 11 August 2016 at 18:15, Hanjun Guo wrote: > > Hi, > > > > On 2016/8/11 17:37, Tomasz Nowicki wrote: > >> > >> Hi Fu, > >> > >> Do you mind if I send IORT series where new

Re: [RFC PATCH v3 05/13] drivers: iommu: make iommu_fwspec OF agnostic

2016-08-11 Thread Lorenzo Pieralisi
On Mon, Jul 25, 2016 at 04:51:00PM +0100, Robin Murphy wrote: > On 25/07/16 16:41, Lorenzo Pieralisi wrote: > [...] > >>> diff --git a/include/linux/of_iommu.h b/include/linux/of_iommu.h > >>> index 308791f..2362232 100644 > >>> --- a/include/linux/of_io

Re: [PATCH] ARM: cpuidle: Fix error return code

2016-08-11 Thread Lorenzo Pieralisi
Register per cpuidle device") > > Signed-off-by: Christophe JAILLET <christophe.jail...@wanadoo.fr> > --- > drivers/cpuidle/cpuidle-arm.c | 1 + > 1 file changed, 1 insertion(+) Acked-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com>

Re: [RFC PATCH v3 13/13] drivers: acpi: iort: introduce iort_iommu_configure

2016-08-11 Thread Lorenzo Pieralisi
On Wed, Aug 03, 2016 at 10:19:43AM -0400, nwatt...@codeaurora.org wrote: [...] > >+const struct iommu_ops *iort_iommu_configure(struct device *dev) > >+{ > >+struct acpi_iort_node *node, *parent; > >+struct fwnode_handle *iort_fwnode; > >+u32 rid = 0, devid = 0; > > Since this

Re: [PATCH V8 1/8] ACPI: I/O Remapping Table (IORT) initial support

2016-08-12 Thread Lorenzo Pieralisi
o get table, %s\n", msg); > + } > +} > diff --git a/drivers/acpi/bus.c b/drivers/acpi/bus.c > index 85b7d07..55a84da 100644 > --- a/drivers/acpi/bus.c > +++ b/drivers/acpi/bus.c > @@ -36,6 +36,7 @@ > #ifdef CONFIG_X86 > #include > #endif > +#include

Re: [PATCH V8 2/8] ACPI: Add new IORT functions to support MSI domain handling

2016-08-12 Thread Lorenzo Pieralisi
On Thu, Aug 11, 2016 at 12:06:32PM +0200, Tomasz Nowicki wrote: [...] > +/** > + * iort_register_domain_token() - register domain token and related ITS ID > + * to the list from where we can get it back later on. > + * @trans_id: ITS ID. > + * @fw_node: Domain token. > + * > + * Returns: 0 on

Re: [PATCH v8 7/9] acpi/arm64: Add memory-mapped timer support in GTDT driver

2016-07-21 Thread Lorenzo Pieralisi
On Wed, Jul 20, 2016 at 02:18:02AM +0800, fu@linaro.org wrote: > From: Fu Wei > > This driver adds support for parsing memory-mapped timer in GTDT: > provide a kernel APIs to parse GT Block Structure in GTDT, > export all the info by filling the struct which provided > by

[RFC PATCH v3 05/13] drivers: iommu: make iommu_fwspec OF agnostic

2016-07-20 Thread Lorenzo Pieralisi
an explicit arch dependency in its config entry. Current drivers using the iommu_fwspec for streamid translation are converted to the new iommu_fwspec API by simply converting the device_node to its fwnode_handle pointer. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com&

[RFC PATCH v3 02/13] drivers: acpi: iort: introduce linker section for IORT entries probing

2016-07-20 Thread Lorenzo Pieralisi
associated with the driver specific callback is matched. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Tomasz Nowicki <t...@semihalf.com> Cc: "Rafael J. Wysocki" <r...@rjwysocki.net> Cc: Marc Zyngier <marc.zyng...@arm.com> --- drivers/acpi/iort

[RFC PATCH v3 00/13] ACPI IORT ARM SMMU v3 support

2016-07-20 Thread Lorenzo Pieralisi
ot; v8 http://marc.info/?l=linux-acpi=146462129816292=2 and is provided for early review/testing purposes here: git://git.kernel.org/pub/scm/linux/kernel/git/lpieralisi/linux.git acpi/iort-smmu-v3 Tested on FVP models for ARM SMMU v3 probing path. Lorenzo Pieralisi (13): drivers: iommu: ad

[RFC PATCH v3 07/13] drivers: acpi: iort: add node match function

2016-07-20 Thread Lorenzo Pieralisi
if a given IORT node type is present or not in the ACPI table, providing an ACPI IORT equivalent for of_find_matching_node(). Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Hanjun Guo <hanjun@linaro.org> Cc: Tomasz Nowicki <t...@semihalf.com> Cc: &quo

[RFC PATCH v3 06/13] drivers: acpi: implement acpi_dma_configure

2016-07-20 Thread Lorenzo Pieralisi
case, but since arch_setup_dma_ops() is a NOP on all architectures but ARM/ARM64 this patch does not change the current kernel behaviour on them. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Acked-by: Bjorn Helgaas <bhelg...@google.com> [pci] Cc: Bjorn Helgaas <bhel

[RFC PATCH v3 03/13] drivers: acpi: iort: add support for IOMMU fwnode registration

2016-07-20 Thread Lorenzo Pieralisi
-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Hanjun Guo <hanjun@linaro.org> Cc: Tomasz Nowicki <t...@semihalf.com> Cc: "Rafael J. Wysocki" <r...@rjwysocki.net> --- drivers/acpi/iort.c | 65 ++

[RFC PATCH v3 11/13] drivers: iommu: arm-smmu-v3: add IORT platform device creation

2016-07-20 Thread Lorenzo Pieralisi
configuration functions to the IORT kernel layer for the ARM SMMU v3 components, so that the ARM SMMU v3 driver can initialize its respective platform device by relying on the IORT kernel infrastructure and by adding a corresponding ACPI device early probe section entry. Signed-off-by: Lorenzo Pieralisi

[RFC PATCH v3 09/13] drivers: iommu: arm-smmu-v3: split probe functions into DT/generic portions

2016-07-20 Thread Lorenzo Pieralisi
portions so that other FW interfaces (ie ACPI) can reuse the HW probing functions and skip the DT portion accordingly. This patch implements no functional change, only code reshuffling. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Acked-by: Will Deacon <will.dea...@ar

[RFC PATCH v3 12/13] drivers: acpi: iort: replace rid map type with type mask

2016-07-20 Thread Lorenzo Pieralisi
node type. Upgrade the IORT iort_node_map_rid() API to work with a type mask instead of a single node type so that it can be used for mappings that span multiple components types (ie IOMMUs). Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Hanjun Guo <hanjun@linar

[RFC PATCH v3 10/13] drivers: iommu: arm-smmu-v3: enable ACPI driver initialization

2016-07-20 Thread Lorenzo Pieralisi
the driver and initialize the bus IOMMU operations accordingly. This patch changes the logic in arm-smmu-v3 init call to allow for it to be probed in ACPI systems. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Acked-by: Will Deacon <will.dea...@arm.com> Cc: Will Deac

[RFC PATCH v3 13/13] drivers: acpi: iort: introduce iort_iommu_configure

2016-07-20 Thread Lorenzo Pieralisi
-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Hanjun Guo <hanjun@linaro.org> Cc: Tomasz Nowicki <t...@semihalf.com> Cc: "Rafael J. Wysocki" <r...@rjwysocki.net> --- drivers/acpi/iort.c | 64 drivers

[RFC PATCH v3 01/13] drivers: iommu: add FWNODE_IOMMU fwnode type

2016-07-20 Thread Lorenzo Pieralisi
kernel layer that allows to allocate/free FWNODE_IOMMU fwnode_handle structures and associate them with IOMMU devices. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Joerg Roedel <j...@8bytes.org> Cc: "Rafael J. Wysocki" <r...@rjwysocki.net> ---

[RFC PATCH v3 08/13] drivers: acpi: iort: add support for ARM SMMU platform devices creation

2016-07-20 Thread Lorenzo Pieralisi
is added to the kernel) to be used to define the platform devices names, init the IOMMUs, count their resources and finally initialize them. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Hanjun Guo <hanjun@linaro.org> Cc: Tomasz Nowicki <t...@semihalf.com

[RFC PATCH v3 04/13] drivers: platform: add fwnode base platform devices retrieval

2016-07-20 Thread Lorenzo Pieralisi
. The OF equivalent (eg of_find_device_by_node()) will reuse the newly introduced function when OF code will take care of setting up the device->fwnode value that is currently left dangling for platform devices instantiated out of device tree nodes. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.c

Re: Purpose of pci_remap_iospace

2016-07-13 Thread Lorenzo Pieralisi
On Wed, Jul 13, 2016 at 12:30:44PM +, Bharat Kumar Gogada wrote: [...] > err = of_pci_get_host_bridge_resources(node, 0, 0xff, , ); > if (err) { > pr_err("Getting bridge resources failed\n"); > return err; > } >

Re: [PATCH v6 00/10] acpi, clocksource: add GTDT driver and GTDT support in arm_arch_timer

2016-07-07 Thread Lorenzo Pieralisi
[+Sudeep] On Thu, Jul 07, 2016 at 02:03:17PM +0200, Rafael J. Wysocki wrote: [...] > > >> So is this a documentation issue in which case Fu Wei can add that to > > >> the file to explain its limited to ARM64. Or we could even rename the > > >> file acpi_arm64_gtdt.c > > >> > > >> It seems a

Re: [PATCH v6 00/10] acpi, clocksource: add GTDT driver and GTDT support in arm_arch_timer

2016-07-08 Thread Lorenzo Pieralisi
On Thu, Jul 07, 2016 at 03:58:04PM +0200, Rafael J. Wysocki wrote: [...] > > Anyway let's avoid these petty arguments, I agree there must be some > > sort of ARM64 ACPI maintainership for the reasons you mentioned above. > > To avoid confusion on who's going to push stuff to Linus, I can do >

Re: [PATCH v8 0/6] ACPI / processor_idle: Add ACPI v6.0 LPI support

2016-07-08 Thread Lorenzo Pieralisi
On Fri, Jul 08, 2016 at 12:04:40PM +0100, Sudeep Holla wrote: > > > On 07/07/16 22:02, Rafael J. Wysocki wrote: > >On Thu, Jul 7, 2016 at 7:10 PM, Sudeep Holla wrote: > >>ACPI 6.0 introduced LPI(Low Power Idle) states that provides an alternate > >>method to describe

Re: [PATCH v8 5/6] arm64: add support for ACPI Low Power Idle(LPI)

2016-07-08 Thread Lorenzo Pieralisi
On Thu, Jul 07, 2016 at 06:10:50PM +0100, Sudeep Holla wrote: > This patch adds appropriate callbacks to support ACPI Low Power Idle > (LPI) on ARM64. > > Cc: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> > Cc: Mark Rutland <mark.rutl...@arm.com> > Cc: Daniel Lezc

Re: [RFC PATCH v3 13/13] drivers: acpi: iort: introduce iort_iommu_configure

2016-08-08 Thread Lorenzo Pieralisi
Hi Nate, thanks for having a look. On Wed, Aug 03, 2016 at 10:19:43AM -0400, nwatt...@codeaurora.org wrote: > On 2016-07-20 07:23, Lorenzo Pieralisi wrote: > >DT based systems have a generic kernel API to configure IOMMUs > >for devices (ie of_iommu_configure()). > > > &g

Re: [PATCH v7 4/4] nmi_backtrace: generate one-line reports for idle cpus

2016-08-09 Thread Lorenzo Pieralisi
On Mon, Aug 08, 2016 at 05:48:28PM +0100, Mark Rutland wrote: > Hi, > > [adding Lorenzo] > > On Mon, Aug 08, 2016 at 12:03:38PM -0400, Chris Metcalf wrote: > > When doing an nmi backtrace of many cores, most of which are idle, > > the output is a little overwhelming and very uninformative.

[PATCH v4 12/15] drivers: iommu: arm-smmu-v3: add IORT configuration

2016-08-15 Thread Lorenzo Pieralisi
configuration functions to the IORT kernel layer for the ARM SMMU v3 components, so that the ARM SMMU v3 driver can initialize its respective platform device by relying on the IORT kernel infrastructure and by adding a corresponding ACPI device early probe section entry. Signed-off-by: Lorenzo Pieralisi

[PATCH v4 15/15] drivers: acpi: iort: introduce iort_iommu_configure

2016-08-15 Thread Lorenzo Pieralisi
-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Hanjun Guo <hanjun@linaro.org> Cc: Tomasz Nowicki <t...@semihalf.com> Cc: "Rafael J. Wysocki" <r...@rjwysocki.net> --- drivers/acpi/arm64/iort.c | 96 +++ drivers/ac

<    1   2   3   4   5   6   7   8   9   10   >