netduino2.c (ef475b5dd12684591e6264e517eaa5b3e90f7ffa) | netduino2.c (ba1ba5cca3962a9cc400c713c736b4fb8db1f38e) |
---|---|
1/* 2 * Netduino 2 Machine Model 3 * 4 * Copyright (c) 2014 Alistair Francis <alistair@alistair23.me> 5 * 6 * Permission is hereby granted, free of charge, to any person obtaining a copy 7 * of this software and associated documentation files (the "Software"), to deal 8 * in the Software without restriction, including without limitation the rights --- 20 unchanged lines hidden (view full) --- 29#include "hw/arm/stm32f205_soc.h" 30#include "hw/arm/arm.h" 31 32static void netduino2_init(MachineState *machine) 33{ 34 DeviceState *dev; 35 36 dev = qdev_create(NULL, TYPE_STM32F205_SOC); | 1/* 2 * Netduino 2 Machine Model 3 * 4 * Copyright (c) 2014 Alistair Francis <alistair@alistair23.me> 5 * 6 * Permission is hereby granted, free of charge, to any person obtaining a copy 7 * of this software and associated documentation files (the "Software"), to deal 8 * in the Software without restriction, including without limitation the rights --- 20 unchanged lines hidden (view full) --- 29#include "hw/arm/stm32f205_soc.h" 30#include "hw/arm/arm.h" 31 32static void netduino2_init(MachineState *machine) 33{ 34 DeviceState *dev; 35 36 dev = qdev_create(NULL, TYPE_STM32F205_SOC); |
37 qdev_prop_set_string(dev, "cpu-model", "cortex-m3"); | 37 qdev_prop_set_string(dev, "cpu-type", ARM_CPU_TYPE_NAME("cortex-m3")); |
38 object_property_set_bool(OBJECT(dev), true, "realized", &error_fatal); 39 40 armv7m_load_kernel(ARM_CPU(first_cpu), machine->kernel_filename, 41 FLASH_SIZE); 42} 43 44static void netduino2_machine_init(MachineClass *mc) 45{ 46 mc->desc = "Netduino 2 Machine"; 47 mc->init = netduino2_init; 48 mc->ignore_memory_transaction_failures = true; 49} 50 51DEFINE_MACHINE("netduino2", netduino2_machine_init) | 38 object_property_set_bool(OBJECT(dev), true, "realized", &error_fatal); 39 40 armv7m_load_kernel(ARM_CPU(first_cpu), machine->kernel_filename, 41 FLASH_SIZE); 42} 43 44static void netduino2_machine_init(MachineClass *mc) 45{ 46 mc->desc = "Netduino 2 Machine"; 47 mc->init = netduino2_init; 48 mc->ignore_memory_transaction_failures = true; 49} 50 51DEFINE_MACHINE("netduino2", netduino2_machine_init) |