Re: [Qemu-devel] [PATCH 6/9] Convert cpu_memory_rw_debug to use MMUAccessType

2016-07-13 Thread Andrey Smirnov
On Wed, Jul 13, 2016 at 2:52 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 13 July 2016 at 01:54, David Gibson <da...@gibson.dropbear.id.au> wrote: >> On Tue, Jul 12, 2016 at 09:05:24AM -0700, Andrey Smirnov wrote: >>> Please let me know how I should proc

[Qemu-devel] [PATCH v3 03/10] Change signature of address_space_write() to avoid casting

2016-07-19 Thread Andrey Smirnov
Change signature of address_space_write() to expectet void * as a buffer instead of uint8_t * to avoid forcing the caller of the function to do a type cast. Reviewed-by: David Gibson <da...@gibson.dropbear.id.au> Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com>

[Qemu-devel] [PATCH v3 04/10] address_space_write_continue: Distill common code

2016-07-19 Thread Andrey Smirnov
Move call to memory_region_dispatch_write() outside of swtich statement since the only thing that is different about all of those call is "length" argument and that matches value in "l". Reviewed-by: David Gibson <da...@gibson.dropbear.id.au> Signed-off-by: A

[Qemu-devel] [PATCH v3 02/10] Change signature of address_space_read() to avoid casting

2016-07-19 Thread Andrey Smirnov
Change signature of address_space_read() to expectet void * as a buffer instead of uint8_t * to avoid forcing the caller of the function to do a type cast. Reviewed-by: David Gibson <da...@gibson.dropbear.id.au> Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com>

[Qemu-devel] [PATCH v3 00/10] Support non-direct memory writes in cpu_memory_rw_debug

2016-07-19 Thread Andrey Smirnov
- Rebased on top of http://patchwork.ozlabs.org/patch/635235/ - Additional code cleanup patches Andrey Smirnov (10): Avoid needless calls to address_space_rw() Change signature of address_space_read() to avoid casting Change signature of address_space_write() to avoid casting

[Qemu-devel] [PATCH v3 05/10] Rename MMUAccessType to MemoryAccessType

2016-07-19 Thread Andrey Smirnov
Rename MMUAccessType to MemoryAccessType and MMU_* constants to corresponding MEM_* constants, so it would be possible to re-use these defenitions in other, non MMU-related, contexts. Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- include/exec/exec-all.h | 2 +- inclu

[Qemu-devel] [PATCH v3 06/10] Change signature of cpu_memory_rw_debug() to avoid casting

2016-07-19 Thread Andrey Smirnov
Change signature of cpu_memory_rw_debug() to expectet void * as a buffer instead of uint8_t * to avoid forcing the caller of the function to do a type cast. Reviewed-by: David Gibson <da...@gibson.dropbear.id.au> Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com>

[Qemu-devel] [PATCH v3 07/10] Convert cpu_memory_rw_debug to use MemoryAccessType

2016-07-19 Thread Andrey Smirnov
Convert cpu_memory_rw_debug() to use MemoryAccessType as a way of specifying memory reads/writes. This makes caller code be more obvious in what it does (previously one had to interpret 0 or 1 and remember the semantics of the last boolean argument of the function). Signed-off-by: Andrey Smirnov

[Qemu-devel] [PATCH v3 10/10] exec: Use address_space_rw to handle reads and wirtes

2016-07-19 Thread Andrey Smirnov
Use address_space_rw to handle reads and wirtes in cpu_memory_rw_debug() this way it becomes possible to modify memory mapped registers through GDB connection. Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- exec.c

[Qemu-devel] [PATCH v3 01/10] Avoid needless calls to address_space_rw()

2016-07-19 Thread Andrey Smirnov
Avoid calling address_space_rw() when direction of the transfer is constant and known at compile time and replace them with explicit calls to address_space_read()/address_space_write(). Reviewed-by: David Gibson <da...@gibson.dropbear.id.au> Signed-off-by: Andrey Smirnov <andrew.smir...@

[Qemu-devel] [PATCH v3 09/10] gdbstub: Convert target_memory_rw_debug to use MemoryAccessType

2016-07-19 Thread Andrey Smirnov
Convert target_memory_rw_debug to use MemoryAccessType as to follow similar conversion of cpu_memory_rw_debug. Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- gdbstub.c | 13 - 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/gdbstub.c b/gdbstub.c

[Qemu-devel] [PATCH v3 08/10] Convert address_space_rw to use MemoryAccessType

2016-07-19 Thread Andrey Smirnov
Convert address_space_rw() to use MemoryAccessType following the conversion of cpu_memory_rw_debug(). Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- exec.c | 14 +- include/exec/memory.h| 7 +-- kvm-all.c| 8 +--- s

Re: [Qemu-devel] [PATCH 4/9] address_space_write_continue: Distill common code

2016-07-12 Thread Andrey Smirnov
On Thu, Jul 7, 2016 at 8:38 PM, David Gibson <da...@gibson.dropbear.id.au> wrote: > On Thu, Jul 07, 2016 at 04:33:38PM -0700, Andrey Smirnov wrote: >> Move call to memory_region_dispatch_write() outside of swtich statement >> since the only thing that is different ab

Re: [Qemu-devel] [PATCH 7/9] Convert address_space_rw to use MMUAccessType

2016-07-12 Thread Andrey Smirnov
>> } >> >> enum write_rom_type { >> @@ -3643,7 +3646,7 @@ int cpu_memory_rw_debug(CPUState *cpu, target_ulong >> addr, >> } else { >> address_space_rw(cpu->cpu_ases[asidx].as, phys_addr, >> MEMTXATTRS_UNSPECIFIED, >> -

Re: [Qemu-devel] [PATCH 4/9] address_space_write_continue: Distill common code

2016-07-12 Thread Andrey Smirnov
On Tue, Jul 12, 2016 at 8:41 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 12 July 2016 at 16:28, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> On Thu, Jul 7, 2016 at 8:38 PM, David Gibson >> <da...@gibson.dropbear.id.au> wrote: >>> On Thu

Re: [Qemu-devel] [PATCH 6/9] Convert cpu_memory_rw_debug to use MMUAccessType

2016-07-12 Thread Andrey Smirnov
On Mon, Jul 11, 2016 at 10:27 PM, David Gibson wrote: > On Mon, Jul 11, 2016 at 05:27:50PM +0100, Peter Maydell wrote: >> On 11 July 2016 at 03:24, David Gibson wrote: >> > On Sun, Jul 10, 2016 at 08:32:32PM +0100, Peter Maydell wrote: >>

[Qemu-devel] [RFC PATCH] armv7m_nvic: Use qemu_get_cpu(0) instead of current_cpu

2016-06-28 Thread Andrey Smirnov
that ARMv7M architecture is a single core architecture. Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/intc/armv7m_nvic.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/hw/intc/armv7m_nvic.c b/hw/intc/armv7m_nvic.c index 890d5d7..06d8db6 100644 --

[Qemu-devel] [RFC PATCH] exec: Support non-direct memory writes in cpu_memory_rw_debug

2016-06-28 Thread Andrey Smirnov
on-running CPU. A concrete example would be starting QEMU emulating Cortex-M with -S, connecting with GDB and modifying the value of Vector Table Offset register. Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- cpus.c | 2 +- disas.c |

Re: [Qemu-devel] [RFC PATCH] exec: Support non-direct memory writes in cpu_memory_rw_debug

2016-06-30 Thread Andrey Smirnov
On Wed, Jun 29, 2016 at 8:55 AM, Paolo Bonzini <pbonz...@redhat.com> wrote: > On 28/06/2016 23:44, Andrey Smirnov wrote: >> Add code to support writing to memory mapped peripherals via >> cpu_memory_rw_debug(). The code of that function already supports >> reading f

Re: [Qemu-devel] [RFC PATCH] exec: Support non-direct memory writes in cpu_memory_rw_debug

2016-06-30 Thread Andrey Smirnov
On Thu, Jun 30, 2016 at 7:06 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 28 June 2016 at 22:44, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> Add code to support writing to memory mapped peripherals via >> cpu_memory_rw_debug(). The code of tha

[Qemu-devel] [PATCH] util/path: Always translate /etc/ld.so.cache

2017-01-27 Thread Andrey Smirnov
application compiled for PowerPC on a x86 host using linux-use/qemu-ppc emulation. Anything as simple as: qemu-ppc -L /bin/ls should trigger the problem. Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- util/path.c | 53 +-

Re: [Qemu-devel] [PATCH] util/path: Always translate /etc/ld.so.cache

2017-01-27 Thread Andrey Smirnov
On Fri, Jan 27, 2017 at 10:53 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 27 January 2017 at 18:31, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> Always translate /etc/ld.so.cache to point somwhere inside of guest's >> filesystem tree pointed to

[Qemu-devel] [PATCH 1/2] fsl_etsec: Pad short payloads with zeros

2016-11-28 Thread Andrey Smirnov
corresponding Linux driver of emulated host to reject buffer as a runt packet Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/fsl_etsec/rings.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/hw/net/fsl_etsec/rings.c b/hw/net/fsl_etsec/rings.c index 79d2f14..1

[Qemu-devel] [PATCH 2/2] fsl_etsec: Fix various small problems in hexdump code

2016-11-28 Thread Andrey Smirnov
Fix various small problems in hexdump code, such as: - Reference to non-existing field etsec->nic->nc.name is replaced with nc->name - Type mismatch warnings Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/fsl_etsec/etsec.c | 4 ++-- 1 file change

[Qemu-devel] [PATCH v2] fsl_etsec: Fix Tx BD ring wrapping handling

2017-01-05 Thread Andrey Smirnov
ts by eight (bytes) each time a descriptor is closed successfully by the eTSEC..." revised algorithm might also a more correct way of emulating this aspect of eTSEC peripheral. Cc: Alexander Graf <ag...@suse.de> Cc: Scott Wood <scottw...@freescale.com> Cc: Jason Wang <jaso

[Qemu-devel] [PATCH v3] fsl_etsec: Fix Tx BD ring wrapping handling

2017-01-05 Thread Andrey Smirnov
ts by eight (bytes) each time a descriptor is closed successfully by the eTSEC..." revised algorithm might also a more correct way of emulating this aspect of eTSEC peripheral. Cc: Alexander Graf <ag...@suse.de> Cc: Scott Wood <scottw...@freescale.com> Cc: Jason Wang <jaso

Re: [Qemu-devel] [PATCH] fsl_etsec: Fix Tx BD ring wrapping handling

2017-01-04 Thread Andrey Smirnov
On Sun, Dec 25, 2016 at 8:12 PM, Jason Wang <jasow...@redhat.com> wrote: > > > On 2016年12月21日 05:11, Andrey Smirnov wrote: >> >> Current code that handles Tx buffer desciprtor ring scanning employs the >> following algorithm: >> >> 1. Restore

[Qemu-devel] [PATCH] fsl_etsec: Fix Tx BD ring wrapping handling

2016-12-20 Thread Andrey Smirnov
quot;start" (from #1) exit the loop loop, otherwise go to #2 This way emulation code always keeps track where guest OS driver was driving data to last while still going full "loop" over every descriptor in a ring, which, hopefully, should

[Qemu-devel] [PATCH 03/17] imx_fec: Refactor imx_eth_enable_rx()

2017-09-18 Thread Andrey Smirnov
m Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/hw/net/imx_fec.c b/hw/net/imx_fec.c index 75822344fc..84085afe09 100644 --- a/hw/net/imx_fec.c +++ b/hw/net/imx_fec.c @@ -536,19 +536

[Qemu-devel] [PATCH 17/17] Implement support for i.MX7 Sabre board

2017-09-18 Thread Andrey Smirnov
Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/arm/Makefile.objs | 2 +- hw/arm/mcimx7d-sabre.c | 100

[Qemu-devel] [PATCH 01/17] imx_fec: Do not link to netdev

2017-09-18 Thread Andrey Smirnov
<jasow...@redhat.com> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/arm/fsl-imx6.c | 1 + hw/net/imx_fec.c | 2 -- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/hw/arm/fsl-imx6.c b/hw/ar

[Qemu-devel] [PATCH 13/17] i.MX: Add code to emulate i.MX2 watchdog IP block

2017-09-18 Thread Andrey Smirnov
Add enough code to emulate i.MX2 watchdog IP block so it would be possible to reboot the machine running Linux Guest. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@

[Qemu-devel] [PATCH 11/17] sdhci: Implement write method of ACMD12ERRSTS register

2017-09-18 Thread Andrey Smirnov
Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/sd/sdhci.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/hw/sd/sdhci.c b/hw/sd/sdhci.c inde

[Qemu-devel] [PATCH 04/17] imx_fec: Change queue flushing heuristics

2017-09-18 Thread Andrey Smirnov
v...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 6 -- include/hw/net/imx_fec.h | 1 + 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/hw/net/imx_fec.c b/hw/net/imx_fec.c index 84085afe09..767402909d 100644 --- a/hw

[Qemu-devel] [PATCH 15/17] include/qemu: Add sizes.h from Linux

2017-09-18 Thread Andrey Smirnov
Add sizes.h from Linux to have a more readable way of specifying MemoryRegion sizes. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- include/qemu/

[Qemu-devel] [PATCH 16/17] i.MX: Add i.MX7 SOC implementation.

2017-09-18 Thread Andrey Smirnov
Maydell <peter.mayd...@linaro.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- default-configs/arm-softmmu.mak | 1 + hw/arm/Makefile.objs| 2 + hw/arm/fsl-imx7.c

[Qemu-devel] [PATCH 08/17] imx_fec: Add support for multiple Tx DMA rings

2017-09-18 Thread Andrey Smirnov
More recent version of the IP block support more than one Tx DMA ring, so add the code implementing that feature. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-of

[Qemu-devel] [PATCH 00/17] Initial i.MX7 support

2017-09-18 Thread Andrey Smirnov
WDT device I also have a follow up series that implements bit needes for PCIe emulation support (DesignWare IP emulation + supporting code) which I'll be submitting after this series is accepted. Feedback is welcome! Thanks, Andrey Smirnov Andrey Smirnov (17): imx_fec: Do not link to netdev

[Qemu-devel] [PATCH 10/17] sdhci: Add i.MX specific subtype of SDHCI

2017-09-18 Thread Andrey Smirnov
: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/sd/sdhci-internal.h | 15 ++ hw/sd/sdhci.c | 123 - include/hw/sd/sdhci.h | 8 3 files

[Qemu-devel] [PATCH 07/17] imx_fec: Emulate SHIFT16 in ENETx_RACC

2017-09-18 Thread Andrey Smirnov
Needed to support latest Linux kernel driver which relies on that functionality. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.sm

[Qemu-devel] [PATCH 14/17] i.MX7: Add code to emulate SNVS IP-block

2017-09-18 Thread Andrey Smirnov
Add code to emulate SNVS IP-block. Currently only the bits needed to be able to emulate machine shutdown are implemented. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@

[Qemu-devel] [PATCH 12/17] i.MX: Add i.MX7 CCM, PMU and ANALOG device

2017-09-18 Thread Andrey Smirnov
Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/misc/Makefile.objs | 1 + hw/misc/imx7_ccm.c

[Qemu-devel] [PATCH 05/17] imx_fec: Use ENET_FTRL to determine truncation length

2017-09-18 Thread Andrey Smirnov
rg Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/net/imx_fec.c b/hw/net/imx_fec.c index 767402909d..989c11be5f 100644 --- a/hw/net/imx_fec.c +++ b/hw/net/imx_fec.c

[Qemu-devel] [PATCH 02/17] imx_fec: Do not calculate FEC

2017-09-18 Thread Andrey Smirnov
Save some computation time and avoid calculating CRC's frame Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> ---

[Qemu-devel] [PATCH 09/17] imx_fec: Use correct length for packet size

2017-09-18 Thread Andrey Smirnov
l@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/net/imx_fec.c b/hw/net/imx_fec.c index 6045ffe673..c45b9648d9 100644 --- a/hw/net/

[Qemu-devel] [PATCH 06/17] imx_fec: Use MIN instead of explicit ternary operator

2017-09-18 Thread Andrey Smirnov
Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 2 +- 1 file changed, 1 insertion(+), 1

Re: [Qemu-devel] [PATCH 05/17] imx_fec: Use ENET_FTRL to determine truncation length

2017-10-09 Thread Andrey Smirnov
On Fri, Oct 6, 2017 at 7:00 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 30 September 2017 at 01:17, Philippe Mathieu-Daudé <f4...@amsat.org> wrote: >> Hi Andrey, >> >> On 09/18/2017 04:50 PM, Andrey Smirnov wrote: >>> >>&g

Re: [Qemu-devel] [PATCH 08/17] imx_fec: Add support for multiple Tx DMA rings

2017-10-09 Thread Andrey Smirnov
On Fri, Oct 6, 2017 at 7:10 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 18 September 2017 at 20:50, Andrey Smirnov <andrew.smir...@gmail.com> > wrote: >> More recent version of the IP block support more than one Tx DMA ring, >> so add the code imple

Re: [Qemu-devel] [PATCH 07/17] imx_fec: Emulate SHIFT16 in ENETx_RACC

2017-10-09 Thread Andrey Smirnov
On Fri, Oct 6, 2017 at 7:02 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 18 September 2017 at 20:50, Andrey Smirnov <andrew.smir...@gmail.com> > wrote: >> Needed to support latest Linux kernel driver which relies on that >> functionality. >&

Re: [Qemu-devel] [PATCH 04/17] imx_fec: Change queue flushing heuristics

2017-10-09 Thread Andrey Smirnov
On Fri, Oct 6, 2017 at 6:56 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 18 September 2017 at 20:50, Andrey Smirnov <andrew.smir...@gmail.com> > wrote: >> In current implementation, packet queue flushing logic seem to suffer >> from a deadlock like sc

Re: [Qemu-devel] [PATCH 02/17] imx_fec: Do not calculate FEC

2017-10-09 Thread Andrey Smirnov
On Fri, Oct 6, 2017 at 6:48 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 18 September 2017 at 20:50, Andrey Smirnov <andrew.smir...@gmail.com> > wrote: >> Save some computation time and avoid calculating CRC's frame >> >> Cc: Peter Maydell <pete

Re: [Qemu-devel] [PATCH 16/17] i.MX: Add i.MX7 SOC implementation.

2017-10-09 Thread Andrey Smirnov
On Fri, Oct 6, 2017 at 7:38 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 18 September 2017 at 20:50, Andrey Smirnov <andrew.smir...@gmail.com> > wrote: >> For now we only support the following devices: >> * up to 2 Cortex A9 cores (SMP works

Re: [Qemu-devel] [PATCH 17/17] Implement support for i.MX7 Sabre board

2017-10-09 Thread Andrey Smirnov
On Fri, Oct 6, 2017 at 7:42 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 18 September 2017 at 20:51, Andrey Smirnov <andrew.smir...@gmail.com> > wrote: >> Cc: Peter Maydell <peter.mayd...@linaro.org> >> Cc: qemu-devel@nongnu.org >> Cc: qem

Re: [Qemu-devel] [PATCH 15/17] include/qemu: Add sizes.h from Linux

2017-10-09 Thread Andrey Smirnov
On Fri, Oct 6, 2017 at 7:13 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 18 September 2017 at 20:50, Andrey Smirnov <andrew.smir...@gmail.com> > wrote: >> Add sizes.h from Linux to have a more readable way of specifying >> MemoryRegion sizes. >&

Re: [Qemu-devel] [PATCH 04/17] imx_fec: Change queue flushing heuristics

2017-09-25 Thread Andrey Smirnov
On Fri, Sep 22, 2017 at 12:27 AM, Jason Wang <jasow...@redhat.com> wrote: > > > On 2017年09月19日 03:50, Andrey Smirnov wrote: >> >> In current implementation, packet queue flushing logic seem to suffer >> from a deadlock like scenario if a packet is received by the i

Re: [Qemu-devel] [PATCH 08/17] imx_fec: Add support for multiple Tx DMA rings

2017-09-25 Thread Andrey Smirnov
On Fri, Sep 22, 2017 at 12:33 AM, Jason Wang <jasow...@redhat.com> wrote: > > > On 2017年09月19日 03:50, Andrey Smirnov wrote: >> >> More recent version of the IP block support more than one Tx DMA ring, >> so add the code implementing that feature. >> >&g

Re: [Qemu-devel] [PATCH 13/17] i.MX: Add code to emulate i.MX2 watchdog IP block

2017-10-09 Thread Andrey Smirnov
On Fri, Oct 6, 2017 at 7:22 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 18 September 2017 at 20:50, Andrey Smirnov <andrew.smir...@gmail.com> > wrote: >> Add enough code to emulate i.MX2 watchdog IP block so it would be >> possible to reboot the machine

[Qemu-devel] [PATCH v2 04/27] imx_fec: Use ENET_FTRL to determine truncation length

2017-10-23 Thread Andrey Smirnov
: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c

[Qemu-devel] [PATCH v2 13/27] i.MX: Add code to emulate i.MX7 CCM, PMU and ANALOG IP blocks

2017-10-23 Thread Andrey Smirnov
Add minimal code needed to allow upstream Linux guest to boot. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-

[Qemu-devel] [PATCH v2 26/27] i.MX: Add i.MX7 SOC implementation.

2017-10-23 Thread Andrey Smirnov
000..f1a6a79179 --- /dev/null +++ b/hw/arm/fsl-imx7.c @@ -0,0 +1,596 @@ +/* + * Copyright (c) 2017, Impinj, Inc. + * + * i.MX7 SoC definitions + * + * Author: Andrey Smirnov <andrew.smir...@gmail.com> + * + * Based on hw/arm/fsl-imx6.c + * + * This program is free software; you can redistribute

[Qemu-devel] [PATCH v2 09/27] imx_fec: Fix a typo in imx_enet_receive()

2017-10-23 Thread Andrey Smirnov
Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/

[Qemu-devel] [PATCH v2 17/27] i.MX: Add code to emulate i.MX7 IOMUXC IP block

2017-10-23 Thread Andrey Smirnov
Add minimal code needed to allow upstream Linux guest to boot. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-

[Qemu-devel] [PATCH v2 24/27] i.MX: Add code to emulate i.MX7 ADC IP block

2017-10-23 Thread Andrey Smirnov
Add minimal code needed to allow upstream Linux guest to boot. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-

[Qemu-devel] [PATCH v2 22/27] pci: Add support for Designware IP block

2017-10-23 Thread Andrey Smirnov
eter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- default-configs/arm-softmmu.mak |

[Qemu-devel] [PATCH v2 01/27] imx_fec: Do not link to netdev

2017-10-23 Thread Andrey Smirnov
<jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Reviewed-by: Peter Maydell <peter.mayd...@linaro.org> Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/arm/fsl-imx6.c | 1 + hw/

[Qemu-devel] [PATCH v2 00/27] Initial i.MX7 support

2017-10-23 Thread Andrey Smirnov
without needing to use a PSCI implementing bootloader. If that is something that new board code shouldn't do, please let me know. Thanks, Andrey Smirnov [v1] https://lists.gnu.org/archive/html/qemu-devel/2017-09/msg04770.html P.S.: I don't know the best way to specify mailing list message archives, s

[Qemu-devel] [PATCH v2 02/27] imx_fec: Refactor imx_eth_enable_rx()

2017-10-23 Thread Andrey Smirnov
ongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Reviewed-by: Peter Maydell <peter.mayd...@linaro.org> Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/hw/net/imx_fec.c b/hw/

[Qemu-devel] [PATCH v2 05/27] imx_fec: Use MIN instead of explicit ternary operator

2017-10-23 Thread Andrey Smirnov
Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Reviewed-by: Philippe Mathieu-Daudé <f4...@amsat.org> Signed-off-by: And

[Qemu-devel] [PATCH v2 19/27] i.MX: Add code to emulate SDMA IP block

2017-10-23 Thread Andrey Smirnov
Add minimal code needed to allow upstream Linux guest to boot. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-

[Qemu-devel] [PATCH v2 20/27] i.MX: Add code to emulate FlexCAN IP block

2017-10-23 Thread Andrey Smirnov
Add minimal code needed to allow upstream Linux guest to boot. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-

[Qemu-devel] [PATCH v2 15/27] i.MX: Add code to emulate i.MX7 SNVS IP-block

2017-10-23 Thread Andrey Smirnov
ongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/misc/Makefile.objs | 1 + hw/misc/imx7_snvs.c | 83 + include/hw/misc/imx7_snvs.h | 35 +++ 3 files changed, 1

[Qemu-devel] [PATCH v2 03/27] imx_fec: Change queue flushing heuristics

2017-10-23 Thread Andrey Smirnov
yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 12 ++-- include/hw/net/imx_fec.h | 1 + 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/hw/net/imx_fec.c b/hw/net/imx_fec.c index 8b2e4b8ffe..eb034ffd0c 100644

[Qemu-devel] [PATCH v2 06/27] imx_fec: Emulate SHIFT16 in ENETx_RACC

2017-10-23 Thread Andrey Smirnov
gmail.com Reviewed-by: Peter Maydell <peter.mayd...@linaro.org> Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 23 +++ include/hw/net/imx_fec.h | 2 ++ 2 files changed, 25 insertions(+) diff --git a/hw/net/imx_fec.c b/hw/

[Qemu-devel] [PATCH v2 08/27] imx_fec: Use correct length for packet size

2017-10-23 Thread Andrey Smirnov
athieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Reviewed-by: Peter Maydell <peter.mayd...@linaro.org> Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 2 +- 1 file changed, 1 insertion(+), 1 de

[Qemu-devel] [PATCH v2 10/27] imx_fec: Reserve full 4K page for the register file

2017-10-23 Thread Andrey Smirnov
t.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/net/imx_fec.c

[Qemu-devel] [PATCH v2 12/27] sdhci: Implement write method of ACMD12ERRSTS register

2017-10-23 Thread Andrey Smirnov
Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/sd

[Qemu-devel] [PATCH v2 07/27] imx_fec: Add support for multiple Tx DMA rings

2017-10-23 Thread Andrey Smirnov
-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 106 ++- include/hw/net/imx_fec.h | 18 +++- 2 files changed, 102 insertions(+), 22 deletions(-) diff --git a/h

[Qemu-devel] [PATCH v2 14/27] i.MX: Add code to emulate i.MX2 watchdog IP block

2017-10-23 Thread Andrey Smirnov
-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/misc/Makefile.objs | 1 + hw/misc/imx2_wdt.c | 88 ++ include/hw/misc/imx2_wdt.h | 34 ++ 3 files changed, 123 in

[Qemu-devel] [PATCH v2 11/27] sdhci: Add i.MX specific subtype of SDHCI

2017-10-23 Thread Andrey Smirnov
Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/sd/sdhci-internal.h | 15 ++ hw/s

[Qemu-devel] [PATCH v2 16/27] i.MX: Add code to emulate GPCv2 IP block

2017-10-23 Thread Andrey Smirnov
Add minimal code needed to allow upstream Linux guest to boot. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-

[Qemu-devel] [PATCH v2 23/27] i.MX: Add code to emulate i.MX7 USBMISC IP block

2017-10-23 Thread Andrey Smirnov
Add minimal code needed to allow upstream Linux guest to boot. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-

[Qemu-devel] [PATCH v2 21/27] i.MX: Add implementation of i.MX7 GPR IP block

2017-10-23 Thread Andrey Smirnov
Add minimal code needed to allow upstream Linux guest to boot. Cc: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-

Re: [Qemu-devel] [PATCH v3 30/30] Implement support for i.MX7 Sabre board

2017-11-22 Thread Andrey Smirnov
On Tue, Nov 21, 2017 at 10:22 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 6 November 2017 at 15:48, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> Implement code needed to set up emulation of MCIMX7SABRE board from >> NXP. For more info about the HW see

Re: [Qemu-devel] [PATCH v3 14/30] i.MX: Add code to emulate i.MX2 watchdog IP block

2017-11-22 Thread Andrey Smirnov
On Tue, Nov 21, 2017 at 10:10 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 6 November 2017 at 15:47, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> Add enough code to emulate i.MX2 watchdog IP block so it would be >> possible to reboot the machine ru

Re: [Qemu-devel] [PATCH v3 13/30] i.MX: Add code to emulate i.MX7 CCM, PMU and ANALOG IP blocks

2017-11-22 Thread Andrey Smirnov
On Tue, Nov 21, 2017 at 10:08 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 6 November 2017 at 15:47, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> Add minimal code needed to allow upstream Linux guest to boot. >> >> Cc: Peter Maydell <peter.m

Re: [Qemu-devel] [PATCH v3 19/30] i.MX: Add code to emulate SDMA IP block

2017-11-22 Thread Andrey Smirnov
On Tue, Nov 21, 2017 at 10:20 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 6 November 2017 at 15:48, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> Add minimal code needed to allow upstream Linux guest to boot. >> >> Cc: Peter Maydell <peter.m

Re: [Qemu-devel] [PATCH v3 29/30] i.MX: Add i.MX7 SOC implementation.

2017-11-22 Thread Andrey Smirnov
On Wed, Nov 22, 2017 at 7:34 AM, Igor Mammedov <imamm...@redhat.com> wrote: > On Mon, 6 Nov 2017 07:48:12 -0800 > Andrey Smirnov <andrew.smir...@gmail.com> wrote: > >> The following interfaces are partially or fully emulated: >> >> * up to 2 Cortex A9

Re: [Qemu-devel] [PATCH v3 00/30] Initial i.MX7 support

2017-11-22 Thread Andrey Smirnov
On Tue, Nov 21, 2017 at 10:34 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 6 November 2017 at 15:47, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> Hi everyone, >> - Added proper USB emulation code, so now it should be possible to >&g

Re: [Qemu-devel] [PATCH v3 04/30] imx_fec: Use ENET_FTRL to determine truncation length

2017-11-22 Thread Andrey Smirnov
On Tue, Nov 21, 2017 at 9:31 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 6 November 2017 at 15:47, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> Frame truncation length, TRUNC_FL, is determined by the contents of >> ENET_FTRL register, so convert

Re: [Qemu-devel] [PATCH v3 03/30] imx_fec: Change queue flushing heuristics

2017-11-22 Thread Andrey Smirnov
On Tue, Nov 21, 2017 at 9:27 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 6 November 2017 at 15:47, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> In current implementation, packet queue flushing logic seem to suffer >> from a deadlock like scena

Re: [Qemu-devel] [PATCH v3 10/30] imx_fec: Reserve full 4K page for the register file

2017-11-22 Thread Andrey Smirnov
On Tue, Nov 21, 2017 at 9:48 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 6 November 2017 at 15:47, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> Some i.MX SoCs (e.g. i.MX7) have FEC registers going as far as offset >> 0x614, so to avoid getting

Re: [Qemu-devel] [PATCH v3 07/30] imx_fec: Add support for multiple Tx DMA rings

2017-11-22 Thread Andrey Smirnov
On Tue, Nov 21, 2017 at 9:44 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 6 November 2017 at 15:47, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> More recent version of the IP block support more than one Tx DMA ring, >> so add the code implementing th

Re: [Qemu-devel] [PATCH v3 11/30] sdhci: Add i.MX specific subtype of SDHCI

2017-11-22 Thread Andrey Smirnov
On Tue, Nov 21, 2017 at 10:02 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 6 November 2017 at 15:47, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> IP block found on several generations of i.MX family does not use >> vanilla SDHCI implementation

Re: [Qemu-devel] [PATCH v3 12/30] sdhci: Implement write method of ACMD12ERRSTS register

2017-11-22 Thread Andrey Smirnov
On Tue, Nov 21, 2017 at 10:04 AM, Peter Maydell <peter.mayd...@linaro.org> wrote: > On 6 November 2017 at 15:47, Andrey Smirnov <andrew.smir...@gmail.com> wrote: >> Cc: Peter Maydell <peter.mayd...@linaro.org> >> Cc: Jason Wang <jasow...@redhat.com> >>

Re: [Qemu-devel] [PATCH v2 12/15] sdhci: Add i.MX specific subtype of SDHCI

2017-12-16 Thread Andrey Smirnov
to be merged in, your code will hopefully be in the master already, sounds good? Meanwhile, do you have public git URL for your changes that I can use to re-base on top of? >>> On 12/14/2017 11:52 AM, Andrey Smirnov wrote: >>>> IP block found on several generations of i.MX family doe

[Qemu-devel] [PATCH v2 03/15] imx_fec: Change queue flushing heuristics

2017-12-14 Thread Andrey Smirnov
c: yurov...@gmail.com Reviewed-by: Peter Maydell <peter.mayd...@linaro.org> Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/hw/net/imx_fec.c b/hw/net/imx_fec.c index 8b2e4b8ffe

[Qemu-devel] [PATCH v2 09/15] imx_fec: Use correct length for packet size

2017-12-14 Thread Andrey Smirnov
athieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Reviewed-by: Peter Maydell <peter.mayd...@linaro.org> Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 2 +- 1 file changed, 1 insertion(+), 1 de

[Qemu-devel] [PATCH v2 02/15] imx_fec: Refactor imx_eth_enable_rx()

2017-12-14 Thread Andrey Smirnov
ongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Reviewed-by: Peter Maydell <peter.mayd...@linaro.org> Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/hw/net/imx_fec.c b/hw/

[Qemu-devel] [PATCH v2 05/15] imx_fec: Use ENET_FTRL to determine truncation length

2017-12-14 Thread Andrey Smirnov
: Peter Maydell <peter.mayd...@linaro.org> Cc: Jason Wang <jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/net/imx_fec.c

[Qemu-devel] [PATCH v2 01/15] imx_fec: Do not link to netdev

2017-12-14 Thread Andrey Smirnov
<jasow...@redhat.com> Cc: Philippe Mathieu-Daudé <f4...@amsat.org> Cc: qemu-devel@nongnu.org Cc: qemu-...@nongnu.org Cc: yurov...@gmail.com Reviewed-by: Peter Maydell <peter.mayd...@linaro.org> Signed-off-by: Andrey Smirnov <andrew.smir...@gmail.com> --- hw/arm/fsl-imx6.c | 1 + hw/

  1   2   3   >