Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some changes for Qgauge driver #35

Closed
wants to merge 71 commits into from

Conversation

z3ntu
Copy link

@z3ntu z3ntu commented Dec 20, 2024

Re-open of #34 due to GitHub shenanigans

Notably stop hardcoding the SDAM address and instead of the qcom,spmi-sdam driver and access the SDAM via the nvmem framework.

Please test on pm6150 if this works as expected, the driver seems to need some changes for pm7250b to get ocv values there, we just get 0. (edit: this is explained in #34 (comment))

JIaxyga and others added 30 commits December 13, 2024 16:53
Signed-off-by: Danila Tikhonov <[email protected]>
Signed-off-by: Danila Tikhonov <[email protected]>
The Visionox G2647FB105 is a 6.47 inch 1080x2340 MIPI-DSI CMD mode OLED panel
found in Xiaomi Mi Note 10 / Mi CC9 Pro (sm7150-xiaomi-tucana) and
Xiaomi Mi Note 10 Lite (sm7150-xiaomi-toco)

Add a dt-binding for it.

Signed-off-by: Alexander Baransky <[email protected]>
Add the driver for Visionox G2647FB105 6.47" FHD Plus CMD mode OLED panel
support found in Xiaomi Mi Note 10 / Mi CC9 Pro (sm7150-xiaomi-tucana) and
Xiaomi Mi Note 10 Lite (sm7150-xiaomi-toco)

Signed-off-by: Alexander Baransky <[email protected]>
Signed-off-by: Danila Tikhonov <[email protected]>
The Qualcomm SM7150 platform uses the qcom-cpufreq-hw driver, so add
it to the cpufreq-dt-platdev driver's blocklist.

Signed-off-by: Danila Tikhonov <[email protected]>
As there is mappings for other bpc cases, this guarding not needed
anymore.

Signed-off-by: Eugene Lepshy <[email protected]>
Some SDM845-based phones, namely the Pixel 3 (blueline) will fail to
boot a recent kernel on the Q or R bootloader if this is missing.

Meanwhile, the P bootloader can deal with that image properly it seems.

With Q:

```
Booting from slot (a)
KernelDecompress failed: Invalid Parameter Kernel Load Address unaligned
```

With R:

```
Booting from slot (a)
Partition Not Found
KernelDecompress failed: Invalid Parameter Kernel TextOffset does not match
```

This is theorized to be required for other SDM845 devices, but untested.

This (hackily) reverts parts of
120dc60.
Add a document describing the bindings for the AW8695 LRA Haptic Driver.

Signed-off-by: Luca Weiss <[email protected]>
Add a driver for interfacing with the Awinic AW8695 LRA Haptic Driver.

The chip supports multiple modes of which only RAM mode is implemented.
RTP mode would enable a user to "stream" waveform data but to my
knowledge no such user space API exists in the kernel yet.

We upload a basic sine wave to the chip and play this on request.

Signed-off-by: Luca Weiss <[email protected]>
For now, just add a chipid for aw8624.

Signed-off-by: Danila Tikhonov <[email protected]>
Not for upstreaming as is.

Signed-off-by: Vladimyr Lypak <[email protected]>
Signed-off-by: Gabriel David <[email protected]>

ASoC: tfa9872: Remove non_legacy_dai_naming
This is an updated version of the one published by goodix at
https://github.com/goodix/gtx8_driver_linux

Modifications:

- Adapt for changes in recent kernel versions
- Rename pinctrls to "default" and "sleep"
- Resolve some miscellaneous GCC warnings
- clang-formatted the entire driver
- Fix all typos reported by codespell
- Add support for avdd-load/vtouch-load from older
  versions (required for davinci (gt9886) to function)
- Add support for vdd-gpio from Xiaomi's changes (required for sweet
  (gt9896) to function)
- Turn down log verbosity, demote everything except probe and cfg load
  to debug level
- Allow compilation as a module and rename it to gtx8
- Remove IRQ disable depth debug info
- Remove the firmware updater, it does not actually flash the firmware
  and there are not going to be future updates
- Remove the debug tools (disabled in all downstream kernels)
- Remove support for gestures (disabled in all downstream kernels)
- Remove support for pens (disabled in all downstream kernels)
- Configuration blob files are not needed anymore and not exposed by the
  driver in the sysfs, instead values are taken from hardcoded structs
  for each IC variant
- IC variant is guessed from compatible in DTS
- CONFIG_OF is a build time requirement

Signed-off-by: Jens Reidel <[email protected]>
This is battery fuel gauge driver for pmic5 (PMI632/PM6150/PM7250B)
and pmic-lite (PM2250).

Signed-off-by: Danila Tikhonov <[email protected]>
Add support for the pin controller block on SM7150's Low Power Island.

Signed-off-by: Danila Tikhonov <[email protected]>
Add base dtsi for SM7150-AA/SM7150-AB/SM7150-AC SoCs

Co-developed-by: David Wronek <[email protected]>
Signed-off-by: David Wronek <[email protected]>
Signed-off-by: Danila Tikhonov <[email protected]>
Add common device tree for SM7150 Xiaomi devices.

Co-developed-by: David Wronek <[email protected]>
Signed-off-by: David Wronek <[email protected]>
Signed-off-by: Danila Tikhonov <[email protected]>
Add device tree for the Xiaomi POCO X3 NFC (surya) smartphone.
This device is based on Snapdragon 732G (sm7150) SoC.

Co-developed-by: David Wronek <[email protected]>
Signed-off-by: David Wronek <[email protected]>
Signed-off-by: Danila Tikhonov <[email protected]>
Add device tree for the Xiaomi Redmi Note 10 Pro (sweet) smartphone.
This device is based on Snapdragon 732G (sm7150) SoC.

Co-developed-by: Kali Prasad <[email protected]>
Co-developed-by: Salvatore Stella <[email protected]>
Signed-off-by: Danila Tikhonov <[email protected]>
Add device tree for the Xiaomi Mi 9T / Redmi K20 (davinci) smartphone.
This device is based on Snapdragon 730 (sm7150) SoC.

Co-developed-by: Jens Reidel <[email protected]>
Signed-off-by: Jens Reidel <[email protected]>
Signed-off-by: Danila Tikhonov <[email protected]>
JIaxyga and others added 25 commits December 13, 2024 16:54
This driver was published at https://github.com/STMicroelectronics/STTouchController-Android-Drivers

Modifications:
- Adapt for changes in recent kernel versions
- Allow building as a module (fts521)
- Add MODULE_DEVICE_TABLE macros to support autoloading
- Parse configuration data from a DT node
- Use a threaded IRQ handler instead of a blocking one (as in Xiaomi's changes)
- Set the required voltage before enabling AVDD regulator
- Add pinctrl support (as in Xiaomi's changes), rename them to "default" and "sleep"
- Fix various warnings (not all)
- Turn down log verbosity a much
- clang-formatted the entire driver
- Remove /proc file for debugging
- Remove the firmware updater (there are not going to be future updates)
- Remove production tests, move IC initialization function code to fts.c. Why this even exists in a driver...
- Remove fts_limits.h (some data for production tests) and fts_fw.h (firmware)
- Remove various code that became unused

Signed-off-by: Alexander Baransky <[email protected]>
Modifications:
- Move leds-aw3644.h contents here
- Texas Instruments -> Awinic (???)
- Adapt for the latest kernel
- Set MODULE_DEVICE_TABLE macro
- Parse torch LEDs from device tree, drop hardcoded LED names, they are assigned automatically by the kernel now
- Fix warnings
- clang-formatted the entire driver

Signed-off-by: Alexander Baransky <[email protected]>
This driver was removed.

Signed-off-by: Alexander Baransky <[email protected]>
New panel driver has appeared, so fix device tree

Signed-off-by: Alexander Baransky <[email protected]>
- Fix reserved memory regions
- Add panel node (probably Visionox one, Tianma is unsupported for now) and fixed regulators for it
- Add FTS touchscreen support, add a fixed regulator for it
- Add battery design capacity
- Add sound support (only main speaker is supported for now)
- Add QCOM flash support (two LEDs)
- Add soft light LEDs support (aw3644, two LEDs)
- Add haptics support (drv2605l)

Signed-off-by: Alexander Baransky <[email protected]>
Signed-off-by: Luca Weiss <[email protected]>
It's equivalent but this makes it a bit more unified instead of
mix-and-match.

Signed-off-by: Luca Weiss <[email protected]>
And invert the condition for PROP_CHARGE_FULL
It's 1/10th degree celsius (see sysfs docs) and not 1/1000th degree
celsius (see vadc driver)
While PM7250B appears to also support Li-polymer batteries, it's
primarily for Li-ion batteries.
@JIaxyga JIaxyga force-pushed the v6.13 branch 2 times, most recently from 0cb22c6 to f50018c Compare January 27, 2025 19:24
@JIaxyga
Copy link
Member

JIaxyga commented Jan 27, 2025

Thanks! Merged manually

@JIaxyga JIaxyga closed this Jan 27, 2025
@z3ntu z3ntu deleted the sm7150-v6.13-qg branch January 27, 2025 21:07
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.