2018-05-06 21:58:06 +00:00
|
|
|
// SPDX-License-Identifier: GPL-2.0+
|
2005-07-28 15:08:46 +00:00
|
|
|
/*
|
|
|
|
* (C) Copyright 2000-2002
|
|
|
|
* Wolfgang Denk, DENX Software Engineering, wd@denx.de.
|
|
|
|
*
|
|
|
|
* Copyright 2004 Freescale Semiconductor, Inc.
|
|
|
|
*/
|
|
|
|
|
|
|
|
#include <common.h>
|
|
|
|
#include <command.h>
|
|
|
|
#include <mpc83xx.h>
|
|
|
|
#include <asm/processor.h>
|
|
|
|
|
2006-03-31 16:32:53 +00:00
|
|
|
DECLARE_GLOBAL_DATA_PTR;
|
|
|
|
|
2005-07-28 15:08:46 +00:00
|
|
|
struct irq_action {
|
|
|
|
interrupt_handler_t *handler;
|
|
|
|
void *arg;
|
|
|
|
ulong count;
|
|
|
|
};
|
|
|
|
|
2017-08-14 02:44:37 +00:00
|
|
|
void interrupt_init_cpu (unsigned *decrementer_count)
|
2005-07-28 15:08:46 +00:00
|
|
|
{
|
2008-10-16 13:01:15 +00:00
|
|
|
volatile immap_t *immr = (immap_t *) CONFIG_SYS_IMMR;
|
2006-01-11 17:19:12 +00:00
|
|
|
|
2008-10-16 13:01:15 +00:00
|
|
|
*decrementer_count = (gd->bus_clk / 4) / CONFIG_SYS_HZ;
|
2006-01-11 17:19:12 +00:00
|
|
|
|
|
|
|
/* Enable e300 time base */
|
|
|
|
|
|
|
|
immr->sysconf.spcr |= 0x00400000;
|
2005-07-28 15:08:46 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Handle external interrupts
|
|
|
|
*/
|
|
|
|
|
|
|
|
void external_interrupt (struct pt_regs *regs)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/*
|
|
|
|
* Install and free an interrupt handler.
|
|
|
|
*/
|
|
|
|
|
|
|
|
void
|
|
|
|
irq_install_handler (int irq, interrupt_handler_t * handler, void *arg)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void irq_free_handler (int irq)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void timer_interrupt_cpu (struct pt_regs *regs)
|
|
|
|
{
|
|
|
|
/* nothing to do here */
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
|
|
|
|
|
2007-07-10 00:06:00 +00:00
|
|
|
#if defined(CONFIG_CMD_IRQ)
|
2005-07-28 15:08:46 +00:00
|
|
|
|
|
|
|
/* ripped this out of ppc4xx/interrupts.c */
|
|
|
|
|
|
|
|
/*
|
|
|
|
* irqinfo - print information about PCI devices
|
|
|
|
*/
|
|
|
|
|
|
|
|
void
|
2010-06-28 20:00:46 +00:00
|
|
|
do_irqinfo(cmd_tbl_t *cmdtp, bd_t *bd, int flag, int argc, char * const argv[])
|
2005-07-28 15:08:46 +00:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2007-07-10 00:06:00 +00:00
|
|
|
#endif
|