disc: log adaptive patch speed transitions; issue SET CD SPEED max unconditionally
Two recovery-path fixes: - patch: log the per-range speed transitions (INFO, phase="patch_speed") — each range enters at 0xFFFF (max) and drops to 0x0000 (slow recovery) on its first read failure. Previously the adaptive-speed behavior was invisible in the logs. - drive init: issue the generic SET CD SPEED max UNCONDITIONALLY at drive-open, not only when a firmware unlocker matched. A stock-mode BD/UHD drive (no firmware unlock) was left riplocked because the call sat inside the unlocker-matched branch.
This commit is contained in:
@@ -1957,6 +1957,14 @@ impl Disc {
|
||||
// (below), dropping to the slow recovery speed for the rest of the
|
||||
// range and arming the inter-range cooldown.
|
||||
reader.set_speed(0xFFFF);
|
||||
tracing::info!(
|
||||
target: "freemkv::disc",
|
||||
phase = "patch_speed",
|
||||
range_lba = *range_pos / 2048,
|
||||
range_sectors,
|
||||
speed = "0xFFFF",
|
||||
"patch: range entering at MAX read speed (drops to slow recovery on first failure)"
|
||||
);
|
||||
state.current_batch = initial_batch;
|
||||
let mut range_slowed = false;
|
||||
loop {
|
||||
@@ -2082,9 +2090,17 @@ impl Disc {
|
||||
// Idempotent — only the first failure issues SET CD SPEED.
|
||||
if !range_slowed {
|
||||
reader.set_speed(0x0000);
|
||||
tracing::info!(
|
||||
target: "freemkv::disc",
|
||||
phase = "patch_speed",
|
||||
lba,
|
||||
speed = "0x0000",
|
||||
"patch: range dropped to slow recovery speed on first read failure"
|
||||
);
|
||||
range_slowed = true;
|
||||
cooldown_pending = true;
|
||||
}
|
||||
|
||||
match handle_read_failure(
|
||||
&mut state,
|
||||
&frame,
|
||||
|
||||
Reference in New Issue
Block a user