aboutsummaryrefslogtreecommitdiff
path: root/sys/powerpc/cpufreq
Commit message (Collapse)AuthorAgeFilesLines
* cpufreq(4): Fix a typo in a source code commentGordon Bergling2026-01-311-1/+1
| | | | | | - s/transcation/transaction/ MFC after: 5 days
* powerpc: Use proper prototype for SYSINIT functionsZhenlei Huang2025-10-131-1/+2
| | | | MFC after: 1 week
* newbus: replace leftover device unit wildcardsAhmad Khalifa2025-06-215-10/+10
| | | | | | Reviewed by: imp, jhb Approved by: imp (mentor) Differential Revision: https://reviews.freebsd.org/D50913
* sys: Automated cleanup of cdefs and other formattingWarner Losh2023-11-275-5/+0
| | | | | | | | | | | | | | | | Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row. Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/ Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/ Remove /\n+#if.*\n#endif.*\n+/ Remove /^#if.*\n#endif.*\n/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/ Sponsored by: Netflix
* sys: Remove $FreeBSD$: one-line .c patternWarner Losh2023-08-165-10/+0
| | | | Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
* spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSDWarner Losh2023-05-124-4/+4
| | | | | | | | | The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch up to that fact and revert to their recommended match of BSD-2-Clause. Discussed with: pfg MFC After: 3 days Sponsored by: Netflix
* powerpc: Use valid prototypes for function declarations with no arguments.John Baldwin2023-04-241-1/+1
| | | | | Reviewed by: emaste Differential Revision: https://reviews.freebsd.org/D39733
* cpufreq: Remove unused devclass arguments to DRIVER_MODULE.John Baldwin2022-05-065-10/+5
|
* powerpc cpufreq: Remove unused variables.John Baldwin2022-04-122-6/+0
|
* powerpc: clean up empty lines in .c and .h filesMateusz Guzik2020-09-015-18/+8
| | | | Notes: svn path=/head/; revision=365073
* powerpc: Fix cpufreq statement scopingJustin Hibbits2019-03-082-4/+8
| | | | | | | | | | | | | The second statements on the lines are not guarded by the `if' condition. This triggers a warning with newer gcc. It's relatively harmless given the usage, but incorrect. Instead, wrap the statements so they're properly guarded. Reported by: powerpc64-gcc xtoolchain MFC after: 1 week Notes: svn path=/head/; revision=344915
* pmcr: Fix pstate setting on Power8Conrad Meyer2018-12-011-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | Fix p-state setting on Power8 by removing the accidental double-indirection of the pstate_ids table. The pstate_ids table comes from the OF property "ibm,pstate-ids." On Power9, the values happen to be identical to the indices, so the extra indirection was harmless. On Power8, the values were out of the range [0, npstates], so pmcr_set() would fail the spec[0] range check with EINVAL. While here, include both the value and index in the driver-specific register array as spec[0] and spec[1] respectively. They're redundant, but relatively harmless, and it may aid debugging. While here, fix the range check to exclude the index npstates, which is one past the last valid index. PR: 233693 Reported and tested by: sbruno Reviewed by: jhibbits Notes: svn path=/head/; revision=341389
* Fix the build post-PMCR addition.Justin Hibbits2018-06-211-1/+1
| | | | | | | Submitted by: lwhsu Notes: svn path=/head/; revision=335491
* Introduce PMCR-based cpufreq(4) driver, for IBM POWER8 and POWER9 systemsJustin Hibbits2018-06-211-0/+248
| | | | | | | | | | | | | | | | | | | Summary: POWER8 and POWER9 use a single CPU register, per core, to change clock speed. Everything else is handled by the on-chip controller. This change necessitates a change to the cpufreq global kernel driver to bump supported levels, as the device tree for these systems can have theoretically 256 different options. On my POWER9 Talos, the list consists of 100 items. At 16.67MHz intervals, that allows for a change of roughly 1.67GHz between lowest and highest. This has only been tested on the POWER9. However, since they're similar, this should work on POWER8 as well. Reviewed By: nwhitehorn Differential Revision: https://reviews.freebsd.org/D15932 Notes: svn path=/head/; revision=335481
* [ofw] fix errneous checks for OF_finddevice(9) return valueOleksandr Tymoshenko2018-03-201-1/+1
| | | | | | | | | | | | | | | OF_finddevices returns ((phandle_t)-1) in case of failure. Some code in existing drivers checked return value to be equal to 0 or less/equal to 0 which is also wrong because phandle_t is unsigned type. Most of these checks were for negative cases that were never triggered so trhere was no impact on functionality. Reviewed by: nwhitehorn MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D14645 Notes: svn path=/head/; revision=331229
* sys/powerpc: further adoption of SPDX licensing ID tags.Pedro F. Giffuni2017-11-273-0/+6
| | | | | | | | | | | | | | | Mainly focus on files that use BSD 2-Clause license, however the tool I was using misidentified many licenses so this was mostly a manual - error prone - task. The Software Package Data Exchange (SPDX) group provides a specification to make it easier for automated tools to detect and summarize well known opensource licenses. We are gradually adopting the specification, noting that the tags are considered only advisory and do not, in any way, superceed or replace the license texts. Notes: svn path=/head/; revision=326261
* Add cpufreq support for P1022 and MPC8536Justin Hibbits2017-07-211-0/+343
| | | | | | | | | P1022 and MPC8536 include a 'jog' feature for clock control (jog being a slower form of run mode). This is done by changing the PLL multiplier, and cannot be done if any core is in doze or sleep mode. Notes: svn path=/head/; revision=321318
* Some style(9) fixesJustin Hibbits2013-12-131-4/+3
| | | | | | | | MFC after: 1 month X-MFC with: r259284 Notes: svn path=/head/; revision=259287
* Add PMU-based CPU frequency scaling. This method is used on most TitaniumJustin Hibbits2013-12-131-0/+222
| | | | | | | | | PowerBooks. MFC after: 1 month Notes: svn path=/head/; revision=259284
* Remove unused variables. Spotted by a cppcheckAndreas Tobler2011-01-062-4/+0
| | | | | | | | | (devel/cppcheck, http://sourceforge.net/projects/cppcheck) run. Approved by: nwhitehorn (mentor) Notes: svn path=/head/; revision=217065
* MFppc64:Nathan Whitehorn2010-07-131-3/+8
| | | | | | | | | | Kernel sources for 64-bit PowerPC, along with build-system changes to keep 32-bit kernels compiling (build system changes for 64-bit kernels are coming later). Existing 32-bit PowerPC kernel configurations must be updated after this change to specify their architecture. Notes: svn path=/head/; revision=209975
* On SMP G5 systems, sometimes the power-mode-data property is only foundNathan Whitehorn2010-05-161-0/+5
| | | | | | | on CPU 0, so look there if it is not otherwise available. Notes: svn path=/head/; revision=208150
* Add cpufreq support on the PowerPC G5, along with a skeleton SMU driverNathan Whitehorn2009-06-231-0/+333
| | | | | | | | in order to slew CPU voltage during frequency changes. The OpenBSD SMU driver was an extremely helpful reference for this. Notes: svn path=/head/; revision=194679
* Introduce support for cpufreq on PowerPC with the dynamic frequencyNathan Whitehorn2009-05-311-0/+230
switching capabilities of the MPC7447A and MPC7448. Notes: svn path=/head/; revision=193156