Skip to content

Add stats compatible and config for Shikra#833

Open
smankad-oss wants to merge 3 commits into
qualcomm-linux:qcom-6.18.yfrom
smankad-oss:shikra_stats_qli2.0
Open

Add stats compatible and config for Shikra#833
smankad-oss wants to merge 3 commits into
qualcomm-linux:qcom-6.18.yfrom
smankad-oss:shikra_stats_qli2.0

Conversation

@smankad-oss

Copy link
Copy Markdown

SoC LPM stats are present in RPM MSGRAM and subsystem LPM stats are
present in SMEM for Shikra.

For earlier targets using RPM processor like msm8974, rpm_master_stat.c was
used for subsystem LPM stats since those stats were populated in RPM
MSGRAM.

qcom_stats.c supports both the configurations for shikra, reading subsystem
LPM stats from SMEM and reading SoC LPM stats from RPM MSGRAM.

A generic "qcom,rpm-stats" compatible only reads SoC LPM stats like vmin
and vlow. Add shikra rpm compatible and config to read subsystem LPM
stats too along with SoC LPM stats.

@qlijarvis

Copy link
Copy Markdown

PR #833 — validate-patch

PR: #833

Verdict Issues Detailed Report
3 Full report

Final Summary

  1. Lore link present: No — no lore.kernel.org Link tags found in any of the 3 commits
  2. Lore link matches PR commits: N/A — no lore link to compare against
  3. Upstream patch status: Unknown — cannot determine without lore link; however, presence of Reviewed-by tags from upstream maintainers (Konrad Dybcio) suggests these may have been posted to a mailing list
  4. PR present in qcom-next/topics: Fail - 2/3 commit(s) are missing from both qcom-next and topics
Verdict: ❌ — click to expand

🔍 Patch Validation

PR: #833 - Add Shikra rpm-stats support (3 commits)
Upstream commit: N/A
Verdict: ❌ FAIL

Commit Message

Check Status Note
Subject matches upstream N/A No lore link to compare against
Body preserves rationale N/A No lore link to compare against
Fixes tag present/correct No Fixes tag needed (new feature)
Authorship preserved N/A No lore link to compare against
Backport note (if applicable) N/A Not a backport

Diff

File Status Notes
Documentation/devicetree/bindings/soc/qcom/qcom-stats.yaml ⚠️ Cannot verify against upstream - no lore link
drivers/soc/qcom/qcom_stats.c ⚠️ Cannot verify against upstream - no lore link
arch/arm64/boot/dts/qcom/shikra.dtsi ⚠️ Cannot verify against upstream - no lore link

Issues

Critical:

  1. No lore.kernel.org link found in any of the 3 commit messages. This skill only validates patches against a lore.kernel.org source.
  2. No commit prefix (UPSTREAM:, FROMLIST:, BACKPORT:, QCLINUX:, etc.) to indicate the source or status of these changes.
  3. Integration presence check failed: 2/3 commits are completely missing from both qcom-next and topics branches; 1/3 commit shows only partial evidence.

Observations:

  • All three commits have proper sign-offs and review tags (Reviewed-by: Konrad Dybcio, Maulik Shah)
  • Commit messages are well-structured with clear rationale
  • Changes appear to be new Shikra-specific functionality for rpm-stats

Verdict

Do not merge without correction. These commits lack the required upstream attribution. Each commit must include either:

  • A Link: https://lore.kernel.org/r/<message-id> tag if posted to a mailing list (use FROMLIST: prefix), or
  • A Link: https://git.kernel.org/... tag if merged upstream (use UPSTREAM: or BACKPORT: prefix), or
  • A QCLINUX: prefix if this is vendor-only code not intended for upstream

Additionally, the integration presence check shows these changes are not yet in qcom-next or topics, which is inconsistent with the presence of upstream review tags.

Final Summary

  1. Lore link present: No — no lore.kernel.org Link tags found in any of the 3 commits
  2. Lore link matches PR commits: N/A — no lore link to compare against
  3. Upstream patch status: Unknown — cannot determine without lore link; however, presence of Reviewed-by tags from upstream maintainers (Konrad Dybcio) suggests these may have been posted to a mailing list
  4. PR present in qcom-next/topics: Fail — 2/3 commits are missing from both qcom-next and topics; 1/3 shows only partial evidence (per integration_presence_report.md)

Recommendation

Add appropriate Link: tags and commit prefixes to all three commits:

  • If posted to linux-kernel mailing list: add FROMLIST: prefix and Link: https://lore.kernel.org/r/<message-id>
  • If merged to mainline: add UPSTREAM: prefix and Link: https://git.kernel.org/.../commit/?id=<sha>
  • If vendor-only: add QCLINUX: prefix (no link required)

Then re-run validation.

Deterministic Integration Presence

Integration Presence Report

This report is generated by Jarvis before validate-patch runs.
It is the authoritative source for whether PR changes are already present
in qcom-next or in the kernel topic branches.

Kernel repo: /local/mnt/workspace/sgaud/Qgenie/image_pipeline/kernel
qcom-next ref: a5cf3debd8c3c660711ad586ad4bb84e9ca42635
topics remote: topics -> https://github.com/qualcomm-linux/kernel-topics
topics fetch: fetched

Commit Subject qcom-next topics Final
1/3 [PATCH 1/3] dt-bindings: soc: qcom: stats: Add compatible for Shikra missing - no subject, patch-id, or full tree-content match found missing - no subject, patch-id, or full tree-content match found missing
2/3 [PATCH 2/3] soc: qcom: stats: Add stats compatible and config for partial - subject or partial tree evidence found, but full change was not verified missing - no subject, patch-id, or full tree-content match found partial
3/3 [PATCH 3/3] arm64: dts: qcom: shikra: Update rpm-stats compatible to missing - no subject, patch-id, or full tree-content match found missing - no subject, patch-id, or full tree-content match found missing

Final Status

overall_status: FAIL
present_commits: 0/3
partial_commits: 1/3
missing_commits: 2/3
topics_checked_for_commits: 3/3
final_summary: PR present in qcom-next/topics: Fail - 2/3 commit(s) are missing from both qcom-next and topics

@qlijarvis

Copy link
Copy Markdown

PR #833 — checker-log-analyzer

PR: #833
Checker run: https://github.com/qualcomm-linux/kernel-config/actions/runs/29482364177

Checker Result Summary
Checker Result Summary
checkpatch All commits pass style checks
dt-binding-check Binding schema validation passed
dtb-check Compatible array too long (schema mismatch)
sparse-check No sparse warnings
check-uapi-headers No UAPI changes
check-patch-compliance Missing required subject prefix on all 3 commits
tag-check Missing required subject prefix on all 3 commits

Detailed report: Full report

Checker analysis — click to expand

🤖 CI Checker Analysis (checker-log-analyzer)

PR: #833 - Add Shikra rpm-stats support
Source: https://github.com/qualcomm-linux/kernel-config/actions/runs/29482364177
Target branch: qcom-6.18.y

Checker Result Summary
checkpatch All commits pass style checks
dt-binding-check Binding schema validation passed
dtb-check Compatible array too long (schema mismatch)
sparse-check No sparse warnings
check-uapi-headers No UAPI changes
check-patch-compliance Missing required subject prefix on all 3 commits
tag-check Missing required subject prefix on all 3 commits

❌ dtb-check

Root cause: The binding schema only allows a single compatible string, but the DTS uses a 2-element array with a fallback compatible.

Failure details:

shikra-cqm-evk.dtb: sram@4690000 (qcom,shikra-rpm-stats): compatible: 
  ['qcom,shikra-rpm-stats', 'qcom,rpm-stats'] is too long
  from schema $id: http://devicetree.org/schemas/soc/qcom/qcom-stats.yaml#

This error appears for all 6 Shikra DTB files (cqm-evk, cqs-evk, iqs-evk, and their camera variants).

Analysis:

The DTS patch (3/3) changes the compatible from:

compatible = "qcom,rpm-stats";

to:

compatible = "qcom,shikra-rpm-stats", "qcom,rpm-stats";

This is a valid pattern (SoC-specific compatible with generic fallback), but the binding schema in patch 1/3 doesn't declare support for this. The schema currently has:

properties:
  compatible:
    items:
      - enum:
          - qcom,msm8226-rpm-stats
          - qcom,msm8916-rpm-stats
          - qcom,msm8974-rpm-stats
          - qcom,shikra-rpm-stats

This schema structure implicitly allows only maxItems: 1. To support the fallback pattern, the binding needs:

properties:
  compatible:
    oneOf:
      - items:
          - enum:
              - qcom,msm8226-rpm-stats
              - qcom,msm8916-rpm-stats
              - qcom,msm8974-rpm-stats
              - qcom,shikra-rpm-stats
      - items:
          - const: qcom,shikra-rpm-stats
          - const: qcom,rpm-stats

Or more simply, if all SoC-specific compatibles can use qcom,rpm-stats as fallback:

properties:
  compatible:
    oneOf:
      - items:
          - enum:
              - qcom,msm8226-rpm-stats
              - qcom,msm8916-rpm-stats
              - qcom,msm8974-rpm-stats
              - qcom,shikra-rpm-stats
      - items:
          - enum:
              - qcom,msm8226-rpm-stats
              - qcom,msm8916-rpm-stats
              - qcom,msm8974-rpm-stats
              - qcom,shikra-rpm-stats
          - const: qcom,rpm-stats

Fix:

Update patch 1/3 to allow the fallback compatible pattern. Modify Documentation/devicetree/bindings/soc/qcom/qcom-stats.yaml:

properties:
  compatible:
    oneOf:
      - items:
          - enum:
              - qcom,msm8226-rpm-stats
              - qcom,msm8916-rpm-stats
              - qcom,msm8974-rpm-stats
              - qcom,shikra-rpm-stats
      - items:
          - const: qcom,shikra-rpm-stats
          - const: qcom,rpm-stats

Reproduce locally:

make -j$(nproc) O=out defconfig
make -j$(nproc) O=out CHECK_DTBS=y arch/arm64/boot/dts/qcom/shikra-cqm-evk.dtb

❌ check-patch-compliance

Root cause: All three commits lack the required subject-line prefix (FROMLIST:, FROMGIT:, UPSTREAM:, BACKPORT:).

Failure details:

Checking commit: dt-bindings: soc: qcom: stats: Add compatible for Shikra
Commit summary does not start with a required prefix

Checking commit: soc: qcom: stats: Add stats compatible and config for Shikra
Commit summary does not start with a required prefix

Checking commit: arm64: dts: qcom: shikra: Update rpm-stats compatible to SoC specific
Commit summary does not start with a required prefix

Fix:

The check-patch-compliance checker enforces that commits must start with one of:

  • FROMLIST: — patch posted to mailing list (lore.kernel.org)
  • FROMGIT: — patch taken from a maintainer git tree
  • UPSTREAM: — patch merged into Linus's mainline tree
  • BACKPORT: — upstream patch backported with modifications

For each commit, amend the subject to add the appropriate prefix:

git rebase -i <base_sha>   # mark each commit as 'edit'

# For commit 1/3:
git commit --amend -m "FROMLIST: dt-bindings: soc: qcom: stats: Add compatible for Shikra"

# For commit 2/3:
git commit --amend -m "FROMLIST: soc: qcom: stats: Add stats compatible and config for Shikra"

# For commit 3/3:
git commit --amend -m "FROMLIST: arm64: dts: qcom: shikra: Update rpm-stats compatible to SoC specific"

git rebase --continue

If these patches have been posted to a mailing list, also add a Link: trailer pointing to the lore.kernel.org URL in each commit message body.

Note: The checker only accepts upstream-linkable prefixes. If these are vendor-only changes with no upstream equivalent, use QCLINUX: instead, but be aware that check-patch-compliance will still fail (this is a known limitation for vendor-only commits).


❌ tag-check

Root cause: All three commits lack the required subject-line prefix tag.

Applies because: The target branch is qcom-6.18.y, which is not qcom-next or qcom-next-staging. All branches except those two require every commit to start with a valid prefix tag.

Required prefix tags:

  • FROMLIST: — Patch posted to mailing list (lore.kernel.org)
  • FROMGIT: — Patch taken from a maintainer git tree
  • UPSTREAM: — Patch merged into Linus's mainline tree
  • BACKPORT: — Upstream patch backported with modifications
  • QCLINUX: — Vendor-only change with no upstream equivalent
  • PENDING: — Work-in-progress, not yet posted upstream
  • WORKAROUND: — Temporary fix not suitable for upstream

Failure details:

All three commits are missing a prefix:

  1. 30343a2420fd — "dt-bindings: soc: qcom: stats: Add compatible for Shikra"
  2. a974768fde64 — "soc: qcom: stats: Add stats compatible and config for Shikra"
  3. 2599a9ae2751 — "arm64: dts: qcom: shikra: Update rpm-stats compatible to SoC specific"

Fix:

Same as check-patch-compliance fix above — add the appropriate prefix to each commit subject. Choose the correct prefix based on the patch origin:

  • If posted to lore but not yet merged → FROMLIST:
  • If in a maintainer tree → FROMGIT:
  • If merged into Linus's tree → UPSTREAM:
  • If backported with modifications → BACKPORT:
  • If vendor-only, no upstream → QCLINUX:

Verdict

3 blockers must be fixed before merge:

  1. dtb-check failure — Update the binding schema (patch 1/3) to allow the fallback compatible pattern used in the DTS (patch 3/3).

  2. check-patch-compliance failure — Add required subject prefix (FROMLIST:, UPSTREAM:, etc.) to all three commits.

  3. tag-check failure — Same as Adding Email Checker  #2 (both checks enforce the same requirement for the qcom-6.18.y branch).

Recommended action:

  1. Amend patch 1/3 to update the binding schema to support compatible = "qcom,shikra-rpm-stats", "qcom,rpm-stats";
  2. Rebase all three commits to add the appropriate subject prefix (likely FROMLIST: if these are being upstreamed)
  3. If posted upstream, add Link: trailers pointing to the lore.kernel.org URLs
  4. Re-run CI to verify all checkers pass

SoC LPM stats are present in RPM MSGRAM and subsystem LPM stats are present
in SMEM for Shikra.

A generic "qcom,rpm-stats" compatible only reads SoC LPM stats
like vmin and vlow.

Document shikra rpm compatible to read subsystem LPM stats too
along with SoC LPM stats.

Link: https://lore.kernel.org/r/20260713-shikra_stats-v3-1-4be17121729d@oss.qualcomm.com
Reviewed-by: Maulik Shah <maulik.shah@oss.qualcomm.com>
Signed-off-by: Sneh Mankad <sneh.mankad@oss.qualcomm.com>
SoC LPM stats are present in RPM MSGRAM and subsystem LPM stats are
present in SMEM for Shikra.

For earlier targets using RPM processor like msm8974, rpm_master_stat.c was
used for subsystem LPM stats since those stats were populated in RPM
MSGRAM.

Here is a brief summary of previous targets and their stats configuration,
along with the drivers used to display them.

+---------------|----------------------------|---------------------------+
| SoC           | subsystem LPM stats        | SoC LPM stats             |
|---------------|----------------------------|---------------------------|
| msm8974,      | RPM processor MSGRAM       | RPM processor MSGRAM      |
| msm8226       | (rpm_master_stat.c)        | (qcom_stats.c)            |
|---------------|----------------------------|---------------------------|
| sm6350,       | SMEM (DDR)                 | AOP processor MSGRAM      |
| sdm845, etc.  | (qcom_stats.c)             | (qcom_stats.c)            |
|---------------|----------------------------|---------------------------|
| Shikra        | SMEM (DDR)                 | RPM processor MSGRAM      |
|               | (qcom_stats.c)             | (qcom_stats.c)            |
+---------------|----------------------------|---------------------------+

qcom_stats.c supports both the configurations for shikra, reading subsystem
LPM stats from SMEM and reading SoC LPM stats from RPM MSGRAM.

A generic "qcom,rpm-stats" compatible only reads SoC LPM stats like vmin
and vlow. Add shikra rpm compatible and config to read subsystem LPM
stats too along with SoC LPM stats.

Below is an example showing LPM stats for "apss" subsystem with this
change:

cat /sys/kernel/debug/qcom_stats/apss
Count: 2192
Last Entered At: 5498618336
Last Exited At: 5498708046
Accumulated Duration: 2046572620.

Link: https://lore.kernel.org/r/20260713-shikra_stats-v3-2-4be17121729d@oss.qualcomm.com
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Reviewed-by: Maulik Shah <maulik.shah@oss.qualcomm.com>
Signed-off-by: Sneh Mankad <sneh.mankad@oss.qualcomm.com>
…C specific

A generic "qcom,rpm-stats" compatible only reads stats for SoC level LPM
stats like vmin and vlow.

Shikra SoC specific compatible allows reading individual subsystem level
LPM stats along with SoC level LPM stats. Change it.

Keep "qcom,rpm-stats" as fallback compatible.

Link: https://lore.kernel.org/r/20260713-shikra_stats-v3-3-4be17121729d@oss.qualcomm.com
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Signed-off-by: Sneh Mankad <sneh.mankad@oss.qualcomm.com>
@smankad-oss
smankad-oss force-pushed the shikra_stats_qli2.0 branch from 2599a9a to 57cc790 Compare July 17, 2026 10:04
@qlijarvis

Copy link
Copy Markdown

PR #833 — validate-patch

PR: #833

Verdict Issues Detailed Report
0 Full report

Final Summary

  1. Lore link present: Yes — all 3 commits have valid lore.kernel.org links in Link: trailers
  2. Lore link matches PR commits: Yes — all diffs are faithful to lore (patch 3/3 has context-only line number delta due to tree differences, but code change is identical)
  3. Upstream patch status: ⏳ Decision Pending — posted Jul 13, 2026 (v3); all have Reviewed-by tags from subsystem reviewers; no maintainer merge/NAK signal yet
  4. PR present in qcom-next/topics: Fail - 2/3 commit(s) are missing from both qcom-next and topics
Verdict: ❌ — click to expand

🔍 Patch Validation

PR: #833 - Add subsystem LPM stats support for Shikra (3 commits)
Upstream commits:


Commit Message

Check Patch 1/3 Patch 2/3 Patch 3/3 Note
Subject matches upstream All subjects match lore (with FROMLIST: prefix added)
Body preserves rationale All commit bodies faithfully preserve lore content
Fixes tag present/correct N/A N/A N/A No Fixes tags in upstream patches
Authorship preserved FROMLIST: original author Sneh Mankad <sneh.mankad@oss.qualcomm.com> present in Signed-off-by
Backport note (if applicable) N/A N/A N/A FROMLIST: prefix used correctly
Reviewed-by tags preserved All upstream review tags present

Diff

File Status Notes
Documentation/devicetree/bindings/soc/qcom/qcom-stats.yaml Patch 1/3: Identical to lore - adds qcom,shikra-rpm-stats compatible
drivers/soc/qcom/qcom_stats.c Patch 2/3: Identical to lore - adds rpm_data_shikra config and of_device_id entry
arch/arm64/boot/dts/qcom/shikra.dtsi Patch 3/3: Context-only delta (line 1510 in PR vs 535 in lore) - code change identical

Upstream Patch Status

Commit Community Verdict
Patch 1/3: dt-bindings: soc: qcom: stats: Add compatible for Shikra ⏳ Decision Pending — posted Jul 13, 2026; Reviewed-by from Maulik Shah; no merge/NAK signal found in thread
Patch 2/3: soc: qcom: stats: Add stats compatible and config for Shikra ⏳ Decision Pending — posted Jul 13, 2026; Reviewed-by from Konrad Dybcio and Maulik Shah; no merge/NAK signal found in thread
Patch 3/3: arm64: dts: qcom: shikra: Update rpm-stats compatible to SoC specific ⏳ Decision Pending — posted Jul 13, 2026; Reviewed-by from Konrad Dybcio; no merge/NAK signal found in thread

Analysis: All three patches were posted to lore.kernel.org on July 13, 2026 (v3 revision). Each has received formal Reviewed-by: tags from subsystem reviewers (Konrad Dybcio, Maulik Shah), which are positive signals. However, no maintainer has issued an applied, queued, or merged confirmation, and the patches are not yet present in torvalds/linux or stable trees. The series is under active review but not yet accepted into any maintainer tree.


Integration Presence (qcom-next/topics)

Per integration_presence_report.md (authoritative source):

Commit qcom-next topics Final Status
Patch 1/3: dt-bindings ❌ missing ❌ missing ❌ missing
Patch 2/3: soc: qcom: stats ⚠️ partial ❌ missing ⚠️ partial
Patch 3/3: arm64: dts ❌ missing ❌ missing ❌ missing

Overall: ❌ FAIL — 2/3 commits are missing from both qcom-next and topics; 1/3 has partial evidence only.


Issues

  1. Integration presence failure: The PR commits are not present in the qcom-next integration branch or kernel-topics branches. Per the integration_presence_report.md:

    • Patch 1/3 (dt-bindings): missing from both qcom-next and topics
    • Patch 2/3 (soc driver): partial evidence in qcom-next (subject or partial tree match), but full change not verified; missing from topics
    • Patch 3/3 (dts): missing from both qcom-next and topics
  2. Upstream status: All three patches are still under review on the mailing list (Decision Pending). While they have received Reviewed-by: tags from subsystem reviewers, no maintainer has confirmed acceptance or merge. The FROMLIST: prefix is appropriate for this state, but the patches should not be merged into qcom-next until they are accepted upstream or the prefix is changed to reflect their actual status.


Verdict

Do not merge. The PR commits are not present in qcom-next or topics, indicating they have not been integrated into the Qualcomm kernel tree. The FROMLIST: prefix is correct (patches posted to lore but not yet merged upstream), but the integration presence check failed. The patches should be integrated into qcom-next first before being accepted in this PR, or this PR should be the mechanism for adding them to qcom-next (in which case the integration check failure is expected and acceptable).

Recommendation: Clarify the intended workflow:

  • If this PR is meant to add these patches to qcom-next for the first time → the integration check failure is expected; verify that the patches are ready for integration (have sufficient review, no outstanding concerns).
  • If these patches should already be in qcom-next → investigate why they are missing and sync with the integration branch before merging this PR.

Final Summary

  1. Lore link present: Yes — all 3 commits have valid lore.kernel.org links in Link: trailers
  2. Lore link matches PR commits: Yes — all diffs are faithful to lore (patch 3/3 has context-only line number delta due to tree differences, but code change is identical)
  3. Upstream patch status: ⏳ Decision Pending — posted Jul 13, 2026 (v3); all have Reviewed-by tags from subsystem reviewers; no maintainer merge/NAK signal yet
  4. PR present in qcom-next/topics: No — FAIL: 2/3 commits missing from both qcom-next and topics; 1/3 has partial evidence only (per integration_presence_report.md)

Deterministic Integration Presence

Integration Presence Report

This report is generated by Jarvis before validate-patch runs.
It is the authoritative source for whether PR changes are already present
in qcom-next or in the kernel topic branches.

Kernel repo: /local/mnt/workspace/sgaud/Qgenie/image_pipeline/kernel
qcom-next ref: a5cf3debd8c3c660711ad586ad4bb84e9ca42635
topics remote: topics -> https://github.com/qualcomm-linux/kernel-topics
topics fetch: fetched

Commit Subject qcom-next topics Final
1/3 [PATCH 1/3] FROMLIST: dt-bindings: soc: qcom: stats: Add compatible missing - no subject, patch-id, or full tree-content match found missing - no subject, patch-id, or full tree-content match found missing
2/3 [PATCH 2/3] FROMLIST: soc: qcom: stats: Add stats compatible and partial - subject or partial tree evidence found, but full change was not verified missing - no subject, patch-id, or full tree-content match found partial
3/3 [PATCH 3/3] FROMLIST: arm64: dts: qcom: shikra: Update rpm-stats missing - no subject, patch-id, or full tree-content match found missing - no subject, patch-id, or full tree-content match found missing

Final Status

overall_status: FAIL
present_commits: 0/3
partial_commits: 1/3
missing_commits: 2/3
topics_checked_for_commits: 3/3
final_summary: PR present in qcom-next/topics: Fail - 2/3 commit(s) are missing from both qcom-next and topics

@qlijarvis

Copy link
Copy Markdown

PR #833 — checker-log-analyzer

PR: #833
Checker run: https://github.com/qualcomm-linux/kernel-config/actions/runs/29572317712

Checker Result Summary
Checker Result Summary
checkpatch Passed
dt-binding-check Passed
dtb-check Compatible array too long
sparse-check Passed (build errors are pre-existing)
check-uapi-headers Passed
check-patch-compliance Passed
tag-check All commits have FROMLIST: prefix

Detailed report: Full report

Checker analysis — click to expand

🤖 CI Checker Analysis (checker-log-analyzer)

PR: #833 - FROMLIST: dt-bindings: soc: qcom: stats: Add compatible for Shikra (+ driver and DTS updates)
Source: https://github.com/qualcomm-linux/kernel-config/actions/runs/29572317712

Checker Result Summary
checkpatch Passed
dt-binding-check Passed
dtb-check Compatible array too long
sparse-check Passed (build errors are pre-existing)
check-uapi-headers Passed
check-patch-compliance Passed
tag-check All commits have FROMLIST: prefix

❌ dtb-check

Root cause: The binding schema qcom-stats.yaml only allows a single compatible string (maxItems: 1 implicit), but the DTS patch adds a fallback compatible creating a 2-element array ["qcom,shikra-rpm-stats", "qcom,rpm-stats"].

Failure details:

/opt/actions-runner/_work/kernel-config/kernel-config/kernel/temp-out/arch/arm64/boot/dts/qcom/shikra-cqm-evk.dtb: 
  sram@4690000 (qcom,shikra-rpm-stats): compatible: ['qcom,shikra-rpm-stats', 'qcom,rpm-stats'] is too long
  from schema $id: http://devicetree.org/schemas/soc/qcom/qcom-stats.yaml#

This error appears for all 6 shikra DTB files:

  • shikra-cqm-evk.dtb
  • shikra-cqm-evk-imx577-camera.dtb
  • shikra-cqs-evk.dtb
  • shikra-cqs-evk-imx577-camera.dtb
  • shikra-iqs-evk.dtb
  • shikra-iqs-evk-imx577-camera.dtb

Analysis:

The PR consists of 3 patches:

  1. Patch 1/3: Adds qcom,shikra-rpm-stats to the binding's enum list
  2. Patch 2/3: Adds driver support for qcom,shikra-rpm-stats
  3. Patch 3/3: Updates DTS to use compatible = "qcom,shikra-rpm-stats", "qcom,rpm-stats";

The binding schema in qcom-stats.yaml currently has:

properties:
  compatible:
    items:
      - enum:
          - qcom,apq8084-rpm-stats
          - qcom,msm8226-rpm-stats
          - qcom,msm8916-rpm-stats
          - qcom,msm8974-rpm-stats
          - qcom,shikra-rpm-stats    # Added by patch 1/3

This schema structure (items: - enum:) defines a single-item array — it only allows one compatible string. However, patch 3/3 uses a fallback compatible pattern with two strings.

Fix: Update patch 1/3 to allow the fallback compatible pattern. The binding schema should be:

properties:
  compatible:
    oneOf:
      - items:
          - enum:
              - qcom,apq8084-rpm-stats
              - qcom,msm8226-rpm-stats
              - qcom,msm8916-rpm-stats
              - qcom,msm8974-rpm-stats
              - qcom,shikra-rpm-stats
      - items:
          - const: qcom,shikra-rpm-stats
          - const: qcom,rpm-stats

Or more simply, if all SoC-specific compatibles should allow qcom,rpm-stats as fallback:

properties:
  compatible:
    oneOf:
      - items:
          - enum:
              - qcom,apq8084-rpm-stats
              - qcom,msm8226-rpm-stats
              - qcom,msm8916-rpm-stats
              - qcom,msm8974-rpm-stats
              - qcom,shikra-rpm-stats
      - items:
          - enum:
              - qcom,shikra-rpm-stats
          - const: qcom,rpm-stats

Reproduce locally:

make -j$(nproc) O=out defconfig
make -j$(nproc) O=out CHECK_DTBS=y arch/arm64/boot/dts/qcom/shikra-cqm-evk.dtb

Alternative fix (if fallback is not needed):

If the fallback compatible is not actually required, simply remove it from patch 3/3:

-			compatible = "qcom,shikra-rpm-stats", "qcom,rpm-stats";
+			compatible = "qcom,shikra-rpm-stats";

However, based on the commit message stating "Keep 'qcom,rpm-stats' as fallback compatible", the intent is clearly to support the fallback pattern, so the binding schema fix is the correct approach.

Verdict

1 blocker must be fixed before merge:

The binding schema in patch 1/3 must be updated to allow the two-element compatible array used in patch 3/3. The current schema only permits a single compatible string, causing dtb-check validation failures across all shikra DTB files.

All other checkers passed successfully. The commits are properly formatted with FROMLIST: prefixes and include upstream lore.kernel.org links.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants