mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 08:13:54 -06:00
xilinx_timer: changed nr_timers to one_timer_only
The configurable property for this IP in the Xilinx tools is a boolean switch "one-timer-only" that flicks this timer from being dual channel to single. Updated QEMU to work the same way for better match with the IP core and its TRM. Signed-off-by: Peter A. G. Crosthwaite <peter.crosthwaite@petalogix.com> Signed-off-by: Edgar E. Iglesias <edgar.iglesias@gmail.com>
This commit is contained in:
parent
8d4eb373f7
commit
abe098e4f9
5 changed files with 16 additions and 11 deletions
|
@ -16,12 +16,12 @@ xilinx_intc_create(target_phys_addr_t base, qemu_irq irq, int kind_of_intr)
|
|||
|
||||
/* OPB Timer/Counter. */
|
||||
static inline DeviceState *
|
||||
xilinx_timer_create(target_phys_addr_t base, qemu_irq irq, int nr, int freq)
|
||||
xilinx_timer_create(target_phys_addr_t base, qemu_irq irq, int oto, int freq)
|
||||
{
|
||||
DeviceState *dev;
|
||||
|
||||
dev = qdev_create(NULL, "xilinx,timer");
|
||||
qdev_prop_set_uint32(dev, "nr-timers", nr);
|
||||
qdev_prop_set_uint32(dev, "one-timer-only", oto);
|
||||
qdev_prop_set_uint32(dev, "frequency", freq);
|
||||
qdev_init_nofail(dev);
|
||||
sysbus_mmio_map(sysbus_from_qdev(dev), 0, base);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue