From 5b8af0721d57cb334547ff203647eb9ce17c17ca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Berkay=20K=C3=B6sebay?= Date: Fri, 4 Dec 2026 14:50:52 +0100 Subject: [PATCH] devices/n42: Ship the camera ISP firmware MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Take H4ISPFIRMWARE and the 31 sensor module set-files from the armv7s H4ISPServices image in the 12H321 system volume. Pin the cache and every file installed for the A6 camera driver. Assisted-by: LLM Signed-off-by: Berkay Kösebay --- devices/n42/firmware.json | 358 ++++++++++++++++++++++++++++++++++++++ docs/firmware-recipes.md | 2 + 2 files changed, 360 insertions(+) diff --git a/devices/n42/firmware.json b/devices/n42/firmware.json index bba3b5ec..25dedad6 100644 --- a/devices/n42/firmware.json +++ b/devices/n42/firmware.json @@ -55,6 +55,13 @@ ] }, "sha256": "a1b855d41993968b40005e886f7ac11c8c3abb42aa0987e005eec4e6cb2a2285" + }, + "dyld_shared_cache_armv7s": { + "ipsw": { + "rootfs": "System/Library/Caches/com.apple.dyld/dyld_shared_cache_armv7s" + }, + "device": "/System/Library/Caches/com.apple.dyld/dyld_shared_cache_armv7s", + "sha256": "f640e8a12e5e660e6059ed1a97461c13678a38503c6e9410d6154db22baed9d8" } }, "outputs": [ @@ -121,6 +128,357 @@ "input": "gl-event.pds" } ] + }, + { + "destination": "lib/firmware/apple/h4isp-firmware.bin", + "sha256": "a78fcc7b1346ba1904b84f441a8dde44d616bfe17bd88d4611ddc1ac49b4e3ec", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-0011_01XX.bin", + "sha256": "30e1d1da7f1c1a24d9fb1a0f5c8d8a45737c054c387b8ac3764e46c5156fdd74", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "0011_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-0022_02XX.bin", + "sha256": "92e4f5d2e25652fb75cec6b5cc5b4352d349a93609b79c16e76dbe993fc9be12", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "0022_02XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-0211_01XX.bin", + "sha256": "cd94abd394c9e22196d9a732be270dadf151ab812d017394645ffaf1e3a2113f", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "0211_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-0221_01XX.bin", + "sha256": "f524da8c2c5dd1d73ffcaad34fff4c19d357d83f6882a1e077d8fb0081e41f11", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "0221_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-0222_02XX.bin", + "sha256": "5d1c43792458d2622838822dc981d3f827cd7b4e97fe39d6aa4a3924ef337d90", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "0222_02XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-1011_04XX.bin", + "sha256": "bc697544ca991cdbb41216bd111f53d2d29cb662db52432c87f51a51dc7c2039", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "1011_04XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-1031_04XX.bin", + "sha256": "99d7e0c84d0308bb9152f4b88a3f7c939765fab560f5d9ba9dbdfa0c43c9404d", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "1031_04XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-1032_04XX.bin", + "sha256": "86282458c4fc3dc26b9651308155251b62229bf2e84a6c75e068d2b083344936", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "1032_04XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-2111_01XX.bin", + "sha256": "dfffec935fb906ee927a997857e4cd05e62b23b977e18c6d124827a98c968ebd", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "2111_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-2122_02XX.bin", + "sha256": "895cb15470349053c8ea2fb9ec3052d34395ef27060a1d83c8502781ca009f38", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "2122_02XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-4413_02XX.bin", + "sha256": "10c87ded2e0a1ab8bf17a19f0cc7df662bd3def768a71069aaa3613100d7a180", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "4413_02XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-4441_02XX.bin", + "sha256": "1bcc958f6393aa5db22303c140460ed09279d8b350f891e8c476beb146b2dc87", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "4441_02XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-5212_01XX.bin", + "sha256": "ccedb3c677b08cc70c85a3b02f4dc41469be2c6bdcc4aacccd75ed7e88614f2a", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "5212_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-5213_01XX.bin", + "sha256": "92fa3a91e6fa090be06d245322a26a16c4b71ffddc2db05a746c4592fe4049c9", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "5213_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-5222_01XX.bin", + "sha256": "0044a74b43d59e741b69200d586336343f10110a61b98d29b82cee5eadd94fc6", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "5222_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-5223_01XX.bin", + "sha256": "11a29166393abfdff4bc90e2f8ad7ae5cd44520dc99bee3538d43e64860e1d52", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "5223_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-6521_01XX.bin", + "sha256": "e59de189ccfcc7b6c618e2b5bd23c2a31fe2fc131daa502056f030d69e368f1d", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "6521_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-6522_01XX.bin", + "sha256": "f5725294d6a2dc3ce19cd6a91031e04a2bb98fa37d60bdaba974246900cf6e1a", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "6522_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-6921_01XX.bin", + "sha256": "ea24c8e23acb33a357cca5b637882b7ffa7fb67888527caf9d05439f73182c6b", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "6921_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-6922_01XX.bin", + "sha256": "d1c53c0f9836b9e7ff7d9f792c33a1c9864660c32b8346529710ebda02b99c10", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "6922_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-7651_01XX.bin", + "sha256": "91ec6b17a0d4be2f7d6a5b2362e89cf4a6007a7a16fdf543d1234a15e75e6a17", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "7651_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-7652_01XX.bin", + "sha256": "a18119fd0028919b0ed97d3678fe5433752c7b84e26bdce392cc79babd7fb409", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "7652_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-7653_01XX.bin", + "sha256": "fa33be8f3f029326cfae4766b7898e2b4852760497933f827da3b902fb8df757", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "7653_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-8111_01XX.bin", + "sha256": "f23b20309ea889e0409bd80ed0756d32e50802c017eed2487cacee756346d0ec", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "8111_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-8112_01XX.bin", + "sha256": "727513be00659bd7e08767191e6d72722407d7bbc95053ef7fcab24b69374b04", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "8112_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-8121_01XX.bin", + "sha256": "a9b856fda82256ca9210ce6ce19dba16a98f720632c43d9f51317d7e54525a5d", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "8121_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-8122_01XX.bin", + "sha256": "b12faaf12b6353f90b5153827836920644f5e009a94fcb6a14b18a8c37ebbae4", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "8122_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-8411_01XX.bin", + "sha256": "7d57729d727d9938a1759dcb015e30230c6e1823ea550c4d340e52dc741a507c", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "8411_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-8413_01XX.bin", + "sha256": "2b72fb1426f6b5da7cdff7ab553d05f4273986725577554cfbafa8f6ec1d94df", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "8413_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-8421_01XX.bin", + "sha256": "adf9697b53e771fa90a32f2e08ea612425d1d212039e75be67541778fb834476", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "8421_01XX" + } + ] + }, + { + "destination": "lib/firmware/apple/h4isp-setfile-8423_01XX.bin", + "sha256": "cbf028c9ceaec2ed39027e76220fdbf98c4acd31271f51d539cbaa036494702c", + "steps": [ + { + "step": "h4isp-from-services@1", + "input": "dyld_shared_cache_armv7s", + "module": "8423_01XX" + } + ] } ] } diff --git a/docs/firmware-recipes.md b/docs/firmware-recipes.md index 56c16684..5af8c555 100644 --- a/docs/firmware-recipes.md +++ b/docs/firmware-recipes.md @@ -101,6 +101,7 @@ recipe. Where a new device's firmware usually is: | Touch | `usr/share/firmware/multitouch/.mtprops` | | Video encoder (A10) | AppleAVE2 in iOS 14's kernelcache (`ave2-firmware-from-kernelcache@1`). iOS 15 ships a later build in `Firmware/ave/`, which the driver doesn't speak | | SmartIO, video decoder | the kernelcache (`smartio-from-kernelcache@1`, `im4p-payload@1`) | +| Camera ISP (iPhone 5, N42) | `System/Library/Caches/com.apple.dyld/dyld_shared_cache_armv7s` in iOS 8.4.1 (12H321) contains `/System/Library/PrivateFrameworks/H4ISPServices.framework/H4ISPServices`. Its `H4ISPFIRMWARE` and `H4ISPSETFILE` sections supply the firmware and 31 module set-files. | | Camera ISP (A10) | `System/Library/PrivateFrameworks/H9ISPServices.framework/adc-.bin.gz` (`gunzip@1`), `hephaestus` on the iPhone 7 | Then: @@ -150,6 +151,7 @@ The CLI used to do that; it isn't needed for recipes any more. | `agx-g4p-border-from-kernelcache@1` | `input` (kernelcache) | the A8 GPU's border colour table, 0x800 bytes of AGXG4P's data, whose hash is the output's | | `agx-g3-ldr-from-kernelcache@1` | `input` (kernelcache) | the A7 GPU firmware (a META LDR) from AGXFirmwareKextG3: the LDR whose hash is the output's | | `im4p-payload@1` | `input` | the payload of an IM4P container | +| `h4isp-from-services@1` | `input` (armv7s dyld cache), optional `module` | `h4isp-firmware.bin` when `module` is omitted, or the set-file for the named iOS module (e.g. `8111_01XX`). Each output is checked against its size, header and recipe SHA-256. | | `gunzip@1` | `input` | the contents of a gzip file, every member, each checked against its CRC and length | | `aop-image@1` | `coprocessor` | one image (`AOP`, `AOP_ext`) of an AOP firmware container, the OSSerializeBinary payload of `Firmware/AOP/aopfw-*.im4p` | | `z2fw-from-mtprops@1` | `input`, `profile`, `packet`, `load_address`, `hbpp_version` | Z2 touch firmware with calibration records |