Repository navigation
Conversation
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
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)
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.
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.
Replacement for #31, from a clean branch. The original
devices/barbet-prisstill 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
Boot tool collision.
devices/boot/android-v2now 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
--dtbnames areplacement, the signer trailer after the DTB is kept, and the Pixel path
still recompresses with the template's LZ4 settings and
text_offset.--tailwrites the boot partition's module/firmware filesystemafter the DTB, and
devices/READMEdocuments 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_DISABLEDset after setup and still suppresses UARTsystem wake while bound.
Bluetooth address.
qcom,use-firmware-bdaddr, its binding commit and itsdriver commit are gone.
radio-addr-bluetooth.servicesupplies the addressfrom the shared image.
Debug logging. The
dev_infocalls and the experimental structures inq6afe,q6afe-dai,q6asm-dai,sm8250andtas2562are removed.TDM clock attribute. The default is unchanged.
qcom,tdm-clk-no-invertis a per-port property, documented in the LPASS ports binding and set on
barbet's QUINARY_TDM_RX_0.
tas2562shutdown. The amplifier goes back toTAS2562_SHUTDOWNwhenthe DAC is off, and
tas2562_mute()only records the mute state.Return values.
sm8250_snd_startup()returns the clock and slot errorsinstead of printing them.
UFS reset. UFS_RESET is pin 146, the SDC pads move up one,
.ngpiosis147, and barbet uses
reset-gpios = <&tlmm 146 GPIO_ACTIVE_LOW>. Thepin-state path in
ufs-qcom.cis removed, so that file is upstream again.Unused code. TFA9874 and its config line are gone. The
rt5514port isunchanged in this branch; see the question below.
Kernel-doc.
q6afe_slot_map_v2()is above theq6afe_tdm_port_prepare()documentation and has a plain comment.
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 whatwas 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-startunbinds and rebindsserial0-0afterwcn3990-wifi.service. The combo chip is powered by themodem, 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.configis 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 systemwake 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.
rt5514size. The microphone path needs the SPI burst framing and busarbitration in
rt5514-spi.c, the register patch/LDO/clock changes, thefirmware load and DSP enable, and the DMIC clock and DAPM routes in
rt5514.c. The hotword, ambient, music-detect, memory-test, firmware-versionand 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.mdis in the Phonewave PR, where the batteryrow 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 otherdevices/boot/*tools (all mode 755); checkpatch only accepts executable.py/.shnames in this tree, and the tool has to keep its extensionlessname to stay the same tool #37 uses.