summaryrefslogtreecommitdiffstats
path: root/drivers/power/pmic/stpmic1.c
Commit message (Collapse)AuthorAgeFilesLines
* dm: core: Create a new header file for 'compat' featuresSimon Glass2020-02-051-0/+1
| | | | | | | | | | | | At present dm/device.h includes the linux-compatible features. This requires including linux/compat.h which in turn includes a lot of headers. One of these is malloc.h which we thus end up including in every file in U-Boot. Apart from the inefficiency of this, it is problematic for sandbox which needs to use the system malloc() in some files. Move the compatibility features into a separate header file. Signed-off-by: Simon Glass <sjg@chromium.org>
* common: Move get_ticks() function out of common.hSimon Glass2019-12-021-0/+1
| | | | | | | This function belongs in time.h so move it over and add a comment. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
* stpmic1: simplify stpmic1_sysreset_requestPatrick Delaunay2019-08-271-8/+1
| | | | | | | Retrieve parent device from dev->parent instead of calling uclass_get_device_by_driver() Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
* pmu: stpmic1: change specific NVM api to MISCPatrick Delaunay2019-08-271-42/+56
| | | | | | | | | Use MISC u-class to export the NVM register (starting at 0xF8 offset) and avoid specific API. - SHADOW have offset < 0. - NVM have register > 0 Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
* pmic: stpmic1: add support for SYSRESET_POWER_OFFPatrick Delaunay2019-07-121-3/+8
| | | | | | | | | Adds support for SYSRESET_POWER_OFF = PMIC power off used by command power off and introduced by commit 751fed426f87 ("sysreset: Add a way to find the last reset"). The driver use SYSRESET_POWER for the PMIC-level power cycle, with restart. Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
* stpmic1: add NVM update support in fuse commandPatrick Delaunay2019-04-121-0/+114
| | | | | | | | | | | | | | | | Add functions to read/update the non volatile memory of STPMIC1 (8 bytes-register at 0xF8 address) and allow access with fuse command (bank=1, word > 0xF8). For example: STM32MP> fuse read 1 0xf8 8 Reading bank 1: Word 0x000000f8: 000000ee 00000092 000000c0 00000002 Word 0x000000fc: 000000f2 00000080 00000002 00000033 Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
* pmic: stpmu1: add power switch off supportPatrick Delaunay2019-04-121-0/+46
| | | | | | | Add sysreset support, and support power switch off request, needed by poweroff command. Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
* power: rename stpmu1 to official name stpmic1Patrick Delaunay2019-04-121-31/+31
| | | | | | | | | Alignment with kernel driver name & binding introduced by https://patchwork.kernel.org/cover/10761943/ to use the final marketing name = STPMIC1. Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com> Reviewed-by: Lukasz Majewski <lukma@denx.de>
* power: stpmu1: rename files to stpmic1Patrick Delaunay2019-04-121-0/+95
Prepare file modification for kernel alignment and rename driver to stpmic1. Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com> Reviewed-by: Lukasz Majewski <lukma@denx.de>