opentitanlib/chip/
boolean.rs

1// Copyright lowRISC contributors (OpenTitan project).
2// Licensed under the Apache License, Version 2.0, see LICENSE for details.
3// SPDX-License-Identifier: Apache-2.0
4
5use crate::with_unknown;
6
7with_unknown! {
8    /// From `//sw/device/lib/base/hardened.h`.
9    pub enum HardenedBool: u32 [default = Self::False] {
10        True = bindgen::hardened::hardened_bool_kHardenedBoolTrue,
11        False = bindgen::hardened::hardened_bool_kHardenedBoolFalse,
12    }
13
14    /// From `//sw/device/lib/base/hardened.h`.
15    pub enum HardenedByteBool: u8 [default = Self::False] {
16        True = bindgen::hardened::hardened_byte_bool_kHardenedByteBoolTrue as u8,
17        False = bindgen::hardened::hardened_byte_bool_kHardenedByteBoolFalse as u8,
18    }
19}