Hello,

The SMMU drivers 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.

To make the change obvious the resync of the SMMU code is made in several step
    1) Revert the current SMMU driver (patch #5)
    2) Import as it is the driver from Linux (patch #9)
    3) Apply 2 fixes which are useful to correctly use the SATA with SMMU on
    calxeda. I don't know why Linux didn't yet applied (patch #10-11)
    4) Chanes for Xen (patch #12)

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 assing_dt_device and reassign_dt_device), I didn't think about merging the
ops with the PCI one. In fact Linux is using a single set and have only few
lines per driver specific to each set (PCI or platform device).

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

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

Regards,

Andreas Herrmann (2):
  xen/iommu: smmu: Check for duplicate stream IDs when registering
    master devices
  xen/iommu: smmu: Introduce automatic stream-id-masking

Julien Grall (10):
  xen/arm: gic-v2: Change the device name in DT_DEVICE_START
  xen/arm: vgic: Drop unecessary include asm/device.h
  xen/dt: Extend dt_device_match to possibly store data
  xen/arm: device: Rename device_type into device_match
  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 device supported by a driver with dt_match_node
  xen/iommu: arm: Import the SMMU driver from Linux
  xen/iommu: smmu: Add Xen specific code to be able to use the driver

 xen/arch/arm/device.c                 |   25 +-
 xen/arch/arm/gic-v2.c                 |   12 +-
 xen/arch/arm/gic-v3.c                 |    8 +-
 xen/arch/arm/platform.c               |    2 +-
 xen/arch/arm/vgic-v2.c                |    1 -
 xen/arch/arm/vgic-v3.c                |    1 -
 xen/common/device.c                   |   21 +
 xen/common/device_tree.c              |   15 +-
 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/passthrough/arm/smmu.c    | 4115 +++++++++++++++++++++------------
 xen/drivers/passthrough/device_tree.c |    5 +-
 xen/drivers/passthrough/pci.c         |   20 +-
 xen/include/asm-arm/device.h          |   38 +-
 xen/include/asm-arm/gic.h             |   15 +-
 xen/include/asm-x86/device.h          |   25 +
 xen/include/xen/device_tree.h         |   19 +-
 xen/include/xen/iommu.h               |   18 +-
 xen/include/xen/pci.h                 |    1 +
 21 files changed, 2781 insertions(+), 1596 deletions(-)
 create mode 100644 xen/common/device.c
 create mode 100644 xen/include/asm-x86/device.h

-- 
2.1.4


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel

Reply via email to