summaryrefslogtreecommitdiffstats
path: root/drivers/memory/brcmstb_dpfe.c
Commit message (Collapse)AuthorAgeFilesLines
* memory: brcmstb: dpfe: support new way of passing data from the DCPUMarkus Mayer2018-02-231-10/+55
| | | | | | | | | | | | | The DCPU can now send message data in two ways: - via the data RAM, as before (this is now message type 0) - via the message RAM (this is message type 1) In order to support both methods, we check the message type of the response (bits 31:28) and then treat the offset (bits 27:0) accordingly. Signed-off-by: Markus Mayer <mmayer@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
* memory: brcmstb: dpfe: fix type declaration of variable "ret"Markus Mayer2018-02-231-3/+3
| | | | | | | | In some functions, variable "ret" should be ssize_t, so we fix it. Fixes: 2f330caff577 ("memory: brcmstb: Add driver for DPFE") Signed-off-by: Markus Mayer <mmayer@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
* memory: brcmstb: dpfe: properly mask vendor error bitsMarkus Mayer2018-02-231-1/+2
| | | | | | | | | We were printing the entire 32 bit register rather than just the lower 8 bits. Anything above bit 7 is reserved and may be any random value. Fixes: 2f330caff577 ("memory: brcmstb: Add driver for DPFE") Signed-off-by: Markus Mayer <mmayer@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
* memory: brcmstb: dpfe: skip downloading firmware when possibleMarkus Mayer2017-10-071-2/+14
| | | | | | | | | | | | We want to skip downloading the DPFE firmware from Linux if it was already downloaded by the boot loader. The driver now checks if the DCPU is already running and, if so, whether it can process commands. If the DCPU processes commands successfully, the driver skips the firmware download step. Signed-off-by: Markus Mayer <mmayer@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
* memory: brcmstb: dpfe: introduce is_dcpu_enabled()Markus Mayer2017-10-071-6/+15
| | | | | | | | In order to check whether or not the DCPU is running, we introduce a function called is_dcpu_enabled(). Signed-off-by: Markus Mayer <mmayer@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
* memory: brcmstb: Add driver for DPFEMarkus Mayer2017-09-181-0/+701
This driver allows access to DRAM properties, such as the refresh rate, via the Broadcom STB DDR PHY Front End (DPFE). The refresh rate can be used as indirect indicator of the DRAM temperature. The driver also allows setting of the sampling interval. Signed-off-by: Markus Mayer <mmayer@broadcom.com> Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>