#
29363fb4 |
|
23-Nov-2023 |
Warner Losh <imp@FreeBSD.org> |
sys: Remove ancient SCCS tags. Remove ancient SCCS tags from the tree, automated scripting, with two minor fixup to keep things compiling. All the common forms in the tree were removed with a perl script. Sponsored by: Netflix
|
#
031beb4e |
|
16-Aug-2023 |
Warner Losh <imp@FreeBSD.org> |
sys: Remove $FreeBSD$: one-line sh pattern Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
|
#
b926b6db |
|
11-Jan-2023 |
Mitchell Horne <mhorne@FreeBSD.org> |
riscv: always include frame pointer Specifically it is missing in kernel modules, meaning a proper backtrace can't be constructed. Reviewed by: jhb MFC after: 1 week Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D37657
|
#
384bd0b5 |
|
16-Jan-2021 |
Emmanuel Vadot <manu@FreeBSD.org> |
riscv: Add the device-tree path to the include path
|
#
e1a6e0e3 |
|
22-May-2020 |
Mitchell Horne <mhorne@FreeBSD.org> |
Simplify the RISC-V kernel linker invocation Remove our custom SYSTEM_LD definition. This generates program headers that are more consistent with other architectures, and more importantly, are in line with what loader(8) expects when loading a kernel. As noted in https://reviews.freebsd.org/D22920, there is no apparent reason why the kernel would need a writable text segment, so removal of the -N flag isn't likely to cause issue. Reviewed by: kp, br MFC after: 1 week Differential Revision: https://reviews.freebsd.org/D24909
|
#
02343a67 |
|
27-Apr-2020 |
John Baldwin <jhb@FreeBSD.org> |
Retire the GENERICSF kernel config. Now that hw.machine_arch handles soft-float vs hard-float there is no longer a reason for this config. Submitted by: mhorne (kern.mk hunk) Reviewed by: imp (earlier version), kp Sponsored by: DARPA Differential Revision: https://reviews.freebsd.org/D24544
|
#
6b72948d |
|
27-Feb-2020 |
Warner Losh <imp@FreeBSD.org> |
Better check for floating point type. Use __riscv_flen instead of __riscv_float_abi_soft. While the latter works for userland (and one could argue it's more correct), it fails for the kernel. We compile the kernel with -mabi=lp64 (eg soft float abi) to avoid floating point instructions in the kernel. We also compile the kernel -march=rv64imafdc for hard float kernels (eg those with options FPE), but with -march=rv64imac for softfloat kernels (eg those with FPE). Since we do this, in the kernel (as in userland) __riscv_flen will be defined for 'riscv64' and not for 'riscv64sf'. This also removes the -DMACHINE_ARCH hack now that it's no longer needed. Longer term, we should return the ABI from the sysctl hw.machine_arch like on amd64 for i386 binaries. Suggested by: mhorne@ Differential Revision: https://reviews.freebsd.org/D23813
|
#
990a56e8 |
|
24-Feb-2020 |
Warner Losh <imp@FreeBSD.org> |
Add a soft-float riscv kernel config GENERICSF is just like GENERIC, only creates a soft-float kernel. Omit it from the universe build for now. Reviewed by: philip Differential Revision: https://reviews.freebsd.org/D23812
|
#
1f8198e3 |
|
23-Feb-2020 |
Warner Losh <imp@FreeBSD.org> |
Use MACHINE_ARCH instead of TARGET_ARCH TARGET_ARCH is only for use in Makefile.inc1 contexts. MACHINE_ARCH is the preferred thing to set. Makefile.inc1 sets MACHINE_ARCH in the cross build case, and make sets it in the native build case. This will fix anybody doing a native build. Add a comment for why we have to do this dance so when/if the problem with CFLAGS is fixed for the kernel this workaround can be removed.
|
#
6ebb17df |
|
22-Feb-2020 |
Kristof Provost <kp@FreeBSD.org> |
riscv: Set MACHINE_ARCH correctly MACHINE_ARCH sets the hw.machine_arch sysctl in the kernel. In userspace it sets MACHINE_ARCH in bmake, which bsd.cpu.mk uses to configure the target ABI for ports. For riscv64sf builds (i.e. soft-float) that needs to be riscv64sf, but the sysctl didn't reflect that. It is static. Set the define from the riscv makefile so that we correctly reflect our actual build (i.e. riscv64 or riscv64sf), depending on what TARGET_ARCH we were built with. That still doesn't satisfy userspace builds (e.g. bmake), so check if we're building with a software-floating point toolchain there. That check doesn't work in the kernel, because it never uses floating point. Reviewed by: philip (previous version), mhorne Sponsored by: Axiado Differential Revision: https://reviews.freebsd.org/D23741
|
#
febe2bd2 |
|
03-Feb-2020 |
Alex Richardson <arichardson@FreeBSD.org> |
Set the LMA of the riscv kernel to the OpenSBI jump target by default This allows us to boot FreeBSD RISCV on QEMU using the -kernel command line options. When using that option, QEMU maps the kernel ELF file to the addresses specified in the LMAs in the program headers. Since version 4.2 QEMU ships with OpenSBI fw_jump by default so this allows booting FreeBSD using the following command line: qemu-system-riscv64 -bios default -kernel /.../boot/kernel/kernel -nographic -M virt Without this change the -kernel option cannot be used since the LMAs start at address zero and QEMU already maps a ROM to these low physical addresses. For targets that require a different kernel LMA the make variable KERNEL_LMA can be overwritten in the config file. For example, adding `makeoptions KERNEL_LMA=0xc0200000` will create an ELF file that will be loaded at 0xc0200000. Before: There are 4 program headers, starting at offset 64 Program Headers: Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align LOAD 0x001000 0xffffffc000000000 0x0000000000000000 0x75e598 0x8be318 RWE 0x1000 DYNAMIC 0x71fb20 0xffffffc00071eb20 0x000000000071eb20 0x000100 0x000100 RW 0x8 GNU_STACK 0x000000 0x0000000000000000 0x0000000000000000 0x000000 0x000000 RW 0x0 NOTE 0x693400 0xffffffc000692400 0x0000000000692400 0x000024 0x000024 R 0x4 After: There are 4 program headers, starting at offset 64 Program Headers: Type Offset VirtAddr PhysAddr FileSiz MemSiz Flg Align LOAD 0x001000 0xffffffc000000000 0x0000000080200000 0x734198 0x893e18 RWE 0x1000 DYNAMIC 0x6f7810 0xffffffc0006f6810 0x00000000808f6810 0x000100 0x000100 RW 0x8 GNU_STACK 0x000000 0x0000000000000000 0x0000000000000000 0x000000 0x000000 RW 0x0 NOTE 0x66ca70 0xffffffc00066ba70 0x000000008086ba70 0x000024 0x000024 R 0x4 Reviewed By: br, mhorne (earlier version) Differential Revision: https://reviews.freebsd.org/D23436
|
#
eb342591 |
|
25-Dec-2019 |
Ian Lepore <ian@FreeBSD.org> |
Revert r356077, apparently the change doesn't work after all (failed to build in CI).
|
#
0b15fc29 |
|
25-Dec-2019 |
Ian Lepore <ian@FreeBSD.org> |
For riscv kernel builds, add -N to LDFLAGS instead of replacing the SYSTEM_LD variable. This avoids duplicating the contents of SYSTEM_LD from kern.pre.mk just to add the -N flag to it. If the basic linker command ever needs to be changed, this will be one less place that has to be found and fixed. Some testing by kp@ indicates that the -N flag may not be needed at all, so a comment to that effect is also added, and the -N flag may be removed in a followup commit. Differential Revision: https://reviews.freebsd.org/D22920
|
#
e47edf50 |
|
17-Jul-2018 |
Kyle Evans <kevans@FreeBSD.org> |
Revert r336353 completely based on protest; compatibility shims incoming
|
#
59996cb2 |
|
16-Jul-2018 |
Kyle Evans <kevans@FreeBSD.org> |
Revert 336358 and step away fron machine for the day... VERSREQ < 7.+ physically will not work with new config(8) due to major bump, which is why I bumped it in the first place... Back to the original version
|
#
78a25cc7 |
|
16-Jul-2018 |
Kyle Evans <kevans@FreeBSD.org> |
Partially revert r336353: sys/conf/* %VERSREQ bumps The changes made in r335998 don't strictly require a newer config(8), though it is advised. The %VERSREQ bumps were premature.
|
#
2df45ae0 |
|
16-Jul-2018 |
Kyle Evans <kevans@FreeBSD.org> |
config(8): Bump major version after r335998 config-generated hints.c/env.c from r335998 and later are incompatible with earlier kernels due to no longer setting envmode/hintmode. A minor bump for this is insufficient, as matching major version with a later minor version is still viewed as backwards-compatible. This was an MI kernel change, soo all VERSREQ's are bumped.
|
#
af19cc59 |
|
10-Aug-2017 |
Ruslan Bukin <br@FreeBSD.org> |
Support for v1.10 (latest) of RISC-V privilege specification. New version is not compatible on supervisor mode with v1.9.1 (previous version). Highlights: o BBL (Berkeley Boot Loader) provides no initial page tables anymore allowing us to choose VM, to build page tables manually and enable MMU in S-mode. o SBI interface changed. o GENERIC kernel. FDT is now chosen standard for RISC-V hardware description. DTB is now provided by Spike (golden model simulator). This allows us to introduce GENERIC kernel. However, description for console and timer devices is not provided in DTB, so move these devices temporary to nexus bus. o Supervisor can't access userspace by default. Solution is to set SUM (permit Supervisor User Memory access) bit in sstatus register. o Compressed extension is now turned on by default. o External GCC 7.1 compiler used. o _gp renamed to __global_pointer$ o Compiler -march= string is now in use allowing us to choose required extensions (compressed, FPU, atomic, etc). Sponsored by: DARPA, AFRL Differential Revision: https://reviews.freebsd.org/D11800
|
#
fa851a8b |
|
24-May-2016 |
Ruslan Bukin <br@FreeBSD.org> |
Set dependencies for genassym.c. This fixes non-parallel build.
|
#
d52d6d7c |
|
10-Mar-2016 |
Ruslan Bukin <br@FreeBSD.org> |
Add support for ddb(4). Sponsored by: DARPA, AFRL Sponsored by: HEIF5
|
#
28029b68 |
|
29-Jan-2016 |
Ruslan Bukin <br@FreeBSD.org> |
Welcome the RISC-V 64-bit kernel. This is the final step required allowing to compile and to run RISC-V kernel and userland from HEAD. RISC-V is a completely open ISA that is freely available to academia and industry. Thanks to all the people involved! Special thanks to Andrew Turner, David Chisnall, Ed Maste, Konstantin Belousov, John Baldwin and Arun Thomas for their help. Thanks to Robert Watson for organizing this project. This project sponsored by UK Higher Education Innovation Fund (HEIF5) and DARPA CTSRD project at the University of Cambridge Computer Laboratory. FreeBSD/RISC-V project home: https://wiki.freebsd.org/riscv Reviewed by: andrew, emaste, kib Relnotes: Yes Sponsored by: DARPA, AFRL Sponsored by: HEIF5 Differential Revision: https://reviews.freebsd.org/D4982
|