示例#1
0
文件: smp.c 项目: 1x23/unifi-gpl
void iSeries_smp_message_recv(struct pt_regs *regs)
{
	int cpu = smp_processor_id();
	int msg;

	if (num_online_cpus() < 2)
		return;

	for (msg = 0; msg < 4; msg++)
		if (test_and_clear_bit(msg, &iSeries_smp_message[cpu]))
			smp_message_recv(msg, regs);
}
示例#2
0
void xics_ipi_action(int irq, void *dev_id, struct pt_regs *regs)
{
	extern volatile unsigned long xics_ipi_message[];
	int cpu = smp_processor_id();

	ops->qirr_info(cpu, 0xff);
	while (xics_ipi_message[cpu]) {
		if (test_and_clear_bit(PPC_MSG_CALL_FUNCTION, &xics_ipi_message[cpu])) {
			mb();
			smp_message_recv(PPC_MSG_CALL_FUNCTION, regs);
		}
		if (test_and_clear_bit(PPC_MSG_RESCHEDULE, &xics_ipi_message[cpu])) {
			mb();
			smp_message_recv(PPC_MSG_RESCHEDULE, regs);
		}
#ifdef CONFIG_XMON
		if (test_and_clear_bit(PPC_MSG_XMON_BREAK, &xics_ipi_message[cpu])) {
			mb();
			smp_message_recv(PPC_MSG_XMON_BREAK, regs);
		}
#endif
	}
}
示例#3
0
static irqreturn_t ipi_interrupt_handler(int irq, void *arg)
{
	unsigned int message = (unsigned int)(long)arg;
	unsigned int cpu = hard_smp_processor_id();
	unsigned int offs = 4 * cpu;
	unsigned int x;

	x = __raw_readl(0xfe410070 + offs); /* C0INITICI..CnINTICI */
	x &= (1 << (message << 2));
	__raw_writel(x, 0xfe410080 + offs); /* C0INTICICLR..CnINTICICLR */

	smp_message_recv(message);

	return IRQ_HANDLED;
}
static irqreturn_t j2_ipi_interrupt_handler(int irq, void *arg)
{
	unsigned cpu = hard_smp_processor_id();
	volatile unsigned *pmsg = &per_cpu(j2_ipi_messages, cpu);
	unsigned messages, i;

	do messages = *pmsg;
	while (cmpxchg(pmsg, messages, 0) != messages);

	if (!messages) return IRQ_NONE;

	for (i=0; i<SMP_MSG_NR; i++)
		if (messages & (1U<<i))
			smp_message_recv(i);

	return IRQ_HANDLED;
}
示例#5
0
static irqreturn_t debug_ipi_action(int irq, void *data)
{
	smp_message_recv(PPC_MSG_DEBUGGER_BREAK);
	return IRQ_HANDLED;
}
示例#6
0
文件: xics.c 项目: TitaniumBoy/lin
void xics_ipi_action(int irq, void *dev_id, struct pt_regs *regs)
{
	qirr_info(smp_processor_id()) = 0xff;
	smp_message_recv(MSG_RESCHEDULE, regs);
}
示例#7
0
文件: smp.c 项目: cywzl/spice4xen
static irqreturn_t xen_ppc_msg_debugger_break(int irq, void *dev_id,
					  struct pt_regs *regs)
{
	smp_message_recv(PPC_MSG_DEBUGGER_BREAK, regs);
	return IRQ_HANDLED;
}
示例#8
0
文件: smp.c 项目: cywzl/spice4xen
static irqreturn_t xen_ppc_msg_call_function(int irq, void *dev_id,
					     struct pt_regs *regs)
{
	smp_message_recv(PPC_MSG_CALL_FUNCTION, regs);
	return IRQ_HANDLED;
}
示例#9
0
文件: smp.c 项目: cywzl/spice4xen
static irqreturn_t xen_ppc_msg_reschedule(int irq, void *dev_id,
					  struct pt_regs *regs)
{
	smp_message_recv(PPC_MSG_RESCHEDULE, regs);
	return IRQ_HANDLED;
}