DriveProfile with all per-drive fields, drive.rs uses init() as single entry
DriveProfile now has every field traced from firmware: - drive_signature, unlock_init_value, unlock_response_size_minus_init - ld_microcode (base64, ~1888B firmware payload) - hardware_register_a_cdb, hardware_register_b_cdb (10B pre-built CDBs) - drive_nominal_speed_cdb (12B calibration speed) - speed_zone_table (28B), speed_calc_table (25B) drive.rs simplified: - open() calls init() instead of unlock() - init() is the ONLY entry point — handles full dispatch sequence internally - Removed read_config, read_register, maintain_speed, read_sectors from public API - Added set_read_speed() for per-zone speed during content reads - disc.rs updated to call init() instead of unlock() Compiles clean, all tests pass.
This commit is contained in:
+1
-3
@@ -793,12 +793,10 @@ impl Disc {
|
||||
detail: format!("title index {} out of range (have {})", title_idx, self.titles.len()),
|
||||
})?;
|
||||
|
||||
// Try to unlock for raw reads. Non-fatal — BD discs work without unlock.
|
||||
if !session.is_unlocked() {
|
||||
let _ = session.unlock();
|
||||
let _ = session.init();
|
||||
}
|
||||
|
||||
// Set max read speed — nothing else. No calibration, no probes.
|
||||
let speed_cdb = crate::scsi::build_set_cd_speed(0xFFFF);
|
||||
let mut dummy = [0u8; 0];
|
||||
let _ = session.scsi_execute(&speed_cdb, crate::scsi::DataDirection::None, &mut dummy, 5_000);
|
||||
|
||||
Reference in New Issue
Block a user