sim: Convert ftruncate64 to GuestABI.
This function was specifying a particular width to getSyscallArg. The new ISA specific ABIs now handle that automatically. Change-Id: I141655d3bcb78f56c2a9278d140dfbc0d69e1ff4 Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/23454 Reviewed-by: Bobby R. Bruce <bbruce@ucdavis.edu> Maintainer: Gabe Black <gabeblack@google.com> Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
@@ -613,12 +613,10 @@ truncate64Func(SyscallDesc *desc, int num, ThreadContext *tc,
|
||||
}
|
||||
|
||||
SyscallReturn
|
||||
ftruncate64Func(SyscallDesc *desc, int num, ThreadContext *tc)
|
||||
ftruncate64Func(SyscallDesc *desc, int num, ThreadContext *tc,
|
||||
int tgt_fd, int64_t length)
|
||||
{
|
||||
int index = 0;
|
||||
auto p = tc->getProcessPtr();
|
||||
int tgt_fd = p->getSyscallArg(tc, index);
|
||||
int64_t length = p->getSyscallArg(tc, index, 64);
|
||||
|
||||
auto ffdp = std::dynamic_pointer_cast<FileFDEntry>((*p->fds)[tgt_fd]);
|
||||
if (!ffdp)
|
||||
|
||||
@@ -235,8 +235,8 @@ SyscallReturn truncate64Func(SyscallDesc *desc, int num, ThreadContext *tc,
|
||||
Addr pathname, int64_t length);
|
||||
|
||||
/// Target ftruncate64() handler.
|
||||
SyscallReturn ftruncate64Func(SyscallDesc *desc, int num, ThreadContext *tc);
|
||||
|
||||
SyscallReturn ftruncate64Func(SyscallDesc *desc, int num, ThreadContext *tc,
|
||||
int tgt_fd, int64_t length);
|
||||
|
||||
/// Target umask() handler.
|
||||
SyscallReturn umaskFunc(SyscallDesc *desc, int num, ThreadContext *tc);
|
||||
|
||||
Reference in New Issue
Block a user