-
Notifications
You must be signed in to change notification settings - Fork 49
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
resources: add scripts to make and extract arm kernel #60
base: stable
Are you sure you want to change the base?
Conversation
I am adding gem5-bridge driver based on #48 |
@@ -47,21 +61,29 @@ if [ -z "$ISA" ]; then | |||
fi | |||
|
|||
# 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/nkrim/gem5.git --depth=1 --filter=blob:none --no-checkout --sparse --single-branch --branch=gem5-bridge |
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.
I assume this is just a placeholder, but don't forget to fix this.
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.
I tested this by building the disk image, then using the disk image and kernel as resources in a script that Harshil provided. It boots, so this LGTM
I think going for the method that I used in the 22.04 image, is better than the one that is used in 24.04 image. The only issue is that you have to give write permissions to the the directory we are mounting to the docker to get the kernel and the modules. does this look good, If so I can update the 24.04 image as well |
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
in the `/workspace/source`, lets get the driver files | ||
|
||
```bash | ||
git clone https://github.com/nkrim/gem5.git --depth=1 --filter=blob:none --no-checkout --sparse --single-branch --branch=gem5-bridge |
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.
get this committed to gem5 and use the gem5 source.
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
I built and tests the gem5 bridge driver with both the 22.04 and 24.04 disk images. I built the base image and then built the npb image using this base image. I was able to run the benchmark without sudo in gem5. The only blocker to his now should be getting the m5 driver code in gem5. |
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.
Looks good overall. There are just a few typos and minor things that could be added in make-kernel-and-gem5-bridge-driver.md
.
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
rm -rf build | ||
|
||
# Use bash as the default shell | ||
CMD ["/bin/bash"] |
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.
Should be removed so the image won't be used interactively.
make -j 32 && \ | ||
make 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 && \ |
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.
Must be changed before merging
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
src/ubuntu-generic-diskimages/make-kernel-and-gem5-bridge-driver.md
Outdated
Show resolved
Hide resolved
@Harshil2107 Please update the documentation on how to increase the size of the disk-image. I would like to see an example of how each size is calculated--- rather than saying size A has to be at least 1 megabyte more than size B. In my experience when I tried to resize the image for ~20GB, this is what I had to do. UEFI_size: First partition size defined in http/user-data; I am assume it is the size of the partition allocated for UEFI. This in your case is the magical number 564133888. Using this information, the disk_size is equal to 564133888 + 20909654016 + 1048576 = 21474836480 (which btw is exactly 20GiB (GibiBytes). Please note that the unit for disk_size in .hcl is not MibiBytes (2^20), it is rather MegaBytes (10^6). Which means you have to divide the final number by 1_000_000 which will give you 21474.833. In my case, I just rounded that to 21600. |
This worked btw! |
@mahyarsamani I updated the documentation with example #65 |
I think the iso link for 24.04 is outdated. |
I want to propose holding off on getting this merged. I faced a few challenges when I tried to use the scripts here to get my packages installed and get them to work without effecting other parts of the system setup (e.g. [email protected], gem5_init.sh, ...). I have created a draft pr for it here: #68 |
No description provided.