summaryrefslogtreecommitdiff
path: root/sys/dev/psci/psci.c
Commit message (Collapse)AuthorAgeFilesLines
* psci: clean up empty lines in .c and .h filesMateusz Guzik2020-09-011-1/+0
| | | | Notes: svn path=/head/; revision=365173
* Add generic arm/arm64 secure-monitor SMCCC interface and switchRuslan Bukin2019-09-131-6/+11
| | | | | | | | | | | | | | | | PSCI code to use it. This interface will also be used by Intel Stratix 10 platform. This was not tested on arm due to lack of PSCI-enabled arm hardware lying around. Reviewed by: andrew Sponsored by: DARPA, AFRL Differential Revision: https://reviews.freebsd.org/D21439 Notes: svn path=/head/; revision=352301
* PSCI: Don't take missing implementation of psci get_version() as fatal.Michal Meloun2019-03-191-16/+49
| | | | | | | | | | | Minimalistic PSCI implementation in U-Boot doesn't implement get_version() method for some SoC. In this case, use PSCI version declared by 'psci' node in DT as fallback. MFC after: 2 weeks Notes: svn path=/head/; revision=345299
* psci: Add \n at the end of printfEmmanuel Vadot2018-07-061-1/+1
| | | | | | | | Add a \n at the end of the printf if no PSCI function was found otherwise it mess up the console log. Notes: svn path=/head/; revision=336037
* Move psci_call to a header file so we can use it in other files toAndrew Turner2018-06-131-8/+1
| | | | | | | | | communicate with the firmware. Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=335061
* Add a handler for the PSCI_FEATURES function. This needs PSCI 1.0, soAndrew Turner2018-06-131-0/+14
| | | | | | | | | check for this, returning an error if the version is too old. Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=335056
* Find and cache the PSCI version on driver attach.Andrew Turner2018-06-131-0/+3
| | | | | | | Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=335055
* Rework PSCI so it only searches for the call function once.Andrew Turner2018-06-121-42/+64
| | | | | | | | | | | This is in preperation for supporting newer smccc functions that also use the same call method. Reviewed by: manu Differential Revision: https://reviews.freebsd.org/D15745 Notes: svn path=/head/; revision=334999
* Add a function to find the PSCI version the firmware implements fromAndrew Turner2018-01-091-2/+11
| | | | | | | | | | outside the PSCI driver. MFC after: 1 week Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=327728
* psci: change bootverbose string to 'PSCI 0.2 compatible'Ed Maste2017-10-191-1/+1
| | | | | | | | | | | | | Prior to r324754 we treated PSCI 0.2 and 1.0 as identical, and r324754 extended that to include all PSCI 1.x revisions. Change the string emitted under bootverbose to reference '0.2 compatible' to avoid confusion when the system includes a later PSCI rev. Discussed with: andrew Sponsored by: The FreeBSD Foundation Notes: svn path=/head/; revision=324758
* Allow later PSCI revisions to also work. The latest ARM Trusted FirmwareAndrew Turner2017-10-191-1/+1
| | | | | | | | | | | reports version 1.1 so the check was failing. As thjis is a minor change from 1.0, and future 1.x revisions are also expected to be backwards compatible just ignore the minor revision in the init handler. Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=324754
* Also handle psci 1.0. This can be seen as a bug fix update for the 0.2Andrew Turner2017-10-061-3/+6
| | | | | | | | | | specification we already support, with the only changes in functions we don't currently use. Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=324368
* Call the PSCI reset from cpu_reset on arm64. When rebooting from DDB theAndrew Turner2017-04-241-0/+7
| | | | | | | | | | | | kernel calls this directly so the event handler is not called, meaning the computer fails to reboot. Tested by: cognet MFC after: 1 week Sponsored by: DARPA, AFRL Notes: svn path=/head/; revision=317361
* Add ACPI support to the PSCI driver. This checks the Fixed ACPI DescriptionAndrew Turner2016-12-071-25/+219
| | | | | | | | | | | Table to find if the hardware supports PSCI, and if so what method the kernel should use to interact with it. Obtained from: ABT Systems Ltd Sponsored by: The FreeBSD Foundation Notes: svn path=/head/; revision=309674
* Create a new PSCI error code and use it to signal that starting the CPU isAndrew Turner2016-10-251-2/+2
| | | | | | | | | impossible as the PSCI firmware is missing. Sponsored by: ABT Systmes Ltd Notes: svn path=/head/; revision=307910
* Start to support PSCI 1.0. For all the functions we currently support thisAndrew Turner2015-08-111-14/+15
| | | | | | | | | | can be seen as the same as 0.2. There are changes with the data passed to CPU_SUSPEND, however we don't yet use this call. Sponsored by: ABT Systems Ltd Notes: svn path=/head/; revision=286630
* Rework the PSCI cpu on code to allow it to work before device drivers haveAndrew Turner2015-05-241-18/+39
| | | | | | | | started. This allows this functions to be used with the regular ARM SMP initialisation sequence. Notes: svn path=/head/; revision=283363
* Add a driver for the ARM Power State Coordination Interface (PSCI). ThisAndrew Turner2015-04-121-0/+286
handles versions 0.1 and 0.2 of the standard on 32-bit ARM. With this driver we can shutdown in QEMU. Further work is needed to turn secondary cores on on boot and to support later revisions of the specification. Submitted by: Robin Randhawa <Robin.Randhawa at ARM.com> Sponsored by: The FreeBSD Foundation Notes: svn path=/head/; revision=281466