mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-16 08:38:26 +00:00
make volume label different for alt-boot mode
this helps differentiate the modes to end users
This commit is contained in:
parent
4235cba854
commit
395791b70b
1 changed files with 6 additions and 0 deletions
|
|
@ -44,6 +44,12 @@ fn fill_sparse_data(dest: &mut [u8], offset: usize) {
|
|||
let copy_len = (dest.len().saturating_sub(write_start_in_dest)).min(block.len());
|
||||
|
||||
dest[write_start_in_dest..write_start_in_dest + copy_len].copy_from_slice(&block[..copy_len]);
|
||||
#[cfg(feature = "alt-boot1")]
|
||||
// patch the volume name so we can tell alt-boot apart
|
||||
if addr == 0x410000 {
|
||||
// patch ALT over BAO. Assumes that the block is aligned.
|
||||
dest[write_start_in_dest..write_start_in_dest + 3].copy_from_slice(&[0x41, 0x4c, 0x54])
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue