Date: Mon, 30 Dec 2019 13:29:31 +0000 (UTC) From: Ruslan Bukin <br@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r356202 - head/sys/riscv/riscv Message-ID: <201912301329.xBUDTVqG088272@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: br Date: Mon Dec 30 13:29:30 2019 New Revision: 356202 URL: https://svnweb.freebsd.org/changeset/base/356202 Log: Round the kernel stack allocation up as required. Submitted by: James Clarke <jrtc27@jrtc27.com> Sponsored by: DARPA, AFRL Differential Revision: https://reviews.freebsd.org/D22961 Modified: head/sys/riscv/riscv/locore.S Modified: head/sys/riscv/riscv/locore.S ============================================================================== --- head/sys/riscv/riscv/locore.S Mon Dec 30 09:22:52 2019 (r356201) +++ head/sys/riscv/riscv/locore.S Mon Dec 30 13:29:30 2019 (r356202) @@ -186,8 +186,10 @@ va: /* Initialize stack pointer */ la s3, initstack_end mv sp, s3 - addi sp, sp, -PCB_SIZE + /* Allocate space for thread0 PCB and riscv_bootparams */ + addi sp, sp, -(PCB_SIZE + 40) & ~STACKALIGNBYTES + /* Clear BSS */ la s0, _C_LABEL(__bss_start) la s1, _C_LABEL(_end) @@ -203,8 +205,6 @@ va: #endif /* Fill riscv_bootparams */ - addi sp, sp, -40 - la t0, pagetable_l1 sd t0, 0(sp) /* kern_l1pt */ sd s9, 8(sp) /* kern_phys */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201912301329.xBUDTVqG088272>