zig fmt
This commit is contained in:
@@ -2023,7 +2023,10 @@ fn faultNull() void {
|
||||
// access). `allowzero` skips the same null check on the cast. The write then
|
||||
// hits the unmapped page 0 and takes a real hardware #PF.
|
||||
var address: u64 = 0;
|
||||
address = asm ("" : [ret] "=r" (-> u64) : [in] "0" (address));
|
||||
address = asm (""
|
||||
: [ret] "=r" (-> u64),
|
||||
: [in] "0" (address),
|
||||
);
|
||||
const p: *allowzero volatile u64 = @ptrFromInt(address);
|
||||
p.* = 1;
|
||||
}
|
||||
@@ -2049,8 +2052,7 @@ fn faultDoubleFault() void {
|
||||
\\ud2
|
||||
:
|
||||
: [sp] "r" (bad_sp),
|
||||
: .{ .memory = true }
|
||||
);
|
||||
: .{ .memory = true });
|
||||
bad_sp += 0;
|
||||
}
|
||||
|
||||
@@ -2069,8 +2071,7 @@ fn apDoubleFaultTask() void {
|
||||
\\ud2
|
||||
:
|
||||
: [sp] "r" (bad_sp),
|
||||
: .{ .memory = true }
|
||||
);
|
||||
: .{ .memory = true });
|
||||
bad_sp += 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user