Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1594999

Re: [PATCH v7 06/07] iommu/ipmmu-vmsa: ARM and ARM64 archdata access

From Geert Uytterhoeven <geert@linux-m68k.org>
Newsgroups linux.kernel
Subject Re: [PATCH v7 06/07] iommu/ipmmu-vmsa: ARM and ARM64 archdata access
Date 2017-03-08 11:00 +0100
Message-ID <tiGxX-4My-19@gated-at.bofh.it> (permalink)
References <tie8G-1nN-7@gated-at.bofh.it> <tie8G-1nN-13@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


Hi Magnus,

On Tue, Mar 7, 2017 at 4:17 AM, Magnus Damm <magnus.damm@gmail.com> wrote:
> From: Magnus Damm <damm+renesas@opensource.se>
>
> Not all architectures have an iommu member in their archdata, so
> use #ifdefs support build with COMPILE_TEST on any architecture.

to support

> Signed-off-by: Magnus Damm <damm+renesas@opensource.se>
> Reviewed-by: Joerg Roedel <jroedel@suse.de>

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>

> --- 0010/drivers/iommu/ipmmu-vmsa.c
> +++ work/drivers/iommu/ipmmu-vmsa.c     2017-03-06 19:26:26.070607110 +0900
> @@ -72,6 +72,25 @@ static struct ipmmu_vmsa_domain *to_vmsa
>         return container_of(dom, struct ipmmu_vmsa_domain, io_domain);
>  }
>
> +#if defined(CONFIG_ARM) || defined(CONFIG_ARM64)
> +static struct ipmmu_vmsa_archdata *to_archdata(struct device *dev)
> +{
> +       return dev->archdata.iommu;
> +}
> +static void set_archdata(struct device *dev, struct ipmmu_vmsa_archdata *p)
> +{
> +       dev->archdata.iommu = p;
> +}
> +#else

#else /* compile testing */

> +static struct ipmmu_vmsa_archdata *to_archdata(struct device *dev)
> +{
> +       return NULL;
> +}
> +static void set_archdata(struct device *dev, struct ipmmu_vmsa_archdata *p)
> +{
> +}
> +#endif

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v7 06/07] iommu/ipmmu-vmsa: ARM and ARM64 archdata access Magnus Damm <magnus.damm@gmail.com> - 2017-03-07 04:40 +0100
  Re: [PATCH v7 06/07] iommu/ipmmu-vmsa: ARM and ARM64 archdata access Geert Uytterhoeven <geert@linux-m68k.org> - 2017-03-08 11:00 +0100
  Re: [PATCH v7 06/07] iommu/ipmmu-vmsa: ARM and ARM64 archdata access Robin Murphy <robin.murphy@arm.com> - 2017-03-08 13:50 +0100
    Re: [PATCH v7 06/07] iommu/ipmmu-vmsa: ARM and ARM64 archdata access Magnus Damm <magnus.damm@gmail.com> - 2017-03-09 04:50 +0100
      Re: [PATCH v7 06/07] iommu/ipmmu-vmsa: ARM and ARM64 archdata access Robin Murphy <robin.murphy@arm.com> - 2017-03-09 12:50 +0100

csiph-web