Re: [Qemu-devel] [Qemu devel v8 PATCH 0/5] Add support for Smartfusion2 SoC

2017-09-14 Thread Peter Maydell
On 14 September 2017 at 18:06, Alistair Francis  wrote:
> Once you have all the devices there you can enable bus access errors
> as well. That's a future patch set though.

Ah, I hadn't noticed this code was opting out of bus access
errors; I don't want to permit new boards which do that,
so we do need to fix that in this round. (I just sent an
email to that effect in reply to patch 1.)

thanks
-- PMM



Re: [Qemu-devel] [Qemu devel v8 PATCH 0/5] Add support for Smartfusion2 SoC

2017-09-14 Thread Alistair Francis
On Wed, Sep 13, 2017 at 9:10 PM, Philippe Mathieu-Daudé  wrote:
> On 09/08/2017 04:24 AM, sundeep subbaraya wrote:
>>
>> Hi Phillipe,
>>
>> On Fri, Sep 8, 2017 at 3:14 AM, Philippe Mathieu-Daudé > > wrote:
>>
>> Hi Subbaraya,
>>
>> very good work!
>>
>> On 09/07/2017 04:24 PM, Subbaraya Sundeep wrote:
>>
>> Hi Qemu-devel,
>>
>> I am trying to add Smartfusion2 SoC.
>> SoC is from Microsemi and System on Module(SOM)
>> board is from Emcraft systems. Smartfusion2 has hardened
>> Microcontroller(Cortex-M3)based Sub System and FPGA fabric.
>> At the moment only system timer, sysreg and SPI
>> controller are modelled.
>>
>> Testing:
>> ./arm-softmmu/qemu-system-arm -M smartfusion2-som -serial
>> mon:stdio \
>> -kernel u-boot.bin -display none -drive
>> file=spi.bin,if=mtd,format=raw
>>
>>
>> "-M emcraft-sf2" ;)
>>
>>
>> copy/paste error :)
>>
>>
>> U-Boot 2010.03-00147-g7da5092 (Jul 03 2017 - 09:04:50)
>>
>> CPU  : SmartFusion2 SoC (Cortex-M3 Hard IP)
>> Freqs: CORTEX-M3=142MHz,PCLK0=71MHz,PCLK1=71MHz
>> Board: M2S-FG484-SOM Rev 1A, www.emcraft.com 
>>
>> DRAM:  64 MB
>> *** Warning - bad CRC, using default environment
>>
>> In:serial
>> Out:   serial
>> Err:   serial
>> Net:   M2S_MAC
>> Hit any key to stop autoboot:  0
>> 16384 KiB S25FL128P_64K at 0:0 is now current device
>> ## Booting kernel from Legacy Image at a0007fc0 ...
>> Image Name:   dtskernel
>> Image Type:   ARM Linux Kernel Image (uncompressed)
>> Data Size:2664224 Bytes =  2.5 MB
>> Load Address: a0008000
>> Entry Point:  a0008001
>> Verifying Checksum ... OK
>> Loading Kernel Image ... OK
>> OK
>>
>> Starting kernel ...
>>
>> NVIC: Bad read offset 0xd74
>> [0.00] Booting Linux on physical CPU 0x0
>> [0.00] Linux version 4.5.0-1-g3aa90e8-dirty
>> (sundeep@sundeep-Vostro-3458) (gcc version 5.4.0 (GCC) ) #102
>> PREEMPT Tue May 16 19:43:40 IST 2017
>> [0.00] CPU: ARMv7-M [410fc231] revision 1 (ARMv7M),
>> cr=
>> [0.00] CPU: unknown data cache, unknown instruction cache
>> [0.00] Machine model: Microsemi SmartFusion 2 development
>> board
>> [0.00] Kernel command line: console=ttyS0,115200n8 panic=10
>> mem=64M@0xa000 earlyprintk
>> [0.00] Memory: 62204K/65536K available (1472K kernel code,
>> 73K rwdata, 652K rodata, 400K init, 120K bss, 3332K reserved, 0K
>> cma-reserved)
>> [0.00] NR_IRQS:16 nr_irqs:16 16
>> [0.001178] sched_clock: 32 bits at 83MHz, resolution 12ns, wraps
>> every 25873297401ns
>> [0.003085] clocksource: msf2_clocksource: mask: 0x
>> max_cycles: 0x, max_idle_ns: 23027234290 ns
>> [0.009732] timer at 40004000, irq=16
>> [0.014475] Calibrating delay loop... 442.36 BogoMIPS (lpj=2211840)
>> [0.653685] Serial: 8250/16550 driver, 1 ports, IRQ sharing
>> disabled
>> [0.690789] console [ttyS0] disabled
>> [0.696659] 4000.serial: ttyS0 at MMIO 0x4000 (irq = 17,
>> base_baud = 5187500) is a 16550
>> [0.702725] console [ttyS0] enabled
>> [0.826251] Freeing unused kernel memory: 400K (a021c000 -
>> a028)
>> init started: BusyBox v1.24.1 (2017-05-15 09:57:00 IST)
>> ~ #
>>
>> (qemu) info mtree
>> address-space: cpu-memory
>>- (prio 0, i/o): armv7m-container
>>  - (prio -1, i/o): system
>>-0003 (prio 0, i/o): alias
>> MSF2.eNVM.alias @MSF2.eNVM -0003
>>2000-2000 (prio 0, ram): MSF2.eSRAM
>>4000-401f (prio 0, i/o): serial
>>40001000-4000103f (prio 0, i/o): mss-spi
>>40004000-4000402f (prio 0, i/o): mss-timer
>>40011000-4001103f (prio 0, i/o): mss-spi
>>40038000-400382ff (prio 0, i/o): msf2-sysreg
>>6000-6003 (prio 0, rom): MSF2.eNVM
>>a000-a3ff (prio 0, ram): ddr-ram
>>  2200-23ff (prio 0, i/o): bitband
>>  4200-43ff (prio 0, i/o): bitband
>>  e000e000-e000efff (prio 0, i/o): nvic
>>e000e000-e000efff (prio 0, i/o): nvic_sysregs
>>e000e010-e000e0ef (prio 1, i/o): systick
>>
>> (qemu) info qtree
>> bus: main-system-bus
>>type System
>>dev: msf2-soc, id ""
>>  part-name = "M2S010"
>>  

Re: [Qemu-devel] [Qemu devel v8 PATCH 0/5] Add support for Smartfusion2 SoC

2017-09-13 Thread Philippe Mathieu-Daudé

On 09/08/2017 04:24 AM, sundeep subbaraya wrote:

Hi Phillipe,

On Fri, Sep 8, 2017 at 3:14 AM, Philippe Mathieu-Daudé > wrote:


Hi Subbaraya,

very good work!

On 09/07/2017 04:24 PM, Subbaraya Sundeep wrote:

Hi Qemu-devel,

I am trying to add Smartfusion2 SoC.
SoC is from Microsemi and System on Module(SOM)
board is from Emcraft systems. Smartfusion2 has hardened
Microcontroller(Cortex-M3)based Sub System and FPGA fabric.
At the moment only system timer, sysreg and SPI
controller are modelled.

Testing:
./arm-softmmu/qemu-system-arm -M smartfusion2-som -serial
mon:stdio \
-kernel u-boot.bin -display none -drive
file=spi.bin,if=mtd,format=raw


"-M emcraft-sf2" ;)


copy/paste error :)


U-Boot 2010.03-00147-g7da5092 (Jul 03 2017 - 09:04:50)

CPU  : SmartFusion2 SoC (Cortex-M3 Hard IP)
Freqs: CORTEX-M3=142MHz,PCLK0=71MHz,PCLK1=71MHz
Board: M2S-FG484-SOM Rev 1A, www.emcraft.com 
DRAM:  64 MB
*** Warning - bad CRC, using default environment

In:    serial
Out:   serial
Err:   serial
Net:   M2S_MAC
Hit any key to stop autoboot:  0
16384 KiB S25FL128P_64K at 0:0 is now current device
## Booting kernel from Legacy Image at a0007fc0 ...
    Image Name:   dtskernel
    Image Type:   ARM Linux Kernel Image (uncompressed)
    Data Size:    2664224 Bytes =  2.5 MB
    Load Address: a0008000
    Entry Point:  a0008001
    Verifying Checksum ... OK
    Loading Kernel Image ... OK
OK

Starting kernel ...

NVIC: Bad read offset 0xd74
[    0.00] Booting Linux on physical CPU 0x0
[    0.00] Linux version 4.5.0-1-g3aa90e8-dirty
(sundeep@sundeep-Vostro-3458) (gcc version 5.4.0 (GCC) ) #102
PREEMPT Tue May 16 19:43:40 IST 2017
[    0.00] CPU: ARMv7-M [410fc231] revision 1 (ARMv7M), cr=
[    0.00] CPU: unknown data cache, unknown instruction cache
[    0.00] Machine model: Microsemi SmartFusion 2 development board
[    0.00] Kernel command line: console=ttyS0,115200n8 panic=10
mem=64M@0xa000 earlyprintk
[    0.00] Memory: 62204K/65536K available (1472K kernel code,
73K rwdata, 652K rodata, 400K init, 120K bss, 3332K reserved, 0K
cma-reserved)
[    0.00] NR_IRQS:16 nr_irqs:16 16
[    0.001178] sched_clock: 32 bits at 83MHz, resolution 12ns, wraps
every 25873297401ns
[    0.003085] clocksource: msf2_clocksource: mask: 0x
max_cycles: 0x, max_idle_ns: 23027234290 ns
[    0.009732] timer at 40004000, irq=16
[    0.014475] Calibrating delay loop... 442.36 BogoMIPS (lpj=2211840)
[    0.653685] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[    0.690789] console [ttyS0] disabled
[    0.696659] 4000.serial: ttyS0 at MMIO 0x4000 (irq = 17,
base_baud = 5187500) is a 16550
[    0.702725] console [ttyS0] enabled
[    0.826251] Freeing unused kernel memory: 400K (a021c000 - a028)
init started: BusyBox v1.24.1 (2017-05-15 09:57:00 IST)
~ #

(qemu) info mtree
address-space: cpu-memory
   - (prio 0, i/o): armv7m-container
     - (prio -1, i/o): system
       -0003 (prio 0, i/o): alias
MSF2.eNVM.alias @MSF2.eNVM -0003
       2000-2000 (prio 0, ram): MSF2.eSRAM
       4000-401f (prio 0, i/o): serial
       40001000-4000103f (prio 0, i/o): mss-spi
       40004000-4000402f (prio 0, i/o): mss-timer
       40011000-4001103f (prio 0, i/o): mss-spi
       40038000-400382ff (prio 0, i/o): msf2-sysreg
       6000-6003 (prio 0, rom): MSF2.eNVM
       a000-a3ff (prio 0, ram): ddr-ram
     2200-23ff (prio 0, i/o): bitband
     4200-43ff (prio 0, i/o): bitband
     e000e000-e000efff (prio 0, i/o): nvic
       e000e000-e000efff (prio 0, i/o): nvic_sysregs
       e000e010-e000e0ef (prio 1, i/o): systick

(qemu) info qtree
bus: main-system-bus
   type System
   dev: msf2-soc, id ""
     part-name = "M2S010"
     eNVM-size = 262144 (0x4)
     eSRAM-size = 65536 (0x1)
     m3clk = 14200 (0x876bf80)
     apb0div = 2 (0x2)
     apb1div = 2 (0x2)
   dev: mss-spi, id ""
     gpio-out "sysbus-irq" 2
     mmio 40011000/0040
     bus: spi
       type SSI
   dev: mss-spi, id ""
     gpio-out "sysbus-irq" 2
     mmio 40001000/0040
     bus: 

Re: [Qemu-devel] [Qemu devel v8 PATCH 0/5] Add support for Smartfusion2 SoC

2017-09-08 Thread sundeep subbaraya
Hi Phillipe,

On Fri, Sep 8, 2017 at 3:14 AM, Philippe Mathieu-Daudé 
wrote:

> Hi Subbaraya,
>
> very good work!
>
> On 09/07/2017 04:24 PM, Subbaraya Sundeep wrote:
>
>> Hi Qemu-devel,
>>
>> I am trying to add Smartfusion2 SoC.
>> SoC is from Microsemi and System on Module(SOM)
>> board is from Emcraft systems. Smartfusion2 has hardened
>> Microcontroller(Cortex-M3)based Sub System and FPGA fabric.
>> At the moment only system timer, sysreg and SPI
>> controller are modelled.
>>
>> Testing:
>> ./arm-softmmu/qemu-system-arm -M smartfusion2-som -serial mon:stdio \
>> -kernel u-boot.bin -display none -drive file=spi.bin,if=mtd,format=raw
>>
>
> "-M emcraft-sf2" ;)
>

copy/paste error :)

>
> U-Boot 2010.03-00147-g7da5092 (Jul 03 2017 - 09:04:50)
>
> CPU  : SmartFusion2 SoC (Cortex-M3 Hard IP)
> Freqs: CORTEX-M3=142MHz,PCLK0=71MHz,PCLK1=71MHz
> Board: M2S-FG484-SOM Rev 1A, www.emcraft.com
> DRAM:  64 MB
> *** Warning - bad CRC, using default environment
>
> In:serial
> Out:   serial
> Err:   serial
> Net:   M2S_MAC
> Hit any key to stop autoboot:  0
> 16384 KiB S25FL128P_64K at 0:0 is now current device
> ## Booting kernel from Legacy Image at a0007fc0 ...
>Image Name:   dtskernel
>Image Type:   ARM Linux Kernel Image (uncompressed)
>Data Size:2664224 Bytes =  2.5 MB
>Load Address: a0008000
>Entry Point:  a0008001
>Verifying Checksum ... OK
>Loading Kernel Image ... OK
> OK
>
> Starting kernel ...
>
> NVIC: Bad read offset 0xd74
> [0.00] Booting Linux on physical CPU 0x0
> [0.00] Linux version 4.5.0-1-g3aa90e8-dirty
> (sundeep@sundeep-Vostro-3458) (gcc version 5.4.0 (GCC) ) #102 PREEMPT Tue
> May 16 19:43:40 IST 2017
> [0.00] CPU: ARMv7-M [410fc231] revision 1 (ARMv7M), cr=
> [0.00] CPU: unknown data cache, unknown instruction cache
> [0.00] Machine model: Microsemi SmartFusion 2 development board
> [0.00] Kernel command line: console=ttyS0,115200n8 panic=10
> mem=64M@0xa000 earlyprintk
> [0.00] Memory: 62204K/65536K available (1472K kernel code, 73K
> rwdata, 652K rodata, 400K init, 120K bss, 3332K reserved, 0K cma-reserved)
> [0.00] NR_IRQS:16 nr_irqs:16 16
> [0.001178] sched_clock: 32 bits at 83MHz, resolution 12ns, wraps every
> 25873297401ns
> [0.003085] clocksource: msf2_clocksource: mask: 0x max_cycles:
> 0x, max_idle_ns: 23027234290 ns
> [0.009732] timer at 40004000, irq=16
> [0.014475] Calibrating delay loop... 442.36 BogoMIPS (lpj=2211840)
> [0.653685] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
> [0.690789] console [ttyS0] disabled
> [0.696659] 4000.serial: ttyS0 at MMIO 0x4000 (irq = 17,
> base_baud = 5187500) is a 16550
> [0.702725] console [ttyS0] enabled
> [0.826251] Freeing unused kernel memory: 400K (a021c000 - a028)
> init started: BusyBox v1.24.1 (2017-05-15 09:57:00 IST)
> ~ #
>
> (qemu) info mtree
> address-space: cpu-memory
>   - (prio 0, i/o): armv7m-container
> - (prio -1, i/o): system
>   -0003 (prio 0, i/o): alias
> MSF2.eNVM.alias @MSF2.eNVM -0003
>   2000-2000 (prio 0, ram): MSF2.eSRAM
>   4000-401f (prio 0, i/o): serial
>   40001000-4000103f (prio 0, i/o): mss-spi
>   40004000-4000402f (prio 0, i/o): mss-timer
>   40011000-4001103f (prio 0, i/o): mss-spi
>   40038000-400382ff (prio 0, i/o): msf2-sysreg
>   6000-6003 (prio 0, rom): MSF2.eNVM
>   a000-a3ff (prio 0, ram): ddr-ram
> 2200-23ff (prio 0, i/o): bitband
> 4200-43ff (prio 0, i/o): bitband
> e000e000-e000efff (prio 0, i/o): nvic
>   e000e000-e000efff (prio 0, i/o): nvic_sysregs
>   e000e010-e000e0ef (prio 1, i/o): systick
>
> (qemu) info qtree
> bus: main-system-bus
>   type System
>   dev: msf2-soc, id ""
> part-name = "M2S010"
> eNVM-size = 262144 (0x4)
> eSRAM-size = 65536 (0x1)
> m3clk = 14200 (0x876bf80)
> apb0div = 2 (0x2)
> apb1div = 2 (0x2)
>   dev: mss-spi, id ""
> gpio-out "sysbus-irq" 2
> mmio 40011000/0040
> bus: spi
>   type SSI
>   dev: mss-spi, id ""
> gpio-out "sysbus-irq" 2
> mmio 40001000/0040
> bus: spi
>   type SSI
>   dev: s25sl12801, id ""
> gpio-in "ssi-gpio-cs" 1
> nonvolatile-cfg = 36863 (0x8fff)
> spansion-cr1nv = 0 (0x0)
> spansion-cr2nv = 1 (0x1)
> spansion-cr3nv = 2 (0x2)
> spansion-cr4nv = 16 (0x10)
> drive = "mtd0"
>   dev: mss-timer, id ""
> gpio-out "sysbus-irq" 2
> clock-frequency = 

Re: [Qemu-devel] [Qemu devel v8 PATCH 0/5] Add support for Smartfusion2 SoC

2017-09-07 Thread Philippe Mathieu-Daudé

Hi Subbaraya,

very good work!

On 09/07/2017 04:24 PM, Subbaraya Sundeep wrote:

Hi Qemu-devel,

I am trying to add Smartfusion2 SoC.
SoC is from Microsemi and System on Module(SOM)
board is from Emcraft systems. Smartfusion2 has hardened
Microcontroller(Cortex-M3)based Sub System and FPGA fabric.
At the moment only system timer, sysreg and SPI
controller are modelled.

Testing:
./arm-softmmu/qemu-system-arm -M smartfusion2-som -serial mon:stdio \
-kernel u-boot.bin -display none -drive file=spi.bin,if=mtd,format=raw


"-M emcraft-sf2" ;)

U-Boot 2010.03-00147-g7da5092 (Jul 03 2017 - 09:04:50)

CPU  : SmartFusion2 SoC (Cortex-M3 Hard IP)
Freqs: CORTEX-M3=142MHz,PCLK0=71MHz,PCLK1=71MHz
Board: M2S-FG484-SOM Rev 1A, www.emcraft.com
DRAM:  64 MB
*** Warning - bad CRC, using default environment

In:serial
Out:   serial
Err:   serial
Net:   M2S_MAC
Hit any key to stop autoboot:  0
16384 KiB S25FL128P_64K at 0:0 is now current device
## Booting kernel from Legacy Image at a0007fc0 ...
   Image Name:   dtskernel
   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:2664224 Bytes =  2.5 MB
   Load Address: a0008000
   Entry Point:  a0008001
   Verifying Checksum ... OK
   Loading Kernel Image ... OK
OK

Starting kernel ...

NVIC: Bad read offset 0xd74
[0.00] Booting Linux on physical CPU 0x0
[0.00] Linux version 4.5.0-1-g3aa90e8-dirty 
(sundeep@sundeep-Vostro-3458) (gcc version 5.4.0 (GCC) ) #102 PREEMPT 
Tue May 16 19:43:40 IST 2017

[0.00] CPU: ARMv7-M [410fc231] revision 1 (ARMv7M), cr=
[0.00] CPU: unknown data cache, unknown instruction cache
[0.00] Machine model: Microsemi SmartFusion 2 development board
[0.00] Kernel command line: console=ttyS0,115200n8 panic=10 
mem=64M@0xa000 earlyprintk
[0.00] Memory: 62204K/65536K available (1472K kernel code, 73K 
rwdata, 652K rodata, 400K init, 120K bss, 3332K reserved, 0K cma-reserved)

[0.00] NR_IRQS:16 nr_irqs:16 16
[0.001178] sched_clock: 32 bits at 83MHz, resolution 12ns, wraps 
every 25873297401ns
[0.003085] clocksource: msf2_clocksource: mask: 0x 
max_cycles: 0x, max_idle_ns: 23027234290 ns

[0.009732] timer at 40004000, irq=16
[0.014475] Calibrating delay loop... 442.36 BogoMIPS (lpj=2211840)
[0.653685] Serial: 8250/16550 driver, 1 ports, IRQ sharing disabled
[0.690789] console [ttyS0] disabled
[0.696659] 4000.serial: ttyS0 at MMIO 0x4000 (irq = 17, 
base_baud = 5187500) is a 16550

[0.702725] console [ttyS0] enabled
[0.826251] Freeing unused kernel memory: 400K (a021c000 - a028)
init started: BusyBox v1.24.1 (2017-05-15 09:57:00 IST)
~ #

(qemu) info mtree
address-space: cpu-memory
  - (prio 0, i/o): armv7m-container
- (prio -1, i/o): system
  -0003 (prio 0, i/o): alias 
MSF2.eNVM.alias @MSF2.eNVM -0003

  2000-2000 (prio 0, ram): MSF2.eSRAM
  4000-401f (prio 0, i/o): serial
  40001000-4000103f (prio 0, i/o): mss-spi
  40004000-4000402f (prio 0, i/o): mss-timer
  40011000-4001103f (prio 0, i/o): mss-spi
  40038000-400382ff (prio 0, i/o): msf2-sysreg
  6000-6003 (prio 0, rom): MSF2.eNVM
  a000-a3ff (prio 0, ram): ddr-ram
2200-23ff (prio 0, i/o): bitband
4200-43ff (prio 0, i/o): bitband
e000e000-e000efff (prio 0, i/o): nvic
  e000e000-e000efff (prio 0, i/o): nvic_sysregs
  e000e010-e000e0ef (prio 1, i/o): systick

(qemu) info qtree
bus: main-system-bus
  type System
  dev: msf2-soc, id ""
part-name = "M2S010"
eNVM-size = 262144 (0x4)
eSRAM-size = 65536 (0x1)
m3clk = 14200 (0x876bf80)
apb0div = 2 (0x2)
apb1div = 2 (0x2)
  dev: mss-spi, id ""
gpio-out "sysbus-irq" 2
mmio 40011000/0040
bus: spi
  type SSI
  dev: mss-spi, id ""
gpio-out "sysbus-irq" 2
mmio 40001000/0040
bus: spi
  type SSI
  dev: s25sl12801, id ""
gpio-in "ssi-gpio-cs" 1
nonvolatile-cfg = 36863 (0x8fff)
spansion-cr1nv = 0 (0x0)
spansion-cr2nv = 1 (0x1)
spansion-cr3nv = 2 (0x2)
spansion-cr4nv = 16 (0x10)
drive = "mtd0"
  dev: mss-timer, id ""
gpio-out "sysbus-irq" 2
clock-frequency = 7100 (0x43b5fc0)
mmio 40004000/0030
  dev: msf2-sysreg, id ""
apb0divisor = 2 (0x2)
apb1divisor = 2 (0x2)
mmio 40038000/0300

So far:
Tested-by: Philippe Mathieu-Daudé 

Just some comments (no need to fix):

M2S-FG484-SOM> reset
resetting ...
M2S-FG484-SOM>

Hmm no reset, I was 

[Qemu-devel] [Qemu devel v8 PATCH 0/5] Add support for Smartfusion2 SoC

2017-09-07 Thread Subbaraya Sundeep
Hi Qemu-devel,

I am trying to add Smartfusion2 SoC.
SoC is from Microsemi and System on Module(SOM)
board is from Emcraft systems. Smartfusion2 has hardened
Microcontroller(Cortex-M3)based Sub System and FPGA fabric.
At the moment only system timer, sysreg and SPI
controller are modelled.

Testing:
./arm-softmmu/qemu-system-arm -M smartfusion2-som -serial mon:stdio \
-kernel u-boot.bin -display none -drive file=spi.bin,if=mtd,format=raw

Binaries u-boot.bin and spi.bin are at:
https://github.com/Subbaraya-Sundeep/qemu-test-binaries.git

U-boot is from Emcraft with modified
- SPI driver not to use PDMA.
- ugly hack to pass dtb to kernel in r1.
@
https://github.com/Subbaraya-Sundeep/emcraft-uboot-sf2.git

Linux is 4.5 linux with Smartfusion2 SoC dts and clocksource
driver added by myself @
https://github.com/Subbaraya-Sundeep/linux.git

v8:
memory_region_init_ram to memory_region_init_rom in soc
%s/emcraft_sf2_init/emcraft_sf2_s2s010_init/g in som
Added mc->ignore_memory_transaction_failures = true in som
as per latest commit.
Code simplifications as suggested by Alistair in sysreg and ssi.

v7:
Removed vmstate_register_ram_global as per latest commit
Moved header files to C which are local to C source files
Removed abort() from msf2-sysreg.c
Added VMStateDescription in mss-timer.c

v6:
Moved some defines from header files to source files
Added properties m3clk, apb0div, apb0div1 properties
to soc.
Added properties apb0divisor, apb1divisor to sysreg
Update system_clock_source in msf2-soc.c
Changed machine name smartfusion2-som->emcraft-sf2

v5
As per Philippe comments:
Added abort in Sysreg if guest tries to remap memory
other than default mapping.
Use of CONFIG_MSF2 in Makefile for soc.c
Fixed incorrect logic in timer model.
Renamed msf2-timer.c -> mss-timer.c
msf2-spi.c -> mss-spi.c also type names
Renamed function msf2_init->emcraft_sf2_init in msf2-som.c
Added part-name,eNVM-size,eSRAM-size,pclk0 and pclk1
properties to soc.
Pass soc part-name,memory size and clock rate properties from som.
v4:
Fixed build failure by using PRIx macros.
v3:
Added SoC file and board file as per Alistair comments.
v2:
Added SPI controller so that u-boot loads kernel from spi flash.
v1:
Initial patch set with timer and sysreg

Thanks,
Sundeep


Subbaraya Sundeep (5):
  msf2: Add Smartfusion2 System timer
  msf2: Microsemi Smartfusion2 System Register block
  msf2: Add Smartfusion2 SPI controller
  msf2: Add Smartfusion2 SoC
  msf2: Add Emcraft's Smartfusion2 SOM kit

 default-configs/arm-softmmu.mak |   1 +
 hw/arm/Makefile.objs|   1 +
 hw/arm/msf2-soc.c   | 218 ++
 hw/arm/msf2-som.c   |  95 ++
 hw/misc/Makefile.objs   |   1 +
 hw/misc/msf2-sysreg.c   | 195 +++
 hw/ssi/Makefile.objs|   1 +
 hw/ssi/mss-spi.c| 404 
 hw/timer/Makefile.objs  |   1 +
 hw/timer/mss-timer.c| 289 
 include/hw/arm/msf2-soc.h   |  66 +++
 include/hw/misc/msf2-sysreg.h   |  78 
 include/hw/ssi/mss-spi.h|  58 ++
 include/hw/timer/mss-timer.h|  64 +++
 14 files changed, 1472 insertions(+)
 create mode 100644 hw/arm/msf2-soc.c
 create mode 100644 hw/arm/msf2-som.c
 create mode 100644 hw/misc/msf2-sysreg.c
 create mode 100644 hw/ssi/mss-spi.c
 create mode 100644 hw/timer/mss-timer.c
 create mode 100644 include/hw/arm/msf2-soc.h
 create mode 100644 include/hw/misc/msf2-sysreg.h
 create mode 100644 include/hw/ssi/mss-spi.h
 create mode 100644 include/hw/timer/mss-timer.h

-- 
2.5.0