Page MenuHomeFreeBSD

Round TF_SIZE up to the stack alignment (16-bytes).
ClosedPublic

Authored by brooks on Sep 4 2020, 5:58 PM.
Tags
None
Referenced Files
F111184320: D26328.id.diff
Fri, Feb 28, 1:37 PM
F111148406: D26328.id.diff
Fri, Feb 28, 2:07 AM
Unknown Object (File)
Tue, Feb 25, 3:44 AM
Unknown Object (File)
Mon, Feb 24, 1:47 AM
Unknown Object (File)
Fri, Feb 21, 9:55 AM
Unknown Object (File)
Thu, Feb 20, 5:14 PM
Unknown Object (File)
Tue, Feb 18, 12:01 PM
Unknown Object (File)
Jan 25 2025, 12:03 AM
Subscribers

Details

Summary

The kernel adjusts the stack by TF_SIZE and the RISC-V ABI requires
that it remain 16-byte aligned.

Test Plan

works on CheriBSD

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

brooks requested review of this revision.Sep 4 2020, 5:58 PM
brooks created this revision.
mhorne added inline comments.
sys/riscv/riscv/genassym.c
90 ↗(On Diff #76655)

It seems to me that STACKALIGNBYTES should really just be 16.

This revision is now accepted and ready to land.Sep 4 2020, 6:43 PM
sys/riscv/riscv/genassym.c
90 ↗(On Diff #76655)

I like this documents what we're doing. I didn't use STACKALIGNBYTES in the D26327 because in CheriBSD our roundup2 isn't assembly friendly (we use a type-preserving builtin).

This revision was automatically updated to reflect the committed changes.