-
Notifications
You must be signed in to change notification settings - Fork 57
TCG, fix: fix TCG mode #197
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
xiezyang
commented
Dec 12, 2025
- Isolate TCG mode implementation from other optimizations
- Redefine tb_find, tb_gen_code, cpu_tb_exec for TCG mode
|
@codex review |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
linux-user/main.c
Outdated
| exec_path = argv[optind]; | ||
| #ifdef CONFIG_LATX | ||
| real_path = realpath(exec_path, (char *)malloc(MAX_PATH)); | ||
| #endif |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Always initialize real_path for user emulation
The realpath() call is now wrapped in #ifdef CONFIG_LATX, so in non-LATX builds real_path remains NULL. The readlink handler in linux-user/syscall.c falls back to this global when realpath(exec_path) fails (e.g., guest readlink("/proc/self/exe") after the binary has been removed or when the path exceeds PATH_MAX), and will dereference the NULL pointer. Move the initialization out of the CONFIG_LATX guard so real_path is populated for all user-mode runs.
Useful? React with 👍 / 👎.
Signed-off-by: Zhaoyang Xie <xie_zyang@163.com>
Signed-off-by: Zhaoyang Xie <xie_zyang@163.com>
Signed-off-by: Zhaoyang Xie <xie_zyang@163.com>
Signed-off-by: Zhaoyang Xie <xie_zyang@163.com>
Signed-off-by: Zhaoyang Xie <xie_zyang@163.com>
Signed-off-by: Zhaoyang Xie <xie_zyang@163.com>
Signed-off-by: liuchaoyi <liuchaoyi@loongson.cn>
translate atomic insns without alignment check, use SIGBUS to interpret.
Signed-off-by: Zhaoyang Xie <xie_zyang@163.com>
The HID ioctl handling code was incorrectly intercepting v4l2 ioctl commands due to overlapping ioctl number (nr) values. Specifically, v4l2 commands with nr=4 were matching HIDIOCGRAWNAME(0) which also has nr=4.
Signed-off-by: liuchaoyi <liuchaoyi@loongson.cn>
… memory operand Signed-off-by: liuchaoyi <liuchaoyi@loongson.cn>
Signed-off-by: liuchaoyi <liuchaoyi@loongson.cn>
Signed-off-by: Zhaoyang Xie <xie_zyang@163.com>
Signed-off-by: Zhaoyang Xie <xie_zyang@163.com>
… cpu_tb_exec Signed-off-by: Zhaoyang Xie <xie_zyang@163.com>