Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
L
libtcg
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Anton
libtcg
Commits
01ffc75b
Commit
01ffc75b
authored
22 years ago
by
Fabrice Bellard
Browse files
Options
Downloads
Patches
Plain Diff
avoid pt_regs clash
git-svn-id:
svn://svn.savannah.nongnu.org/qemu/trunk@5
c046a42c-6fe2-441c-8c8c-71466251a162
parent
31e31b8a
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
elf.h
+1
-1
1 addition, 1 deletion
elf.h
linux-user/main.c
+3
-5
3 additions, 5 deletions
linux-user/main.c
linux-user/qemu.h
+2
-2
2 additions, 2 deletions
linux-user/qemu.h
with
6 additions
and
8 deletions
elf.h
+
1
−
1
View file @
01ffc75b
...
...
@@ -6,7 +6,7 @@
typedef
uint32_t
elf_greg_t
;
#define ELF_NGREG (sizeof (struct pt_regs) / sizeof(elf_greg_t))
#define ELF_NGREG (sizeof (struct
target_
pt_regs) / sizeof(elf_greg_t))
typedef
elf_greg_t
elf_gregset_t
[
ELF_NGREG
];
typedef
struct
user_i387_struct
elf_fpregset_t
;
...
...
This diff is collapsed.
Click to expand it.
linux-user/main.c
+
3
−
5
View file @
01ffc75b
...
...
@@ -20,8 +20,6 @@
#include
<stdlib.h>
#include
<stdio.h>
#include
<stdarg.h>
#include
<elf.h>
#include
<endian.h>
#include
<errno.h>
#include
"gemu.h"
...
...
@@ -210,7 +208,7 @@ void usage(void)
int
main
(
int
argc
,
char
**
argv
)
{
const
char
*
filename
;
struct
pt_regs
regs1
,
*
regs
=
&
regs1
;
struct
target_
pt_regs
regs1
,
*
regs
=
&
regs1
;
struct
image_info
info1
,
*
info
=
&
info1
;
Interp_ENV
*
env
;
...
...
@@ -220,12 +218,12 @@ int main(int argc, char **argv)
filename
=
argv
[
1
];
/* Zero out regs */
memset
(
regs
,
0
,
sizeof
(
struct
pt_regs
));
memset
(
regs
,
0
,
sizeof
(
struct
target_
pt_regs
));
/* Zero out image_info */
memset
(
info
,
0
,
sizeof
(
struct
image_info
));
if
(
elf_exec
(
filename
,
argv
+
1
,
__
environ
,
regs
,
info
)
!=
0
)
{
if
(
elf_exec
(
filename
,
argv
+
1
,
environ
,
regs
,
info
)
!=
0
)
{
printf
(
"Error loading %s
\n
"
,
filename
);
exit
(
1
);
}
...
...
This diff is collapsed.
Click to expand it.
linux-user/qemu.h
+
2
−
2
View file @
01ffc75b
...
...
@@ -3,7 +3,7 @@
#include
"thunk.h"
struct
pt_regs
{
struct
target_
pt_regs
{
long
ebx
;
long
ecx
;
long
edx
;
...
...
@@ -44,7 +44,7 @@ struct image_info {
};
int
elf_exec
(
const
char
*
filename
,
char
**
argv
,
char
**
envp
,
struct
pt_regs
*
regs
,
struct
image_info
*
infop
);
struct
target_
pt_regs
*
regs
,
struct
image_info
*
infop
);
void
target_set_brk
(
char
*
new_brk
);
void
syscall_init
(
void
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment