Conversation
This was referenced Sep 7, 2026
The polling loop continues while the LOCKED bit is set, although the register definition says that a set bit means the PLL has locked. It can therefore time out on a locked PLL or report success before lock. Continue polling while the bit is clear. A successful lock reaches the existing bypass setup, while exhausting the retry limit returns the existing error. This corrects the condition; it does not establish that the separate machine hangs during module reload are resolved. Based-on: patjak#340
DDR setup ignores the PLL initialization result, and fthd_hw_init() ignores the DDR setup result in turn. An initialization failure can therefore be followed by further DDR programming and memory access. Return a PLL failure from DDR setup and propagate a DDR failure through fthd_hw_init() before memory verification or ISP initialization. Both callers must check the result for the failure to reach probe. Successful initialization follows the existing path. A failed clock or DDR setup now prevents the driver from continuing as if it succeeded. Based-on: patjak#340
vrilutza
force-pushed
the
pll-lock-check
branch
from
September 17, 2026 08:53
b87cd6c to
f979869
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The S2 PLL polling loop continues while
S2_PLL_CMU_STATUS_LOCKEDis set, although that bit means the PLL has locked. It can therefore report failure for a locked PLL and success before lock, with different paths into the later DDR setup.The first commit polls while the bit is clear, keeping the existing retry limit and error return. The second propagates initialization errors through both callers: PLL initialization to DDR setup, then DDR setup to
fthd_hw_init(). Initialization stops before DDR verification and ISP setup if the prerequisite fails.The additional correction in this revision is the check in
fthd_hw_init(). The earlier PR propagated the PLL error only as far as the DDR function, whose caller still discarded it. Checking only that first return value does not stop probe from continuing.An extracted-function regression with stubbed hardware verifies that a DDR initialization failure stops the outer initialization path. This is a simulated error-path test, not an injected PLL failure on the physical camera. The revised combined driver has also captured successfully on MacBookPro14,1.
This fixes the inverted condition and ignored return values. It does not establish that the separate machine hangs during module reload or PCI reset are resolved; the earlier investigation did not establish that either.
Validation scope: this individual rebased branch builds against Linux 7.1.13+deb14-amd64 with
W=1; the two existing compiler warnings remain. The complete nine-topic series previously passed 57/57 streaming-inclusive v4l2-compliance checks on MacBookPro14,1. Its final source tree is unchanged by the commit-message rewrite. The combined hardware tests are not nine separate hardware certifications, and no new module reload or hardware test was performed for this publication.Revision:
f97986919b0735831d80c76512d630d6daac2f3e.