Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F150419718
D29401.id86216.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
837 B
Referenced Files
None
Subscribers
None
D29401.id86216.diff
View Options
Index: sys/arm64/arm64/vfp.c
===================================================================
--- sys/arm64/arm64/vfp.c
+++ sys/arm64/arm64/vfp.c
@@ -208,7 +208,15 @@
void
vfp_reset_state(struct thread *td, struct pcb *pcb)
{
+ /* Discard the threads VFP state before resetting it */
critical_enter();
+ vfp_discard(td);
+ critical_exit();
+
+ /*
+ * Clear the thread state. The VFP is disabled and is not the current
+ * VFP thread so we won't change any of these on context switch.
+ */
bzero(&pcb->pcb_fpustate.vfp_regs, sizeof(pcb->pcb_fpustate.vfp_regs));
KASSERT(pcb->pcb_fpusaved == &pcb->pcb_fpustate,
("pcb_fpusaved should point to pcb_fpustate."));
@@ -216,8 +224,6 @@
pcb->pcb_fpustate.vfp_fpsr = 0;
pcb->pcb_vfpcpu = UINT_MAX;
pcb->pcb_fpflags = 0;
- vfp_discard(td);
- critical_exit();
}
void
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Apr 2, 2:08 AM (6 h, 35 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
30698967
Default Alt Text
D29401.id86216.diff (837 B)
Attached To
Mode
D29401: Discard the arm64 VFP state before resetting it
Attached
Detach File
Event Timeline
Log In to Comment