All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v4 0/8] xen/arm: Resync the SMMU driver with the Linux one
@ 2015-02-25 18:52 Julien Grall
  2015-02-25 18:52 ` [PATCH v4 1/8] xen/iommu: arm: Remove temporary the SMMU driver Julien Grall
                   ` (8 more replies)
  0 siblings, 9 replies; 19+ messages in thread
From: Julien Grall @ 2015-02-25 18:52 UTC (permalink / raw)
  To: xen-devel
  Cc: stefano.stabellini, manish.jaggi, Julien Grall, tim, ian.campbell

Hello,

The SMMU driver has diverged from Linux. Having our own driver doesn't make
any benefits and make difficult to backport fixes and/or porting features
such as PCI.

With this series, the code of the SMMU drivers (copied from Linux) is mostly
not modified. If it's the case a comment /* Xen: ... */ has been added to
explain why. The driver is based on Linux 3.19. Even if they reworked the SMMU
code in 4.0 (page table code has been moved in a separate library), I think
we should stay on 3.19 version. Mainly because I don't want to spend again a
week to resync and Linux drivers can change fast.

To make the change obvious, the resync of the SMMU code is made in several
steps:
    1) Revert the current SMMU driver (patch #1)
    2) Import as it is the driver from Linux (patch #5)
    3) Changes for Xen (patch #6)

I also took the opportunity of the resync to consolidate the iommu ops in a
single set. When I added the IOMMU set to handle platform device passthrough
(ops assign_dt_device and reassign_dt_device), I didn't think about merging
the ops with the PCI one. In fact Linux is using a signel set and have only
few lines per driver specific to each set (PCI or platform device).

A branch is available with all changes:
    git://xenbits.xen.org/people/julieng/xen-unstable.git branch smmu-rework-v4

Major changes in v4:
    - Drop the support of midway in the patch which will be upstreamed.
    - Re-order/re-work the SMMU changes in order to modify less the Linux code.

Major changes in v3:
    - Add back coherent walk support (see patch #13)

Major changes in v2:
    - Introduce the geneirc struct to describe device on ARM. Alias it
    to pci_dev on x86.
    - Defer the introduction of PCI in the generic device later

For all changes see each patches.

I have summarized below the patch acked/modified:

    A: Patch acked
    M: Patch modified in this version

Sincerely yours,

Julien Grall (8):
  xen/iommu: arm: Remove temporary the SMMU driver
  xen/arm: Introduce a generic way to describe device
  xen/iommu: Consolidate device assignment ops into a single set
  xen/arm: Describe devices supported by a driver with dt_device_match
  xen/iommu: arm: Import the SMMU driver from Linux
  xen/iommu: smmu: Add Xen specific code to be able to use the driver
  xen/iommu: smmu: Advertise when the SMMU support coherent table walk
  DO NOT APPLY xen/iommu: smmu: Changes to support Midway SMMU

 xen/arch/arm/device.c                 |   21 +-
 xen/arch/arm/gic-v2.c                 |   10 +-
 xen/arch/arm/gic-v3.c                 |    8 +-
 xen/common/device_tree.c              |    3 +
 xen/drivers/char/exynos4210-uart.c    |    8 +-
 xen/drivers/char/ns16550.c            |   12 +-
 xen/drivers/char/omap-uart.c          |    8 +-
 xen/drivers/char/pl011.c              |    8 +-
 xen/drivers/char/scif-uart.c          |    8 +-
 xen/drivers/passthrough/arm/smmu.c    | 4057 +++++++++++++++++++++------------
 xen/drivers/passthrough/device_tree.c |    5 +-
 xen/drivers/passthrough/pci.c         |   20 +-
 xen/include/asm-arm/device.h          |   30 +-
 xen/include/asm-arm/gic.h             |   15 +-
 xen/include/asm-x86/device.h          |   25 +
 xen/include/xen/device_tree.h         |   13 +
 xen/include/xen/iommu.h               |   18 +-
 xen/include/xen/pci.h                 |    1 +
 18 files changed, 2672 insertions(+), 1598 deletions(-)
 create mode 100644 xen/include/asm-x86/device.h

-- 
2.1.4

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

end of thread, other threads:[~2015-03-30  9:52 UTC | newest]

Thread overview: 19+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-02-25 18:52 [PATCH v4 0/8] xen/arm: Resync the SMMU driver with the Linux one Julien Grall
2015-02-25 18:52 ` [PATCH v4 1/8] xen/iommu: arm: Remove temporary the SMMU driver Julien Grall
2015-02-25 18:52 ` [PATCH v4 2/8] xen/arm: Introduce a generic way to describe device Julien Grall
2015-03-30  9:51   ` Manish Jaggi
2015-02-25 18:52 ` [PATCH v4 3/8] xen/iommu: Consolidate device assignment ops into a single set Julien Grall
2015-02-25 18:52 ` [PATCH v4 4/8] xen/arm: Describe devices supported by a driver with dt_device_match Julien Grall
2015-02-25 18:52 ` [PATCH v4 5/8] xen/iommu: arm: Import the SMMU driver from Linux Julien Grall
2015-02-25 18:52 ` [PATCH v4 6/8] xen/iommu: smmu: Add Xen specific code to be able to use the driver Julien Grall
2015-03-02  7:03   ` Manish Jaggi
2015-03-04  2:08     ` Manish Jaggi
2015-03-02 13:17   ` Ian Campbell
2015-03-02 13:45     ` Julien Grall
2015-03-02 13:54       ` Ian Campbell
2015-02-25 18:53 ` [PATCH v4 7/8] xen/iommu: smmu: Advertise when the SMMU support coherent table walk Julien Grall
2015-03-02 13:10   ` Ian Campbell
2015-03-02 15:23     ` Julien Grall
2015-03-02 16:24       ` Ian Campbell
2015-02-25 18:53 ` [PATCH v4 8/8] DO NOT APPLY xen/iommu: smmu: Changes to support Midway SMMU Julien Grall
2015-03-02 14:47 ` [PATCH v4 0/8] xen/arm: Resync the SMMU driver with the Linux one Ian Campbell

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.