Skip to content

feat: update deps (especially "syscalls")#113

Merged
AsakuraMizu merged 2 commits intomainfrom
pr/update-deps
Feb 7, 2026
Merged

feat: update deps (especially "syscalls")#113
AsakuraMizu merged 2 commits intomainfrom
pr/update-deps

Conversation

@AsakuraMizu
Copy link
Contributor

No description provided.

Copilot AI review requested due to automatic review settings February 7, 2026 14:51
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates dependencies (notably switching syscalls to a crates.io release) and adjusts syscall dispatch/availability across architectures.

Changes:

  • Bump arceos submodule revision.
  • Switch syscalls dependency from a git rev to version = "0.8.1".
  • Add cfg gating for renameat/fstatat syscall handling on riscv64.

Reviewed changes

Copilot reviewed 4 out of 5 changed files in this pull request and generated 2 comments.

File Description
arceos Updates the submodule commit to pick up upstream changes.
api/src/syscall/mod.rs Adjusts syscall match arms with new architecture cfg gating.
api/src/syscall/fs/ctl.rs Gates sys_renameat on riscv64 to align with syscall availability.
api/Cargo.toml Moves syscalls from a git dependency to a crates.io version.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 481 to 486
pub fn sys_rename(old_path: *const c_char, new_path: *const c_char) -> AxResult<isize> {
sys_renameat(AT_FDCWD, old_path, AT_FDCWD, new_path)
}

#[cfg(not(target_arch = "riscv64"))]
pub fn sys_renameat(
Copy link

Copilot AI Feb 7, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sys_rename unconditionally calls sys_renameat, but sys_renameat is now behind #[cfg(not(target_arch = \"riscv64\"))]. On riscv64 this will fail to compile because sys_renameat is not defined. Fix by either (a) also gating sys_rename with the same cfg, or (b) providing a riscv64 implementation of sys_renameat (or changing sys_rename to call an always-available function like sys_renameat2).

Copilot uses AI. Check for mistakes.
Sysno::symlinkat => sys_symlinkat(uctx.arg0() as _, uctx.arg1() as _, uctx.arg2() as _),
#[cfg(target_arch = "x86_64")]
Sysno::rename => sys_rename(uctx.arg0() as _, uctx.arg1() as _),
#[cfg(not(target_arch = "riscv64"))]
Copy link

Copilot AI Feb 7, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The riscv64 gating for renameat is now split between the syscall dispatcher (handle_syscall) and the function definition (sys_renameat in fs/ctl.rs). Consider centralizing the architecture availability in one place (e.g., gate the exported syscall functions uniformly, or gate only the dispatch paths) to reduce the risk of mismatched cfgs causing build errors or dead code paths.

Suggested change
#[cfg(not(target_arch = "riscv64"))]

Copilot uses AI. Check for mistakes.
@AsakuraMizu AsakuraMizu merged commit 21da36f into main Feb 7, 2026
13 checks passed
@AsakuraMizu AsakuraMizu deleted the pr/update-deps branch February 7, 2026 15:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant