[PATCH v7 06/16] drivers: iommu: arm-smmu-v3: convert struct device of_node to fwnode usage

2016-11-09 Thread Lorenzo Pieralisi
also on systems that do not associate an of_node pointer to a struct device (eg ACPI), making the device look-up and iommu_ops retrieval firmware agnostic. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomas

[PATCH v7 12/16] drivers: iommu: arm-smmu: split probe functions into DT/generic portions

2016-11-09 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> Tested-by: Hanjun Guo <hanjun@linaro.or

[PATCH v7 16/16] drivers: acpi: iort: introduce iort_iommu_configure

2016-11-09 Thread Lorenzo Pieralisi
-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomasz Nowicki <t...@semihalf.com> Cc: Hanjun Guo <hanjun@linaro.org> Cc: Tomasz Nowicki <t...@semihalf.com> Cc: "Rafael J. Wysocki" <r...@rjwysoc

[PATCH v7 09/16] drivers: acpi: iort: add support for ARM SMMU platform devices creation

2016-11-09 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> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomasz Nowicki <t...@s

[PATCH v7 13/16] drivers: iommu: arm-smmu: add IORT configuration

2016-11-09 Thread Lorenzo Pieralisi
functions to the IORT kernel layer for the ARM SMMU components, so that the ARM SMMU 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 v7 04/16] drivers: iommu: make of_iommu_set/get_ops() DT agnostic

2016-11-09 Thread Lorenzo Pieralisi
struct device.fwnode member pointer. Convert the DT specific of_iommu_{set/get}_ops() interface to use struct device.fwnode as a look-up token, making the interface usable on ACPI systems. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Tested-by: Hanjun Guo <hanjun@linaro.or

[PATCH v7 08/16] drivers: acpi: iort: add node match function

2016-11-09 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> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomasz Nowicki <t...@semihalf.com> Cc:

[PATCH v7 11/16] drivers: iommu: arm-smmu-v3: add IORT configuration

2016-11-09 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 v7 01/16] drivers: acpi: add FWNODE_ACPI_STATIC fwnode type

2016-11-09 Thread Lorenzo Pieralisi
to dynamically allocate and free the corresponding firmware nodes so that kernel subsystems can use it to instantiate the nodes and associate them with the respective devices. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Hanjun Guo <hanjun@linaro.or

[PATCH v7 10/16] drivers: iommu: arm-smmu-v3: split probe functions into DT/generic portions

2016-11-09 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...@arm.co

[PATCH v7 07/16] drivers: acpi: implement acpi_dma_configure

2016-11-09 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] Tested-by: Hanjun

[PATCH v7 00/16] ACPI IORT ARM SMMU support

2016-11-09 Thread Lorenzo Pieralisi
urposes here: git://git.kernel.org/pub/scm/linux/kernel/git/lpieralisi/linux.git acpi/iort-smmu-v7 Tested on Juno and FVP models for ARM SMMU v1 and v3 probing path. Lorenzo Pieralisi (16): drivers: acpi: add FWNODE_ACPI_STATIC fwnode type drivers: acpi: iort: introduce linker section for IORT entries

[PATCH v7 03/16] drivers: acpi: iort: add support for IOMMU fwnode registration

2016-11-09 Thread Lorenzo Pieralisi
-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomasz Nowicki <t...@semihalf.com> Cc: Hanjun Guo <hanjun@linaro.org> Cc: Tomasz Nowicki <t...@semihal

[PATCH v7 02/16] drivers: acpi: iort: introduce linker section for IORT entries probing

2016-11-09 Thread Lorenzo Pieralisi
associated with the driver specific callback is matched. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomasz Nowicki <t...@semihalf.com> Cc: Tomasz Nowicki <t...

[PATCH v7 05/16] drivers: iommu: arm-smmu: convert struct device of_node to fwnode usage

2016-11-09 Thread Lorenzo Pieralisi
on systems that do not associate an of_node pointer to a struct device (eg ACPI), making the device look-up and iommu_ops retrieval firmware agnostic. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomas

Re: [PATCH] drivers: cpuidle: assign enter_freeze to same as enter callback function

2016-11-09 Thread Lorenzo Pieralisi
On Wed, Nov 09, 2016 at 05:43:30PM +, Sudeep Holla wrote: > enter_freeze() callback is expected atleast to do the same as enter() > but it has to guarantee that interrupts aren't enabled at any point > in its execution, as the tick is frozen. > > CPUs execute ->enter_freeze with the local

Re: [PATCHv2] PCI: QDF2432 32 bit config space accessors

2016-11-10 Thread Lorenzo Pieralisi
On Thu, Nov 10, 2016 at 06:25:16PM +0800, Ard Biesheuvel wrote: > On 10 November 2016 at 06:49, Bjorn Helgaas wrote: > > On Wed, Nov 09, 2016 at 08:29:23PM +, Ard Biesheuvel wrote: > >> Hi Bjorn, > >> > >> On 9 November 2016 at 20:06, Bjorn Helgaas

Re: [PATCH v7 00/16] ACPI IORT ARM SMMU support

2016-11-10 Thread Lorenzo Pieralisi
Hi Rafael, On Thu, Nov 10, 2016 at 12:36:12AM +0100, Rafael J. Wysocki wrote: > Hi Lorenzo, > > On Wed, Nov 9, 2016 at 3:19 PM, Lorenzo Pieralisi > <lorenzo.pieral...@arm.com> wrote: > > This patch series is v7 of a previous posting: > > > > https://lkml.org/

Re: [PATCH v7 04/16] drivers: iommu: make of_iommu_set/get_ops() DT agnostic

2016-11-10 Thread Lorenzo Pieralisi
On Wed, Nov 09, 2016 at 02:40:08PM +, Robin Murphy wrote: [...] > > +void fwnode_iommu_set_ops(struct fwnode_handle *fwnode, > > + const struct iommu_ops *ops) > > +{ > > + struct iommu_fwentry *iommu = kzalloc(sizeof(*iommu), GFP_KERNEL); > > + > > + if

Re: [PATCH V6 2/3] ACPI: Add support for ResourceSource/IRQ domain mapping

2016-11-10 Thread Lorenzo Pieralisi
On Thu, Nov 10, 2016 at 10:02:35AM -0500, agust...@codeaurora.org wrote: > Hey Hanjun, > > On 2016-11-09 21:36, Hanjun Guo wrote: > >Hi Marc, Rafael, Lorenzo, > > > >Since we agreed to add a probe deferral if we failed to get irq > >resources which mirroring the DT does (patch 1 in this patch

Re: [PATCH v6 04/16] drivers: iommu: make of_iommu_set/get_ops() DT agnostic

2016-11-07 Thread Lorenzo Pieralisi
On Tue, Nov 01, 2016 at 04:36:10PM +, Robin Murphy wrote: > Bikeshed alert... > > On 18/10/16 17:04, Lorenzo Pieralisi wrote: > > The of_iommu_{set/get}_ops() API is used to associate a device > > tree node with a specific set of IOMMU operations. The same > > k

Re: [PATCH v6 09/16] drivers: acpi: iort: add support for ARM SMMU platform devices creation

2016-11-07 Thread Lorenzo Pieralisi
On Tue, Nov 01, 2016 at 04:30:22PM -0600, Graeme Gregory wrote: > On Fri, Oct 28, 2016 at 04:50:07PM +0100, Lorenzo Pieralisi wrote: > > On Tue, Oct 18, 2016 at 05:04:07PM +0100, Lorenzo Pieralisi wrote: > > > In ARM ACPI systems, IOMMU components are specified through stati

Re: aarch64 ACPI boot regressed by commit 7ba5f605f3a0 ("arm64/numa: remove the limitation that cpu0 must bind to node0")

2016-10-14 Thread Lorenzo Pieralisi
On Fri, Oct 14, 2016 at 05:27:58PM +0200, Laszlo Ersek wrote: > On 10/14/16 17:01, Laszlo Ersek wrote: > > > Maybe the code I > > tried to analyze in this email was never *meant* to associate CPU#0 with > > any NUMA node at all (not even node 0); instead, other code -- for > > example code

Re: [PATCH V5 1/2] ACPI: Add support for ResourceSource/IRQ domain mapping

2016-10-20 Thread Lorenzo Pieralisi
Hi Agustin, On Tue, Oct 18, 2016 at 01:41:48PM -0400, Agustin Vega-Frias wrote: > This allows irqchip drivers to associate an ACPI DSDT device to > an IRQ domain and provides support for using the ResourceSource > in Extended IRQ Resources to find the domain and map the IRQs > specified on that

[PATCH v6 00/16] ACPI IORT ARM SMMU support

2016-10-18 Thread Lorenzo Pieralisi
DMA configure API. This patchset is provided for review/testing purposes here: git://git.kernel.org/pub/scm/linux/kernel/git/lpieralisi/linux.git acpi/iort-smmu-v6 Tested on Juno and FVP models for ARM SMMU v1 and v3 probing path. Lorenzo Pieralisi (16): drivers: acpi: add FWNODE_ACP

[PATCH v6 09/16] drivers: acpi: iort: add support for ARM SMMU platform devices creation

2016-10-18 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

[PATCH v6 15/16] drivers: acpi: iort: add single mapping function

2016-10-18 Thread Lorenzo Pieralisi
a requester id, so it cannot be used for IORT named components. Add an interface to the IORT API to enable retrieval of id by allowing an indexed walk of the single mappings array for a given component, therefore completing the IORT mapping API. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.

[PATCH v6 16/16] drivers: acpi: iort: introduce iort_iommu_configure

2016-10-18 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 | 99 +++ drivers/ac

[PATCH v6 10/16] drivers: iommu: arm-smmu-v3: split probe functions into DT/generic portions

2016-10-18 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

[PATCH v6 02/16] drivers: acpi: iort: introduce linker section for IORT entries probing

2016-10-18 Thread Lorenzo Pieralisi
associated with the driver specific callback is matched. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Hanjun Guo <hanjun@linaro.org> Cc: Tomasz Nowicki <t...@semihalf.com> Cc: "Rafael J. Wysocki" <r...@rjwysocki.net> Cc: Marc Zyngier <marc.

[PATCH v6 11/16] drivers: iommu: arm-smmu-v3: add IORT configuration

2016-10-18 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 v6 08/16] drivers: acpi: iort: add node match function

2016-10-18 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

[PATCH v6 14/16] drivers: acpi: iort: replace rid map type with type mask

2016-10-18 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

[PATCH v6 13/16] drivers: iommu: arm-smmu: add IORT configuration

2016-10-18 Thread Lorenzo Pieralisi
functions to the IORT kernel layer for the ARM SMMU components, so that the ARM SMMU 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 v6 04/16] drivers: iommu: make of_iommu_set/get_ops() DT agnostic

2016-10-18 Thread Lorenzo Pieralisi
struct device.fwnode member pointer. Convert the DT specific of_iommu_{set/get}_ops() interface to use struct device.fwnode as a look-up token, making the interface usable on ACPI systems. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Will Deacon <will.dea...@arm.com> Cc

[PATCH v6 05/16] drivers: iommu: arm-smmu: convert struct device of_node to fwnode usage

2016-10-18 Thread Lorenzo Pieralisi
on systems that do not associate an of_node pointer to a struct device (eg ACPI), making the device look-up and iommu_ops retrieval firmware agnostic. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Will Deacon <will.dea...@arm.com> Cc: Hanjun Guo <hanjun@linaro

[PATCH v6 03/16] drivers: acpi: iort: add support for IOMMU fwnode registration

2016-10-18 Thread Lorenzo Pieralisi
-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Hanjun Guo <hanjun@linaro.org> Cc: Hanjun Guo <hanjun@linaro.org> Cc: Tomasz Nowicki <t...@semihalf.com> Cc: "Rafael J. Wysocki" <r...@rjwysocki.net

[PATCH v6 12/16] drivers: iommu: arm-smmu: split probe functions into DT/generic portions

2016-10-18 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

[PATCH v6 06/16] drivers: iommu: arm-smmu-v3: convert struct device of_node to fwnode usage

2016-10-18 Thread Lorenzo Pieralisi
also on systems that do not associate an of_node pointer to a struct device (eg ACPI), making the device look-up and iommu_ops retrieval firmware agnostic. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Cc: Will Deacon <will.dea...@arm.com> Cc: Hanjun Guo <hanjun

[PATCH v6 07/16] drivers: acpi: implement acpi_dma_configure

2016-10-18 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 <bhelg...

[PATCH v6 01/16] drivers: acpi: add FWNODE_ACPI_STATIC fwnode type

2016-10-18 Thread Lorenzo Pieralisi
to dynamically allocate and free the corresponding firmware nodes so that kernel subsystems can use it to instantiate the nodes and associate them with the respective devices. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Hanjun Guo <hanjun@linaro.org> C

Re: [PATCH V3 2/2] PCI/ACPI: hisi: Add ACPI support for HiSilicon SoCs Host Controllers

2016-10-21 Thread Lorenzo Pieralisi
On Fri, Oct 21, 2016 at 02:12:44PM +0800, Dongdong Liu wrote: [...] > >>+static int hisi_pcie_init(struct pci_config_window *cfg) > >>+{ > >>+ int ret; > >>+ struct acpi_device *adev = to_acpi_device(cfg->parent); > > > >Why is this expected to be struct acpi_device? > > I use this

Re: [PATCH V3 2/2] PCI/ACPI: hisi: Add ACPI support for HiSilicon SoCs Host Controllers

2016-10-24 Thread Lorenzo Pieralisi
On Mon, Oct 24, 2016 at 02:56:37PM +0800, Dongdong Liu wrote: [...] > >The PNP0A08 acpi_device (that is what is pointed at by > >struct acpi_device = to_acpi_device(pci_config_window.parent) > >is the respective pci bridge device companion. > > > >arch/arm64/kernel/pci.c

Re: [PATCH v7 04/16] drivers: iommu: make of_iommu_set/get_ops() DT agnostic

2016-11-14 Thread Lorenzo Pieralisi
Hi Robin, Joerg, On Fri, Nov 11, 2016 at 05:43:39PM +, Robin Murphy wrote: > On 11/11/16 16:27, Joerg Roedel wrote: > > On Fri, Nov 11, 2016 at 04:17:37PM +, Robin Murphy wrote: > >> In the original of_iommu_configure design, the thought was that an ops > >> structure could be

Re: [PATCH v7 04/16] drivers: iommu: make of_iommu_set/get_ops() DT agnostic

2016-11-14 Thread Lorenzo Pieralisi
On Mon, Nov 14, 2016 at 04:52:23PM +0100, Joerg Roedel wrote: > On Mon, Nov 14, 2016 at 12:00:47PM +, Robin Murphy wrote: > > If we've already made the decision to move away from bus ops, I don't > > see that it makes sense to deliberately introduce new dependencies on > > them. Besides, as it

Re: [PATCH v7 04/16] drivers: iommu: make of_iommu_set/get_ops() DT agnostic

2016-11-15 Thread Lorenzo Pieralisi
On Mon, Nov 14, 2016 at 06:25:16PM +, Robin Murphy wrote: > On 14/11/16 15:52, Joerg Roedel wrote: > > On Mon, Nov 14, 2016 at 12:00:47PM +, Robin Murphy wrote: > >> If we've already made the decision to move away from bus ops, I don't > >> see that it makes sense to deliberately introduce

Re: [PATCH] PCI: Add information about describing PCI in ACPI

2016-11-23 Thread Lorenzo Pieralisi
On Wed, Nov 23, 2016 at 07:28:12AM +, Ard Biesheuvel wrote: > On 23 November 2016 at 01:06, Bjorn Helgaas wrote: > > On Tue, Nov 22, 2016 at 10:09:50AM +, Ard Biesheuvel wrote: > >> On 17 November 2016 at 17:59, Bjorn Helgaas wrote: > > > >> >

Re: [PATCH V6 1/2] PCI/ACPI: Provide acpi_get_rc_resources() for ARM64 platform

2016-11-22 Thread Lorenzo Pieralisi
On Tue, Nov 22, 2016 at 08:08:48PM +0800, Dongdong Liu wrote: > The acpi_get_rc_resources() is used to get the RC register address that can > not be described in MCFG. It takes the _HID to look for and returns > the RC address resource. Use PNP0C02 devices to describe such RC address > resource.

Re: [PATCH V6 1/2] PCI/ACPI: Provide acpi_get_rc_resources() for ARM64 platform

2016-11-22 Thread Lorenzo Pieralisi
On Tue, Nov 22, 2016 at 04:09:57PM +, Gabriele Paoloni wrote: [...] > > On Tue, Nov 22, 2016 at 08:08:48PM +0800, Dongdong Liu wrote: > > > The acpi_get_rc_resources() is used to get the RC register address > > that can > > > not be described in MCFG. It takes the _HID to look for and > >

Re: [PATCH V7 2/3] ACPI: Add support for ResourceSource/IRQ domain mapping

2016-11-25 Thread Lorenzo Pieralisi
Hi Agustin, On Thu, Nov 24, 2016 at 04:15:48PM +, Lorenzo Pieralisi wrote: [...] > > @@ -448,6 +449,7 @@ bool acpi_dev_resource_interrupt(struct acpi_resource > > *ares, int index, > > { > > struct acpi_resource_irq *irq; > > struct acpi_

Re: [PATCH V7 2/3] ACPI: Add support for ResourceSource/IRQ domain mapping

2016-11-24 Thread Lorenzo Pieralisi
Hi Agustin, On Sun, Nov 13, 2016 at 04:59:34PM -0500, Agustin Vega-Frias wrote: > When an Extended IRQ Resource contains a valid ResourceSource > use it to map the IRQ on the domain associated with the ACPI > device referenced. > > With this in place an irqchip driver can create its domain using

Re: [PATCH V7 1/3] ACPI: Retry IRQ conversion if it failed previously

2016-11-15 Thread Lorenzo Pieralisi
On Sun, Nov 13, 2016 at 04:59:33PM -0500, Agustin Vega-Frias wrote: > This allows probe deferral to work properly when a dependent device > fails to get a valid IRQ because the IRQ domain was not registered > at the time the resources were added to the platform_device. > > Signed-off-by: Agustin

Re: [PATCH v7 04/16] drivers: iommu: make of_iommu_set/get_ops() DT agnostic

2016-11-16 Thread Lorenzo Pieralisi
Hi Joerg, On Mon, Nov 14, 2016 at 06:25:16PM +, Robin Murphy wrote: > On 14/11/16 15:52, Joerg Roedel wrote: > > On Mon, Nov 14, 2016 at 12:00:47PM +, Robin Murphy wrote: > >> If we've already made the decision to move away from bus ops, I don't > >> see that it makes sense to

[PATCH v8 02/16] drivers: acpi: iort: introduce linker section for IORT entries probing

2016-11-16 Thread Lorenzo Pieralisi
associated with the driver specific callback is matched. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Hanjun Guo <hanjun@linaro.org> Reviewed-by: Tomasz Nowicki <t...@semihalf.com> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomasz Nowi

[PATCH v8 06/16] drivers: iommu: arm-smmu-v3: convert struct device of_node to fwnode usage

2016-11-16 Thread Lorenzo Pieralisi
also on systems that do not associate an of_node pointer to a struct device (eg ACPI), making the device look-up and iommu_ops retrieval firmware agnostic. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Robin Murphy <robin.mur...@arm.com> Reviewed-by: Tomas

[PATCH v8 00/16] ACPI IORT ARM SMMU support

2016-11-16 Thread Lorenzo Pieralisi
mu-v8 Tested on Juno and FVP models for ARM SMMU v1 and v3 probing path. Lorenzo Pieralisi (16): drivers: acpi: add FWNODE_ACPI_STATIC fwnode type drivers: acpi: iort: introduce linker section for IORT entries probing drivers: acpi: iort: add support for IOMMU fwnode registration drivers: iom

[PATCH v8 01/16] drivers: acpi: add FWNODE_ACPI_STATIC fwnode type

2016-11-16 Thread Lorenzo Pieralisi
to dynamically allocate and free the corresponding firmware nodes so that kernel subsystems can use it to instantiate the nodes and associate them with the respective devices. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Acked-by: Rafael J. Wysocki <rafael.j.wyso...@

[PATCH v8 08/16] drivers: acpi: iort: add node match function

2016-11-16 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> Reviewed-by: Tomasz Nowicki <t...@semihalf.com> Tested-by: Hanjun Guo <hanjun@linaro.org>

[PATCH v8 07/16] drivers: acpi: implement acpi_dma_configure

2016-11-16 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] Acked-by: Rafael J. Wysocki &l

[PATCH v8 11/16] drivers: iommu: arm-smmu-v3: add IORT configuration

2016-11-16 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 v8 16/16] drivers: acpi: iort: introduce iort_iommu_configure

2016-11-16 Thread Lorenzo Pieralisi
-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Acked-by: Rafael J. Wysocki <rafael.j.wyso...@intel.com> [ACPI core] Reviewed-by: Tomasz Nowicki <t...@semihalf.com> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomasz Nowicki <t...@semihalf.com> Cc: Hanjun

[PATCH v8 14/16] drivers: acpi: iort: replace rid map type with type mask

2016-11-16 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> Reviewed-by: Tomasz Nowicki <t...@sem

[PATCH v8 15/16] drivers: acpi: iort: add single mapping function

2016-11-16 Thread Lorenzo Pieralisi
a requester id, so it cannot be used for IORT named components. Add an interface to the IORT API to enable retrieval of id by allowing an indexed walk of the single mappings array for a given component, therefore completing the IORT mapping API. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.

[PATCH v8 12/16] drivers: iommu: arm-smmu: split probe functions into DT/generic portions

2016-11-16 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> Reviewed-by: Tomasz Nowicki <t...@semihalf.co

[PATCH v8 10/16] drivers: iommu: arm-smmu-v3: split probe functions into DT/generic portions

2016-11-16 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...@arm.com&

[PATCH v8 13/16] drivers: iommu: arm-smmu: add IORT configuration

2016-11-16 Thread Lorenzo Pieralisi
functions to the IORT kernel layer for the ARM SMMU components, so that the ARM SMMU 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 v8 09/16] drivers: acpi: iort: add support for ARM SMMU platform devices creation

2016-11-16 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> Reviewed-by: Tomasz Nowicki <t...@semihalf.com> Tested-by: Hanjun Guo <hanjun

[PATCH v8 04/16] drivers: iommu: make of_iommu_set/get_ops() DT agnostic

2016-11-16 Thread Lorenzo Pieralisi
the data structures and the registration API so that they are made to represent their usage more clearly. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Robin Murphy <robin.mur...@arm.com> Reviewed-by: Tomasz Nowicki <t...@semihalf.com> Tested-by:

[PATCH v8 03/16] drivers: acpi: iort: add support for IOMMU fwnode registration

2016-11-16 Thread Lorenzo Pieralisi
-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Hanjun Guo <hanjun@linaro.org> Reviewed-by: Tomasz Nowicki <t...@semihalf.com> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomasz Nowicki <t...@semihalf.com> Cc: Hanjun Guo <hanjun..

[PATCH v8 05/16] drivers: iommu: arm-smmu: convert struct device of_node to fwnode usage

2016-11-16 Thread Lorenzo Pieralisi
on systems that do not associate an of_node pointer to a struct device (eg ACPI), making the device look-up and iommu_ops retrieval firmware agnostic. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Robin Murphy <robin.mur...@arm.com> Reviewed-by: Tomas

Re: [PATCH V7 1/3] ACPI: Retry IRQ conversion if it failed previously

2016-11-16 Thread Lorenzo Pieralisi
On Tue, Nov 15, 2016 at 12:43:38PM -0500, Agustin Vega-Frias wrote: > Hi Lorenzo, > > On 2016-11-15 10:48, Lorenzo Pieralisi wrote: > >On Sun, Nov 13, 2016 at 04:59:33PM -0500, Agustin Vega-Frias wrote: > >>This allows probe deferral to work properly when a dependent

Re: [PATCH v16 13/15] acpi/arm64: Add memory-mapped timer support in GTDT driver

2016-11-18 Thread Lorenzo Pieralisi
On Wed, Nov 16, 2016 at 09:49:06PM +0800, fu@linaro.org wrote: > From: Fu Wei > > On platforms booting with ACPI, architected memory-mapped timers' > configuration data is provided by firmware through the ACPI GTDT > static table. > > The clocksource architected timer

Re: [PATCH v8 13/16] drivers: iommu: arm-smmu: add IORT configuration

2016-11-18 Thread Lorenzo Pieralisi
On Fri, Nov 18, 2016 at 05:36:46PM +, Robin Murphy wrote: > On 16/11/16 15:29, Lorenzo Pieralisi wrote: > > In ACPI bases systems, in order to be able to create platform > > based? Ok. > > devices and initialize them for ARM SMMU components, the IORT >

[PATCH v9 04/16] drivers: iommu: make of_iommu_set/get_ops() DT agnostic

2016-11-21 Thread Lorenzo Pieralisi
the data structures and the registration API so that they are made to represent their usage more clearly. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Acked-by: Will Deacon <will.dea...@arm.com> Reviewed-by: Robin Murphy <robin.mur...@arm.com> Reviewed-by:

[PATCH v9 07/16] drivers: acpi: implement acpi_dma_configure

2016-11-21 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] Acked-by: Rafael J. Wysocki &l

[PATCH v9 02/16] drivers: acpi: iort: introduce linker section for IORT entries probing

2016-11-21 Thread Lorenzo Pieralisi
associated with the driver specific callback is matched. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Hanjun Guo <hanjun@linaro.org> Reviewed-by: Tomasz Nowicki <t...@semihalf.com> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomasz Nowi

[PATCH v9 05/16] drivers: iommu: arm-smmu: convert struct device of_node to fwnode usage

2016-11-21 Thread Lorenzo Pieralisi
on systems that do not associate an of_node pointer to a struct device (eg ACPI), making the device look-up and iommu_ops retrieval firmware agnostic. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Acked-by: Will Deacon <will.dea...@arm.com> Reviewed-by: Robin Murph

[PATCH v9 06/16] drivers: iommu: arm-smmu-v3: convert struct device of_node to fwnode usage

2016-11-21 Thread Lorenzo Pieralisi
also on systems that do not associate an of_node pointer to a struct device (eg ACPI), making the device look-up and iommu_ops retrieval firmware agnostic. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Acked-by: Will Deacon <will.dea...@arm.com> Reviewed-by: Robin Murph

[PATCH v9 16/16] drivers: acpi: iort: introduce iort_iommu_configure

2016-11-21 Thread Lorenzo Pieralisi
-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Acked-by: Rafael J. Wysocki <rafael.j.wyso...@intel.com> [ACPI core] Reviewed-by: Tomasz Nowicki <t...@semihalf.com> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomasz Nowicki <t...@semihalf.com> Cc: Hanjun

[PATCH v9 14/16] drivers: acpi: iort: replace rid map type with type mask

2016-11-21 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> Reviewed-by: Tomasz Nowicki <t...@sem

[PATCH v9 09/16] drivers: acpi: iort: add support for ARM SMMU platform devices creation

2016-11-21 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> Reviewed-by: Tomasz Nowicki <t...@semihalf.com> Tested-by: Hanjun Guo <hanjun

[PATCH v9 13/16] drivers: iommu: arm-smmu: add IORT configuration

2016-11-21 Thread Lorenzo Pieralisi
functions to the IORT kernel layer for the ARM SMMU components, so that the ARM SMMU 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 v9 10/16] drivers: iommu: arm-smmu-v3: split probe functions into DT/generic portions

2016-11-21 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> Reviewed-by: Tomasz Nowicki <t...@sem

[PATCH v9 11/16] drivers: iommu: arm-smmu-v3: add IORT configuration

2016-11-21 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 v9 12/16] drivers: iommu: arm-smmu: split probe functions into DT/generic portions

2016-11-21 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> Reviewed-by: Will Deacon <will.dea...@arm.com&

[PATCH v9 00/16] ACPI IORT ARM SMMU support

2016-11-21 Thread Lorenzo Pieralisi
it up to the previously introduced ACPI DMA configure API. This patchset is provided for review/testing purposes here: git://git.kernel.org/pub/scm/linux/kernel/git/lpieralisi/linux.git acpi/iort-smmu-v9 Tested on Juno and FVP models for ARM SMMU v1 and v3 probing path. Lorenzo P

[PATCH v9 01/16] drivers: acpi: add FWNODE_ACPI_STATIC fwnode type

2016-11-21 Thread Lorenzo Pieralisi
to dynamically allocate and free the corresponding firmware nodes so that kernel subsystems can use it to instantiate the nodes and associate them with the respective devices. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Acked-by: Rafael J. Wysocki <rafael.j.wyso...@

[PATCH v9 03/16] drivers: acpi: iort: add support for IOMMU fwnode registration

2016-11-21 Thread Lorenzo Pieralisi
-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Reviewed-by: Hanjun Guo <hanjun@linaro.org> Reviewed-by: Tomasz Nowicki <t...@semihalf.com> Tested-by: Hanjun Guo <hanjun@linaro.org> Tested-by: Tomasz Nowicki <t...@semihalf.com> Cc: Hanjun Guo <hanjun..

[PATCH v9 15/16] drivers: acpi: iort: add single mapping function

2016-11-21 Thread Lorenzo Pieralisi
a requester id, so it cannot be used for IORT named components. Add an interface to the IORT API to enable retrieval of id by allowing an indexed walk of the single mappings array for a given component, therefore completing the IORT mapping API. Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.

[PATCH v9 08/16] drivers: acpi: iort: add node match function

2016-11-21 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> Reviewed-by: Tomasz Nowicki <t...@semihalf.com> Tested-by: Hanjun Guo <hanjun@linaro.org>

Re: [PATCH v7 00/16] ACPI IORT ARM SMMU support

2016-11-15 Thread Lorenzo Pieralisi
Hi Rafael, On Thu, Nov 10, 2016 at 12:36:12AM +0100, Rafael J. Wysocki wrote: > Hi Lorenzo, > > On Wed, Nov 9, 2016 at 3:19 PM, Lorenzo Pieralisi > <lorenzo.pieral...@arm.com> wrote: > > This patch series is v7 of a previous posting: > > > > https://lkml.org/

Re: [PATCH v7 00/16] ACPI IORT ARM SMMU support

2016-11-15 Thread Lorenzo Pieralisi
On Tue, Nov 15, 2016 at 02:04:09PM +0100, Rafael J. Wysocki wrote: > On Tue, Nov 15, 2016 at 11:12 AM, Lorenzo Pieralisi > <lorenzo.pieral...@arm.com> wrote: > > Hi Rafael, > > > > On Thu, Nov 10, 2016 at 12:36:12AM +0100, Rafael J. Wysocki wrote: > >> Hi

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

2016-10-20 Thread Lorenzo Pieralisi
On Thu, Oct 20, 2016 at 03:31:01PM +0100, Mark Rutland wrote: > Hi, > > On Thu, Sep 29, 2016 at 02:17:08AM +0800, fu@linaro.org wrote: > > From: Fu Wei > > > This patchset depends on the following patchset: > > [UPDATE PATCH V11 1/8] ACPI: I/O Remapping Table (IORT)

Re: [PATCH v6 00/16] ACPI IORT ARM SMMU support

2016-10-27 Thread Lorenzo Pieralisi
On Thu, Oct 27, 2016 at 12:24:48PM +0200, Rafael J. Wysocki wrote: > On Wed, Oct 26, 2016 at 1:04 PM, Lorenzo Pieralisi > <lorenzo.pieral...@arm.com> wrote: > > Rafael, Joerg (and anyone else CC'ed), > > > > On Tue, Oct 18, 2016 at 05:03:58PM +0100, Lorenzo Pieralisi

Re: [PATCH v6 00/16] ACPI IORT ARM SMMU support

2016-10-26 Thread Lorenzo Pieralisi
Rafael, Joerg (and anyone else CC'ed), On Tue, Oct 18, 2016 at 05:03:58PM +0100, Lorenzo Pieralisi wrote: > This patch series is v6 of a previous posting: > > https://lkml.org/lkml/2016/9/9/418 > > v5 -> v6 > - Rebased against v4.9-rc1 > - Changed FWNODE_IOM

Re: [PATCH v5 01/14] drivers: iommu: add FWNODE_IOMMU fwnode type

2016-10-13 Thread Lorenzo Pieralisi
Hi Rafael, On Fri, Sep 30, 2016 at 05:48:01PM +0200, Rafael J. Wysocki wrote: > On Fri, Sep 30, 2016 at 11:07 AM, Lorenzo Pieralisi > <lorenzo.pieral...@arm.com> wrote: > > On Thu, Sep 29, 2016 at 10:59:40PM +0200, Rafael J. Wysocki wrote: > >> On Thursday, September 2

[PATCH] arm64: kernel: numa: fix ACPI boot cpu numa node mapping

2016-10-17 Thread Lorenzo Pieralisi
carries out the early cpu<->node mapping also for the boot cpu (ie cpu 0), mirroring what is currently done in the DT boot path. Fixes: 7ba5f605f3a0 ("arm64/numa: remove the limitation that cpu0 must bind to node0") Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com>

[PATCH v2] arm64: kernel: numa: fix ACPI boot cpu numa node mapping

2016-10-17 Thread Lorenzo Pieralisi
rly cpu<->node mapping also for the boot cpu (ie cpu 0), mirroring what is currently done in the DT boot path. Fixes: 7ba5f605f3a0 ("arm64/numa: remove the limitation that cpu0 must bind to node0") Signed-off-by: Lorenzo Pieralisi <lorenzo.pieral...@arm.com> Tested-b

Re: aarch64 ACPI boot regressed by commit 7ba5f605f3a0 ("arm64/numa: remove the limitation that cpu0 must bind to node0")

2016-10-14 Thread Lorenzo Pieralisi
On Fri, Oct 14, 2016 at 06:22:55PM +0200, Laszlo Ersek wrote: > On 10/14/16 17:42, Lorenzo Pieralisi wrote: > > On Fri, Oct 14, 2016 at 05:27:58PM +0200, Laszlo Ersek wrote: > >> On 10/14/16 17:01, Laszlo Ersek wrote: > >> > >>> Maybe the code I > &g

Re: [PATCH V8 1/3] ACPI: Add support for ResourceSource/IRQ domain mapping

2016-12-08 Thread Lorenzo Pieralisi
Hi Agustin, please CC me for next version. On Tue, Nov 29, 2016 at 05:57:37PM -0500, Agustin Vega-Frias wrote: > When an Extended IRQ Resource contains a valid ResourceSource > use it to map the IRQ on the domain associated with the ACPI > device referenced. > > With this in place an irqchip

<    3   4   5   6   7   8   9   10   11   12   >