Chandni Cherukuri | 3aa09f7 | 2018-11-28 11:31:51 +0530 | [diff] [blame] | 1 | /* |
Rohit Mathew | a0dd307 | 2024-02-03 17:22:54 +0000 | [diff] [blame] | 2 | * Copyright (c) 2018-2024, Arm Limited and Contributors. All rights reserved. |
Chandni Cherukuri | 3aa09f7 | 2018-11-28 11:31:51 +0530 | [diff] [blame] | 3 | * |
| 4 | * SPDX-License-Identifier: BSD-3-Clause |
| 5 | */ |
| 6 | |
Antonio Nino Diaz | e0f9063 | 2018-12-14 00:18:21 +0000 | [diff] [blame] | 7 | #include <plat/common/platform.h> |
Rohit Mathew | a0dd307 | 2024-02-03 17:22:54 +0000 | [diff] [blame] | 8 | |
| 9 | #include <nrd_plat.h> |
| 10 | #include <nrd_variant.h> |
Ambroise Vincent | b237bca | 2019-02-13 15:58:00 +0000 | [diff] [blame] | 11 | |
Rohit Mathew | 0ec6ed9 | 2024-02-03 18:39:10 +0000 | [diff] [blame] | 12 | unsigned int plat_arm_nrd_get_platform_id(void) |
Chandni Cherukuri | 3aa09f7 | 2018-11-28 11:31:51 +0530 | [diff] [blame] | 13 | { |
| 14 | return mmio_read_32(SSC_VERSION) & SSC_VERSION_PART_NUM_MASK; |
| 15 | } |
| 16 | |
Rohit Mathew | 0ec6ed9 | 2024-02-03 18:39:10 +0000 | [diff] [blame] | 17 | unsigned int plat_arm_nrd_get_config_id(void) |
Chandni Cherukuri | 3aa09f7 | 2018-11-28 11:31:51 +0530 | [diff] [blame] | 18 | { |
| 19 | return (mmio_read_32(SSC_VERSION) >> SSC_VERSION_CONFIG_SHIFT) |
| 20 | & SSC_VERSION_CONFIG_MASK; |
| 21 | } |
Vijayenthiran Subramaniam | 2b4ad8d | 2019-09-23 19:32:32 +0530 | [diff] [blame] | 22 | |
Rohit Mathew | 0ec6ed9 | 2024-02-03 18:39:10 +0000 | [diff] [blame] | 23 | unsigned int plat_arm_nrd_get_multi_chip_mode(void) |
Vijayenthiran Subramaniam | 8af1843 | 2019-10-22 15:46:14 +0530 | [diff] [blame] | 24 | { |
| 25 | return 0; |
| 26 | } |
| 27 | |
Vijayenthiran Subramaniam | 2b4ad8d | 2019-09-23 19:32:32 +0530 | [diff] [blame] | 28 | void bl31_platform_setup(void) |
| 29 | { |
Rohit Mathew | 0ec6ed9 | 2024-02-03 18:39:10 +0000 | [diff] [blame] | 30 | nrd_bl31_common_platform_setup(); |
Vijayenthiran Subramaniam | 2b4ad8d | 2019-09-23 19:32:32 +0530 | [diff] [blame] | 31 | } |