Repository navigation
kboot: hand the J713 ISP its address filter windows from the ADT - #309
Conversation
|
Thanks, reading the filter from this boot's ADT is the right direction. Two requests. First, in dt_set_j713_isp_one() the call |
The T8132 ISP loses its DART's address filter whenever it powers down, and the kernel programs it again before each firmware start. Its windows were a table in the kernel copied from one J713's ADT. With the rest of the camera handoff, copy them from this boot's ADT /arm-io/dart-isp dapf-instance records into the ISP's apple,dapf-ranges, as inclusive start and end pairs in record order. The DART's DAPF bank is found in its instance metadata by type, not by position; a DART with no DAPF bank, or more than one, has none to give. The kernel writes every slice with the same register words: the window control word, the second control word and the stream ID mask, named after the driver's. A record with other words is refused. Without a usable filter the ISP is still handed over, only without the property (one already in the tree is dropped, as it is not this boot's): a kernel with its own table keeps working, and one that needs the property leaves the camera off and says why. The ISP DART also lists its two SMMU banks in its instance metadata; accept that type when validating a T8132 DART. Developed with Claude Code. Signed-off-by: Erik Bourget <erik@ebourget.net>
445f8ae to
29440f5
Compare
|
Both done. |
Ryan's merge notes on aurora-silicon/linux#531 asked for the T8132 ISP's DART address filter table to come from the loader reading the ADT, the way the firmware carveouts already do. The kernel had it as a table copied from one J713's ADT.
With the rest of the J713 ISP handoff,
dt_set_j713_isp_one()now copies this boot's/arm-io/dart-ispDAPF records into the ISP'sapple,dapf-ranges, as inclusive start and end pairs in record order.dapf_t8132_ranges()finds the DART's DAPF bank by its type in theinstancemetadata and refuses a DART with none or more than one. The kernel writes every slice with the same register words, named after the ISP driver's:J713_ISP_DAPF_CTRL0(0x31, the window control word at 0x00),J713_ISP_DAPF_CTRL1(0, at 0x04) andJ713_ISP_DAPF_SIDMASK(1, the stream ID mask at 0x20). A record with other words is not used.If the filter can't be read, the ISP is still handed over, without
apple,dapf-ranges(a stale one in the tree is dropped), so the kernel decides: today's kernels keep their built-in table, and aurora-silicon/linux#2229 refuses with a message naming the missing property.dapf_select_t8132()rejected the ISP DART: it lists two SMMU banks in itsinstancemetadata, a type the validator didn't know. It now accepts SMMU instances.Merge order: this goes first, with aurora-silicon/u-boot#52 (importer), before aurora-silicon/linux#2229, the kernel change that needs the property. Under this aura alone, today's kernels ignore the new property.
Tested
tests/python/test_j713_isp_dapf.pyruns the productiondapf_t8132_ranges()on the J713's realdart-isprecords, plus a moved DAPF bank, no DAPF bank, two DAPF banks, other register words, and source-mutation controls.test_j713_isp_handoff.pychecks the property, every refusal, and the hand-off without the property (with and without a stale one).tests/pythonmatchesmain.aura-trytrial with this change and the U-Boot importer: the kernel DT got the 13 windows from that boot's ADT, and the camera streamed with no faults.This change was developed and tested by Claude (Anthropic), working with me on the J713.
🤖 Generated with Claude Code