提交 5c6f4f17 编写于 作者: A Andreas Färber

z2: Rename PXA2xxState variable

Avoid cpu->cpu by using "mpu" as variable name.
Signed-off-by: NAndreas Färber <afaerber@suse.de>
Acked-by: NPeter Maydell <peter.maydell@linaro.org>
上级 8efa35e0
...@@ -301,7 +301,7 @@ static void z2_init(ram_addr_t ram_size, ...@@ -301,7 +301,7 @@ static void z2_init(ram_addr_t ram_size,
{ {
MemoryRegion *address_space_mem = get_system_memory(); MemoryRegion *address_space_mem = get_system_memory();
uint32_t sector_len = 0x10000; uint32_t sector_len = 0x10000;
PXA2xxState *cpu; PXA2xxState *mpu;
DriveInfo *dinfo; DriveInfo *dinfo;
int be; int be;
void *z2_lcd; void *z2_lcd;
...@@ -313,7 +313,7 @@ static void z2_init(ram_addr_t ram_size, ...@@ -313,7 +313,7 @@ static void z2_init(ram_addr_t ram_size,
} }
/* Setup CPU & memory */ /* Setup CPU & memory */
cpu = pxa270_init(address_space_mem, z2_binfo.ram_size, cpu_model); mpu = pxa270_init(address_space_mem, z2_binfo.ram_size, cpu_model);
#ifdef TARGET_WORDS_BIGENDIAN #ifdef TARGET_WORDS_BIGENDIAN
be = 1; be = 1;
...@@ -337,25 +337,25 @@ static void z2_init(ram_addr_t ram_size, ...@@ -337,25 +337,25 @@ static void z2_init(ram_addr_t ram_size,
} }
/* setup keypad */ /* setup keypad */
pxa27x_register_keypad(cpu->kp, map, 0x100); pxa27x_register_keypad(mpu->kp, map, 0x100);
/* MMC/SD host */ /* MMC/SD host */
pxa2xx_mmci_handlers(cpu->mmc, pxa2xx_mmci_handlers(mpu->mmc,
NULL, NULL,
qdev_get_gpio_in(cpu->gpio, Z2_GPIO_SD_DETECT)); qdev_get_gpio_in(mpu->gpio, Z2_GPIO_SD_DETECT));
type_register_static(&zipit_lcd_info); type_register_static(&zipit_lcd_info);
type_register_static(&aer915_info); type_register_static(&aer915_info);
z2_lcd = ssi_create_slave(cpu->ssp[1], "zipit-lcd"); z2_lcd = ssi_create_slave(mpu->ssp[1], "zipit-lcd");
bus = pxa2xx_i2c_bus(cpu->i2c[0]); bus = pxa2xx_i2c_bus(mpu->i2c[0]);
i2c_create_slave(bus, "aer915", 0x55); i2c_create_slave(bus, "aer915", 0x55);
wm = i2c_create_slave(bus, "wm8750", 0x1b); wm = i2c_create_slave(bus, "wm8750", 0x1b);
cpu->i2s->opaque = wm; mpu->i2s->opaque = wm;
cpu->i2s->codec_out = wm8750_dac_dat; mpu->i2s->codec_out = wm8750_dac_dat;
cpu->i2s->codec_in = wm8750_adc_dat; mpu->i2s->codec_in = wm8750_adc_dat;
wm8750_data_req_set(wm, cpu->i2s->data_req, cpu->i2s); wm8750_data_req_set(wm, mpu->i2s->data_req, mpu->i2s);
qdev_connect_gpio_out(cpu->gpio, Z2_GPIO_LCD_CS, qdev_connect_gpio_out(mpu->gpio, Z2_GPIO_LCD_CS,
qemu_allocate_irqs(z2_lcd_cs, z2_lcd, 1)[0]); qemu_allocate_irqs(z2_lcd_cs, z2_lcd, 1)[0]);
if (kernel_filename) { if (kernel_filename) {
...@@ -363,7 +363,7 @@ static void z2_init(ram_addr_t ram_size, ...@@ -363,7 +363,7 @@ static void z2_init(ram_addr_t ram_size,
z2_binfo.kernel_cmdline = kernel_cmdline; z2_binfo.kernel_cmdline = kernel_cmdline;
z2_binfo.initrd_filename = initrd_filename; z2_binfo.initrd_filename = initrd_filename;
z2_binfo.board_id = 0x6dd; z2_binfo.board_id = 0x6dd;
arm_load_kernel(&cpu->cpu->env, &z2_binfo); arm_load_kernel(&mpu->cpu->env, &z2_binfo);
} }
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册