diff options
author | Ian Lepore <ian@FreeBSD.org> | 2014-05-17 00:53:12 +0000 |
---|---|---|
committer | Ian Lepore <ian@FreeBSD.org> | 2014-05-17 00:53:12 +0000 |
commit | 1ead3d43cdd6a38d17e9f1558c850221c171b77c (patch) | |
tree | a678b33cef5a4d49b1c5fdb050ea93cf7bea3287 | |
parent | 946b7ce0ee8a47ba50b0db43fd6a78d8db6e6dfd (diff) |
Notes
91 files changed, 567 insertions, 448 deletions
diff --git a/sys/arm/allwinner/common.c b/sys/arm/allwinner/a10_common.c index 2aaa4511f412..2aaa4511f412 100644 --- a/sys/arm/allwinner/common.c +++ b/sys/arm/allwinner/a10_common.c diff --git a/sys/arm/allwinner/a20/files.a20 b/sys/arm/allwinner/a20/files.a20 index 9346347456e9..fc66cee76318 100644 --- a/sys/arm/allwinner/a20/files.a20 +++ b/sys/arm/allwinner/a20/files.a20 @@ -19,5 +19,5 @@ arm/allwinner/if_emac.c optional emac arm/allwinner/a10_wdog.c standard arm/allwinner/timer.c standard arm/allwinner/bus_space.c standard -arm/allwinner/common.c standard +arm/allwinner/a10_common.c standard arm/allwinner/a10_machdep.c standard diff --git a/sys/arm/allwinner/files.a10 b/sys/arm/allwinner/files.a10 index eeffd620d858..22bc94e84099 100644 --- a/sys/arm/allwinner/files.a10 +++ b/sys/arm/allwinner/files.a10 @@ -9,16 +9,16 @@ arm/arm/cpufunc_asm_arm11.S standard arm/arm/cpufunc_asm_armv7.S standard arm/arm/irq_dispatch.S standard -arm/allwinner/a20/a20_cpu_cfg.c standard arm/allwinner/a10_clk.c standard -arm/allwinner/a10_sramc.c standard +arm/allwinner/a10_common.c standard arm/allwinner/a10_gpio.c optional gpio arm/allwinner/a10_ehci.c optional ehci -arm/allwinner/if_emac.c optional emac +arm/allwinner/a10_machdep.c standard +arm/allwinner/a10_sramc.c standard arm/allwinner/a10_wdog.c standard -arm/allwinner/timer.c standard +arm/allwinner/a20/a20_cpu_cfg.c standard arm/allwinner/aintc.c standard +arm/allwinner/if_emac.c optional emac +arm/allwinner/timer.c standard arm/allwinner/bus_space.c standard -arm/allwinner/common.c standard #arm/allwinner/console.c standard -arm/allwinner/a10_machdep.c standard diff --git a/sys/arm/arm/exception.S b/sys/arm/arm/exception.S index 3d110e325f62..d7ef5f2b2dc1 100644 --- a/sys/arm/arm/exception.S +++ b/sys/arm/arm/exception.S @@ -218,46 +218,25 @@ END(exception_exit) * look like direct entry from the vector. */ ASENTRY_NP(undefined_entry) - stmfd sp!, {r0, r1} - ldr r0, Lundefined_handler_indirection - ldr r1, [sp], #0x0004 - str r1, [r0, #0x0000] - ldr r1, [sp], #0x0004 - str r1, [r0, #0x0004] - ldmia r0, {r0, r1, pc} - -Lundefined_handler_indirection: - .word Lundefined_handler_indirection_data + sub lr, lr, #0x00000004 /* Adjust the lr */ + PUSHFRAMEINSVC /* Push trap frame and switch */ + /* to SVC32 mode */ + ldr r1, Lundefined_handler_address + adr lr, exception_exit + mov r0, sp /* pass the stack pointer as r0 */ + ldr pc, [r1] END(undefined_entry) -/* - * assembly bounce code for calling the kernel - * undefined instruction handler. This uses - * a standard trap frame and is called in SVC mode. - */ - -ENTRY_NP(undefinedinstruction_bounce) - PUSHFRAMEINSVC +ASENTRY_NP(undefinedinstruction_bounce) + b undefinedinstruction +END(undefinedinstruction_bounce) - mov r0, sp - adr lr, exception_exit - b _C_LABEL(undefinedinstruction) +Lundefined_handler_address: + .word _C_LABEL(undefined_handler_address) .data - .align 0 - -/* - * Indirection data - * 2 words use for preserving r0 and r1 - * 3rd word contains the undefined handler address. - */ - -Lundefined_handler_indirection_data: - .word 0 - .word 0 - .global _C_LABEL(undefined_handler_address) _C_LABEL(undefined_handler_address): - .word _C_LABEL(undefinedinstruction_bounce) -END(undefinedinstruction_bounce) + .word undefinedinstruction_bounce + diff --git a/sys/arm/arm/genassym.c b/sys/arm/arm/genassym.c index e38733ba0cbc..ab0be4ca138d 100644 --- a/sys/arm/arm/genassym.c +++ b/sys/arm/arm/genassym.c @@ -60,7 +60,6 @@ ASSYM(PCB_NOALIGNFLT, PCB_NOALIGNFLT); ASSYM(PCB_ONFAULT, offsetof(struct pcb, pcb_onfault)); ASSYM(PCB_DACR, offsetof(struct pcb, pcb_dacr)); ASSYM(PCB_FLAGS, offsetof(struct pcb, pcb_flags)); -ASSYM(PCB_UND_SP, offsetof(struct pcb, un_32.pcb32_und_sp)); ASSYM(PCB_PAGEDIR, offsetof(struct pcb, pcb_pagedir)); ASSYM(PCB_L1VEC, offsetof(struct pcb, pcb_l1vec)); ASSYM(PCB_PL1VEC, offsetof(struct pcb, pcb_pl1vec)); @@ -119,9 +118,7 @@ ASSYM(ARM_RAS_END, ARM_RAS_END); #ifdef VFP ASSYM(PCB_VFPSTATE, offsetof(struct pcb, pcb_vfpstate)); -ASSYM(PCB_VFPCPU, offsetof(struct pcb, pcb_vfpcpu)); -ASSYM(PC_VFPCTHREAD, offsetof(struct pcpu, pc_vfpcthread)); ASSYM(PC_CPU, offsetof(struct pcpu, pc_cpu)); ASSYM(PC_CURPMAP, offsetof(struct pcpu, pc_curpmap)); diff --git a/sys/arm/arm/machdep.c b/sys/arm/arm/machdep.c index 35f14326e352..9fb2ffc56854 100644 --- a/sys/arm/arm/machdep.c +++ b/sys/arm/arm/machdep.c @@ -379,8 +379,6 @@ cpu_startup(void *dummy) bufinit(); vm_pager_bufferinit(); - pcb->un_32.pcb32_und_sp = (u_int)thread0.td_kstack + - USPACE_UNDEF_STACK_TOP; pcb->un_32.pcb32_sp = (u_int)thread0.td_kstack + USPACE_SVC_STACK_TOP; vector_page_setprot(VM_PROT_READ); @@ -995,6 +993,7 @@ init_proc0(vm_offset_t kstack) thread0.td_pcb = (struct pcb *) (thread0.td_kstack + KSTACK_PAGES * PAGE_SIZE) - 1; thread0.td_pcb->pcb_flags = 0; + thread0.td_pcb->pcb_vfpcpu = -1; thread0.td_frame = &proc0_tf; pcpup->pc_curpcb = thread0.td_pcb; } diff --git a/sys/arm/arm/swtch.S b/sys/arm/arm/swtch.S index 133b0d949eff..d7048239cfb0 100644 --- a/sys/arm/arm/swtch.S +++ b/sys/arm/arm/swtch.S @@ -84,6 +84,8 @@ #include <machine/asm.h> #include <machine/asmacros.h> #include <machine/armreg.h> +#include <machine/vfp.h> + __FBSDID("$FreeBSD$"); #define DOMAIN_CLIENT 0x01 @@ -102,6 +104,10 @@ __FBSDID("$FreeBSD$"); ldr tmp, .Lcurpcpu #endif +#ifdef VFP + .fpu vfp /* allow VFP instructions */ +#endif + .Lcurpcpu: .word _C_LABEL(__pcpu) .word PCPU_SIZE @@ -118,20 +124,11 @@ ENTRY(cpu_throw) * r5 = newtd */ - GET_PCPU(r7, r9) - -#ifdef VFP - /* - * vfp_discard will clear pcpu->pc_vfpcthread, and modify - * and modify the control as needed. - */ - ldr r4, [r7, #(PC_VFPCTHREAD)] /* this thread using vfp? */ - cmp r0, r4 - bne 3f - bl _C_LABEL(vfp_discard) /* yes, shut down vfp */ -3: -#endif /* VFP */ +#ifdef VFP /* This thread is dying, disable */ + bl _C_LABEL(vfp_discard) /* VFP without preserving state. */ +#endif + GET_PCPU(r7, r9) ldr r7, [r5, #(TD_PCB)] /* r7 = new thread's PCB */ /* Switch to lwp0 context */ @@ -303,46 +300,19 @@ ENTRY(cpu_switch) /* Get the user structure for the new process in r9 */ ldr r9, [r1, #(TD_PCB)] - mrs r3, cpsr - /* - * We can do that, since - * PSR_SVC32_MODE|PSR_UND32_MODE == MSR_UND32_MODE - */ - orr r8, r3, #(PSR_UND32_MODE) - msr cpsr_c, r8 - - str sp, [r2, #(PCB_UND_SP)] - - msr cpsr_c, r3 /* Restore the old mode */ /* rem: r2 = old PCB */ /* rem: r9 = new PCB */ /* rem: interrupts are enabled */ #ifdef VFP - /* - * vfp_store will clear pcpu->pc_vfpcthread, save - * registers and state, and modify the control as needed. - * a future exception will bounce the backup settings in the fp unit. - * XXX vfp_store can't change r4 - */ - GET_PCPU(r7, r8) - ldr r8, [r7, #(PC_VFPCTHREAD)] - cmp r4, r8 /* old thread used vfp? */ - bne 1f /* no, don't save */ - cmp r1, r4 /* same thread ? */ - beq 1f /* yes, skip vfp store */ -#ifdef SMP - ldr r8, [r7, #(PC_CPU)] /* last used on this cpu? */ - ldr r3, [r2, #(PCB_VFPCPU)] - cmp r8, r3 /* last cpu to use these registers? */ - bne 1f /* no. these values are stale */ + fmrx r0, fpexc /* If the VFP is enabled */ + tst r0, #(VFPEXC_EN) /* the current thread has */ + movne r1, #1 /* used it, so go save */ + addne r0, r2, #(PCB_VFPSTATE) /* the state into the PCB */ + blne _C_LABEL(vfp_store) /* and disable the VFP. */ #endif - add r0, r2, #(PCB_VFPSTATE) - bl _C_LABEL(vfp_store) -1: -#endif /* VFP */ - /* r1 now free! */ + /* r0-r3 now free! */ /* Third phase : restore saved context */ @@ -438,10 +408,6 @@ ENTRY(cpu_switch) movne r0, #0 /* We *know* vector_page's VA is 0x0 */ movne lr, pc ldrne pc, [r10, #CF_TLB_FLUSHID_SE] - /* - * We can do that, since - * PSR_SVC32_MODE|PSR_UND32_MODE == MSR_UND32_MODE - */ .Lcs_context_switched: @@ -460,17 +426,6 @@ ENTRY(cpu_switch) /* rem: r9 = new PCB */ - mrs r3, cpsr - /* - * We can do that, since - * PSR_SVC32_MODE|PSR_UND32_MODE == MSR_UND32_MODE - */ - orr r2, r3, #(PSR_UND32_MODE) - msr cpsr_c, r2 - - ldr sp, [r9, #(PCB_UND_SP)] - - msr cpsr_c, r3 /* Restore the old mode */ /* Restore all the save registers */ #ifndef _ARM_ARCH_5E add r7, r9, #PCB_R8 @@ -520,26 +475,12 @@ ENTRY(savectx) add r2, r0, #(PCB_R8) stmia r2, {r8-r13} #ifdef VFP - /* - * vfp_store will clear pcpu->pc_vfpcthread, save - * registers and state, and modify the control as needed. - * a future exception will bounce the backup settings in the fp unit. - */ - GET_PCPU(r7, r4) - ldr r4, [r7, #(PC_VFPCTHREAD)] /* vfp thread */ - ldr r2, [r7, #(PC_CURTHREAD)] /* current thread */ - cmp r4, r2 - bne 1f -#ifdef SMP - ldr r2, [r7, #(PC_CPU)] /* last used on this cpu? */ - ldr r3, [r0, #(PCB_VFPCPU)] - cmp r2, r3 - bne 1f /* no. these values are stale */ + fmrx r2, fpexc /* If the VFP is enabled */ + tst r2, #(VFPEXC_EN) /* the current thread has */ + movne r1, #1 /* used it, so go save */ + addne r0, r0, #(PCB_VFPSTATE) /* the state into the PCB */ + blne _C_LABEL(vfp_store) /* and disable the VFP. */ #endif - add r0, r0, #(PCB_VFPSTATE) - bl _C_LABEL(vfp_store) -1: -#endif /* VFP */ add sp, sp, #4; ldmfd sp!, {r4-r7, pc} END(savectx) diff --git a/sys/arm/arm/undefined.c b/sys/arm/arm/undefined.c index 7829ecea5f67..5b7b91780871 100644 --- a/sys/arm/arm/undefined.c +++ b/sys/arm/arm/undefined.c @@ -183,7 +183,6 @@ undefinedinstruction(struct trapframe *frame) if (!(frame->tf_spsr & I32_bit)) enable_interrupts(I32_bit|F32_bit); - frame->tf_pc -= INSN_SIZE; PCPU_INC(cnt.v_trap); fault_pc = frame->tf_pc; diff --git a/sys/arm/arm/vfp.c b/sys/arm/arm/vfp.c index 8ee38bba8ed3..240ede32bb31 100644 --- a/sys/arm/arm/vfp.c +++ b/sys/arm/arm/vfp.c @@ -1,4 +1,5 @@ -/* +/*- + * Copyright (c) 2014 Ian Lepore <ian@freebsd.org> * Copyright (c) 2012 Mark Tinguely * * All rights reserved. @@ -34,6 +35,7 @@ __FBSDID("$FreeBSD$"); #include <sys/proc.h> #include <sys/kernel.h> +#include <machine/armreg.h> #include <machine/frame.h> #include <machine/fp.h> #include <machine/pcb.h> @@ -41,12 +43,8 @@ __FBSDID("$FreeBSD$"); #include <machine/vfp.h> /* function prototypes */ -unsigned int get_coprocessorACR(void); static int vfp_bounce(u_int, u_int, struct trapframe *, int); static void vfp_restore(struct vfp_state *); -void vfp_discard(void); -void vfp_store(struct vfp_state *); -void set_coprocessorACR(u_int); extern int vfp_exists; static struct undefined_handler vfp10_uh, vfp11_uh; @@ -64,7 +62,20 @@ static int is_d32; val; \ }) -u_int +/* + * Work around an issue with GCC where the asm it generates is not unified + * syntax and fails to assemble because it expects the ldcleq instruction in the + * form ldc<c>l, not in the UAL form ldcl<c>, and similar for stcleq. + */ +#ifdef __clang__ +#define LDCLNE "ldclne " +#define STCLNE "stclne " +#else +#define LDCLNE "ldcnel " +#define STCLNE "stcnel " +#endif + +static u_int get_coprocessorACR(void) { u_int val; @@ -72,7 +83,7 @@ get_coprocessorACR(void) return val; } -void +static void set_coprocessorACR(u_int val) { __asm __volatile("mcr p15, 0, %0, c1, c0, 2\n\t" @@ -136,147 +147,105 @@ SYSINIT(vfp, SI_SUB_CPU, SI_ORDER_ANY, vfp_init, NULL); static int vfp_bounce(u_int addr, u_int insn, struct trapframe *frame, int code) { - u_int fpexc; + u_int cpu, fpexc; struct pcb *curpcb; - struct thread *vfptd; - int i; - if (!vfp_exists) - return 1; /* vfp does not exist */ - i = disable_interrupts(I32_bit|F32_bit); - fpexc = fmrx(VFPEXC); /* read the vfp exception reg */ + if ((code & FAULT_USER) == 0) + panic("undefined floating point instruction in supervisor mode"); + + critical_enter(); + + /* + * If the VFP is already on and we got an undefined instruction, then + * something tried to executate a truly invalid instruction that maps to + * the VFP. + */ + fpexc = fmrx(VFPEXC); if (fpexc & VFPEXC_EN) { - vfptd = PCPU_GET(vfpcthread); - /* did the kernel call the vfp or exception that expect us - * to emulate the command. Newer hardware does not require - * emulation, so we don't emulate yet. - */ -#ifdef SMP - /* don't save if newer registers are on another processor */ - if (vfptd /* && (vfptd == curthread) */ && - (vfptd->td_pcb->pcb_vfpcpu == PCPU_GET(cpu))) -#else - /* someone did not save their registers, */ - if (vfptd /* && (vfptd == curthread) */) -#endif - vfp_store(&vfptd->td_pcb->pcb_vfpstate); - - fpexc &= ~VFPEXC_EN; - fmxr(VFPEXC, fpexc); /* turn vfp hardware off */ - if (vfptd == curthread) { - /* kill the process - we do not handle emulation */ - restore_interrupts(i); - killproc(curthread->td_proc, "vfp emulation"); - return 1; - } - /* should not happen. someone did not save their context */ - printf("vfp_bounce: vfpcthread: %p curthread: %p\n", - vfptd, curthread); + /* kill the process - we do not handle emulation */ + critical_exit(); + killproc(curthread->td_proc, "vfp emulation"); + return 1; } - fpexc |= VFPEXC_EN; - fmxr(VFPEXC, fpexc); /* enable the vfp and repeat command */ - curpcb = curthread->td_pcb; - /* If we were the last process to use the VFP, the process did not - * use a VFP on another processor, then the registers in the VFP - * will still be ours and are current. Eventually, we will make the - * restore smarter. + + /* + * If the last time this thread used the VFP it was on this core, and + * the last thread to use the VFP on this core was this thread, then the + * VFP state is valid, otherwise restore this thread's state to the VFP. */ - vfp_restore(&curpcb->pcb_vfpstate); -#ifdef SMP - curpcb->pcb_vfpcpu = PCPU_GET(cpu); -#endif - PCPU_SET(vfpcthread, curthread); - restore_interrupts(i); - return 0; + fmxr(VFPEXC, fpexc | VFPEXC_EN); + curpcb = curthread->td_pcb; + cpu = PCPU_GET(cpu); + if (curpcb->pcb_vfpcpu != cpu || curthread != PCPU_GET(fpcurthread)) { + vfp_restore(&curpcb->pcb_vfpstate); + curpcb->pcb_vfpcpu = cpu; + PCPU_SET(fpcurthread, curthread); + } + + critical_exit(); + return (0); } -/* vfs_store is called from from a VFP command to restore the registers and - * turn on the VFP hardware. - * Eventually we will use the information that this process was the last - * to use the VFP hardware and bypass the restore, just turn on the hardware. +/* + * Restore the given state to the VFP hardware. */ static void vfp_restore(struct vfp_state *vfpsave) { u_int vfpscr = 0; - /* - * Work around an issue with GCC where the asm it generates is - * not unified syntax and fails to assemble because it expects - * the ldcleq instruction in the form ldc<c>l, not in the UAL - * form ldcl<c>, and similar for stcleq. - */ -#ifdef __clang__ -#define ldclne "ldclne" -#define stclne "stclne" -#else -#define ldclne "ldcnel" -#define stclne "stcnel" -#endif - if (vfpsave) { - __asm __volatile("ldc p10, c0, [%1], #128\n" /* d0-d15 */ + __asm __volatile("ldc p10, c0, [%1], #128\n" /* d0-d15 */ "cmp %2, #0\n" /* -D16 or -D32? */ - ldclne" p11, c0, [%1], #128\n" /* d16-d31 */ + LDCLNE "p11, c0, [%1], #128\n" /* d16-d31 */ "addeq %1, %1, #128\n" /* skip missing regs */ "ldr %0, [%1]\n" /* set old vfpscr */ "mcr p10, 7, %0, cr1, c0, 0\n" : "=&r" (vfpscr) : "r" (vfpsave), "r" (is_d32) : "cc"); - } } -/* vfs_store is called from switch to save the vfp hardware registers - * into the pcb before switching to another process. - * we already know that the new process is different from this old - * process and that this process last used the VFP registers. - * Below we check to see if the VFP has been enabled since the last - * register save. - * This routine will exit with the VFP turned off. The next VFP user - * will trap to restore its registers and turn on the VFP hardware. +/* + * If the VFP is on, save its current state and turn it off if requested to do + * so. If the VFP is not on, does not change the values at *vfpsave. Caller is + * responsible for preventing a context switch while this is running. */ void -vfp_store(struct vfp_state *vfpsave) +vfp_store(struct vfp_state *vfpsave, boolean_t disable_vfp) { - u_int tmp, vfpscr = 0; + u_int tmp, vfpscr; tmp = fmrx(VFPEXC); /* Is the vfp enabled? */ - if (vfpsave && (tmp & VFPEXC_EN)) { - __asm __volatile("stc p11, c0, [%1], #128\n" /* d0-d15 */ + if (tmp & VFPEXC_EN) { + __asm __volatile( + "stc p11, c0, [%1], #128\n" /* d0-d15 */ "cmp %2, #0\n" /* -D16 or -D32? */ - stclne" p11, c0, [%1], #128\n" /* d16-d31 */ + STCLNE "p11, c0, [%1], #128\n" /* d16-d31 */ "addeq %1, %1, #128\n" /* skip missing regs */ "mrc p10, 7, %0, cr1, c0, 0\n" /* fmxr(VFPSCR) */ "str %0, [%1]\n" /* save vfpscr */ : "=&r" (vfpscr) : "r" (vfpsave), "r" (is_d32) : "cc"); + if (disable_vfp) + fmxr(VFPEXC , tmp & ~VFPEXC_EN); } -#undef ldcleq -#undef stcleq - -#ifndef SMP - /* eventually we will use this information for UP also */ - PCPU_SET(vfpcthread, 0); -#endif - tmp &= ~VFPEXC_EN; /* disable the vfp hardware */ - fmxr(VFPEXC , tmp); } -/* discard the registers at cpu_thread_free() when fpcurthread == td. - * Turn off the VFP hardware. +/* + * The current thread is dying. If the state currently in the hardware belongs + * to the current thread, set fpcurthread to NULL to indicate that the VFP + * hardware state does not belong to any thread. If the VFP is on, turn it off. + * Called only from cpu_throw(), so we don't have to worry about a context + * switch here. */ void -vfp_discard() +vfp_discard(struct thread *td) { - u_int tmp = 0; + u_int tmp; + + if (PCPU_GET(fpcurthread) == td) + PCPU_SET(fpcurthread, NULL); - /* - * No need to protect the access to vfpcthread by disabling - * interrupts, since it's called from cpu_throw(), who is called - * with interrupts disabled. - */ - - PCPU_SET(vfpcthread, 0); /* permanent forget about reg */ tmp = fmrx(VFPEXC); - tmp &= ~VFPEXC_EN; /* turn off VFP hardware */ - fmxr(VFPEXC, tmp); + if (tmp & VFPEXC_EN) + fmxr(VFPEXC, tmp & ~VFPEXC_EN); } #endif diff --git a/sys/arm/arm/vm_machdep.c b/sys/arm/arm/vm_machdep.c index c51ae56f5585..1e225dba4816 100644 --- a/sys/arm/arm/vm_machdep.c +++ b/sys/arm/arm/vm_machdep.c @@ -144,9 +144,9 @@ cpu_fork(register struct thread *td1, register struct proc *p2, bcopy(td1->td_pcb, pcb2, sizeof(*pcb2)); mdp2 = &p2->p_md; bcopy(&td1->td_proc->p_md, mdp2, sizeof(*mdp2)); - pcb2->un_32.pcb32_und_sp = td2->td_kstack + USPACE_UNDEF_STACK_TOP; pcb2->un_32.pcb32_sp = td2->td_kstack + USPACE_SVC_STACK_TOP - sizeof(*pcb2); + pcb2->pcb_vfpcpu = -1; pmap_activate(td2); td2->td_frame = tf = (struct trapframe *)STACKALIGN( pcb2->un_32.pcb32_sp - sizeof(struct trapframe)); @@ -366,7 +366,6 @@ cpu_set_upcall(struct thread *td, struct thread *td0) tf->tf_spsr &= ~PSR_C_bit; tf->tf_r0 = 0; td->td_pcb->un_32.pcb32_sp = (u_int)sf; - td->td_pcb->un_32.pcb32_und_sp = td->td_kstack + USPACE_UNDEF_STACK_TOP; KASSERT((td->td_pcb->un_32.pcb32_sp & 7) == 0, ("cpu_set_upcall: Incorrect stack alignment")); diff --git a/sys/arm/at91/at91.c b/sys/arm/at91/at91.c index dce1f9341f54..5caa326713b9 100644 --- a/sys/arm/at91/at91.c +++ b/sys/arm/at91/at91.c @@ -24,6 +24,8 @@ * SUCH DAMAGE. */ +#include "opt_platform.h" + #include <sys/cdefs.h> __FBSDID("$FreeBSD$"); @@ -49,12 +51,6 @@ __FBSDID("$FreeBSD$"); #include <arm/at91/at91_pmcvar.h> #include <arm/at91/at91_aicreg.h> -static struct at91_softc *at91_softc; - -static void at91_eoi(void *); - -extern const struct arm_devmap_entry at91_devmap[]; - uint32_t at91_master_clock; static int @@ -84,8 +80,12 @@ at91_bs_unmap(void *t, bus_space_handle_t h, bus_size_t size) { vm_offset_t va, endva; + if (t == 0) + return; va = trunc_page((vm_offset_t)t); - endva = va + round_page(size); + if (va >= AT91_BASE && va <= AT91_BASE + 0xff00000) + return; + endva = round_page((vm_offset_t)t + size); /* Free the kernel virtual mapping. */ kva_free(va, endva - va); @@ -229,6 +229,12 @@ struct bus_space at91_bs_tag = { NULL, }; +#ifndef FDT + +static struct at91_softc *at91_softc; + +static void at91_eoi(void *); + static int at91_probe(device_t dev) { @@ -260,7 +266,6 @@ static int at91_attach(device_t dev) { struct at91_softc *sc = device_get_softc(dev); - int i; arm_post_filter = at91_eoi; @@ -290,29 +295,6 @@ at91_attach(device_t dev) 0xfffffffful) != 0) panic("at91_attach: failed to set up memory rman"); - /* - * Setup the interrupt table. - */ - if (soc_info.soc_data == NULL || soc_info.soc_data->soc_irq_prio == NULL) - panic("Interrupt priority table missing\n"); - for (i = 0; i < 32; i++) { - bus_space_write_4(sc->sc_st, sc->sc_aic_sh, IC_SVR + - i * 4, i); - /* Priority. */ - bus_space_write_4(sc->sc_st, sc->sc_aic_sh, IC_SMR + i * 4, - soc_info.soc_data->soc_irq_prio[i]); - if (i < 8) - bus_space_write_4(sc->sc_st, sc->sc_aic_sh, IC_EOICR, - 1); - } - - bus_space_write_4(sc->sc_st, sc->sc_aic_sh, IC_SPU, 32); - /* No debug. */ - bus_space_write_4(sc->sc_st, sc->sc_aic_sh, IC_DCR, 0); - /* Disable and clear all interrupts. */ - bus_space_write_4(sc->sc_st, sc->sc_aic_sh, IC_IDCR, 0xffffffff); - bus_space_write_4(sc->sc_st, sc->sc_aic_sh, IC_ICCR, 0xffffffff); - /* * Add this device's children... */ @@ -472,42 +454,6 @@ at91_print_child(device_t dev, device_t child) return (retval); } -void -arm_mask_irq(uintptr_t nb) -{ - - bus_space_write_4(at91_softc->sc_st, - at91_softc->sc_aic_sh, IC_IDCR, 1 << nb); -} - -int -arm_get_next_irq(int last __unused) -{ - int status; - int irq; - - irq = bus_space_read_4(at91_softc->sc_st, - at91_softc->sc_aic_sh, IC_IVR); - status = bus_space_read_4(at91_softc->sc_st, - at91_softc->sc_aic_sh, IC_ISR); - if (status == 0) { - bus_space_write_4(at91_softc->sc_st, - at91_softc->sc_aic_sh, IC_EOICR, 1); - return (-1); - } - return (irq); -} - -void -arm_unmask_irq(uintptr_t nb) -{ - - bus_space_write_4(at91_softc->sc_st, - at91_softc->sc_aic_sh, IC_IECR, 1 << nb); - bus_space_write_4(at91_softc->sc_st, at91_softc->sc_aic_sh, - IC_EOICR, 0); -} - static void at91_eoi(void *unused) { @@ -584,3 +530,4 @@ static driver_t at91_driver = { static devclass_t at91_devclass; DRIVER_MODULE(atmelarm, nexus, at91_driver, at91_devclass, 0, 0); +#endif diff --git a/sys/arm/at91/at91_aic.c b/sys/arm/at91/at91_aic.c new file mode 100644 index 000000000000..0f1556c6fe57 --- /dev/null +++ b/sys/arm/at91/at91_aic.c @@ -0,0 +1,188 @@ +/*- + * Copyright (c) 2014 Warner Losh. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + */ + +#include "opt_platform.h" + +#include <sys/cdefs.h> +__FBSDID("$FreeBSD$"); + +#include <sys/param.h> +#include <sys/bus.h> +#include <sys/kernel.h> +#include <sys/module.h> +#include <sys/resource.h> +#include <sys/systm.h> +#include <sys/rman.h> + +#include <machine/bus.h> +#include <machine/cpu.h> +#include <machine/cpufunc.h> +#include <machine/frame.h> +#include <machine/intr.h> +#include <machine/resource.h> + +#include <arm/at91/at91var.h> +#include <arm/at91/at91_aicreg.h> + +#ifdef FDT +#include <dev/fdt/fdt_common.h> +#include <dev/ofw/ofw_bus.h> +#include <dev/ofw/ofw_bus_subr.h> +#endif + +static struct aic_softc { + struct resource *mem_res; /* Memory resource */ + void *intrhand; /* Interrupt handle */ + device_t sc_dev; +} *sc; + +static inline uint32_t +RD4(struct aic_softc *sc, bus_size_t off) +{ + + return (bus_read_4(sc->mem_res, off)); +} + +static inline void +WR4(struct aic_softc *sc, bus_size_t off, uint32_t val) +{ + + bus_write_4(sc->mem_res, off, val); +} + +void +arm_mask_irq(uintptr_t nb) +{ + + WR4(sc, IC_IDCR, 1 << nb); +} + +int +arm_get_next_irq(int last __unused) +{ + int status; + int irq; + + irq = RD4(sc, IC_IVR); + status = RD4(sc, IC_ISR); + if (status == 0) { + WR4(sc, IC_EOICR, 1); + return (-1); + } + return (irq); +} + +void +arm_unmask_irq(uintptr_t nb) +{ + + WR4(sc, IC_IECR, 1 << nb); + WR4(sc, IC_EOICR, 0); +} + +static int +at91_aic_probe(device_t dev) +{ +#ifdef FDT + if (!ofw_bus_is_compatible(dev, "atmel,at91rm9200-aic")) + return (ENXIO); +#endif + device_set_desc(dev, "AIC"); + return (0); +} + +static int +at91_aic_attach(device_t dev) +{ + int i, rid, err = 0; + + device_printf(dev, "Attach %d\n", bus_current_pass); + + sc = device_get_softc(dev); + sc->sc_dev = dev; + + rid = 0; + sc->mem_res = bus_alloc_resource_any(dev, SYS_RES_MEMORY, &rid, + RF_ACTIVE); + + if (sc->mem_res == NULL) + panic("couldn't allocate register resources"); + + /* + * Setup the interrupt table. + */ + if (soc_info.soc_data == NULL || soc_info.soc_data->soc_irq_prio == NULL) + panic("Interrupt priority table missing\n"); + for (i = 0; i < 32; i++) { + WR4(sc, IC_SVR + i * 4, i); + /* Priority. */ + WR4(sc, IC_SMR + i * 4, soc_info.soc_data->soc_irq_prio[i]); + if (i < 8) + WR4(sc, IC_EOICR, 1); + } + + WR4(sc, IC_SPU, 32); + /* No debug. */ + WR4(sc, IC_DCR, 0); + /* Disable and clear all interrupts. */ + WR4(sc, IC_IDCR, 0xffffffff); + WR4(sc, IC_ICCR, 0xffffffff); + enable_interrupts(I32_bit | F32_bit); + + return (err); +} + +static void +at91_aic_new_pass(device_t dev) +{ + device_printf(dev, "Pass %d\n", bus_current_pass); +} + +static device_method_t at91_aic_methods[] = { + DEVMETHOD(device_probe, at91_aic_probe), + DEVMETHOD(device_attach, at91_aic_attach), + DEVMETHOD(bus_new_pass, at91_aic_new_pass), + DEVMETHOD_END +}; + +static driver_t at91_aic_driver = { + "at91_aic", + at91_aic_methods, + sizeof(struct aic_softc), +}; + +static devclass_t at91_aic_devclass; + +#ifdef FDT +DRIVER_MODULE(at91_aic, simplebus, at91_aic_driver, at91_aic_devclass, NULL, + NULL); +#else +DRIVER_MODULE(at91_aic, atmelarm, at91_aic_driver, at91_aic_devclass, NULL, + NULL); +#endif +/* not yet +EARLY_DRIVER_MODULE(at91_aic, simplebus, at91_aic_driver, at91_aic_devclass, + NULL, NULL, BUS_PASS_INTERRUPT); +*/ diff --git a/sys/arm/at91/at91rm9200.c b/sys/arm/at91/at91rm9200.c index f2ee45060f4e..2cc0c9cfcb6d 100644 --- a/sys/arm/at91/at91rm9200.c +++ b/sys/arm/at91/at91rm9200.c @@ -105,6 +105,7 @@ static const uint32_t at91_pio_base[] = { static const struct cpu_devs at91_devs[] = { + DEVICE("at91_aic", AIC, 0), DEVICE("at91_pmc", PMC, 0), DEVICE("at91_st", ST, 0), DEVICE("at91_pio", PIOA, 0), diff --git a/sys/arm/at91/at91sam9g20.c b/sys/arm/at91/at91sam9g20.c index d4e6347a8312..3c17e3aadabc 100644 --- a/sys/arm/at91/at91sam9g20.c +++ b/sys/arm/at91/at91sam9g20.c @@ -103,6 +103,7 @@ static const uint32_t at91_pio_base[] = { static const struct cpu_devs at91_devs[] = { + DEVICE("at91_aic", AIC, 0), DEVICE("at91_pmc", PMC, 0), DEVICE("at91_wdt", WDT, 0), DEVICE("at91_rst", RSTC, 0), diff --git a/sys/arm/at91/at91sam9g20reg.h b/sys/arm/at91/at91sam9g20reg.h index 539d71864d8f..59f6099b3ac3 100644 --- a/sys/arm/at91/at91sam9g20reg.h +++ b/sys/arm/at91/at91sam9g20reg.h @@ -221,6 +221,7 @@ #define AT91SAM9G20_IRQ_RSTC AT91SAM9G20_IRQ_SYSTEM #define AT91SAM9G20_IRQ_OHCI AT91SAM9G20_IRQ_UHP #define AT91SAM9G20_IRQ_NAND (-1) +#define AT91SAM9G20_IRQ_AIC (-1) #define AT91SAM9G20_AIC_BASE 0xffff000 #define AT91SAM9G20_AIC_SIZE 0x200 diff --git a/sys/arm/at91/at91sam9x5.c b/sys/arm/at91/at91sam9x5.c index 4e8c3f43c96c..9fe7104740b0 100644 --- a/sys/arm/at91/at91sam9x5.c +++ b/sys/arm/at91/at91sam9x5.c @@ -104,6 +104,7 @@ static const uint32_t at91_pio_base[] = { static const struct cpu_devs at91_devs[] = { + DEVICE("at91_aic", AIC, 0), DEVICE("at91_pmc", PMC, 0), DEVICE("at91_wdt", WDT, 0), DEVICE("at91_rst", RSTC, 0), diff --git a/sys/arm/at91/files.at91 b/sys/arm/at91/files.at91 index 5533594da887..8c366ca5ebea 100644 --- a/sys/arm/at91/files.at91 +++ b/sys/arm/at91/files.at91 @@ -2,6 +2,7 @@ arm/arm/cpufunc_asm_arm9.S standard arm/arm/irq_dispatch.S standard arm/at91/at91_machdep.c standard +arm/at91/at91_aic.c standard arm/at91/at91.c standard arm/at91/at91_cfata.c optional at91_cfata arm/at91/at91_mci.c optional at91_mci diff --git a/sys/arm/broadcom/bcm2835/common.c b/sys/arm/broadcom/bcm2835/bcm2835_common.c index 5c3c2580cbe8..5c3c2580cbe8 100644 --- a/sys/arm/broadcom/bcm2835/common.c +++ b/sys/arm/broadcom/bcm2835/bcm2835_common.c diff --git a/sys/arm/broadcom/bcm2835/bus_space.c b/sys/arm/broadcom/bcm2835/bus_space.c deleted file mode 100644 index 4cce8203abcc..000000000000 --- a/sys/arm/broadcom/bcm2835/bus_space.c +++ /dev/null @@ -1,113 +0,0 @@ -/*- - * Copyright (C) 2012 FreeBSD Foundation - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of MARVELL nor the names of contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -#include <sys/cdefs.h> -__FBSDID("$FreeBSD$"); - -#include <sys/param.h> -#include <sys/systm.h> -#include <sys/bus.h> -#include <sys/kernel.h> -#include <sys/malloc.h> - -#include <machine/bus.h> - -/* Prototypes for all the bus_space structure functions */ -bs_protos(generic); -bs_protos(generic_armv4); - -struct bus_space _base_tag = { - /* cookie */ - .bs_cookie = (void *) 0, - - /* mapping/unmapping */ - .bs_map = generic_bs_map, - .bs_unmap = generic_bs_unmap, - .bs_subregion = generic_bs_subregion, - - /* allocation/deallocation */ - .bs_alloc = generic_bs_alloc, - .bs_free = generic_bs_free, - - /* barrier */ - .bs_barrier = generic_bs_barrier, - - /* read (single) */ - .bs_r_1 = generic_bs_r_1, - .bs_r_2 = generic_armv4_bs_r_2, - .bs_r_4 = generic_bs_r_4, - .bs_r_8 = NULL, - - /* read multiple */ - .bs_rm_1 = generic_bs_rm_1, - .bs_rm_2 = generic_armv4_bs_rm_2, - .bs_rm_4 = generic_bs_rm_4, - .bs_rm_8 = NULL, - - /* read region */ - .bs_rr_1 = generic_bs_rr_1, - .bs_rr_2 = generic_armv4_bs_rr_2, - .bs_rr_4 = generic_bs_rr_4, - .bs_rr_8 = NULL, - - /* write (single) */ - .bs_w_1 = generic_bs_w_1, - .bs_w_2 = generic_armv4_bs_w_2, - .bs_w_4 = generic_bs_w_4, - .bs_w_8 = NULL, - - /* write multiple */ - .bs_wm_1 = generic_bs_wm_1, - .bs_wm_2 = generic_armv4_bs_wm_2, - .bs_wm_4 = generic_bs_wm_4, - .bs_wm_8 = NULL, - - /* write region */ - .bs_wr_1 = generic_bs_wr_1, - .bs_wr_2 = generic_armv4_bs_wr_2, - .bs_wr_4 = generic_bs_wr_4, - .bs_wr_8 = NULL, - - /* set multiple */ - /* XXX not implemented */ - - /* set region */ - .bs_sr_1 = NULL, - .bs_sr_2 = generic_armv4_bs_sr_2, - .bs_sr_4 = generic_bs_sr_4, - .bs_sr_8 = NULL, - - /* copy */ - .bs_c_1 = NULL, - .bs_c_2 = generic_armv4_bs_c_2, - .bs_c_4 = NULL, - .bs_c_8 = NULL, -}; - -bus_space_tag_t fdtbus_bs_tag = &_base_tag; diff --git a/sys/arm/broadcom/bcm2835/files.bcm2835 b/sys/arm/broadcom/bcm2835/files.bcm2835 index e7356ae5ae5f..4563b35909b4 100644 --- a/sys/arm/broadcom/bcm2835/files.bcm2835 +++ b/sys/arm/broadcom/bcm2835/files.bcm2835 @@ -1,6 +1,7 @@ # $FreeBSD$ arm/broadcom/bcm2835/bcm2835_bsc.c optional bcm2835_bsc +arm/broadcom/bcm2835/bcm2835_common.c optional fdt arm/broadcom/bcm2835/bcm2835_dma.c standard arm/broadcom/bcm2835/bcm2835_fb.c optional sc arm/broadcom/bcm2835/bcm2835_fbd.c optional vt @@ -12,10 +13,9 @@ arm/broadcom/bcm2835/bcm2835_sdhci.c optional sdhci arm/broadcom/bcm2835/bcm2835_spi.c optional bcm2835_spi arm/broadcom/bcm2835/bcm2835_systimer.c standard arm/broadcom/bcm2835/bcm2835_wdog.c standard -arm/broadcom/bcm2835/bus_space.c optional fdt -arm/broadcom/bcm2835/common.c optional fdt dev/usb/controller/dwc_otg_fdt.c optional dwcotg +arm/arm/bus_space-v6.c standard arm/arm/bus_space_generic.c standard arm/arm/bus_space_asm_generic.S standard arm/arm/cpufunc_asm_arm11.S standard diff --git a/sys/arm/conf/AC100 b/sys/arm/conf/AC100 index d368bdf65365..b41cc3689cfb 100644 --- a/sys/arm/conf/AC100 +++ b/sys/arm/conf/AC100 @@ -25,6 +25,9 @@ options FFS #Berkeley Fast Filesystem #options BOOTP_NFSV3 #options BOOTP_WIRED_TO=mge0 +options TMPFS #Efficient memory filesystem +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme options GEOM_PART_GPT options ROOTDEVNAME=\"ufs:/dev/da0p1\" diff --git a/sys/arm/conf/ARMADAXP b/sys/arm/conf/ARMADAXP index 2b4945971e2b..085422daaf33 100644 --- a/sys/arm/conf/ARMADAXP +++ b/sys/arm/conf/ARMADAXP @@ -26,6 +26,9 @@ options BOOTP_NFSROOT options BOOTP_NFSV3 options BOOTP_WIRED_TO=mge0 +options TMPFS #Efficient memory filesystem +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme options GEOM_PART_GPT options ROOTDEVNAME=\"ufs:/dev/da0p1\" diff --git a/sys/arm/conf/ARNDALE b/sys/arm/conf/ARNDALE index ae2e2650b7e1..0ce39391af5b 100644 --- a/sys/arm/conf/ARNDALE +++ b/sys/arm/conf/ARNDALE @@ -31,6 +31,9 @@ options HZ=100 ## options SCHED_4BSD #4BSD scheduler options INET #InterNETworking options INET6 #IPv6 communications protocols +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options FFS #Berkeley Fast Filesystem options SOFTUPDATES options UFS_ACL #Support for access control lists diff --git a/sys/arm/conf/ATMEL b/sys/arm/conf/ATMEL index 28c4bec448ea..c330fade68e6 100644 --- a/sys/arm/conf/ATMEL +++ b/sys/arm/conf/ATMEL @@ -48,10 +48,13 @@ options NFSCL # New Network Filesystem Client options NFSD # New Network Filesystem Server options NFSLOCKD # Network Lock Manager options NFS_ROOT # NFS usable as /, requires NFSCL +options TMPFS #Efficient memory filesystem options MSDOSFS # MSDOS Filesystem options CD9660 # ISO 9660 Filesystem options PROCFS # Process filesystem (requires PSEUDOFS) options PSEUDOFS # Pseudo-filesystem framework +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme options GEOM_PART_GPT # GUID Partition Tables. options GEOM_LABEL # Provides labelization options COMPAT_FREEBSD5 # Compatible with FreeBSD5 diff --git a/sys/arm/conf/AVILA b/sys/arm/conf/AVILA index 502fd2540382..38d79cdd84fd 100644 --- a/sys/arm/conf/AVILA +++ b/sys/arm/conf/AVILA @@ -47,6 +47,9 @@ options INVARIANT_SUPPORT #Extra sanity checks of internal structures, required options SCHED_4BSD #4BSD scheduler options INET #InterNETworking +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options FFS #Berkeley Fast Filesystem options SOFTUPDATES #Enable FFS soft updates support options NFSCL #New Network Filesystem Client diff --git a/sys/arm/conf/BEAGLEBONE b/sys/arm/conf/BEAGLEBONE index c0fb9c6e75d5..895095cca3e3 100644 --- a/sys/arm/conf/BEAGLEBONE +++ b/sys/arm/conf/BEAGLEBONE @@ -34,6 +34,9 @@ options FFS #Berkeley Fast Filesystem options SOFTUPDATES #Enable FFS soft updates support options UFS_ACL #Support for access control lists options UFS_DIRHASH #Improve performance on big directories +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options MSDOSFS #MSDOS Filesystem options CD9660 #ISO 9660 Filesystem options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/BWCT b/sys/arm/conf/BWCT index 28c724ff760b..82e09ad9370a 100644 --- a/sys/arm/conf/BWCT +++ b/sys/arm/conf/BWCT @@ -51,6 +51,9 @@ options NFS_ROOT #NFS usable as /, requires NFSCL options BOOTP_NFSROOT options BOOTP +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem #options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/CAMBRIA b/sys/arm/conf/CAMBRIA index 57c63870870e..1969c5198f56 100644 --- a/sys/arm/conf/CAMBRIA +++ b/sys/arm/conf/CAMBRIA @@ -48,6 +48,9 @@ options INVARIANT_SUPPORT #Extra sanity checks of internal structures, required options SCHED_4BSD #4BSD scheduler #options PREEMPTION options INET #InterNETworking +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options FFS #Berkeley Fast Filesystem options SOFTUPDATES #Enable FFS soft updates support options NFSCL #New Network Filesystem Client diff --git a/sys/arm/conf/CNS11XXNAS b/sys/arm/conf/CNS11XXNAS index c459d0eec4cf..4984794bdba7 100644 --- a/sys/arm/conf/CNS11XXNAS +++ b/sys/arm/conf/CNS11XXNAS @@ -53,6 +53,8 @@ options DDB #Enable the kernel debugger options SCHED_ULE #ULE scheduler #options SCHED_4BSD #4BSD scheduler +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme options GEOM_PART_GPT # GUID Partition Tables. #options GEOM_PART_EBR #options GEOM_PART_EBR_COMPAT @@ -69,6 +71,7 @@ options NFSCL #New Network Filesystem Client #options NFSD #New Network Filesystem Server #options NFSLOCKD #Network Lock Manager options NFS_ROOT #NFS usable as /, requires NFSCL +options TMPFS #Efficient memory filesystem options MSDOSFS #MSDOS Filesystem #options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/CRB b/sys/arm/conf/CRB index 0a19f3bd3896..26efd82a5799 100644 --- a/sys/arm/conf/CRB +++ b/sys/arm/conf/CRB @@ -45,6 +45,9 @@ options NFSD #New Network Filesystem Server options NFSLOCKD #Network Lock Manager options NFS_ROOT #NFS usable as /, requires NFSCL #options MSDOSFS #MSDOS Filesystem +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) options PSEUDOFS #Pseudo-filesystem framework diff --git a/sys/arm/conf/CUBIEBOARD b/sys/arm/conf/CUBIEBOARD index 7dee59b55c9c..07c8c049af1c 100644 --- a/sys/arm/conf/CUBIEBOARD +++ b/sys/arm/conf/CUBIEBOARD @@ -29,6 +29,9 @@ options HZ=100 options SCHED_4BSD #4BSD scheduler options INET #InterNETworking options INET6 #IPv6 communications protocols +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options FFS #Berkeley Fast Filesystem options SOFTUPDATES #Enable FFS soft updates support options UFS_ACL #Support for access control lists diff --git a/sys/arm/conf/CUBIEBOARD2 b/sys/arm/conf/CUBIEBOARD2 index 50fc2be740d8..ccd9edbb702e 100644 --- a/sys/arm/conf/CUBIEBOARD2 +++ b/sys/arm/conf/CUBIEBOARD2 @@ -29,6 +29,9 @@ options HZ=100 options SCHED_4BSD #4BSD scheduler options INET #InterNETworking options INET6 #IPv6 communications protocols +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options FFS #Berkeley Fast Filesystem options SOFTUPDATES #Enable FFS soft updates support options UFS_ACL #Support for access control lists diff --git a/sys/arm/conf/DB-78XXX b/sys/arm/conf/DB-78XXX index f3e62f5b61a9..2617e28fe030 100644 --- a/sys/arm/conf/DB-78XXX +++ b/sys/arm/conf/DB-78XXX @@ -16,6 +16,9 @@ makeoptions WERROR="-Werror" options SCHED_4BSD #4BSD scheduler options INET #InterNETworking options INET6 #IPv6 communications protocols +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options FFS #Berkeley Fast Filesystem options NANDFS #NAND Filesystem options NFSCL #New Network Filesystem Client diff --git a/sys/arm/conf/DB-88F5XXX b/sys/arm/conf/DB-88F5XXX index 50ca24e57eac..c2b8c3eef79c 100644 --- a/sys/arm/conf/DB-88F5XXX +++ b/sys/arm/conf/DB-88F5XXX @@ -16,6 +16,9 @@ makeoptions WERROR="-Werror" options SCHED_4BSD #4BSD scheduler options INET #InterNETworking options INET6 #IPv6 communications protocols +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options FFS #Berkeley Fast Filesystem options NFSCL #New Network Filesystem Client options NFSLOCKD #Network Lock Manager diff --git a/sys/arm/conf/DB-88F6XXX b/sys/arm/conf/DB-88F6XXX index cf508ad77259..8f467eefb0b8 100644 --- a/sys/arm/conf/DB-88F6XXX +++ b/sys/arm/conf/DB-88F6XXX @@ -16,6 +16,9 @@ makeoptions WERROR="-Werror" options SCHED_4BSD #4BSD scheduler options INET #InterNETworking options INET6 #IPv6 communications protocols +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options FFS #Berkeley Fast Filesystem options NANDFS #NAND Filesystem options NFSCL #New Network Filesystem Client diff --git a/sys/arm/conf/DEFAULTS b/sys/arm/conf/DEFAULTS index 102f13060982..6755185f54d5 100644 --- a/sys/arm/conf/DEFAULTS +++ b/sys/arm/conf/DEFAULTS @@ -5,8 +5,3 @@ device mem -options GEOM_PART_BSD -options GEOM_PART_MBR - -options TMPFS - diff --git a/sys/arm/conf/DIGI-CCWMX53 b/sys/arm/conf/DIGI-CCWMX53 index 244cff4bc856..229e401cdac2 100644 --- a/sys/arm/conf/DIGI-CCWMX53 +++ b/sys/arm/conf/DIGI-CCWMX53 @@ -41,10 +41,13 @@ options NFSCL # New Network Filesystem Client #options NFSD # New Network Filesystem Server options NFSLOCKD # Network Lock Manager options NFS_ROOT # NFS usable as /, requires NFSCL +options TMPFS #Efficient memory filesystem options MSDOSFS # MSDOS Filesystem options CD9660 # ISO 9660 Filesystem #options PROCFS # Process filesystem (requires PSEUDOFS) options PSEUDOFS # Pseudo-filesystem framework +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme options GEOM_PART_GPT # GUID Partition Tables. options GEOM_LABEL # Provides labelization #options COMPAT_FREEBSD5 # Compatible with FreeBSD5 diff --git a/sys/arm/conf/DOCKSTAR b/sys/arm/conf/DOCKSTAR index f0ddd5fdf667..b87ac9e9d27d 100644 --- a/sys/arm/conf/DOCKSTAR +++ b/sys/arm/conf/DOCKSTAR @@ -34,12 +34,15 @@ options INET6 #IPv6 communications protocols options SOFTUPDATES options CD9660 #ISO 9660 filesystem options FFS #Berkeley Fast Filesystem +options TMPFS #Efficient memory filesystem options MSDOSFS #MS DOS File System (FAT, FAT32) options NULLFS #NULL filesystem options SYSVSHM #SYSV-style shared memory options SYSVMSG #SYSV-style message queues options SYSVSEM #SYSV-style semaphores options _KPOSIX_PRIORITY_SCHEDULING #Posix P1003_1B real-time extensions +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme options GEOM_ELI # Disk encryption. options GEOM_LABEL # Providers labelization. options GEOM_PART_GPT # GPT partitioning diff --git a/sys/arm/conf/DREAMPLUG-1001 b/sys/arm/conf/DREAMPLUG-1001 index baebc77ecca4..7598c74100cd 100644 --- a/sys/arm/conf/DREAMPLUG-1001 +++ b/sys/arm/conf/DREAMPLUG-1001 @@ -35,6 +35,7 @@ options SCHED_4BSD #4BSD scheduler options INET #InterNETworking options INET6 #IPv6 communications protocols options SOFTUPDATES +options TMPFS #Efficient memory filesystem options CD9660 #ISO 9660 filesystem options FFS #Berkeley Fast Filesystem options MSDOSFS #MS DOS File System (FAT, FAT32) @@ -43,6 +44,8 @@ options SYSVSHM #SYSV-style shared memory options SYSVMSG #SYSV-style message queues options SYSVSEM #SYSV-style semaphores options _KPOSIX_PRIORITY_SCHEDULING #Posix P1003_1B real-time extensions +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme options GEOM_ELI # Disk encryption. options GEOM_LABEL # Providers labelization. options GEOM_PART_GPT # GPT partitioning diff --git a/sys/arm/conf/EA3250 b/sys/arm/conf/EA3250 index 89d9fa418c30..fb6a3f8018ab 100644 --- a/sys/arm/conf/EA3250 +++ b/sys/arm/conf/EA3250 @@ -20,6 +20,9 @@ options FFS #Berkeley Fast Filesystem options NFSCL #Network Filesystem Client options NFSLOCKD #Network Lock Manager options NFS_ROOT #NFS usable as /, requires NFSCLIENT +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options MSDOSFS options BOOTP options BOOTP_NFSROOT diff --git a/sys/arm/conf/EB9200 b/sys/arm/conf/EB9200 index 0570699ef808..8c3838355980 100644 --- a/sys/arm/conf/EB9200 +++ b/sys/arm/conf/EB9200 @@ -41,6 +41,9 @@ options NFS_ROOT #NFS usable as /, requires NFSCL options BOOTP_NFSROOT options BOOTP +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem #options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/EFIKA_MX b/sys/arm/conf/EFIKA_MX index ca95f0c2c44a..885f16c38771 100644 --- a/sys/arm/conf/EFIKA_MX +++ b/sys/arm/conf/EFIKA_MX @@ -41,10 +41,13 @@ options NFSCL # New Network Filesystem Client #options NFSD # New Network Filesystem Server options NFSLOCKD # Network Lock Manager options NFS_ROOT # NFS usable as /, requires NFSCL +options TMPFS #Efficient memory filesystem options MSDOSFS # MSDOS Filesystem options CD9660 # ISO 9660 Filesystem #options PROCFS # Process filesystem (requires PSEUDOFS) options PSEUDOFS # Pseudo-filesystem framework +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme options GEOM_PART_GPT # GUID Partition Tables. options GEOM_LABEL # Provides labelization #options COMPAT_FREEBSD5 # Compatible with FreeBSD5 diff --git a/sys/arm/conf/EP80219 b/sys/arm/conf/EP80219 index 107ef4b5b4e2..ce0d718e47cb 100644 --- a/sys/arm/conf/EP80219 +++ b/sys/arm/conf/EP80219 @@ -43,6 +43,7 @@ options NFSCL #New Network Filesystem Client options NFSD #New Network Filesystem Server options NFSLOCKD #Network Lock Manager options NFS_ROOT #NFS usable as /, requires NFSCL +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) @@ -54,6 +55,8 @@ options SYSVMSG #SYSV-style message queues options SYSVSEM #SYSV-style semaphores options _KPOSIX_PRIORITY_SCHEDULING #Posix P1003_1B real-time extensions options KBD_INSTALL_CDEV # install a CDEV entry in /dev +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme options GEOM_PART_GPT # GUID Partition Tables. options GEOM_LABEL # Providers labelization. diff --git a/sys/arm/conf/ETHERNUT5 b/sys/arm/conf/ETHERNUT5 index ef52bc68434b..13a9845f9c1c 100644 --- a/sys/arm/conf/ETHERNUT5 +++ b/sys/arm/conf/ETHERNUT5 @@ -41,6 +41,9 @@ options NFSCL # New Network Filesystem Client #options NFSD # New Network Filesystem Server options NFSLOCKD # Network Lock Manager options NFS_ROOT # NFS usable as /, requires NFSCL +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS # MSDOS Filesystem #options CD9660 # ISO 9660 Filesystem #options PROCFS # Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/GUMSTIX b/sys/arm/conf/GUMSTIX index 8b9824c60566..413931b841c3 100644 --- a/sys/arm/conf/GUMSTIX +++ b/sys/arm/conf/GUMSTIX @@ -47,6 +47,9 @@ options UFS_DIRHASH #Improve performance on big directories options NFSCL #New Network Filesystem Client #options NFSD #New Network Filesystem Server options NFS_ROOT #NFS usable as /, requires NFSCL +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem #options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/HL200 b/sys/arm/conf/HL200 index 8df55cd53573..a3b5640a79cc 100644 --- a/sys/arm/conf/HL200 +++ b/sys/arm/conf/HL200 @@ -49,6 +49,9 @@ options BOOTP_NFSV3 options BOOTP_WIRED_TO=ate0 options BOOTP_COMPAT +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem #options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/HL201 b/sys/arm/conf/HL201 index 8178e3bc1648..4ee00200435f 100644 --- a/sys/arm/conf/HL201 +++ b/sys/arm/conf/HL201 @@ -52,6 +52,9 @@ options NFS_ROOT #NFS usable as /, requires NFSCL options ALT_BREAK_TO_DEBUGGER +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem #options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/IMX53-QSB b/sys/arm/conf/IMX53-QSB index 1561368d128b..0167781254c3 100644 --- a/sys/arm/conf/IMX53-QSB +++ b/sys/arm/conf/IMX53-QSB @@ -40,10 +40,13 @@ options NFSCL # New Network Filesystem Client #options NFSD # New Network Filesystem Server options NFSLOCKD # Network Lock Manager options NFS_ROOT # NFS usable as /, requires NFSCL +options TMPFS #Efficient memory filesystem options MSDOSFS # MSDOS Filesystem options CD9660 # ISO 9660 Filesystem #options PROCFS # Process filesystem (requires PSEUDOFS) options PSEUDOFS # Pseudo-filesystem framework +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme options GEOM_PART_GPT # GUID Partition Tables. options GEOM_LABEL # Provides labelization #options COMPAT_FREEBSD5 # Compatible with FreeBSD5 diff --git a/sys/arm/conf/IMX6 b/sys/arm/conf/IMX6 index 26a135f0401e..3f8a9e4ff8e9 100644 --- a/sys/arm/conf/IMX6 +++ b/sys/arm/conf/IMX6 @@ -36,10 +36,13 @@ options NFSCL # New Network Filesystem Client #options NFSD # New Network Filesystem Server options NFSLOCKD # Network Lock Manager options NFS_ROOT # NFS usable as /, requires NFSCL +options TMPFS #Efficient memory filesystem options MSDOSFS # MSDOS Filesystem options CD9660 # ISO 9660 Filesystem #options PROCFS # Process filesystem (requires PSEUDOFS) options PSEUDOFS # Pseudo-filesystem framework +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme options GEOM_PART_GPT # GUID Partition Tables. options GEOM_LABEL # Provides labelization options KTRACE # ktrace(1) support diff --git a/sys/arm/conf/IQ31244 b/sys/arm/conf/IQ31244 index ba303c7fe475..9868511bf6d8 100644 --- a/sys/arm/conf/IQ31244 +++ b/sys/arm/conf/IQ31244 @@ -44,6 +44,9 @@ options NFSCL #New Network Filesystem Client options NFSD #New Network Filesystem Server options NFSLOCKD #Network Lock Manager options NFS_ROOT #NFS usable as /, requires NFSCL +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/KB920X b/sys/arm/conf/KB920X index 7cf56d82912e..1e1eb5c01f66 100644 --- a/sys/arm/conf/KB920X +++ b/sys/arm/conf/KB920X @@ -47,6 +47,9 @@ options NFSCL #New Network Filesystem Client #options BOOTP_NFSROOT #options BOOTP +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem #options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/LN2410SBC b/sys/arm/conf/LN2410SBC index 8d2a585899ba..40414f73b61e 100644 --- a/sys/arm/conf/LN2410SBC +++ b/sys/arm/conf/LN2410SBC @@ -47,6 +47,9 @@ options ROOTDEVNAME=\"ufs:da0s1\" #options NFSCL #New Network Filesystem Client #options NFS_ROOT #NFS usable as root device +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options PSEUDOFS #Pseudo-filesystem framework #options SCSI_DELAY=5000 #Delay (in ms) before probing SCSI options KTRACE #ktrace(1) support diff --git a/sys/arm/conf/NSLU b/sys/arm/conf/NSLU index 3da5adf396fe..e8094ca229e5 100644 --- a/sys/arm/conf/NSLU +++ b/sys/arm/conf/NSLU @@ -61,6 +61,9 @@ options NFSCL #New Network Filesystem Client options NFSD #New Network Filesystem Server options NFSLOCKD #Network Lock Manager options NFS_ROOT #NFS usable as /, requires NFSCL +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/PANDABOARD b/sys/arm/conf/PANDABOARD index 3c6132920905..9e6e5147d66d 100644 --- a/sys/arm/conf/PANDABOARD +++ b/sys/arm/conf/PANDABOARD @@ -54,6 +54,9 @@ options NFS_ROOT #NFS usable as /, requires NFSCLIENT #options BOOTP #options BOOTP_NFSV3 #options BOOTP_WIRED_TO=ue0 +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options MSDOSFS #MSDOS Filesystem #options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/QILA9G20 b/sys/arm/conf/QILA9G20 index e3cc9146639e..a1960205e469 100644 --- a/sys/arm/conf/QILA9G20 +++ b/sys/arm/conf/QILA9G20 @@ -53,6 +53,9 @@ options ROOTDEVNAME=\"ufs:/dev/mmcsd0s1a\" options ALT_BREAK_TO_DEBUGGER +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem #options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/RADXA b/sys/arm/conf/RADXA index 0396c2f6d6f5..b6edf43e797f 100644 --- a/sys/arm/conf/RADXA +++ b/sys/arm/conf/RADXA @@ -33,6 +33,9 @@ options FFS #Berkeley Fast Filesystem options SOFTUPDATES #Enable FFS soft updates support options UFS_ACL #Support for access control lists options UFS_DIRHASH #Improve performance on big directories +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options MSDOSFS #MSDOS Filesystem options CD9660 #ISO 9660 Filesystem options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/RPI-B b/sys/arm/conf/RPI-B index 5fe031b9f540..711db77d4beb 100644 --- a/sys/arm/conf/RPI-B +++ b/sys/arm/conf/RPI-B @@ -32,6 +32,9 @@ options FFS #Berkeley Fast Filesystem options SOFTUPDATES #Enable FFS soft updates support options UFS_ACL #Support for access control lists options UFS_DIRHASH #Improve performance on big directories +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options MSDOSFS #MSDOS Filesystem device snp diff --git a/sys/arm/conf/SAM9260EK b/sys/arm/conf/SAM9260EK index 8f137e0896bf..5b40706c35cd 100644 --- a/sys/arm/conf/SAM9260EK +++ b/sys/arm/conf/SAM9260EK @@ -25,6 +25,7 @@ include "../at91/std.sam9260ek" hints "SAM9260EK.hints" #makeoptions DEBUG=-g # Build kernel with gdb(1) debug symbols +makeoptions MODULES_OVERRIDE="" options SCHED_4BSD # 4BSD scheduler #options PREEMPTION # Enable kernel thread preemption @@ -42,10 +43,13 @@ options NFSCL # New Network Filesystem Client #options NFSD # New Network Filesystem Server options NFSLOCKD # Network Lock Manager options NFS_ROOT # NFS usable as /, requires NFSCL +options TMPFS #Efficient memory filesystem #options MSDOSFS # MSDOS Filesystem #options CD9660 # ISO 9660 Filesystem #options PROCFS # Process filesystem (requires PSEUDOFS) #options PSEUDOFS # Pseudo-filesystem framework +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme #options GEOM_PART_GPT # GUID Partition Tables. #options GEOM_LABEL # Provides labelization #options COMPAT_FREEBSD5 # Compatible with FreeBSD5 @@ -168,3 +172,12 @@ device at91_wdt # Atmel AT91 Watchdog Timer # NAND Flash - Reference design has Samsung 256MB but others possible device nand # NAND interface on CS3 + +# Coming soon, but not yet +#options FDT +#options FDT_DTB_STATIC +#makeoptions FDT_DTS_FILE=sam9260ek.dts + +options EARLY_PRINTF +options SOCDEV_PA=0xfc000000 +options SOCDEV_VA=0xdc000000 diff --git a/sys/arm/conf/SAM9G20EK b/sys/arm/conf/SAM9G20EK index faa325ac188a..04a84b2ad53a 100644 --- a/sys/arm/conf/SAM9G20EK +++ b/sys/arm/conf/SAM9G20EK @@ -32,6 +32,9 @@ options KDB options SCHED_4BSD #4BSD scheduler options INET #InterNETworking #options INET6 #IPv6 communications protocols +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options FFS #Berkeley Fast Filesystem #options SOFTUPDATES #Enable FFS soft updates support #options UFS_ACL #Support for access control lists diff --git a/sys/arm/conf/SAM9X25EK b/sys/arm/conf/SAM9X25EK index 9363fb94c765..4088e90d56bd 100644 --- a/sys/arm/conf/SAM9X25EK +++ b/sys/arm/conf/SAM9X25EK @@ -33,6 +33,9 @@ options KDB options SCHED_4BSD #4BSD scheduler options INET #InterNETworking #options INET6 #IPv6 communications protocols +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options FFS #Berkeley Fast Filesystem #options SOFTUPDATES #Enable FFS soft updates support #options UFS_ACL #Support for access control lists diff --git a/sys/arm/conf/SHEEVAPLUG b/sys/arm/conf/SHEEVAPLUG index c6bd901cb804..2d0daded1bba 100644 --- a/sys/arm/conf/SHEEVAPLUG +++ b/sys/arm/conf/SHEEVAPLUG @@ -16,6 +16,9 @@ makeoptions WERROR="-Werror" options SCHED_4BSD #4BSD scheduler options INET #InterNETworking options INET6 #IPv6 communications protocols +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options FFS #Berkeley Fast Filesystem options NANDFS #NAND Filesystem options NFSCL #New Network Filesystem Client diff --git a/sys/arm/conf/SIMICS b/sys/arm/conf/SIMICS index 8988d2728b69..6ea8e507e0dc 100644 --- a/sys/arm/conf/SIMICS +++ b/sys/arm/conf/SIMICS @@ -43,6 +43,9 @@ options NFSCL #New Network Filesystem Client options NFSD #New Network Filesystem Server options NFSLOCKD #Network Lock Manager options NFS_ROOT #NFS usable as /, requires NFSCL +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/SN9G45 b/sys/arm/conf/SN9G45 index 05c9062548c8..1d8a1b4e6cf1 100644 --- a/sys/arm/conf/SN9G45 +++ b/sys/arm/conf/SN9G45 @@ -52,6 +52,9 @@ options ROOTDEVNAME=\"ufs:/dev/da0s1\" options ALT_BREAK_TO_DEBUGGER +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem #options MSDOSFS #MSDOS Filesystem #options CD9660 #ISO 9660 Filesystem #options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/TS7800 b/sys/arm/conf/TS7800 index 79e9dbae4de4..c836c1d23524 100644 --- a/sys/arm/conf/TS7800 +++ b/sys/arm/conf/TS7800 @@ -26,6 +26,10 @@ options BOOTP_NFSROOT options BOOTP_NFSV3 options BOOTP_WIRED_TO=mge0 +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem + options SYSVSHM #SYSV-style shared memory options SYSVMSG #SYSV-style message queues options SYSVSEM #SYSV-style semaphores diff --git a/sys/arm/conf/VERSATILEPB b/sys/arm/conf/VERSATILEPB index 6f884d151b79..28b76a589b06 100644 --- a/sys/arm/conf/VERSATILEPB +++ b/sys/arm/conf/VERSATILEPB @@ -43,6 +43,9 @@ options UFS_ACL #Support for access control lists options UFS_DIRHASH #Improve performance on big directories device snp +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options PSEUDOFS #Pseudo-filesystem framework options COMPAT_43 #Compatible with BSD 4.3 [KEEP THIS!] options SCSI_DELAY=5000 #Delay (in ms) before probing SCSI diff --git a/sys/arm/conf/VYBRID.common b/sys/arm/conf/VYBRID.common index 3c5ca9fd9d1e..70fef0240b70 100644 --- a/sys/arm/conf/VYBRID.common +++ b/sys/arm/conf/VYBRID.common @@ -33,6 +33,9 @@ options FFS #Berkeley Fast Filesystem options SOFTUPDATES options UFS_ACL #Support for access control lists options UFS_DIRHASH #Improve performance on big directories +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options MSDOSFS #MSDOS Filesystem options CD9660 #ISO 9660 Filesystem options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/conf/ZEDBOARD b/sys/arm/conf/ZEDBOARD index 464850aed726..9fa2008d2f83 100644 --- a/sys/arm/conf/ZEDBOARD +++ b/sys/arm/conf/ZEDBOARD @@ -41,6 +41,9 @@ options NFSCL #Network Filesystem Client # options BOOTP_NFSROOT # options BOOTP +options GEOM_PART_BSD #BSD partition scheme +options GEOM_PART_MBR #MBR partition scheme +options TMPFS #Efficient memory filesystem options MSDOSFS #MSDOS Filesystem options CD9660 #ISO 9660 Filesystem options PROCFS #Process filesystem (requires PSEUDOFS) diff --git a/sys/arm/freescale/imx/files.imx51 b/sys/arm/freescale/imx/files.imx51 index c4ef506e952a..49781485f9b8 100644 --- a/sys/arm/freescale/imx/files.imx51 +++ b/sys/arm/freescale/imx/files.imx51 @@ -8,9 +8,9 @@ arm/arm/irq_dispatch.S standard kern/kern_clocksource.c standard # Init +arm/freescale/imx/imx_common.c standard arm/freescale/imx/imx_machdep.c standard arm/freescale/imx/imx51_machdep.c standard -arm/freescale/imx/common.c standard arm/freescale/imx/bus_space.c standard # Dummy serial console diff --git a/sys/arm/freescale/imx/files.imx53 b/sys/arm/freescale/imx/files.imx53 index c51c86760a62..34774168b078 100644 --- a/sys/arm/freescale/imx/files.imx53 +++ b/sys/arm/freescale/imx/files.imx53 @@ -8,9 +8,9 @@ arm/arm/irq_dispatch.S standard kern/kern_clocksource.c standard # Init +arm/freescale/imx/imx_common.c standard arm/freescale/imx/imx_machdep.c standard arm/freescale/imx/imx53_machdep.c standard -arm/freescale/imx/common.c standard arm/freescale/imx/bus_space.c standard # Special serial console for debuging early boot code diff --git a/sys/arm/freescale/imx/files.imx6 b/sys/arm/freescale/imx/files.imx6 index 41060dac5b91..8b718d661bd9 100644 --- a/sys/arm/freescale/imx/files.imx6 +++ b/sys/arm/freescale/imx/files.imx6 @@ -18,8 +18,8 @@ arm/arm/gic.c standard arm/arm/pl310.c standard arm/freescale/imx/bus_space.c standard arm/freescale/fsl_ocotp.c standard -arm/freescale/imx/common.c standard arm/freescale/imx/imx6_anatop.c standard +arm/freescale/imx/imx_common.c standard arm/freescale/imx/imx6_ccm.c standard arm/freescale/imx/imx6_machdep.c standard arm/freescale/imx/imx6_mp.c optional smp diff --git a/sys/arm/freescale/imx/common.c b/sys/arm/freescale/imx/imx_common.c index d8fef824394e..d8fef824394e 100644 --- a/sys/arm/freescale/imx/common.c +++ b/sys/arm/freescale/imx/imx_common.c diff --git a/sys/arm/include/param.h b/sys/arm/include/param.h index 15fc2793798c..5cd0b7bb9187 100644 --- a/sys/arm/include/param.h +++ b/sys/arm/include/param.h @@ -125,10 +125,8 @@ #define KSTACK_GUARD_PAGES 1 #endif /* !KSTACK_GUARD_PAGES */ -#define USPACE_SVC_STACK_TOP KSTACK_PAGES * PAGE_SIZE -#define USPACE_SVC_STACK_BOTTOM (USPACE_SVC_STACK_TOP - 0x1000) -#define USPACE_UNDEF_STACK_TOP (USPACE_SVC_STACK_BOTTOM - 0x10) -#define USPACE_UNDEF_STACK_BOTTOM (FPCONTEXTSIZE + 10) +#define USPACE_SVC_STACK_TOP (KSTACK_PAGES * PAGE_SIZE) + /* * Mach derived conversion macros */ diff --git a/sys/arm/include/pcb.h b/sys/arm/include/pcb.h index 8a762aa6789d..0806cd88a4e5 100644 --- a/sys/arm/include/pcb.h +++ b/sys/arm/include/pcb.h @@ -61,7 +61,6 @@ struct pcb_arm32 { u_int pcb32_sp; /* used */ u_int pcb32_lr; u_int pcb32_pc; - u_int pcb32_und_sp; }; #define pcb_pagedir un_32.pcb32_pagedir #define pcb_pl1vec un_32.pcb32_pl1vec diff --git a/sys/arm/include/pcpu.h b/sys/arm/include/pcpu.h index 1771a8e821ab..ee79343af01a 100644 --- a/sys/arm/include/pcpu.h +++ b/sys/arm/include/pcpu.h @@ -46,9 +46,8 @@ struct vmspace; unsigned int pc_vfpsid; \ unsigned int pc_vfpmvfr0; \ unsigned int pc_vfpmvfr1; \ - struct thread *pc_vfpcthread; \ struct pmap *pc_curpmap; \ - char __pad[133] + char __pad[137] #else #define PCPU_MD_FIELDS \ char __pad[157] diff --git a/sys/arm/include/vfp.h b/sys/arm/include/vfp.h index 623f0d011bf9..befba18eca5a 100644 --- a/sys/arm/include/vfp.h +++ b/sys/arm/include/vfp.h @@ -126,6 +126,10 @@ #define COPROC10 (0x3 << 20) #define COPROC11 (0x3 << 22) +#ifndef LOCORE void vfp_init(void); +void vfp_store(struct vfp_state *, boolean_t); +void vfp_discard(struct thread *); +#endif #endif diff --git a/sys/arm/mv/files.mv b/sys/arm/mv/files.mv index 116356d8a2dd..4fbdc6d17357 100644 --- a/sys/arm/mv/files.mv +++ b/sys/arm/mv/files.mv @@ -23,8 +23,8 @@ arm/arm/cpufunc_asm_pj4b.S standard arm/arm/irq_dispatch.S standard arm/mv/bus_space.c standard -arm/mv/common.c standard arm/mv/gpio.c standard +arm/mv/mv_common.c standard arm/mv/mv_localbus.c standard arm/mv/mv_machdep.c standard arm/mv/mv_pci.c optional pci diff --git a/sys/arm/mv/common.c b/sys/arm/mv/mv_common.c index 366fcf153f43..44c22cb20891 100644 --- a/sys/arm/mv/common.c +++ b/sys/arm/mv/mv_common.c @@ -153,8 +153,11 @@ struct fdt_pm_mask_entry fdt_pm_mask_table[] = { static __inline int pm_is_disabled(uint32_t mask) { - +#if defined(SOC_MV_KIRKWOOD) + return (soc_power_ctrl_get(mask) == mask); +#else return (soc_power_ctrl_get(mask) == mask ? 0 : 1); +#endif } /* @@ -221,7 +224,16 @@ fdt_pm(phandle_t node) continue; compat = fdt_is_compatible(node, fdt_pm_mask_table[i].compat); - +#if defined(SOC_MV_KIRKWOOD) + if (compat && (cpu_pm_ctrl & fdt_pm_mask_table[i].mask)) { + dev_mask |= (1 << i); + ena = 0; + break; + } else if (compat) { + dev_mask |= (1 << i); + break; + } +#else if (compat && (~cpu_pm_ctrl & fdt_pm_mask_table[i].mask)) { dev_mask |= (1 << i); ena = 0; @@ -230,6 +242,7 @@ fdt_pm(phandle_t node) dev_mask |= (1 << i); break; } +#endif } return (ena); diff --git a/sys/arm/mv/mvreg.h b/sys/arm/mv/mvreg.h index 79398d9119b7..1d6efed1361d 100644 --- a/sys/arm/mv/mvreg.h +++ b/sys/arm/mv/mvreg.h @@ -142,7 +142,11 @@ /* * Power Control */ +#if defined(SOC_MV_KIRKWOOD) +#define CPU_PM_CTRL 0x18 +#else #define CPU_PM_CTRL 0x1C +#endif #define CPU_PM_CTRL_NONE 0 #define CPU_PM_CTRL_ALL ~0x0 diff --git a/sys/arm/rockchip/files.rk30xx b/sys/arm/rockchip/files.rk30xx index 6a7a7c6840a3..7fcd411d1df1 100644 --- a/sys/arm/rockchip/files.rk30xx +++ b/sys/arm/rockchip/files.rk30xx @@ -13,7 +13,7 @@ arm/arm/gic.c standard arm/arm/mpcore_timer.c standard arm/rockchip/bus_space.c standard -arm/rockchip/common.c standard +arm/rockchip/rk30xx_common.c standard arm/rockchip/rk30xx_machdep.c standard arm/rockchip/rk30xx_pmu.c standard arm/rockchip/rk30xx_grf.c standard diff --git a/sys/arm/rockchip/common.c b/sys/arm/rockchip/rk30xx_common.c index 065318489a04..065318489a04 100644 --- a/sys/arm/rockchip/common.c +++ b/sys/arm/rockchip/rk30xx_common.c diff --git a/sys/arm/samsung/exynos/common.c b/sys/arm/samsung/exynos/exynos5_common.c index 658efc417298..658efc417298 100644 --- a/sys/arm/samsung/exynos/common.c +++ b/sys/arm/samsung/exynos/exynos5_common.c diff --git a/sys/arm/samsung/exynos/files.exynos5 b/sys/arm/samsung/exynos/files.exynos5 index 1d90415e6c0c..bb8218e4c1f7 100644 --- a/sys/arm/samsung/exynos/files.exynos5 +++ b/sys/arm/samsung/exynos/files.exynos5 @@ -16,7 +16,7 @@ arm/arm/generic_timer.c standard arm/samsung/exynos/arch_timer.c standard arm/samsung/exynos/exynos5_mp.c optional smp -arm/samsung/exynos/common.c standard +arm/samsung/exynos/exynos5_common.c standard arm/samsung/exynos/exynos5_machdep.c standard arm/samsung/exynos/uart.c optional uart arm/samsung/exynos/ehci_exynos5.c optional ehci diff --git a/sys/arm/tegra/files.tegra2 b/sys/arm/tegra/files.tegra2 index 7f6e8937b5b8..de91f32fe886 100644 --- a/sys/arm/tegra/files.tegra2 +++ b/sys/arm/tegra/files.tegra2 @@ -11,7 +11,7 @@ arm/arm/irq_dispatch.S standard arm/arm/gic.c standard arm/arm/mpcore_timer.c standard -arm/tegra/common.c standard +arm/tegra/tegra2_common.c standard arm/tegra/tegra2_machdep.c standard kern/kern_clocksource.c standard diff --git a/sys/arm/tegra/common.c b/sys/arm/tegra/tegra2_common.c index 868572dde33f..868572dde33f 100644 --- a/sys/arm/tegra/common.c +++ b/sys/arm/tegra/tegra2_common.c diff --git a/sys/arm/ti/files.ti b/sys/arm/ti/files.ti index b2c964a4f883..510dbf982fd2 100644 --- a/sys/arm/ti/files.ti +++ b/sys/arm/ti/files.ti @@ -11,7 +11,7 @@ arm/arm/cpufunc_asm_arm11.S standard arm/arm/cpufunc_asm_armv7.S standard arm/arm/irq_dispatch.S standard -arm/ti/common.c standard +arm/ti/ti_common.c standard arm/ti/ti_cpuid.c standard arm/ti/ti_machdep.c standard arm/ti/ti_prcm.c standard diff --git a/sys/arm/ti/common.c b/sys/arm/ti/ti_common.c index 983e6f807617..983e6f807617 100644 --- a/sys/arm/ti/common.c +++ b/sys/arm/ti/ti_common.c diff --git a/sys/arm/versatile/files.versatile b/sys/arm/versatile/files.versatile index 702a2366b574..ba892b362121 100644 --- a/sys/arm/versatile/files.versatile +++ b/sys/arm/versatile/files.versatile @@ -9,11 +9,11 @@ arm/arm/cpufunc_asm_armv6.S standard arm/arm/irq_dispatch.S standard arm/versatile/bus_space.c standard -arm/versatile/common.c standard arm/versatile/pl050.c optional sc arm/versatile/sp804.c standard arm/versatile/versatile_machdep.c standard arm/versatile/versatile_clcd.c optional sc +arm/versatile/versatile_common.c standard arm/versatile/versatile_pci.c optional pci arm/versatile/versatile_pci_bus_space.c optional pci arm/versatile/versatile_sic.c standard diff --git a/sys/arm/versatile/common.c b/sys/arm/versatile/versatile_common.c index 766db9deacc5..766db9deacc5 100644 --- a/sys/arm/versatile/common.c +++ b/sys/arm/versatile/versatile_common.c diff --git a/sys/boot/fdt/dts/arm/hl201.dts b/sys/boot/fdt/dts/arm/hl201.dts new file mode 100644 index 000000000000..1566b30f8f96 --- /dev/null +++ b/sys/boot/fdt/dts/arm/hl201.dts @@ -0,0 +1,44 @@ +/* + * Hot-e HL-201 - Warner Losh public domain + * + * $FreeBSD$ + */ +/dts-v1/; + +/* + * The following is a white lie. The HL-201 is a stripped down version of + * the SAM9G20EK board with a video output chip. + */ +#include "at91sam9g20ek_common.dtsi" + +/ { + model = "Thinlinx HL201"; + compatible = "thinlinx,hl201", "atmel,at91sam9g20ek", "atmel,at91sam9g20", "atmel,at91sam9"; + + leds { + compatible = "gpio-leds"; + + ds1 { + label = "ds1"; + gpios = <&pioA 9 0>; + linux,default-trigger = "heartbeat"; + }; + + ds5 { + label = "ds5"; + gpios = <&pioA 6 1>; + }; + }; + + /* Missing: one wire serial number, video chip */ + + aliases { + dbgu = &dbgu; + }; + + + chosen { + stdin = "dbgu"; + stdout = "dbgu"; + }; +}; diff --git a/sys/dev/ffec/if_ffec.c b/sys/dev/ffec/if_ffec.c index 16b9baae34ae..3acec6eb067b 100644 --- a/sys/dev/ffec/if_ffec.c +++ b/sys/dev/ffec/if_ffec.c @@ -958,9 +958,10 @@ ffec_setup_rxfilter(struct ffec_softc *sc) TAILQ_FOREACH(ifma, &sc->ifp->if_multiaddrs, ifma_link) { if (ifma->ifma_addr->sa_family != AF_LINK) continue; - crc = ether_crc32_be(LLADDR((struct sockaddr_dl *) + /* 6 bits from MSB in LE CRC32 are used for hash. */ + crc = ether_crc32_le(LLADDR((struct sockaddr_dl *) ifma->ifma_addr), ETHER_ADDR_LEN); - ghash |= 1LLU << (crc & 0x3f); + ghash |= 1LLU << (((uint8_t *)&crc)[3] >> 2); } if_maddr_runlock(ifp); } diff --git a/sys/dev/uart/uart_bus_fdt.c b/sys/dev/uart/uart_bus_fdt.c index f434f4f4fc01..92e155b34a7a 100644 --- a/sys/dev/uart/uart_bus_fdt.c +++ b/sys/dev/uart/uart_bus_fdt.c @@ -97,9 +97,12 @@ uart_fdt_get_clock(phandle_t node, pcell_t *cell) { pcell_t clock; + /* + * clock-frequency is a FreeBSD-specific hack. Make its presence optional. + */ if ((OF_getprop(node, "clock-frequency", &clock, sizeof(clock))) <= 0) - return (ENXIO); + clock = 0; if (clock == 0) /* Try to retrieve parent 'bus-frequency' */ |