Exemplo n.º 1
0
// Initialize DEX registers
int init_dex_comm()
{
	unsigned long flags;
	printk(KERN_INFO "%s: WinCE DEX init.\n", __func__);

	printk(KERN_INFO "%s: WinCE DEX init.\n", __func__);

	if(machine_is_htcleo())
		base = (unsigned)(MSM_SHARED_RAM_BASE + 0xefe00);
	else
		base = (unsigned)(MSM_SHARED_RAM_BASE + 0xfc100);

	setup_irq(INT_A9_M2A_4, &dex_callback_irq);

	spin_lock_irqsave(&dex_comm_lock, flags);

	writel(0, base + PC_DATA);
	writel(0, base + PC_DATA_RESULT);
	writel(0, base + PC_SERIAL);
	writel(0, base + PC_SERIAL_CHECK);
	writel(0, base + PC_STATUS);

	spin_unlock_irqrestore(&dex_comm_lock, flags);
	printk(KERN_INFO "%s: WinCE DEX initialized.\n", __func__);

	dump_debug_stuff();

	return 0;
}
Exemplo n.º 2
0
// Initialize PCOM registers
int msm_proc_comm_wince_init()
{
	unsigned base = (unsigned)(MSM_SHARED_RAM_BASE + 0xfc100);
	unsigned long flags;

	setup_irq(INT_A9_M2A_4, &dex_callback_irq);
	
	spin_lock_irqsave(&proc_comm_lock, flags);

	writel(0, base + PC_DATA);
	writel(0, base + PC_DATA_RESULT);
	writel(0, base + PC_SERIAL);
	writel(0, base + PC_SERIAL_CHECK);
	writel(0, base + PC_STATUS);

	spin_unlock_irqrestore(&proc_comm_lock, flags);
	register_early_suspend(&early_suspend);

	printk(KERN_INFO "%s: WinCE PCOM initialized.\n", __func__);

	dump_debug_stuff();

	return 0;
}