-
Notifications
You must be signed in to change notification settings - Fork 11
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
Add orin-nx and lenovo-x1 boot tests #43
Conversation
ghaf-test-boot.groovy
Outdated
if(["lenovo-x1"].contains(params.DEVICE_CONFIG_NAME)) { | ||
echo "Wiping filesystem..." | ||
def SECTOR = 512 | ||
def MIB_TO_SECTORS = 20480 | ||
// Disk size in 512-byte sectors | ||
def SECTORS = sh(script: "sudo blockdev --getsz /dev/${dev}", returnStdout: true).trim() | ||
// Unmount possible mounted filesystems | ||
sh "sync; sudo umount -q /dev/${dev}* || true" | ||
// Wipe first 10MiB of disk | ||
sh "sudo dd if=/dev/zero of=/dev/${dev} bs=${SECTOR} count=${MIB_TO_SECTORS} conv=fsync status=none" | ||
// Wipe last 10MiB of disk | ||
sh "sudo dd if=/dev/zero of=/dev/${dev} bs=${SECTOR} count=${MIB_TO_SECTORS} seek=\$(( ${SECTORS} - ${MIB_TO_SECTORS} )) conv=fsync status=none" | ||
} |
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.
We don't have to do it in this PR, but frankly, I think the details of how the flashing needs to happen should come from a script in Ghaf repo, so we would not have to worry about such details in the Jenkins pipeline.
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.
Yes this is just a working one for those new devices and let's improve this later.
Add orin-nx and lenovo-x1 boot tests to ghah-infra mainline. Signed-off-by: Ville-Pekka Juntunen <[email protected]>
d7415ea
to
1ce7d9c
Compare
Signed-off-by: Henri Rosten <[email protected]>
Signed-off-by: Henri Rosten <[email protected]>
Add orin-nx and lenovo-x1 boot tests to ghah-infra mainline.