forked from torvalds/linux
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
36 changed files
with
769 additions
and
410 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
# CONFIG_CC_OPTIMIZE_FOR_PERFORMANCE is not set | ||
CONFIG_CC_OPTIMIZE_FOR_SIZE=y | ||
# CONFIG_KERNEL_GZIP is not set | ||
# CONFIG_KERNEL_BZIP2 is not set | ||
# CONFIG_KERNEL_LZMA is not set | ||
CONFIG_KERNEL_XZ=y | ||
# CONFIG_KERNEL_LZO is not set | ||
# CONFIG_KERNEL_LZ4 is not set | ||
# CONFIG_SLAB is not set | ||
# CONFIG_SLUB is not set | ||
CONFIG_SLOB=y | ||
|
||
CONFIG_PRINTK=y | ||
CONFIG_BINFMT_SCRIPT=y | ||
CONFIG_BUG=y | ||
CONFIG_DEBUG_INFO_DWARF_TOOLCHAIN_DEFAULT=y | ||
CONFIG_DEBUG_INFO=y | ||
CONFIG_DEBUG_KERNEL=y | ||
CONFIG_DEBUG_MEMORY_INIT=y | ||
CONFIG_DEBUG_MISC=y | ||
CONFIG_DEBUG_NOMMU_REGIONS=y | ||
CONFIG_DEBUG_VM=y | ||
CONFIG_EARLY_PRINTK=y | ||
CONFIG_EMBEDDED=y | ||
CONFIG_EXPERT=y | ||
# CONFIG_KALLSYMS is not set | ||
# CONFIG_MMU is not set | ||
CONFIG_UACCESS_MEMCPY=y | ||
CONFIG_PRINTK_TIME=y | ||
CONFIG_EXT4_FS=y | ||
CONFIG_NET=y | ||
|
||
|
||
CONFIG_EMBEDDED=y |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,7 @@ | ||
extra-y := vmlinux.lds | ||
|
||
obj-y += \ | ||
cpuinfo.o \ | ||
early_printk.o \ | ||
irq.o \ | ||
process.o \ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
#include <linux/seq_file.h> | ||
|
||
static void percpu_print(void *arg) | ||
{ | ||
struct seq_file *m = arg; | ||
seq_printf(m, "processor : %d\n", smp_processor_id()); | ||
seq_printf(m, "\n"); | ||
} | ||
|
||
static int c_show(struct seq_file *m, void *v) | ||
{ | ||
int cpu; | ||
|
||
for_each_online_cpu(cpu) | ||
smp_call_function_single(cpu, percpu_print, m, true); | ||
|
||
return 0; | ||
} | ||
|
||
static void *c_start(struct seq_file *m, loff_t *pos) | ||
{ | ||
return *pos < 1 ? (void *)1 : NULL; | ||
} | ||
|
||
static void *c_next(struct seq_file *m, void *v, loff_t *pos) | ||
{ | ||
++*pos; | ||
return NULL; | ||
} | ||
|
||
static void c_stop(struct seq_file *m, void *v) {} | ||
|
||
const struct seq_operations cpuinfo_op = { | ||
.start = c_start, | ||
.next = c_next, | ||
.stop = c_stop, | ||
.show = c_show, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,15 @@ | ||
#include <linux/printk.h> | ||
#include <linux/irqchip.h> | ||
#include <linux/seq_file.h> | ||
|
||
void init_IRQ(void) | ||
{ | ||
__builtin_trap(); | ||
pr_info("init irq\n"); | ||
irqchip_init(); | ||
} | ||
|
||
int show_interrupts(struct seq_file *p, int prec) | ||
{ | ||
seq_printf(p, "nothing to see here\n"); | ||
return 0; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.