Skip to content

Add Google Pixel 5a (barbet / SM7250), review fixes folded - #42

Open
Gibbz wants to merge 49 commits into
denialwm:perpetua/v7.3from
bit-shift-io:devices/barbet-review
Open

Gibbz wants to merge 49 commits into
denialwm:perpetua/v7.3from
bit-shift-io:devices/barbet-review

Conversation

@Gibbz

@Gibbz Gibbz commented Nov 19, 2026 •

Copy link
Copy Markdown

Replacement for #31, from a clean branch. The original devices/barbet-pr is
still there and untouched; this branch starts from the same head and folds the
review fixes into the commits they belong to.

The branch is 49 commits, one per driver or device tree, instead of 95. The
final tree is the tree from the reviewed head with the suggestions applied.
It has not been built or run here: no kernel build and no Pixel 5a in this
environment, so the speaker, microphone and UFS cold-boot retests are still
yours to do.

Review items

  1. Boot tool collision. devices/boot/android-v2 now covers both devices.
    It detects an LZ4-frame template kernel (Pixel 5a) or a raw arm64 Image
    (Galaxy Tab S7 FE). The template's DTB is kept unless --dtb names a
    replacement, the signer trailer after the DTB is kept, and the Pixel path
    still recompresses with the template's LZ4 settings and text_offset.
    --tail writes the boot partition's module/firmware filesystem
    after the DTB, and devices/README documents the new arguments.

    The Bluetooth property is now qcom,no-inband-sleep, the name used by Add Samsung tab S7 FE support (gts7xllite) #37.
    The driver keeps QCA_IBS_DISABLED set after setup and still suppresses UART
    system wake while bound.

  2. Bluetooth address. qcom,use-firmware-bdaddr, its binding commit and its
    driver commit are gone. radio-addr-bluetooth.service supplies the address
    from the shared image.

  3. Debug logging. The dev_info calls and the experimental structures in
    q6afe, q6afe-dai, q6asm-dai, sm8250 and tas2562 are removed.

  4. TDM clock attribute. The default is unchanged. qcom,tdm-clk-no-invert
    is a per-port property, documented in the LPASS ports binding and set on
    barbet's QUINARY_TDM_RX_0.

  5. tas2562 shutdown. The amplifier goes back to TAS2562_SHUTDOWN when
    the DAC is off, and tas2562_mute() only records the mute state.

  6. Return values. sm8250_snd_startup() returns the clock and slot errors
    instead of printing them.

  7. UFS reset. UFS_RESET is pin 146, the SDC pads move up one, .ngpios is
    147, and barbet uses reset-gpios = <&tlmm 146 GPIO_ACTIVE_LOW>. The
    pin-state path in ufs-qcom.c is removed, so that file is upstream again.

  8. Unused code. TFA9874 and its config line are gone. The rt5514 port is
    unchanged in this branch; see the question below.

  9. Kernel-doc. q6afe_slot_map_v2() is above the q6afe_tdm_port_prepare()
    documentation and has a plain comment.

  10. History. The interconnect rewrite, the full SM7250 tree, the TDM
    removals and the DRV2624 rework are folded into the commits they fix. The
    commits by Sreeshankar K and Ishu Brar carry [...] notes describing what
    was added.

Questions

  • UFS through the apps SMMU. Not tried. The 32-bit DMA limit is the known
    working configuration on this board; routing UFS through the SMMU needs the
    downstream stream ID and a cold-boot retest, neither of which I have here. I
    left the limit in place rather than send an untested SMMU path.

  • Bluetooth rebind service. barbet-bt-start unbinds and rebinds
    serial0-0 after wcn3990-wifi.service. The combo chip is powered by the
    modem, and the Bluetooth ROM does not answer until the WLAN firmware has
    powered it, so the boot-time probe fails and the rebind repeats the QCA setup
    after the chip is alive. I agree the kernel should order this itself; it is
    not fixed in this PR. The comment in kernel.config is the current reason,
    not a claim that userspace is the right place.

  • qcom,no-inband-sleep. Yes: with the property set, the UART host's system
    wake stays off while the driver is bound, so Bluetooth cannot wake the phone
    from suspend. That is now in the driver commit message and in the binding's
    description.

  • rt5514 size. The microphone path needs the SPI burst framing and bus
    arbitration in rt5514-spi.c, the register patch/LDO/clock changes, the
    firmware load and DSP enable, and the DMIC clock and DAPM routes in
    rt5514.c. The hotword, ambient, music-detect, memory-test, firmware-version
    and QMI/codec-detect controls are not needed for ordinary capture. I can send
    the driver without those in a follow-up, but I cannot verify capture after
    trimming without the phone. Do you want that as a second PR, tested on
    hardware before it lands, or the current port now?

  • Battery wording. FEATURES.md is in the Phonewave PR, where the battery
    row will say "estimate" rather than "works".

Checkpatch

One error remains: checkpatch objects to the executable bit on the new
devices/boot/android-v2. It is a Python script like the other
devices/boot/* tools (all mode 755); checkpatch only accepts executable
.py/.sh names in this tree, and the tool has to keep its extensionless
name to stay the same tool #37 uses.

sreeshankark and others added 30 commits November 19, 2026 10:45
Add device tree bindings for the global clock controller on SM7250.

[Adapt the schema to Perpetua's SM6375-only binding; keep the posted
clock, reset and power-domain identifiers unchanged.]

Link: https://lore.kernel.org/linux-arm-msm/20261015051926.13752-2-sreeshankar0910@gmail.com/
Signed-off-by: Sreeshankar K <sreeshankar0910@gmail.com>
Add support for the global clock controller found on SM7250 devices.

[Extend Kconfig help and remove a repeated blank line for checkpatch.]

Link: https://lore.kernel.org/linux-arm-msm/20261015051926.13752-3-sreeshankar0910@gmail.com/
Signed-off-by: Sreeshankar K <sreeshankar0910@gmail.com>
Document the Network-On-Chip interconnect providers of the Qualcomm
SM7250 SoC (Snapdragon 765/765G/768G), which are controlled through RPMh
Bus Clock Managers, and add the header with the node and slave IDs.

Signed-off-by: Ishu Brar <patches@brar.si>
Message-ID: <010601a17d6212dc-ed028a84-ea72-48e7-a4d8-fea315dc42cc-000000@ap-northeast-1.amazonses.com>
[Add the BCM IDs the complete SM7250 NoC description uses.]
Add a driver for the Network-On-Chip interconnect providers of the
Qualcomm SM7250 SoC (Snapdragon 765/765G/768G). It follows the layout of
the other RPMh based providers: the nodes and the Bus Clock Managers
come from the downstream interconnect description of the platform.

Tested on a OnePlus Nord: all providers probe, and the UFS, USB,
display, I2C, serial and camera ISP devices get their paths without
errors.

Signed-off-by: Ishu Brar <patches@brar.si>
Message-ID: <010601a17d62222c-befdb9b3-ce1d-469d-a6d3-00511529579f-000000@ap-northeast-1.amazonses.com>
[Take the complete downstream SM7250 NoC description and node table.]
Describe the Top Level Mode Multiplexer pin controller in the Qualcomm
SM7250 SoC, including its three register tiles and reserved GPIO ranges.

This binding has not been posted upstream. It is taken from the
avicii-mainline pinctrl work as retained in the Luma reference tree, with
the corrected tile addresses from its follow-up fix.

Link: https://github.com/lazybrar/avicii-mainline
Signed-off-by: Bronson <bronsonmathews@gmail.com>
Add the pinctrl, pinmux, pinconf and gpiolib driver for the Top Level
Mode Multiplexer block in the Qualcomm SM7250 SoC. It provides the GPIO
and function data for the east, south and west tiles, including the UFS
reset pin.

This driver has not been posted upstream. It is taken from the
avicii-mainline combined patch, with the driver's register macros
parenthesised and the Kconfig help completed for checkpatch.

Link: https://github.com/lazybrar/avicii-mainline
Signed-off-by: Bronson <bronsonmathews@gmail.com>
Add the ID for the Qualcomm SM7250 SoC.

Signed-off-by: Sreeshankar K <sreeshankar0910@gmail.com>
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20260824150156.1310-2-sreeshankar0910@gmail.com
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
(cherry picked from commit b6fe0b2)
Add SoC ID for Qualcomm SM7250 SoC.

Signed-off-by: Sreeshankar K <sreeshankar0910@gmail.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Reviewed-by: Abel Vesa <abel.vesa@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20260824150156.1310-3-sreeshankar0910@gmail.com
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
(cherry picked from commit 4f7b5ac)
Document RPMHCC bindings for clock rpmh driver on Qualcomm SM7250 SoC.

Signed-off-by: Sreeshankar K <sreeshankar0910@gmail.com>
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Link: https://lore.kernel.org/linux-arm-msm/20260821154030.2514-1-sreeshankar0910@gmail.com
Link: https://patch.msgid.link/20260816131646.10551-3-sreeshankar0910@gmail.com
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
(cherry picked from commit 5bea070)
Add the RPMH clocks present in SM7250 SoC.

Signed-off-by: Sreeshankar K <sreeshankar0910@gmail.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@oss.qualcomm.com>
Reviewed-by: Abel Vesa <abel.vesa@oss.qualcomm.com>
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Link: https://patch.msgid.link/20260816131646.10551-2-sreeshankar0910@gmail.com
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
(cherry picked from commit 84a40df)
Document the RPMh power domain for SM7250 SoC.

Signed-off-by: Sreeshankar K <sreeshankar0910@gmail.com>
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Signed-off-by: Ulf Hansson <ulfh@kernel.org>
(cherry picked from commit e1d70a0)
Add RPMh power domains for SM7250 SoC.

Signed-off-by: Sreeshankar K <sreeshankar0910@gmail.com>
Reviewed-by: Abel Vesa <abel.vesa@oss.qualcomm.com>
Reviewed-by: Konrad Dybcio <konrad.dybcio@oss.qualcomm.com>
Signed-off-by: Ulf Hansson <ulfh@kernel.org>
(cherry picked from commit 26b9ea4)
[Add the UFS PHY power domain used by SM7250 boards.]
Document Kryo 475 CPUs found in Qualcomm SM7250 SoC.

Signed-off-by: Sreeshankar K <sreeshankar0910@gmail.com>
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Link: https://lore.kernel.org/r/20260824150156.1310-10-sreeshankar0910@gmail.com
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
(cherry picked from commit 1c8fe88)
Document the PDC block on the SM7250 SoC.

Signed-off-by: Sreeshankar K <sreeshankar0910@gmail.com>
Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Link: https://patch.msgid.link/20261015051926.13752-5-sreeshankar0910@gmail.com
Signed-off-by: Rob Herring (Arm) <robh@kernel.org>
(cherry picked from commit e8b2cbf)
Document the SCM compatible for Qualcomm SM7250 SoC.

Acked-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>
Signed-off-by: Sreeshankar K <sreeshankar0910@gmail.com>
Add the devicetree for SM7250: the CPUs and their PSCI idle states, the
interrupt controllers, RPMh, GCC, TLMM, SPMI, the timer, the memory map,
and the UFS, USB, watchdog, SMMU, display, GPU and NoC nodes.

Based on the v14 posting by Sreeshankar K. TLMM and the QUPv3 wrapper
that carries the debug UART are added here; cpufreq and LMH are left out
until their dependencies are in the tree.

[Add the peripheral nodes from the board bring-up.]
Document the Google Pixel 5a, an SM7250 board.
Add the board tree for the Google Pixel 5a (barbet), an SM7250 device.
It describes the debug UART, the firmware carveouts, the secure GPIOs,
the PMIC rails, storage, USB, display, GPU, touch, audio, Bluetooth,
haptics, battery and charger.
…ntrollers

The debug UART needs the global clock controller and its pins before the
root filesystem is mounted, so build both in. The interconnect driver is
built in as well, for the peripherals that follow.
Register the device, its built-in tree and the SM7250 fragment. The
bootloader uses a version 2 image with the kernel, ramdisk and DTB in the
boot partition, written by devices/boot/android-v2.
Document the SM7250 UFS PHY. It uses the version 4 register layout with
SM7250-specific TX, RX and PCS calibration.

Link: https://github.com/lazybrar/avicii-mainline
Document the SM7250 UFS host controller. Its compatible is
"qcom,sm7250-ufshc", "qcom,ufshc", "jedec,ufs-2.0".

Link: https://github.com/lazybrar/avicii-mainline
The SM7250 UFS PHY uses the version 4 register layout, two lanes and
HS-G3. Its serdes and HS-B tables are the SM8150 ones; TX, RX and PCS
come from the downstream lito calibration. That calibration places the
TX PWM gear dividers 0x10 below the version 5 layout, so those four
registers are written as raw offsets.

Link: https://github.com/lazybrar/avicii-mainline
The SM7250 UFS node has no IOMMU stream, so its descriptors carry raw
physical addresses. Above 4 GiB the controller never writes back the OCS
or the response UPIU and raises no completion interrupt. Limit this
variant to 32-bit DMA.

Link: https://github.com/lazybrar/avicii-mainline
Document the SM7250 DWC3 wrapper. The glue driver matches the fallback
"qcom,dwc3" compatible; the SoC one names the hardware.

Link: https://github.com/lazybrar/avicii-mainline
The SM7250 high-speed USB PHY is the 7 nm Synopsys Femto V2 block.

Link: https://github.com/lazybrar/avicii-mainline
Document the SM7250 APSS watchdog compatible.
Add the SM7250 SMMU-500 compatible so the SoC's apps SMMU can be
described.
Add the DPU 6.1.0 catalog for SM7250, the MDSS support and the Adreno 620
catalog and GMU programming the panel and GPU need, so both can probe on
barbet. Ported from the Luma sm7250-barbet branch without its panel driver,
which is for a different phone.

(cherry picked from commit 4ebf476)
Combined diff of the following commits (base v7.3-rc7):

  - iommu/arm-smmu-qcom: skip PRR setup on the SM7250 GPU SMMU
Gibbz added 18 commits November 19, 2026 10:45
Adds the Samsung SOFEF01 1080x2400 command-mode panel used by barbet.
The mode and init sequence come from the stock Android panel data.

Signed-off-by: Bronson <bronsonmathews@gmail.com>
The Pixel 5a (barbet, Adreno 620) ships the a650 SQE ucode at version
v93. It runs on the a620; the v95 threshold in the version check is for
the a650 family. Accept v93 on the a620 so the stock firmware can boot
the GPU.

Signed-off-by: Bronson <bronsonmathews@gmail.com>
The Pixel 5a's touch controller is an STMicroelectronics FingerTipS on
QUPv3 SE0. Ported from the Luma sm7250-barbet branch.

(cherry picked from commit 78214f2)
The display and GPU nodes reference the display and graphics clock
controllers, which the posted SM7250 support does not have yet. Ported
from the Luma sm7250-barbet branch, limited to the two controllers the
display and GPU need.

(cherry picked from commit 4324969)
The Pixel 5a drives its vibration motor with a TI DRV2624 over I2C.
Ported from the Luma sm7250-barbet branch.

(cherry picked from commit 841dc7c)
Describe the SM7250 ADSP and its resource table so the audio DSP can be
started. Ported from the Luma sm7250-barbet branch.

(cherry picked from commit baa9325)
(cherry picked from commit d2fb860)
Add the SM7250 AFE ports the barbet speaker path needs, the TAS2562
speaker amplifier support, the DSP capture rate, and the machine driver
entries. Ported from the Luma sm7250-barbet branch.

(cherry picked from commit 4b485c3)
(cherry picked from commit d5efa24)
Extend the RT5514 codec and SPI transport with the DSP capture path the
barbet uses for its microphones. Ported from the Luma sm7250-barbet
branch; the bias-level block the original patch removed is adapted to
the newer ASoC DAPM accessor.

(cherry picked from commit 1b1a565)
Report the Pixel 5a battery voltage and a voltage-derived state of charge
from the PM7250B VADC. Ported from the Luma sm7250-barbet branch.

(cherry picked from commit f205d00)
The Pixel 5a charges through the PM7250B; add the charger driver so
charging can be enabled and limited. Ported from the Luma sm7250-barbet
branch.

(cherry picked from commit 5dee3c1)
UBWC 3.1 is the 8-channel macrotile format, which the SM7250 DPU needs
for correct display output. Ported from the Luma sm7250-barbet branch,
adapted to the newer per-version configuration tables.

(cherry picked from commit d2bfafeb7)
Without it the PD mapper reports "no support for the platform" and the
modem's WLAN service never starts. Ported from the Luma sm7250-barbet
branch.

(cherry picked from commit ded32ce)
Some controllers do not answer standard HCI commands once the setup
leaves the QCA in-band-sleep protocol enabled. Document a property that
keeps in-band sleep disabled for the whole session.

The name is the one proposed for the Samsung Galaxy Tab S7 FE, so both
devices describe the same switch.
On some WCN3990 ROMs the controller stops answering standard HCI commands
after the setup while the in-band-sleep protocol is enabled, so the host
waits for wake acknowledgements that never come. Keep the protocol
disabled for the whole session when the device tree asks for it, instead
of only while the patch and NVM are downloaded.

The UART wake is also turned off while the driver is bound, so Bluetooth
can no longer wake the phone from suspend. That is acceptable for now.

The property name matches the one used for the Galaxy Tab S7 FE.
Add the adapter for Android header version 2 images, which carry the
kernel, ramdisk and one DTB in the boot partition. It keeps the stock
template's header, addresses, command line and unsigned AVB properties.

An LZ4-frame kernel is recompressed with the template's settings and its
arm64 text_offset adopts the template's; a raw arm64 Image is used as it
is. The template's DTB is kept unless --dtb names a replacement, so one
tool covers the Pixel 5a and the Galaxy Tab S7 FE. The packed image is
unpacked and its kernel, ramdisk and DTB compared byte for byte, and
avbtool verifies the result.
Document the Google Pixel 5a sound-card compatible and its LPASS vote
and primary/quinary TDM clocks.
A version 2 boot image lists its kernel, ramdisk and DTB in the header and
puts them in that order. Devices that mount modules and firmware from the
boot partition need a filesystem after that payload, which the header does
not describe. --tail writes it at the page after the DTB, before any signer
trailer, so the early userspace finds it from the kernel, ramdisk and DTB
sizes alone. A raw template with a signer trailer is refused: a tail there
would move the trailer.

The packed image is checked for the tail at the computed offset, and the
tail hash joins the evidence record.
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