Antonio Nino Diaz | 7298c1f | 2018-12-05 00:09:30 +0000 | [diff] [blame] | 1 | /* |
Carlo Caione | e5a30db | 2019-08-24 17:31:51 +0100 | [diff] [blame] | 2 | * Copyright (c) 2018-2019, ARM Limited and Contributors. All rights reserved. |
Antonio Nino Diaz | 7298c1f | 2018-12-05 00:09:30 +0000 | [diff] [blame] | 3 | * |
| 4 | * SPDX-License-Identifier: BSD-3-Clause |
| 5 | */ |
| 6 | |
| 7 | #include <stdint.h> |
| 8 | |
Carlo Caione | e5a30db | 2019-08-24 17:31:51 +0100 | [diff] [blame] | 9 | #include "aml_private.h" |
Antonio Nino Diaz | 7298c1f | 2018-12-05 00:09:30 +0000 | [diff] [blame] | 10 | |
| 11 | static int32_t modules_initialized = -1; |
| 12 | |
| 13 | /******************************************************************************* |
| 14 | * Unknown commands related to something thermal-related |
| 15 | ******************************************************************************/ |
Carlo Caione | 68aa5ee | 2019-08-25 18:09:59 +0100 | [diff] [blame] | 16 | void aml_thermal_unknown(void) |
Antonio Nino Diaz | 7298c1f | 2018-12-05 00:09:30 +0000 | [diff] [blame] | 17 | { |
| 18 | uint16_t ret; |
| 19 | |
| 20 | if (modules_initialized == -1) { |
Carlo Caione | 7bb8302 | 2019-08-28 10:08:24 +0100 | [diff] [blame] | 21 | aml_scpi_efuse_read(&ret, 0, 2); |
Antonio Nino Diaz | 7298c1f | 2018-12-05 00:09:30 +0000 | [diff] [blame] | 22 | modules_initialized = ret; |
| 23 | } |
| 24 | |
Carlo Caione | 7bb8302 | 2019-08-28 10:08:24 +0100 | [diff] [blame] | 25 | aml_scpi_unknown_thermal(10, 2, /* thermal */ |
| 26 | 13, 1); /* thermalver */ |
Antonio Nino Diaz | 7298c1f | 2018-12-05 00:09:30 +0000 | [diff] [blame] | 27 | } |