summaryrefslogtreecommitdiffstats
path: root/drivers/misc
Commit message (Collapse)AuthorAge
* misc: eventlib: fix building kernel with gcc 11Igor Nabirushkin2021-11-30
| | | | | | | | | | | | | | | | Eventlib: Add local implementation of __sync_fetch_and_or and __sync_fetch_and_and builtin functions. This fixes eventlib build errors with GCC 11. Bug 3375927 Change-Id: I1a8ed9dcc383242a5fa125df3cfb220c867adaf3 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2629717 Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* nct1008: Check return value.Achal Verma2021-08-13
| | | | | | | | | | | | | | | | | | Check return value of sscanf and let the user know if he entered invalid value. This fixes coverity issue : 10055695, 10055711 Bug 200741055 Change-Id: I8a8a8dd1887d9ebc75598848bd40449c11a95a31 Signed-off-by: Achal Verma <achalv@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2575318 Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: Phoenix Jung <pjung@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* drivers: use overlay instead of relative pathAnkit Patel2021-05-04
| | | | | | | | | | | | | | | | | | Modified misc/tegra-cec and video/tegra/dc NVIDIA git repo Makefile, Now overlay macro will be used instead of relative path from kernel source tree, to find the included header file. Bug 200606454 Signed-off-by: Ankit Patel <anpatel@nvidia.com> Change-Id: I684388e9c81be94915c05db3cdae8b6100c6db91 (cherry picked from commit cc443ca25e19811feb0fba17e4ce7c2b6fcd6962) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2522483 Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra-profiler: add unique identifierIgor Nabirushkin2021-01-15
| | | | | | | | | | | | | | | | | Add unique identifier seqid (sequence number) for samples. Bug 3216659 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Change-Id: I84b595f976f1f1955ecb278ababaf45591cdf5e0 Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2464500 (cherry picked from commit ec284fc0b7b94871565c612358ea9e78e9ae4731) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2469351 Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra-profiler: fix build errors on k5.9Igor Nabirushkin2021-01-15
| | | | | | | | | | | | | | | | | A few tegra-profiler changes to be compatible with kernel-5.9. Bug 3127567 Change-Id: I8cdfe325e4293d23d41c1065d5be5e9a723f5be2 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2416859 (cherry picked from commit 243ad0e26488e8b150551a490d6fedcce25d65a4) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2469350 Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* eqos: fix 'using uninitialized variable'Achal Verma2021-01-15
| | | | | | | | | | | | | | | | | | | stack variable should be initailized before use. This fix coverity issue : 20629 Bug 200689436 Change-Id: I56e9096a581dfe2cc9d1e41bfcc1c599af5993d6 Signed-off-by: Achal Verma <achalv@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2467801 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: Phoenix Jung <pjung@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit
* thermal: continuous: add custom dt entry supportKarthik Mantravadi2021-01-07
| | | | | | | | | | | | | | | | | | | | | Why? In the case of therm-fan-est driver, the dt entry is not added as part of thermal-zones. Hence, any continuous governor parameters defined under therm-fan-est node will not be considered by the continuous governor while binding to the thermal zone. How? Expose the dt parsing logic in continuous governor driver. This way therm-fan-est driver can call the dt parsing function passing the dt node defined under therm-fan-est dt entry. Bug 200594433 Change-Id: I06f1653209887f674db0636fe6f5803771d46877 Signed-off-by: Karthik Mantravadi <mkarthik@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2464743 Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
* drivers: therm_fan_est: Add crit_temp update sysfs nodeKarthik Mantravadi2021-01-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Why? There can be cases where external drivers might be registering their thermal zones instead of thermal frameworks's thermal-zones dt node. In such cases the therm_fan_est probe fails to find the thermal zone in the registered list. We need to wait till all the thermal zones in the therm_fan_est subdevs list are registered, so that the therm_fan_est driver can register its own thermal zone. In case the user driver is built as a module, runtime crit_temp calculation logic needs to be added in therm_fan_est driver. How? Return defer probe if therm_fan_est probe does not find any of its sub-dev thermal zones registered. This does not add complications if all the thermal zones are registered via thermal framework's DT. The changes get applied if individual drivers register their thermal zones as part of their probe sequences. If the user-driver is built as a module, after inserting the kernel module, user needs to - echo 1 > /sys/devices/thermal-fan-est/update_subdevs_crit_temps - check if an errors while getting crit temp from the thermal zone. Bug 200646929 Change-Id: I87b02b26232abef3621b6af611ef97b23831ac45 Signed-off-by: Karthik Mantravadi <mkarthik@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2461873 Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: Rajkumar Kasirajan <rkasirajan@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: Rajkumar Kasirajan <rkasirajan@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* nct1008: set external temperature limit even when detected openOle Bjørn Midtbø2020-12-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | Sometimes the external sensor is detected open during boot. This is suspected to be due to D+ > V+ - 0.3V before V+ voltage has properly settled. Not setting the shutdown limit in this case will cause thermal shutdown to be triggered when the sensor later is switched to extended range since the default limit 0x6C is then only 46C. Moving the check for open sensor to after setting limits and adding retries. The loop also triggers conversions since the open flag is only updated during conversion (not in standby mode). Bug 3150208 Change-Id: If95f053e405946668669360fa11aa1a935e7d6e7 Signed-off-by: Ahung Cheng <ahcheng@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2442149 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Srikar Srimath Tirumala <srikars@nvidia.com> Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: Rajkumar Kasirajan <rkasirajan@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: Rajkumar Kasirajan <rkasirajan@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit
* nct1008: use max conversion time for TMP451Ole Bjørn Midtbø2020-12-30
| | | | | | | | | | | | | | | | | | | | | | Use max (34ms) rather than typical (31ms) to make sure conversion is done when reading result. Also rename variable from '_ns' to '_us' to match variable unit. Bug 3150208 Change-Id: Ie4ebd79800fc93ffc44da2a61e060be0c2fdcb9f Signed-off-by: Ahung Cheng <ahcheng@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2442148 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Srikar Srimath Tirumala <srikars@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: Rajkumar Kasirajan <rkasirajan@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: Rajkumar Kasirajan <rkasirajan@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit
* misc: nvs: Add NVS GTE supportelilliebjerg2020-11-13
| | | | | | | | | | | | | | | | | | - Add the Tegra hardware Generic Timestamping Engine support to the NVidia Sensor framework. - Use CONFIG_NVS_GTE in Linux kernel config. Bug 3046736 Bug 2975033 Change-Id: I55397436ee635cdaf7788a3c5d6dc384601940df Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2342800 (cherry picked from commit 79de33624bb9f6cf10f77251039143d5d3128715) Signed-off-by: elilliebjerg <elilliebjerg@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2439322 Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Reviewed-by: automaticguardword <automaticguardword@nvidia.com>
* misc: nvs: Add on-change moduleelilliebjerg2020-11-13
| | | | | | | | | | | | | | | | | | - Create a common NVS module for on-change sensors. Bug 3046736 Bug 2975069 Change-Id: I1021c4a14db88ad3f8a2daa7c9efce7f667023a8 Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2374392 (cherry picked from commit d7cd7261814a024c86f4a96d4f320badae1bda49) Signed-off-by: elilliebjerg <elilliebjerg@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2439315 Reviewed-by: Greg Lo <glo@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* therm-fan-est: Add support for Tmargin to drive fanmkarthik2020-09-15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Why? Tmargin method of fan control allows multiple groups of therma-fan-est devices temperatures to be considered for the fan control algorithm/fan curve. The limitation of the existing max temp algorithm in therm-fan-est driver is that devices with different fan curves cannot be accomodated in the driver. In case, there are multple fan curves, the device which has the steepest curve wins the algoritm. Hence, taking the temperatures as a reference from their respective critical temperatures and using that value to drive the fan will help in accomodating both the devices' fan curves. How? * Calculate the effective crit temp of all the thermal zones during probe. * In the polling cycles, calculate the effective temperatures of the individual groups and use the tmargin formula to calculate the current temperature. * Since the Tmargin temp trip values are in reverse order, we need to use the reverse order in the pwm-fan dt profile. * The hysterysis is subtracted from the temp in cooling scenario to avoid frequent switching at trip temps. Since the tmargin trip values are taken in the decending order, hysterysis temps in dt should be given as negative values. Bug 200627962 Change-Id: Ideba4bfdb3d3306d1b4aff15093bcfac13d7bb86 Signed-off-by: Mantravadi Karthik <mkarthik@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2362354 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Rajkumar Kasirajan <rkasirajan@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: Rajkumar Kasirajan <rkasirajan@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit
* misc: pex9749: probe again if AIC is not up yetLeon Yu2020-08-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | The driver relies on i2c interface provided by pex9749 which might not be functional before the card is fully powered and operational. Since i2c devices (and therefore subsys) initializes faster than pci ones, it can happen that i2c probe happens before the AIC is up and fail due to not getting ACK. This occurs mostly when the driver is built into kernel. Fix that by requesting to probe later once (and once only) in late_init stage, where most things should have completed except for those requested deferred probe. Bug 200643079 Bug 200596607 Signed-off-by: Leon Yu <leoyu@nvidia.com> Change-Id: I6279c298945d34831fa341fd6f9e0353a975e5a9 Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2393600 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Manikanta Maddireddy <mmaddireddy@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit
* misc: Add PEX9749 thermal sensorLeon Yu2020-07-22
| | | | | | | | | | | | | | | | | | | This change adds PEX9749 (PCIe-MiniSAS) thermal sensor support. Thermal sensing operation is configured via i2c bus which can work independently of PCIe link state. Bug 200596607 Change-Id: I8a1d46ddc82b17da13a4a1d1d78756cb1906500b Signed-off-by: Leon Yu <leoyu@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2363798 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Preetham Chandru <pchandru@nvidia.com> Reviewed-by: Manikanta Maddireddy <mmaddireddy@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit
* nvs: core: Remove multi-linkelilliebjerg2020-07-07
| | | | | | | | | | | | | | | | | | | - NVS now uses the native IIO API for kernel 4.9 and above now that IIO supports multiple drivers per device. Bug 200622878 Change-Id: I8757440cd4a36606c57da5618f5951d2e2c5eab6 Signed-off-by: elilliebjerg <elilliebjerg@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2366174 (cherry picked from commit 45b2fe907d6499fabfd1f3a950eab152abaf4e6c) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2371307 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Robert Collins <rcollins@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: Robert Collins <rcollins@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra-profiler: add check for cpu clustersIgor Nabirushkin2020-06-24
| | | | | | | | | | | | | | | | | | | Add CPU clusters check for Carmel Uncore PMU events. This fixes a possible system crash. Bug 3032970 Change-Id: Ied9636ea1f1e578de4e289fef7895f18caaef508 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2365035 (cherry picked from commit cd922d6975afa3ae99eae49648d70bdf3509967e) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2366081 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* tegra-profiler: fix validation for uncore eventsIgor Nabirushkin2020-05-13
| | | | | | | | | | | | | | | | | | | | | | | | Do not start the Uncore component in the following cases: - If the parameters don't contain Uncore events. - Selected frequency is invalid (too large or too small). - Device is incompatible. Also, check the frequency for "all tasks" mode. Bug 2960340 Change-Id: I0fe18fcade82c7034d23cbbebcc2331e596cc8c1 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2337844 (cherry picked from commit e5164febe6e5a249648c9220093e3f3cea8f76c8) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2342517 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc-mods Fix irq registering for tegra modsLovie Wang2020-04-01
| | | | | | | | | | | | | | | | | | | | | | | Summary: Support to hook mods interrupts for tegra mods devices was broken due to gpu-mods changes that went uncaught in sanity. This change modifies the kernel to allow the tegra code paths to work again. This change also adds support to map irq numbers to gpio input pins to expand functionality in the irq framework. Bug 200598348 Bug 200601582 Change-Id: Ia1c6ece3cca9049a6309d19de183bea30564863e (cherry picked from commit db1caae5f55764ae4b47476b2f3bd5e118326db0) Signed-off-by: Lovie Wang <loview@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2321051 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Yu-Huan Hsu <yhsu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit
* misc: mods: move mods.h to uapiChris Dragan2020-03-26
| | | | | | | | | | | | | | | | | | | | moved mods.h to uapi directory as per Linux user-space ABI to give userland access of mods.h * Update SPDX license header. Bug 2657961 Change-Id: I65f4a8ff48c534144afc5aca7ce556dcc82d9342 (cherry picked from commit a525dd043ba3fc98d7f8fd9d5d1509c39df2b005) Signed-off-by: Ankit Patel <anpatel@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2315156 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Chris Dragan <kdragan@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* headers : move/modified header for User-space ABIAnkit Patel2020-03-25
| | | | | | | | | | | | | | | | | copied/moved/modified headers from the driver directory to the include/uapi directory, which have IOCTL components required to get access from user space as per Linux kernel user-space ABI. Bug 2657961 Signed-off-by: Ankit Patel <anpatel@nvidia.com> Change-Id: Ie70b2839e0a1031a685ff3e4bb93c73741645f44 Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2317530 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit
* eventlib: properly initialize localdmitry pervushin2020-03-24
| | | | | | | | | | | | | | | | | This fixes coverity issue 2011370 Bug 2028892 Change-Id: I628745c6c7819fe23f21101270c87543d4ed136d Signed-off-by: dmitry pervushin <dpervushin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2311736 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Hardik T Shah <hardikts@nvidia.com> Reviewed-by: Phoenix Jung <pjung@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit
* thermal: fix 'out of bound access'Achal Verma2020-03-24
| | | | | | | | | | | | | | | | | | | | correct range in for loop as per the static array size. This fixes coverity issues:9848167,9848011 Bug 2028892 Change-Id: I164967283ba4530fa66c6038d607dba0e2401152 Signed-off-by: Achal Verma <achalv@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2315581 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Dmitry Pervushin <dpervushin@nvidia.com> Reviewed-by: Phoenix Jung <pjung@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* kernel-mods:fix 'freeing stack element'Achal Verma2020-03-19
| | | | | | | | | | | | | | | | | | | | | In case size of arg is small enough to be copied into statically assigned buffer, kfree shouldn't free it mistakenly. This fixes coverity issue:2604401 Bug 2028892 Change-Id: I788fcaac922b3610d6ee81c9991ea7750273d465 Signed-off-by: Achal Verma <achalv@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2313957 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Dmitry Pervushin <dpervushin@nvidia.com> Reviewed-by: Phoenix Jung <pjung@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* tegra-profiler: support carmel perfmon eventsIgor Nabirushkin2020-02-18
| | | | | | | | | | | | | | | | | | | | tegra-profiler: - Support Carmel uncore perfmon events. - Remove obsolete pl310 code. Bug 2847789 Jira DTSP-6023 Change-Id: I41209b1b6bd17ace40be1190ce84de51548d9609 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2293698 (cherry picked from commit f26da26a3c3ac62ad919eb8f577fdea0bf15cb68) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2294398 Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra-profiler: fix duplicate mmap samplesIgor Nabirushkin2019-12-11
| | | | | | | | | | | | | | | | | | | Do not process fork calls for already handled processes. This prevents possible duplicate MMAP samples. Bug 2752793 Jira DTSP-5345 Change-Id: I2471292020dc85690a00666c58c6393f079c9f80 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2256706 (cherry picked from commit b27b1e2f818992a000dde9b102e68390ff46baae) Reviewed-on: https://git-master.nvidia.com/r/2259425 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra-profiler: add cpufreq capabilityIgor Nabirushkin2019-10-08
| | | | | | | | | | | | | | | | | | tegra-profiler capabilities: add cpufreq flag. Bug 2694772 Jira DTSP-1151 Change-Id: I0fc2503339ff796a9bdbaa9984f581edd1308613 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2189809 (cherry picked from commit 32ab6849716cb24243d29140df85f92c01fca356) Reviewed-on: https://git-master.nvidia.com/r/2211141 GVS: Gerrit_Virtual_Submit Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra-profiler: randomize sampling intervalIgor Nabirushkin2019-10-08
| | | | | | | | | | | | | | | | | | | Randomize the duration of the first sampling interval. Bug 2674361 Jira DTSP-4174 Change-Id: Ie267f5885fe42af0ac921765faa13183556158f7 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2172067 (cherry picked from commit 4f8c0952dd838301116594768358d92d94c0d499) Reviewed-on: https://git-master.nvidia.com/r/2184595 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra-profiler: add sampling optionsIgor Nabirushkin2019-10-08
| | | | | | | | | | | | | | | | | | | | | - Add a couple of sampling flags: timer/sched-out. - Fix timestamps for sched-out samples. Bug 2673543 Jira DTSP-4087 Jira DTSP-4395 Change-Id: I8e029cacdd4fbb73d27306db4889572d9f8b0a86 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2171321 (cherry picked from commit 411897429de57e90392b6ef327a10bd1e4b59dcf) Reviewed-on: https://git-master.nvidia.com/r/2184594 GVS: Gerrit_Virtual_Submit Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra-profiler: fix child processesIgor Nabirushkin2019-08-05
| | | | | | | | | | | | | | | | | | | Fix missed child processes in some cases. Bug 2645696 Jira DTSP-4006 Change-Id: Ie8945c8892379623cff9d2f7c743d92be682e1af Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2163192 (cherry picked from commit c88d2624234852a04156e22554886bd740d5263c) Reviewed-on: https://git-master.nvidia.com/r/2164934 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra-profiler: fix kernel stack info leakIgor Nabirushkin2019-08-02
| | | | | | | | | | | | | | | | | | | | Prevent stack info leak in tegra-profiler ioctl call (on-stack variable "state"). Bug 2664195 Jira DTSP-4202 Change-Id: I26ea694a29485463ea84abb48e028d8ab380029e Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2163187 (cherry picked from commit 0a751f93c6716ba8ec4d08230999ef0368d4a611) Reviewed-on: https://git-master.nvidia.com/r/2164936 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* Thermal: therm_fan_est: support continuous fan control featureTaylor Xiao2019-05-09
| | | | | | | | | | | | | | | | | | | | Update for therm_fan_est: Use delayed work of thermal core to update thermal zone temp instead of delayed work of therm_fan_est and poll period of delayed work of therm_fan_est is zero. Register function pointer for governor to fetch pwm value when thermal zone bind with cooling device. Bug 2540031 Change-Id: I503c7ba4e56257c9bcfbae695c58fefb16ed5ca3 Signed-off-by: Taylor Xiao <txiao@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2101167 GVS: Gerrit_Virtual_Submit Reviewed-by: Martin Gao <marting@nvidia.com> Reviewed-by: Vinayak Pane <vpane@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* include: uapi: move linux user-interface headersAnuj Gangwar2019-05-07
| | | | | | | | | | | | | | | | | | | Move the linux tegra_cpc user-interface headers from include/linux/ to include/uapi/linux/ Change the path for above headers in the dependent files. Bug 2062672 Change-Id: I674909f3188a746f3283b2e92296d9c18a2e767c Signed-off-by: Anuj Gangwar <anujg@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1956560 (cherry picked from commit 1373b074d8a76869e143337caeba5d42d213e43f) Reviewed-on: https://git-master.nvidia.com/r/2109985 Reviewed-by: Bibek Basu <bbasu@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* include: uapi: move compat_saf775x_ioctl.h fileAnuj Gangwar2019-05-06
| | | | | | | | | | | | | | | | | | | Move compat_saf775x_ioctl header file from drivers/misc/saf775x/ to include/uapi/misc/. Change the path for header in dependent c files. Bug 2062672 Change-Id: I959d16b8b56214cf2db83c05f181faf1def2a1e1 Signed-off-by: Anuj Gangwar <anujg@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2032464 (cherry picked from commit 07d3aa875210c2f833a60afa5fb5c546a33d29d7) Reviewed-on: https://git-master.nvidia.com/r/2109958 GVS: Gerrit_Virtual_Submit Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* include: uapi: move saf775x_ioctl.h with IOCTLAnuj Gangwar2019-05-06
| | | | | | | | | | | | | | | | | Create new header file saf775x_ioctl.h in include/uapi/misc/. The new file has IOCTL definitions which is moved from drivers/misc/saf775x/. Bug 2062672 Change-Id: Id180b15964d3e3a89da85a9117586b8b79ab641a Signed-off-by: Anuj Gangwar <anujg@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2077102 (cherry picked from commit 8c2f5f580dadb73e12b1a1866c8c4f267c6d0594) Reviewed-on: https://git-master.nvidia.com/r/2109932 GVS: Gerrit_Virtual_Submit Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* include: uapi: move eqos_ape_ioctl header fileAnuj Gangwar2019-05-03
| | | | | | | | | | | | | | | | | | | Move eqos_ape_ioctl header file from drivers/misc/eqos_ape/ to include/uapi/misc/. Change the path for above header in the dependent file. Bug 2062672 Change-Id: I471da15bcc8ecad1cec2855421bf88469737275a Signed-off-by: Anuj Gangwar <anujg@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2030422 (cherry picked from commit d5a783f1c86c9063d2e2bf9085376d20f028c7e4) Reviewed-on: https://git-master.nvidia.com/r/2109960 GVS: Gerrit_Virtual_Submit Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* Thermal: support trip_temps_hyst less than trip temps of lower levelTaylor Xiao2019-04-25
| | | | | | | | | | | | | | | | | | | | | Update as below: Before apply this change, trip_temps_hyst of higher level trip temps should be more than low level trip temps. After this change, support trip_temps_hyst less than trip temps of lower level. Bug 2347864 Bug 2490061 Change-Id: I7aa6d6410ed8939c8abe5ad2a517fb03d61739e4 Signed-off-by: Taylor Xiao <txiao@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2075303 Reviewed-by: Daniel Fu <danifu@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Terry Wang <terwang@nvidia.com> Reviewed-by: Vinayak Pane <vpane@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra_profiler: fix wrong array indexIgor Nabirushkin2019-04-11
| | | | | | | | | | | | | | | | | | | Fix wrong ex_region_info indexes in remove_overlapped_regions() function that can lead to crash in mmap_ex_entry_del(). Bug 2548434 Jira DTSP-2959 Change-Id: Ic9930cc8bbb7a5b2a5599cf3f37a7e57668a9305 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2086206 (cherry picked from commit 262bc4d4b33a6bf753d0050e33617d58b8946e12) Reviewed-on: https://git-master.nvidia.com/r/2093408 GVS: Gerrit_Virtual_Submit Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra_profiler: fix error messageIgor Nabirushkin2019-04-11
| | | | | | | | | | | | | | | | | | | | | | Do not use DWARF functionality (quadd_is_ex_entry_exist_dwarf() function) if the appropriate option is disabled. This fixes the following error message: | tegra_profiler: error: wrong dwarf size Bug 2548386 Jira DTSP-2956 Change-Id: If66aa2c74373fd7789d44120a379fbfbca7c775a Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2086173 (cherry picked from commit da8b1aa1f08b737019056e70265ed1e0599609c5) Reviewed-on: https://git-master.nvidia.com/r/2093407 GVS: Gerrit_Virtual_Submit Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra-profiler: add task comm eventsIgor Nabirushkin2019-04-11
| | | | | | | | | | | | | | | | | | | | Add task COMM events: - Add support for quadd_event_comm() callback. - Send task COMM events to userspace. Bug 2514095 Jira DTSP-2432 Change-Id: Id5b92f544497b69098e3b16bf82baf0f6abb77e1 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2027490 (cherry picked from commit a0c0d3bf9eeabbdad2a43b768235e1cc846b04ef) Reviewed-on: https://git-master.nvidia.com/r/2093405 GVS: Gerrit_Virtual_Submit Reviewed-by: Roman Rybalko <rrybalko@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* drivers: misc: add sleep mode supportMartin Gao2019-03-14
| | | | | | | | | | | | | | | | | | | - per proposed design (detailed in the bug), "sleep mode" temp: same as turn-on temperature; "non-sleep mode" temp: same as turn-off temperature - attempt to turn off fan once, if device in sleep and temp is lower than "sleep mode" temp Bug 2527983 Change-Id: I24bf63e46590fa3fd33a4641403645132c473240 Signed-off-by: Martin Gao <marting@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2035503 Reviewed-by: Daniel Fu <danifu@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Vinayak Pane <vpane@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* driver: therm_fan_est: fix lockdep annotationsumitg2019-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix lockdep warning by moving rwlock_init(&est_data->state_lock) before using. Warning fixed: INFO: trying to register non-static key. the code is fine but needs lockdep annotation. turning off the locking correctness validator. .... Call trace: [<ffffff800808ccb0>] dump_backtrace+0x0/0x1a0 [<ffffff800808d354>] show_stack+0x24/0x30 [<ffffff80084ce2f0>] dump_stack+0xa8/0xd8 [<ffffff800812f8cc>] register_lock_class+0x4fc/0x538 [<ffffff8008133efc>] __lock_acquire+0x7c/0x748 [<ffffff80081349cc>] lock_acquire+0xc4/0x290 [<ffffff80090ad35c>] _raw_read_lock+0x4c/0x60 [<ffffff80088ab550>] therm_fan_est_get_trip_temp+0x38/0x138 [<ffffff8008c60148>] thermal_zone_device_register+0x230/0x778 [<ffffff80088ace68>] therm_fan_est_probe+0xa40/0xc48 Bug 200464909 Change-Id: I60d038a729e018edf260b4d83ecee278a9816b31 Signed-off-by: sumitg <sumitg@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2030043 Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Nat Pettipaw <npettipaw@nvidia.com> Reviewed-by: Vinayak Pane <vpane@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* driver: therm_fan_est: Add fan profilesNat Pettipaw2019-02-27
| | | | | | | | | | | | | | | Allow for different fan profiles to be set for trip point temp/hyst. Bug 2340648 Change-Id: Idb86df6bff74e998f1c1dc73c05e5129044ec09b Signed-off-by: Nat Pettipaw <npettipaw@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1961285 Reviewed-by: Daniel Fu <danifu@nvidia.com> Reviewed-by: Vinayak Pane <vpane@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* tegra-profiler: power_clk: fix possible deadlockIgor Nabirushkin2019-02-14
| | | | | | | | | | | | | | | | | | | | | | | - power_clk: There is a potential deadlock if clk_notifier_unregister() happens during XXXX_notifier_call() callback. Use mutex_trylock() to prevent a possible deadlock. - power_rate samples: Do not send unchanged values. Bug 2491022 Jira DTSP-2248 Change-Id: I53eac956728de88ca645a0ae7ca4e3eb66b2c570 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2016234 (cherry picked from commit a26746d7350d89a351592cf1d0e7b78996b1c342) Reviewed-on: https://git-master.nvidia.com/r/2018190 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Dmitry Antipov <dantipov@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* Revert "CEC: print short device name"Vinayak Pane2019-01-28
| | | | | | | | | | | | | This reverts commit 7361e6a275affd6eb5231d6c4b5dae79ad514438. Bug 200468133 Change-Id: Ib689efb26370b4d1e028c5c1f23cf2655acdb539 Signed-off-by: Vinayak Pane <vpane@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2004296 GVS: Gerrit_Virtual_Submit Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* misc: tegra-profiler: fix unordered samplesIgor Nabirushkin2019-01-22
| | | | | | | | | | | | | | | | | | | | | Mmap samples: prevent possible events in put_mmap_sample() function between quadd_get_time() and quadd_put_sample_this_cpu(). This fixes unordered samples. Bug 2483965 DTSP-1771 Change-Id: I9a2f3f5de0c9b2d6da4bf68b73c16bf92d801a24 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1992767 (cherry picked from commit 9fefd79cccbf9a6f1dfc72b8c71687ceaa99b722) Reviewed-on: https://git-master.nvidia.com/r/2000202 GVS: Gerrit_Virtual_Submit Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Dmitry Antipov <dantipov@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* tegra-profiler: dwarf: support multiple processesIgor Nabirushkin2019-01-18
| | | | | | | | | | | | | | | | | | | | - Support DWARF/ARM-EHABI unwinding for multiple processes. - Add cpu_id for MMAP samples. Bug 2438564 Jira DTSP-824 Jira DTSP-1599 Change-Id: I998906011cff240b9a554cd40679cd9ec9c0f7b7 Signed-off-by: Igor Nabirushkin <inabirushkin@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1945653 (cherry picked from commit 20e2cf7d2509dfc4708f4a3720aee26852998f13) Reviewed-on: https://git-master.nvidia.com/r/1992080 Reviewed-by: Dmitry Antipov <dantipov@nvidia.com> Reviewed-by: Bibek Basu <bbasu@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* CEC: print short device nameChun Xu2019-01-18
| | | | | | | | | | | | | | | | Print short device name when dump CEC message and block. Bug 200468133 Change-Id: I2839d7d2005742a67d1bd65daa3b08e9e57be7a6 Signed-off-by: Chun Xu <chunx@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1980201 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Prafull Suryawanshi <prafulls@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: Mitch Luban <mluban@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* iio: aon: Fix typo in error messageRobert Collins2019-01-10
| | | | | | | | | | | | | | | | | | | | - AONSH driver emits error messages for missing device tree nodes. One of the node names changed from 'gpio' to 'gpios.' The error message was never updated to reflect the name changes. This patch fixes the error message. Bug 1909092 Signed-off-by: Robert Collins <rcollins@nvidia.com> Change-Id: Ie3b36124d928c32e2971e79641273ff9cca2020c Reviewed-on: https://git-master.nvidia.com/r/1938551 (cherry picked from commit 45758dbc1b790fbd3a6f40ba603ed4a46b66fc4c) Reviewed-on: https://git-master.nvidia.com/r/1986036 Reviewed-by: Erik Lilliebjerg <elilliebjerg@nvidia.com> Reviewed-by: Akhilesh Khumbum <akhumbum@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
* nct1008: update initializing sequenceKary Jin2018-11-26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In current code, the "extended range" and "standby" are enabled in one register writing. However, this might cause one race condition in hardware. If the "extended range" is enabled first and then it will cause the thermal shutdown as the LOC/EXT limit is converted to low value. This patch fixes this issue by 1) Enable the "standby" first and then enable "extended range" after setting LOC/EXT limit 2) Do a delay after enabling "standby". Generally, it will really enter into "standby" once the conversion is finished, so this delay will make sure it enters into "standby" mode as expected. Bug 200440952 Change-Id: I7a43e28b89d80a4a3e89ba88030a1c0eaddfbb14 Signed-off-by: Kary Jin <karyj@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1827213 (cherry picked from commit a739418375b8a292670d674e0c8fa38465475439) Reviewed-on: https://git-master.nvidia.com/r/1940004 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Daniel Fu <danifu@nvidia.com> Reviewed-by: Srikar Srimath Tirumala <srikars@nvidia.com> Reviewed-by: Vinayak Pane <vpane@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>