diff options
author | Michael Pratt <mpratt@google.com> | 2019-04-10 17:59:02 -0700 |
---|---|---|
committer | Shentubot <shentubot@google.com> | 2019-04-10 18:00:18 -0700 |
commit | cc48969bb72e3efdc22746c5e7463b79b1942c2b (patch) | |
tree | 8fe3c01ba81b042a8ab9d7b9751b3c0c59e03a75 /pkg/sentry/arch | |
parent | d93d19fd4eefdfd868919a73c9498e7da7eb9258 (diff) |
Internal change
PiperOrigin-RevId: 242978508
Change-Id: I0ea59ac5ba1dd499e87c53f2e24709371048679b
Diffstat (limited to 'pkg/sentry/arch')
-rw-r--r-- | pkg/sentry/arch/arch_x86.go | 4 | ||||
-rw-r--r-- | pkg/sentry/arch/signal_amd64.go | 11 |
2 files changed, 8 insertions, 7 deletions
diff --git a/pkg/sentry/arch/arch_x86.go b/pkg/sentry/arch/arch_x86.go index e50a76083..c8bf0e7f2 100644 --- a/pkg/sentry/arch/arch_x86.go +++ b/pkg/sentry/arch/arch_x86.go @@ -306,8 +306,8 @@ func (s *State) ptraceGetRegs() syscall.PtraceRegs { // FS/GS_TLS_SEL when fs_base/gs_base is a 64-bit value. (We do the // same in PtraceSetRegs.) // - // TODO: Remove this fixup since newer Linux doesn't have - // this behavior anymore. + // TODO: Remove this fixup since newer Linux + // doesn't have this behavior anymore. if regs.Fs == 0 && regs.Fs_base <= 0xffffffff { regs.Fs = _FS_TLS_SEL } diff --git a/pkg/sentry/arch/signal_amd64.go b/pkg/sentry/arch/signal_amd64.go index f7f054b0b..c9de36897 100644 --- a/pkg/sentry/arch/signal_amd64.go +++ b/pkg/sentry/arch/signal_amd64.go @@ -392,15 +392,16 @@ func (c *context64) SignalSetup(st *Stack, act *SignalAct, info *SignalInfo, alt Sigset: sigset, } - // TODO: Set SignalContext64.Err, Trapno, and Cr2 based on - // the fault that caused the signal. For now, leave Err and Trapno - // unset and assume CR2 == info.Addr() for SIGSEGVs and SIGBUSes. + // TODO: Set SignalContext64.Err, Trapno, and Cr2 + // based on the fault that caused the signal. For now, leave Err and + // Trapno unset and assume CR2 == info.Addr() for SIGSEGVs and + // SIGBUSes. if linux.Signal(info.Signo) == linux.SIGSEGV || linux.Signal(info.Signo) == linux.SIGBUS { uc.MContext.Cr2 = info.Addr() } - // "... the value (%rsp+8) is always a multiple of 16 (...) when control is - // transferred to the function entry point." - AMD64 ABI + // "... the value (%rsp+8) is always a multiple of 16 (...) when + // control is transferred to the function entry point." - AMD64 ABI ucSize := binary.Size(uc) if ucSize < 0 { // This can only happen if we've screwed up the definition of |