ioapic: move common init code into driver
The initialization code and macros are the same. So extracts it and puts it into the driver. This is another step to follow the driver model. Those empty C files are there because the current Kbuild requires Makefile to be present at those directories, (due to arch/x86/Kbuild), which requires building some object files. So the empty source files are there to produce empty object files to satisfy this. Change-Id: I14056347ea14cff227d9e8960192e8673c0019b8 Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This commit is contained in:
parent
921ee03094
commit
77d167d004
7 changed files with 4 additions and 43 deletions
|
@ -67,6 +67,7 @@
|
|||
|
||||
#include <toolchain.h>
|
||||
#include <sections.h>
|
||||
#include <init.h>
|
||||
|
||||
#include <drivers/ioapic.h> /* public API declarations */
|
||||
#include <drivers/loapic.h> /* public API declarations and registers */
|
||||
|
@ -350,3 +351,6 @@ static void _IoApicRedUpdateLo(unsigned int irq,
|
|||
ioApicRedSetLo(irq, (ioApicRedGetLo(irq) & ~mask) | (value & mask));
|
||||
}
|
||||
|
||||
DECLARE_DEVICE_INIT_CONFIG(ioapic_0, "", _ioapic_init, NULL);
|
||||
SYS_DEFINE_DEVICE(ioapic_0, NULL, PRIMARY,
|
||||
CONFIG_KERNEL_INIT_PRIORITY_DEFAULT);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue