Skip to content

resources: Add files to make 6.8.12 riscv kernel and gem5 bridge driver #67

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

Open
wants to merge 3 commits into
base: stable
Choose a base branch
from

Conversation

Harshil2107
Copy link
Contributor

No description provided.

"<wait>"
]
iso_checksum = "sha256:ddf1ebb56454ef37e88d6de8aefdef7180fc9a2328a3bf8cff02f7a043e7127b"
iso_urls = ["/home/harshilp/gem5-resources-worktrees/make-riscv-kernel/src/riscv-fs/riscv-ubuntu-22.04-24.04/disk-image-24.04/riscv-ubuntu"]
Copy link
Contributor

Choose a reason for hiding this comment

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

Remember to change this once the base disk image is up

make ARCH=riscv CROSS_COMPILE=riscv64-linux-gnu- -j 32 && \
make ARCH=riscv CROSS_COMPILE=riscv64-linux-gnu- INSTALL_MOD_PATH=/workspace/output modules_install

RUN git clone https://github.com/nkrim/gem5.git --depth=1 --filter=blob:none --no-checkout --sparse --single-branch --branch=gem5-bridge && \
Copy link
Contributor

@erin-le erin-le Feb 19, 2025

Choose a reason for hiding this comment

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

Remember to change this later

@@ -40,10 +45,11 @@ rm /etc/update-motd.d/*
echo "Building and installing gem5-bridge (m5) and libm5"

# Just get the files we need
git clone https://github.com/gem5/gem5.git --depth=1 --filter=blob:none --no-checkout --sparse --single-branch --branch=stable
git clone https://github.com/gem5/gem5.git --depth=1 --filter=blob:none --no-checkout --sparse --single-branch --branch=release-staging-v24-1-1-0
Copy link
Contributor

Choose a reason for hiding this comment

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

Remember to change this back to stable once staging is merged

@erin-le erin-le self-requested a review February 24, 2025 20:24
Copy link
Contributor

@erin-le erin-le left a comment

Choose a reason for hiding this comment

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

I tested building and running the RISCV base and RISCV NPB disk images. I found that the building process was somewhat flaky, but was ultimately able to get it to work.
Previously, the RISCV kernel extraction failed on a machine with Docker version 27.5.0, but succeeded on machines with Docker version 27.3.1. However, upon re-testing, the kernel extraction succeeded on Docker version 27.5.0. I also found that the build process for the disk images would sometimes time out, likely due to timing issues.

After building the disk images, I ran simulations for booting the base disk image and running UA size S on the NPB disk image. Both ran as expected.

@@ -53,7 +53,7 @@ source "qemu" "initialize" {
headless = "true"
disk_image = "true"
boot_command = [
"<wait120>",
"<wait260>",
Copy link
Contributor

Choose a reason for hiding this comment

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

Need to add documentation in README.md or BUILDING.md about how users can/might need to adjust the wait times to avoid timing issues when building the disk image on their own systems. It would also be nice to have a comment in the Packer file.

format = "raw"
headless = "true"
disk_image = "true"
boot_command = ["<wait90>",
Copy link
Contributor

Choose a reason for hiding this comment

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

Need to add documentation in README.md or BUILDING.md about how users can/might need to adjust the wait times to avoid timing issues when building the disk image on their own systems. It would also be nice to have a comment in the Packer file.

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.

2 participants