Hi Will,
On Tue, Oct 24, 2017 at 11:20:29AM +0100, Will Deacon wrote:
> On Tue, Oct 24, 2017 at 11:08:02AM +0530, Linu Cherian wrote:
> > On Fri Sep 01, 2017 at 07:21:03PM +0200, Eric Auger wrote:
> > > This series implements the emulation code for ARM SMMUv3.
> > &
| 123
> include/hw/arm/smmuv3.h | 80 +++
> include/hw/arm/sysbus-fdt.h |2 +
> include/hw/arm/virt.h | 15 +
> target/arm/kvm.c| 27 +
> target/arm/trace-events |3 +
> 17 files changed, 2886 insertions(+), 24 deletions(-)
> create mode 100644 hw/arm/smmu-common.c
> create mode 100644 hw/arm/smmu-internal.h
> create mode 100644 hw/arm/smmuv3-internal.h
> create mode 100644 hw/arm/smmuv3.c
> create mode 100644 include/hw/arm/smmu-common.h
> create mode 100644 include/hw/arm/smmuv3.h
>
> --
> 2.5.5
>
>
--
Linu cherian
gt; smmuv3_cmdq_consume_out(uint8_t prod_wrap, uint32_t prod, uint8_t cons_wrap,
> uint32_t cons) "prod_wrap:%d, prod:0x%x cons_wrap:%d cons:0x%x"
> smmuv3_update(bool is_empty, uint32_t prod, uint32_t cons, uint8_t
> prod_wrap, uint8_t cons_wrap) "q empty:%d prod:%d cons:%d p.wrap:%d p.cons:%d"
> smmuv3_update_check_cmd(int error) "cmdq not enabled or error :0x%x"
> --
> 2.5.5
>
>
--
Linu cherian
a single one. It is unclear to me if we can notify with
> >> hugepage/block page size mask. Peter may confirm/infirm this. in vsmmuv3
> >> code I notify by granule or block size.
> >>
> >> Bharat, please can you add this to your TODO list?
> >>
> >> Linu, thanks a lot for the time you spent debugging this issue.
> >> Curiously on my side, it is really seldom hit but it is ...
> >
> > Thanks Linu and Eric, I added this to my todo list.
> > While I am still not able to reproduce the issue. I tried with e1000 and
> > now try with ixgbe device. May I know which device can be used to reproduce
> > this issue?
>
> On my side I used an i350T2 device (igb) to reproduce the issue.
Myself used a Thunderx NIC which is an on chip PCI device.
--
Linu cherian
Hi Eric,
On Wed Sep 27, 2017 at 11:24:01AM +0200, Auger Eric wrote:
> Hi Linu,
>
> On 27/09/2017 11:21, Linu Cherian wrote:
> > On Wed Sep 27, 2017 at 10:55:07AM +0200, Auger Eric wrote:
> >> Hi Linu,
> >>
> >> On 27/09/2017 10:30, Bharat Bhushan w
On Thu Sep 28, 2017 at 09:54:20AM +0200, Auger Eric wrote:
> Hi Linu, Peter,
>
> On 28/09/2017 09:13, Peter Xu wrote:
> > On Thu, Sep 28, 2017 at 12:13:12PM +0530, Linu Cherian wrote:
> >> Hi Eric,
> >>
> >>
> >> On Fri Sep 01, 2017 at 07
| 15 +
> include/hw/arm/smmu-common.h| 123
> include/hw/arm/smmuv3.h | 80 +++
> include/hw/arm/sysbus-fdt.h |2 +
> include/hw/arm/virt.h | 15 +
> target/arm/kvm.c| 27 +
> target/arm/trace-events |3 +
> 17 files changed, 2886 insertions(+), 24 deletions(-)
> create mode 100644 hw/arm/smmu-common.c
> create mode 100644 hw/arm/smmu-internal.h
> create mode 100644 hw/arm/smmuv3-internal.h
> create mode 100644 hw/arm/smmuv3.c
> create mode 100644 include/hw/arm/smmu-common.h
> create mode 100644 include/hw/arm/smmuv3.h
>
> --
> 2.5.5
>
>
--
Linu cherian
On Wed Sep 27, 2017 at 10:55:07AM +0200, Auger Eric wrote:
> Hi Linu,
>
> On 27/09/2017 10:30, Bharat Bhushan wrote:
> > Hi,
> >
> >> -Original Message-
> >> From: Linu Cherian [mailto:linuc.dec...@gmail.com]
> >> Sent: Wednesday, Se
On Wed Sep 27, 2017 at 10:55:07AM +0200, Auger Eric wrote:
> Hi Linu,
>
> On 27/09/2017 10:30, Bharat Bhushan wrote:
> > Hi,
> >
> >> -Original Message-
> >> From: Linu Cherian [mailto:linuc.dec...@gmail.com]
> >> Sent: Wednesday, Se
On Wed Sep 27, 2017 at 08:30:51AM +, Bharat Bhushan wrote:
> Hi,
>
> > -Original Message-
> > From: Linu Cherian [mailto:linuc.dec...@gmail.com]
> > Sent: Wednesday, September 27, 2017 1:11 PM
> > To: Bharat Bhushan
> > Cc: eric.au...@
| 181
> ++-
> include/hw/virtio/virtio-iommu.h | 6 ++
> target/arm/kvm.c | 27 ++
> target/arm/trace-events | 3 +
> 5 files changed, 219 insertions(+), 3 deletions(-)
>
> --
> 1.9.3
>
>
--
Linu cherian
r=%s"
> smmuv3_notify_flag_del(const char *iommu) "DEL SMMUNotifier node for iommu
> mr=%s"
> smmuv3_replay_mr(const char *name) "iommu mr=%s"
> +smmuv3_replay(const char *name, void *n, hwaddr start, hwaddr end) "iommu
> mr=%s notifier=%p [0x%"PRIx64",0x%"PRIx64"]"
> smmuv3_notify_entry(hwaddr iova, hwaddr pa, hwaddr mask, int perm)
> "iova=0x%"PRIx64" pa=0x%" PRIx64" mask=0x%"PRIx64" perm=%d"
> smmuv3_notify_iova_range(const char *name, uint64_t iova, size_t size, void
> *n) "iommu mr=%s iova=0x%"PRIx64" size=0x%lx n=%p"
> --
> 2.5.5
>
>
--
Linu cherian
nclude/hw/acpi/acpi-defs.h | 15 +
> include/hw/arm/smmu-common.h| 123
> include/hw/arm/smmuv3.h | 80 +++
> include/hw/arm/sysbus-fdt.h |2 +
> include/hw/arm/virt.h | 15 +
> target/arm/kvm.c| 27 +
> target/arm/trace-events |3 +
> 17 files changed, 2886 insertions(+), 24 deletions(-)
> create mode 100644 hw/arm/smmu-common.c
> create mode 100644 hw/arm/smmu-internal.h
> create mode 100644 hw/arm/smmuv3-internal.h
> create mode 100644 hw/arm/smmuv3.c
> create mode 100644 include/hw/arm/smmu-common.h
> create mode 100644 include/hw/arm/smmuv3.h
>
> --
> 2.5.5
>
>
--
Linu cherian
On Fri Sep 08, 2017 at 05:18:19PM +0200, Auger Eric wrote:
> Hi Linu,
>
> On 08/09/2017 12:52, Linu Cherian wrote:
> > Hi Eric,
> >
> > On Fri Sep 01, 2017 at 07:21:08PM +0200, Eric Auger wrote:
> >> From: Prem Mallappa
> >>
> >>
1,79 @@
> +/*
> + * Copyright (C) 2014-2016 Broadcom Corporation
> + * Copyright (c) 2017 Red Hat, Inc.
> + * Written by Prem Mallappa, Eric Auger
> + *
> + * This program is free software; you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation, either version 2 of the License, or
> + * (at your option) any later version.
> + *
> + * This program is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> + * GNU General Public License for more details.
> + *
> + * You should have received a copy of the GNU General Public License along
> + * with this program; if not, see <http://www.gnu.org/licenses/>.
> + */
> +
> +#ifndef HW_ARM_SMMUV3_H
> +#define HW_ARM_SMMUV3_H
> +
> +#include "hw/arm/smmu-common.h"
> +
> +#define TYPE_SMMUV3_IOMMU_MEMORY_REGION "smmuv3-iommu-memory-region"
> +
> +#define SMMU_NREGS0x200
> +
> +typedef struct SMMUQueue {
> + hwaddr base;
> + uint32_t prod;
> + uint32_t cons;
> + union {
> + struct {
> + uint8_t prod:1;
> + uint8_t cons:1;
> + };
> + uint8_t unused;
> + } wrap;
> +
> + uint16_t entries; /* Number of entries */
> + uint8_t ent_size; /* Size of entry in bytes */
> + uint8_t shift; /* Size in log2 */
> +} SMMUQueue;
> +
> +typedef struct SMMUV3State {
> +SMMUState smmu_state;
> +
> +/* Local cache of most-frequently used registers */
> +#define SMMU_FEATURE_2LVL_STE (1 << 0)
> +uint32_t features;
> +uint16_t sid_size;
> +uint16_t sid_split;
> +uint64_t strtab_base;
> +
> +uint32_tregs[SMMU_NREGS];
> +
> +qemu_irq irq[4];
> +SMMUQueuecmdq, evtq;
> +
> +} SMMUV3State;
> +
> +typedef enum {
> +SMMU_IRQ_EVTQ,
> +SMMU_IRQ_PRIQ,
> +SMMU_IRQ_CMD_SYNC,
> +SMMU_IRQ_GERROR,
> +} SMMUIrq;
> +
> +typedef struct {
> +SMMUBaseClass smmu_base_class;
> +} SMMUV3Class;
> +
> +#define TYPE_SMMU_V3_DEV "smmuv3"
> +#define SMMU_V3_DEV(obj) OBJECT_CHECK(SMMUV3State, (obj), TYPE_SMMU_V3_DEV)
> +#define SMMU_V3_DEVICE_GET_CLASS(obj) \
> +OBJECT_GET_CLASS(SMMUBaseClass, (obj), TYPE_SMMU_V3_DEV)
> +
> +#endif
> --
> 2.5.5
>
>
--
Linu cherian
| 5 ++
> hw/virtio/virtio-iommu.c | 163
> +++
> include/hw/virtio/virtio-iommu.h | 6 ++
> target/arm/kvm.c | 27 +++
> target/arm/trace-events | 3 +
> 5 files changed, 204 insertions(+)
>
> --
> 1.9.3
>
>
--
Linu cherian
S=SEV not supported, ignoring"
> smmuv3_cmdq_consume_out(uint8_t prod_wrap, uint32_t prod, uint8_t cons_wrap,
> uint32_t cons) "prod_wrap:%d, prod:0x%x cons_wrap:%d cons:0x%x"
> smmuv3_update(bool is_empty, uint32_t prod, uint32_t cons, uint8_t
> prod_wrap, uint8_t cons_wrap) "q empty:%d prod:%d cons:%d p.wrap:%d p.cons:%d"
> @@ -50,3 +51,16 @@ smmuv3_dump_ste(int i, uint32_t word0, int j, uint32_t
> word1) "STE[%2d]: 0x%x\t
> smmuv3_dump_cd(int i, uint32_t word0, int j, uint32_t word1) "CD[%2d]:
> 0x%x\t CD[%2d]: 0x%x"
> smmuv3_dump_cmd(int i, uint32_t word0, int j, uint32_t word1) "CMD[%2d]:
> 0x%x\t CMD[%2d]: 0x%x"
> smmuv3_cfg_stage(int s, uint32_t oas, uint32_t tsz, uint64_t ttbr, bool
> aa64, uint32_t granule_sz, int initial_level) "TransCFG stage:%d oas:%d
> tsz:%d ttbr:0x%"PRIx64" aa64:%d granule_sz:%d, initial_level = %d"
> +
> +smmuv3_replay(uint16_t sid, bool enabled) "sid=%d, enabled=%d"
> +smmuv3_replay_hook(hwaddr iova, hwaddr pa, hwaddr mask, int perm)
> "iova=0x%"PRIx64" pa=0x%" PRIx64" mask=0x%"PRIx64" perm=%d"
> +smmuv3_map_hook(hwaddr iova, hwaddr pa, hwaddr mask, int perm)
> "iova=0x%"PRIx64" pa=0x%" PRIx64" mask=0x%"PRIx64" perm=%d"
> +smmuv3_notify_flag_add(const char *iommu) "ADD SMMUNotifier node for iommu
> mr=%s"
> +smmuv3_notify_flag_del(const char *iommu) "DEL SMMUNotifier node for iommu
> mr=%s"
> +smmuv3_replay_single(const char *name, uint64_t iova, void *n) "iommu mr=%s
> iova=0x%"PRIx64" n=%p"
> +smmuv3_replay_range(const char *name, uint64_t iova, size_t size, void *n)
> "iommu mr=%s iova=0x%"PRIx64" size=0x%lx n=%p"
> +smmuv3_replay_all(const char *name) "iommu mr=%s"
> +smmuv3_notify_all(const char *name, uint64_t iova) "iommu mr=%s
> iova=0x%"PRIx64
> +smmuv3_unmap_notifier(uint8_t bus, uint8_t slot, uint8_t fn, uint64_t iova,
> uint64_t size) "Device %02x:%02x.%x start 0x%"PRIx64" size 0x%"PRIx64
> +smmuv3_context_device_invalidate(uint32_t sid) "sid=%d"
> +
> --
> 2.5.5
>
>
--
Linu cherian
p:%d cons:0x%x"
> smmuv3_update(bool is_empty, uint32_t prod, uint32_t cons, uint8_t
> prod_wrap, uint8_t cons_wrap) "q empty:%d prod:%d cons:%d p.wrap:%d p.cons:%d"
> @@ -50,3 +51,16 @@ smmuv3_dump_ste(int i, uint32_t word0, int j, uint32_t
> word1) "STE[%2d]: 0x%x\t
> smmuv3_dump_cd(int i, uint32_t word0, int j, uint32_t word1) "CD[%2d]:
> 0x%x\t CD[%2d]: 0x%x"
> smmuv3_dump_cmd(int i, uint32_t word0, int j, uint32_t word1) "CMD[%2d]:
> 0x%x\t CMD[%2d]: 0x%x"
> smmuv3_cfg_stage(int s, uint32_t oas, uint32_t tsz, uint64_t ttbr, bool
> aa64, uint32_t granule_sz, int initial_level) "TransCFG stage:%d oas:%d
> tsz:%d ttbr:0x%"PRIx64" aa64:%d granule_sz:%d, initial_level = %d"
> +
> +smmuv3_replay(uint16_t sid, bool enabled) "sid=%d, enabled=%d"
> +smmuv3_replay_hook(hwaddr iova, hwaddr pa, hwaddr mask, int perm)
> "iova=0x%"PRIx64" pa=0x%" PRIx64" mask=0x%"PRIx64" perm=%d"
> +smmuv3_map_hook(hwaddr iova, hwaddr pa, hwaddr mask, int perm)
> "iova=0x%"PRIx64" pa=0x%" PRIx64" mask=0x%"PRIx64" perm=%d"
> +smmuv3_notify_flag_add(const char *iommu) "ADD SMMUNotifier node for iommu
> mr=%s"
> +smmuv3_notify_flag_del(const char *iommu) "DEL SMMUNotifier node for iommu
> mr=%s"
> +smmuv3_replay_single(const char *name, uint64_t iova, void *n) "iommu mr=%s
> iova=0x%"PRIx64" n=%p"
> +smmuv3_replay_range(const char *name, uint64_t iova, size_t size, void *n)
> "iommu mr=%s iova=0x%"PRIx64" size=0x%lx n=%p"
> +smmuv3_replay_all(const char *name) "iommu mr=%s"
> +smmuv3_notify_all(const char *name, uint64_t iova) "iommu mr=%s
> iova=0x%"PRIx64
> +smmuv3_unmap_notifier(uint8_t bus, uint8_t slot, uint8_t fn, uint64_t iova,
> uint64_t size) "Device %02x:%02x.%x start 0x%"PRIx64" size 0x%"PRIx64
> +smmuv3_context_device_invalidate(uint32_t sid) "sid=%d"
> +
> --
> 2.5.5
>
>
--
Linu cherian
On Thu Aug 17, 2017 at 05:26:53PM +0200, Auger Eric wrote:
> Hi Linu, Jean,
>
> On 17/08/2017 15:39, Jean-Philippe Brucker wrote:
> > Hi Linu,
> >
> > On 17/08/17 12:26, Linu Cherian wrote:
> >> Hi Eric,
> >>
> >> On Tue Aug 01, 2017 at
/linux/virtio_iommu.h | 142 ++
> linux-headers/linux/virtio_iommu.h| 1 +
> scripts/update-linux-headers.sh | 3 +
> 10 files changed, 1005 insertions(+), 9 deletions(-)
> create mode 100644 hw/virtio/virtio-iommu.c
> create mode 100644 include/hw/virtio/virtio-iommu.h
> create mode 100644 include/standard-headers/linux/virtio_iommu.h
> create mode 100644 linux-headers/linux/virtio_iommu.h
>
> --
> 2.5.5
>
>
--
Linu cherian
20 matches
Mail list logo