Fix bitcode support for kernel
This commit is contained in:
parent
5f8eb6fb0c
commit
5f5dcc545f
|
@ -24,9 +24,9 @@ SECTIONS
|
||||||
. += _kern_offset;
|
. += _kern_offset;
|
||||||
|
|
||||||
. = ALIGN(4096); usermapped_start = .;
|
. = ALIGN(4096); usermapped_start = .;
|
||||||
.usermapped_glo : AT(ADDR(.usermapped_glo) - _kern_offset) { usermapped_glo*.o(*) }
|
.usermapped_glo : AT(ADDR(.usermapped_glo) - _kern_offset) { *(.usermapped_glo) }
|
||||||
. = ALIGN(4096); usermapped_nonglo_start = .;
|
. = ALIGN(4096); usermapped_nonglo_start = .;
|
||||||
.usermapped : AT(ADDR(.usermapped) - _kern_offset) { usermapped_*.o(*) }
|
.usermapped : AT(ADDR(.usermapped) - _kern_offset) { *(.usermapped) }
|
||||||
. = ALIGN(4096); usermapped_end = .;
|
. = ALIGN(4096); usermapped_end = .;
|
||||||
.text : AT(ADDR(.text) - _kern_offset) { *(.text*) }
|
.text : AT(ADDR(.text) - _kern_offset) { *(.text*) }
|
||||||
_etext = .;
|
_etext = .;
|
||||||
|
@ -47,5 +47,4 @@ SECTIONS
|
||||||
{
|
{
|
||||||
*(.ARM.exidx*)
|
*(.ARM.exidx*)
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,9 +22,9 @@ SECTIONS
|
||||||
. += _kern_offset;
|
. += _kern_offset;
|
||||||
|
|
||||||
. = ALIGN(4096); usermapped_start = .;
|
. = ALIGN(4096); usermapped_start = .;
|
||||||
.usermapped_glo : AT(ADDR(.usermapped_glo) - _kern_offset) { usermapped_glo*.o(*) }
|
.usermapped_glo : AT(ADDR(.usermapped_glo) - _kern_offset) { *(.usermapped_glo) }
|
||||||
. = ALIGN(4096); usermapped_nonglo_start = .;
|
. = ALIGN(4096); usermapped_nonglo_start = .;
|
||||||
.usermapped : AT(ADDR(.usermapped) - _kern_offset) { usermapped_*.o(*) }
|
.usermapped : AT(ADDR(.usermapped) - _kern_offset) { *(.usermapped) }
|
||||||
. = ALIGN(4096); usermapped_end = .;
|
. = ALIGN(4096); usermapped_end = .;
|
||||||
.text : AT(ADDR(.text) - _kern_offset) { *(.text*) }
|
.text : AT(ADDR(.text) - _kern_offset) { *(.text*) }
|
||||||
.data ALIGN(4096) : AT(ADDR(.data) - _kern_offset) { *(.data .rodata* ) }
|
.data ALIGN(4096) : AT(ADDR(.data) - _kern_offset) { *(.data .rodata* ) }
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
#include "kernel/kernel.h"
|
#include "kernel/kernel.h"
|
||||||
#include "arch_proto.h"
|
#include "arch_proto.h"
|
||||||
|
|
||||||
struct minix_ipcvecs minix_ipcvecs_softint = {
|
struct minix_ipcvecs minix_ipcvecs_softint __section(".usermapped") = {
|
||||||
.send = usermapped_send_softint,
|
.send = usermapped_send_softint,
|
||||||
.receive = usermapped_receive_softint,
|
.receive = usermapped_receive_softint,
|
||||||
.sendrec = usermapped_sendrec_softint,
|
.sendrec = usermapped_sendrec_softint,
|
||||||
|
@ -11,7 +11,7 @@ struct minix_ipcvecs minix_ipcvecs_softint = {
|
||||||
.senda = usermapped_senda_softint
|
.senda = usermapped_senda_softint
|
||||||
};
|
};
|
||||||
|
|
||||||
struct minix_ipcvecs minix_ipcvecs_sysenter = {
|
struct minix_ipcvecs minix_ipcvecs_sysenter __section(".usermapped") = {
|
||||||
.send = usermapped_send_sysenter,
|
.send = usermapped_send_sysenter,
|
||||||
.receive = usermapped_receive_sysenter,
|
.receive = usermapped_receive_sysenter,
|
||||||
.sendrec = usermapped_sendrec_sysenter,
|
.sendrec = usermapped_sendrec_sysenter,
|
||||||
|
@ -21,7 +21,7 @@ struct minix_ipcvecs minix_ipcvecs_sysenter = {
|
||||||
.senda = usermapped_senda_sysenter
|
.senda = usermapped_senda_sysenter
|
||||||
};
|
};
|
||||||
|
|
||||||
struct minix_ipcvecs minix_ipcvecs_syscall = {
|
struct minix_ipcvecs minix_ipcvecs_syscall __section(".usermapped") = {
|
||||||
.send = usermapped_send_syscall,
|
.send = usermapped_send_syscall,
|
||||||
.receive = usermapped_receive_syscall,
|
.receive = usermapped_receive_syscall,
|
||||||
.sendrec = usermapped_sendrec_syscall,
|
.sendrec = usermapped_sendrec_syscall,
|
||||||
|
|
|
@ -1,6 +1,14 @@
|
||||||
#include <minix/ipcconst.h>
|
#include <minix/ipcconst.h>
|
||||||
#include <machine/asm.h>
|
#include <machine/asm.h>
|
||||||
|
|
||||||
|
/* Redefine _ENTRY to put the following function in the section
|
||||||
|
* ".usermapped_glo". */
|
||||||
|
#undef _ENTRY
|
||||||
|
#define _ENTRY(x) \
|
||||||
|
_ALIGN_TEXT; .globl x; .type x,@function; x:
|
||||||
|
|
||||||
|
.section .usermapped_glo, "wax", @progbits
|
||||||
|
|
||||||
/**========================================================================* */
|
/**========================================================================* */
|
||||||
/* IPC assembly routines * */
|
/* IPC assembly routines * */
|
||||||
/**========================================================================* */
|
/**========================================================================* */
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
#include "kernel/kernel.h"
|
#include "kernel/kernel.h"
|
||||||
|
|
||||||
/* This is the user-visible struct that has pointers to other bits of data. */
|
/* This is the user-visible struct that has pointers to other bits of data. */
|
||||||
struct minix_kerninfo minix_kerninfo;
|
struct minix_kerninfo minix_kerninfo __section(".usermapped");
|
||||||
|
|
||||||
/* Kernel information structures. */
|
/* Kernel information structures. */
|
||||||
struct kinfo kinfo; /* kernel information for users */
|
struct kinfo kinfo __section(".usermapped"); /* kernel information for users */
|
||||||
struct machine machine; /* machine information for users */
|
struct machine machine __section(".usermapped"); /* machine information for users */
|
||||||
struct kmessages kmessages; /* diagnostic messages in kernel */
|
struct kmessages kmessages __section(".usermapped"); /* diagnostic messages in kernel */
|
||||||
struct loadinfo loadinfo; /* status of load average */
|
struct loadinfo loadinfo __section(".usermapped"); /* status of load average */
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue