The NetBSD Project

CVS log for src/sys/arch/arm/rockchip/rk_tsadc.c

[BACK] Up to [cvs.NetBSD.org] / src / sys / arch / arm / rockchip

Request diff between arbitrary revisions


Default branch: MAIN


Revision 1.16 / (download) - annotate - [select for diffs], Sat Dec 11 19:24:21 2021 UTC (2 years, 4 months ago) by mrg
Branch: MAIN
CVS Tags: thorpej-ifq-base, thorpej-ifq, thorpej-altq-separation-base, thorpej-altq-separation, netbsd-10-base, netbsd-10-0-RELEASE, netbsd-10-0-RC6, netbsd-10-0-RC5, netbsd-10-0-RC4, netbsd-10-0-RC3, netbsd-10-0-RC2, netbsd-10-0-RC1, netbsd-10, bouyer-sunxi-drm-base, bouyer-sunxi-drm, HEAD
Changes since 1.15: +2 -4 lines
Diff to previous 1.15 (colored)

remove clause 3 from all my licenses that aren't conflicting with
another copyright claim line.  again.  (i did this in 2008 and then
did not update all of my personal templates.)

Revision 1.15 / (download) - annotate - [select for diffs], Sat Nov 13 11:46:32 2021 UTC (2 years, 5 months ago) by jmcneill
Branch: MAIN
Changes since 1.14: +93 -14 lines
Diff to previous 1.14 (colored)

Add support for RK3288 temperature sensors.

Revision 1.14 / (download) - annotate - [select for diffs], Sat Sep 11 20:28:03 2021 UTC (2 years, 7 months ago) by andvar
Branch: MAIN
Changes since 1.13: +3 -3 lines
Diff to previous 1.13 (colored)

Add missing double p and d for stopped and overriden accordingly.
Fix few more typos along the way, mainly in copy-pasted comments.

Revision 1.12.4.1 / (download) - annotate - [select for diffs], Thu Jun 17 04:46:18 2021 UTC (2 years, 10 months ago) by thorpej
Branch: thorpej-i2c-spi-conf
Changes since 1.12: +3 -3 lines
Diff to previous 1.12 (colored) next main 1.13 (colored)

Sync w/ HEAD.

Revision 1.13 / (download) - annotate - [select for diffs], Sat Jun 12 00:04:46 2021 UTC (2 years, 10 months ago) by mrg
Branch: MAIN
CVS Tags: thorpej-i2c-spi-conf2-base, thorpej-i2c-spi-conf2, thorpej-i2c-spi-conf-base, thorpej-futex2-base, thorpej-futex2, thorpej-cfargs2-base, thorpej-cfargs2
Changes since 1.12: +3 -3 lines
Diff to previous 1.12 (colored)

fix comment to talk about correct units (kelvin, not seconds).

Revision 1.7.10.1 / (download) - annotate - [select for diffs], Sat Apr 3 22:28:18 2021 UTC (3 years ago) by thorpej
Branch: thorpej-futex
Changes since 1.7: +10 -20 lines
Diff to previous 1.7 (colored) next main 1.8 (colored)

Sync with HEAD.

Revision 1.12 / (download) - annotate - [select for diffs], Wed Jan 27 03:10:19 2021 UTC (3 years, 2 months ago) by thorpej
Branch: MAIN
CVS Tags: thorpej-futex-base, thorpej-cfargs-base, thorpej-cfargs, cjep_sun2x-base1, cjep_sun2x-base, cjep_sun2x, cjep_staticlib_x-base1, cjep_staticlib_x-base, cjep_staticlib_x
Branch point for: thorpej-i2c-spi-conf
Changes since 1.11: +4 -4 lines
Diff to previous 1.11 (colored)

Rename of_match_compat_data() to of_compatible_match().  Similarly,
rename of_search_compatible() to of_compatible_lookup().

Standardize on of_compatible_match() for driver matching, and adapt
all call sites.

Revision 1.11 / (download) - annotate - [select for diffs], Wed Jan 27 02:00:02 2021 UTC (3 years, 2 months ago) by thorpej
Branch: MAIN
Changes since 1.10: +3 -3 lines
Diff to previous 1.10 (colored)

Use DEVICE_COMPAT_EOL.

Revision 1.10 / (download) - annotate - [select for diffs], Mon Jan 25 14:20:38 2021 UTC (3 years, 2 months ago) by thorpej
Branch: MAIN
Changes since 1.9: +3 -3 lines
Diff to previous 1.9 (colored)

Since we're using designated initialisers for compat data, we should
use a completely empty initializer for the sentinel.

Revision 1.9 / (download) - annotate - [select for diffs], Tue Jan 19 00:38:52 2021 UTC (3 years, 2 months ago) by thorpej
Branch: MAIN
Changes since 1.8: +8 -18 lines
Diff to previous 1.8 (colored)

Use device_compatible_entry / of_search_compatible() rather than
matching against multiple sets of compatibility strings.

Revision 1.8 / (download) - annotate - [select for diffs], Fri Jan 15 18:42:41 2021 UTC (3 years, 3 months ago) by ryo
Branch: MAIN
Changes since 1.7: +4 -4 lines
Diff to previous 1.7 (colored)

use fdtbus_intr_establish_xname

Revision 1.6.2.3 / (download) - annotate - [select for diffs], Mon Apr 13 08:03:37 2020 UTC (4 years ago) by martin
Branch: phil-wifi
Changes since 1.6.2.2: +3 -3 lines
Diff to previous 1.6.2.2 (colored) to branchpoint 1.6 (colored) next main 1.7 (colored)

Mostly merge changes from HEAD upto 20200411

Revision 1.7 / (download) - annotate - [select for diffs], Wed Jul 3 20:55:21 2019 UTC (4 years, 9 months ago) by jmcneill
Branch: MAIN
CVS Tags: phil-wifi-20200421, phil-wifi-20200411, phil-wifi-20200406, phil-wifi-20191119, netbsd-9-base, netbsd-9-3-RELEASE, netbsd-9-2-RELEASE, netbsd-9-1-RELEASE, netbsd-9-0-RELEASE, netbsd-9-0-RC2, netbsd-9-0-RC1, netbsd-9, is-mlppp-base, is-mlppp, bouyer-xenpvh-base2, bouyer-xenpvh-base1, bouyer-xenpvh-base, bouyer-xenpvh, ad-namecache-base3, ad-namecache-base2, ad-namecache-base1, ad-namecache-base, ad-namecache
Branch point for: thorpej-futex
Changes since 1.6: +3 -3 lines
Diff to previous 1.6 (colored)

Set correct bits when enabling gpio tshut mode

Revision 1.6.2.2 / (download) - annotate - [select for diffs], Mon Jun 10 22:05:56 2019 UTC (4 years, 10 months ago) by christos
Branch: phil-wifi
Changes since 1.6.2.1: +904 -0 lines
Diff to previous 1.6.2.1 (colored) to branchpoint 1.6 (colored)

Sync with HEAD

Revision 1.6.2.1, Sat Jun 1 19:32:19 2019 UTC (4 years, 10 months ago) by christos
Branch: phil-wifi
Changes since 1.6: +0 -904 lines
FILE REMOVED

file rk_tsadc.c was added on branch phil-wifi on 2019-06-10 22:05:56 +0000

Revision 1.6 / (download) - annotate - [select for diffs], Sat Jun 1 19:32:19 2019 UTC (4 years, 10 months ago) by joerg
Branch: MAIN
CVS Tags: phil-wifi-20190609
Branch point for: phil-wifi
Changes since 1.5: +3 -3 lines
Diff to previous 1.5 (colored)

Loop variables work better when they are initialized.

Revision 1.5 / (download) - annotate - [select for diffs], Wed May 15 01:24:43 2019 UTC (4 years, 11 months ago) by mrg
Branch: MAIN
Changes since 1.4: +89 -82 lines
Diff to previous 1.4 (colored)

support RK3328 tsadc:

- add clk_24m, clk_tsadc and pclk_tsadc rk3328 clocks
- rk3328 data<->temp conversion table is is wrong.  the actual values
  seen are 4096 - <expected>, and the linux driver has these values
  in the inverted value directly
- the above means the rk3328 is increasing data for increasing temp,
  and the min/max values are also inverted and swapped
- move auto-period into the rk_data
- rk3328 only has one sensor, deal with this
- rename rk_data_table as rk_data, and also s/rdt/rd/

thanks to jmcneill who helped clean up clocks confusion, and pointed
out the linux driver values matched my own inverted data experience.

Revision 1.4 / (download) - annotate - [select for diffs], Tue May 14 07:45:03 2019 UTC (4 years, 11 months ago) by mrg
Branch: MAIN
Changes since 1.3: +219 -78 lines
Diff to previous 1.3 (colored)

mostly port to rk3328.

- add rk3328 data<->temp table, and adjust code to use this vs rk3399
  table for rk3328.  add support for decrementing data.
- adjust auto period times for rk3328 vs rk3399
- add min/max data values, if data is outside these values mark the
  sensor invalid.
- move init code into cpu specific sections, add rk3328 support

with a rk3328_cru.c update to add clocks, this attaches and reports
garbage values, so for now it's disabled.

Revision 1.3 / (download) - annotate - [select for diffs], Fri Apr 26 10:27:49 2019 UTC (4 years, 11 months ago) by mrg
Branch: MAIN
Changes since 1.2: +3 -3 lines
Diff to previous 1.2 (colored)

re-#if 0 some testing code.

Revision 1.2 / (download) - annotate - [select for diffs], Fri Apr 26 10:20:09 2019 UTC (4 years, 11 months ago) by mrg
Branch: MAIN
Changes since 1.1: +37 -17 lines
Diff to previous 1.1 (colored)

- implement sub-5degC interpolation.
- avoid setting TSADC_AUTO_CON_SRC*_EN twice

Revision 1.1 / (download) - annotate - [select for diffs], Fri Apr 26 08:28:11 2019 UTC (4 years, 11 months ago) by mrg
Branch: MAIN

implement TSADC driver for rockchip RK3328 and RK3399.  so far, only
tested on RK3399 but the RK3328 looks mostly the same and has a good
chance of working too.

add clock entries for "clk_tsadc" and "pclk_tsadc" to cru.

exports "CPU" and "GPU" temp sensors.  these currently limited to 5
degC resolution but can be reduced to sub 1 degC resolution with some
interpolation.

todo list:

- handle setting various temp values
- add interpolation between the 5degC intervals in sample data
- handle DT trips/temp value defaults
- interrupts aren't triggered (test by lowering warn/crit values),
  and once they work, make the interrupt do something
- test on RK3328, and port to other rockchips (will require moving
  some part into per-chipset sections, such as code<->temp tables)


thanks to jmcneill for help.

This form allows you to request diff's between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.




CVSweb <webmaster@jp.NetBSD.org>