| Tim Wawrzynczak | 605660b | 2022-06-08 12:48:19 -0600 | [diff] [blame^] | 1 | -- |
| 2 | -- Copyright (C) 2022 Google, LLC |
| 3 | -- |
| 4 | -- This program is free software; you can redistribute it and/or modify |
| 5 | -- it under the terms of the GNU General Public License as published by |
| 6 | -- the Free Software Foundation; either version 2 of the License, or |
| 7 | -- (at your option) any later version. |
| 8 | -- |
| 9 | -- This program is distributed in the hope that it will be useful, |
| 10 | -- but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 11 | -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 12 | -- GNU General Public License for more details. |
| 13 | -- |
| 14 | |
| 15 | private package HW.GFX.GMA.PLLs |
| 16 | with |
| 17 | Abstract_State => (State with Part_Of => GMA.State) |
| 18 | is |
| 19 | |
| 20 | -- XXX: Types should be private (but that triggers a bug in SPARK GPL 2016) |
| 21 | type T is (Invalid_PLL, DPLL0, DPLL1, DPLL4, DPLL2); |
| 22 | subtype Configurable_DPLLs is T range DPLL0 .. DPLL4; |
| 23 | Invalid : constant T := Invalid_PLL; |
| 24 | |
| 25 | procedure Initialize |
| 26 | with |
| 27 | Global => (Output => State); |
| 28 | |
| 29 | pragma Warnings (Off, "unused variable ""Port_Cfg""", |
| 30 | Reason => "Not yet implemented."); |
| 31 | procedure Alloc |
| 32 | (Port_Cfg : in Port_Config; |
| 33 | PLL : out T; |
| 34 | Success : out Boolean); |
| 35 | pragma Warnings (On, "unused variable ""Port_Cfg"""); |
| 36 | |
| 37 | |
| 38 | pragma Warnings (Off, "subprogram ""Free"" has no effect", |
| 39 | Reason => "Not yet implemented."); |
| 40 | procedure Free (PLL : T); |
| 41 | pragma Warnings (On, "subprogram ""Free"" has no effect"); |
| 42 | |
| 43 | pragma Warnings (Off, "subprogram ""All_Off"" has no effect", |
| 44 | Reason => "Not yet implemented."); |
| 45 | procedure All_Off; |
| 46 | pragma Warnings (On, "subprogram ""All_Off"" has no effect"); |
| 47 | |
| 48 | pragma Warnings (Off, "unused variable ""PLL""", |
| 49 | Reason => "Not yet implemented."); |
| 50 | function Register_Value (PLL : T) return Word32; |
| 51 | pragma Warnings (On, "unused variable ""PLL"""); |
| 52 | |
| 53 | end HW.GFX.GMA.PLLs; |