Skip to content

Commit 380d86e

Browse files
committed
asahi_firmware.isp: Make missing cal files nonfatal
Signed-off-by: Hector Martin <[email protected]>
1 parent 1c88a62 commit 380d86e

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

asahi_firmware/isp.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -100,15 +100,15 @@ def extract_isp(self, data):
100100
dat = data[offset:offset + size]
101101
sensor_name = f"{setfile.sensor:x}_{setfile.name}"
102102

103-
logging.info(f"isp-extract: {found + 1}/{ISP_SETFILE_COUNT}: Found sensor {sensor_name} data at offset {offset:#x}")
103+
log.info(f"isp-extract: {found + 1}/{ISP_SETFILE_COUNT}: Found sensor {sensor_name} data at offset {offset:#x}")
104104
yield FWFile(f"apple/isp_{setfile.name}.dat", dat)
105105

106106
found += 1
107107

108108
if found != ISP_SETFILE_COUNT:
109-
raise ValueError(f"isp-extract: Found {found}/{ISP_SETFILE_COUNT} calibration files. Please report this bug.")
110-
111-
logging.info(f"isp-extract: Found all {found}/{ISP_SETFILE_COUNT} sensor calibration files!")
109+
log.warn(f"isp-extract: Found {found}/{ISP_SETFILE_COUNT} calibration files.")
110+
else:
111+
log.info(f"isp-extract: Found all {found}/{ISP_SETFILE_COUNT} sensor calibration files!")
112112

113113
def load(self, source_path):
114114
if os.path.isdir(source_path):

0 commit comments

Comments
 (0)