repo
stringlengths
6
65
file_url
stringlengths
81
311
file_path
stringlengths
6
227
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:31:58
2026-01-04 20:25:31
truncated
bool
2 classes
Weasy666/bevy_svg
https://github.com/Weasy666/bevy_svg/blob/c0ede2b5481bf65ede166c6dc39e6a376bf05010/examples/2d/complex_one_color.rs
examples/2d/complex_one_color.rs
use bevy::prelude::*; use bevy_svg::prelude::*; #[path = "../common/lib.rs"] mod common; fn main() { App::new() .add_plugins(DefaultPlugins.set(WindowPlugin { primary_window: Some(Window { title: "2d_complex_one_color".to_string(), resolution: (600, 600).into(),...
rust
Apache-2.0
c0ede2b5481bf65ede166c6dc39e6a376bf05010
2026-01-04T20:23:13.998577Z
false
Weasy666/bevy_svg
https://github.com/Weasy666/bevy_svg/blob/c0ede2b5481bf65ede166c6dc39e6a376bf05010/examples/2d/two_colors.rs
examples/2d/two_colors.rs
use bevy::prelude::*; use bevy_svg::prelude::*; #[path = "../common/lib.rs"] mod common; fn main() { App::new() .add_plugins(DefaultPlugins.set(WindowPlugin { primary_window: Some(Window { title: "2d_two_colors".to_string(), resolution: (600, 600).into(), ...
rust
Apache-2.0
c0ede2b5481bf65ede166c6dc39e6a376bf05010
2026-01-04T20:23:13.998577Z
false
Weasy666/bevy_svg
https://github.com/Weasy666/bevy_svg/blob/c0ede2b5481bf65ede166c6dc39e6a376bf05010/examples/2d/multiple_translation.rs
examples/2d/multiple_translation.rs
use bevy::prelude::*; use bevy_svg::prelude::*; #[path = "../common/lib.rs"] mod common; fn main() { App::new() .add_plugins(DefaultPlugins.set(WindowPlugin { primary_window: Some(Window { title: "2d_multiple_translation".to_string(), resolution: (600, 600).into...
rust
Apache-2.0
c0ede2b5481bf65ede166c6dc39e6a376bf05010
2026-01-04T20:23:13.998577Z
false
Weasy666/bevy_svg
https://github.com/Weasy666/bevy_svg/blob/c0ede2b5481bf65ede166c6dc39e6a376bf05010/examples/2d/twinkle.rs
examples/2d/twinkle.rs
use bevy::prelude::*; use bevy_svg::prelude::*; #[path = "../common/lib.rs"] mod common; fn main() { App::new() .add_plugins(DefaultPlugins.set(WindowPlugin { primary_window: Some(Window { title: "2d_twinkle".to_string(), resolution: (600, 600).into(), ...
rust
Apache-2.0
c0ede2b5481bf65ede166c6dc39e6a376bf05010
2026-01-04T20:23:13.998577Z
false
Weasy666/bevy_svg
https://github.com/Weasy666/bevy_svg/blob/c0ede2b5481bf65ede166c6dc39e6a376bf05010/examples/common/lib.rs
examples/common/lib.rs
use bevy::color::palettes::css::{GOLD, GREEN}; use bevy::input::mouse::{MouseScrollUnit, MouseWheel}; use bevy::text::TextSpanAccess; use bevy::{ diagnostic::{DiagnosticsStore, FrameTimeDiagnosticsPlugin}, prelude::*, }; use bevy_svg::prelude::*; /// Provides some common functionallity for all examples. /// Li...
rust
Apache-2.0
c0ede2b5481bf65ede166c6dc39e6a376bf05010
2026-01-04T20:23:13.998577Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/nth_naive.rs
src/bin/nth_naive.rs
// It's now hardcoded how many numbers fibonacci_array() calculates const FIBONACCI_NUMS: usize = 100; // Inspect the resulting assembly using: // cargo asm --rust --bin nth_naive nth_fibonacci #[inline(never)] // so that we can easily view the assembly fn nth_fibonacci(n: usize, fibonacci: &[u64]) -> u64 { fibona...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/comparison_split.rs
src/bin/comparison_split.rs
// Inspect the resulting assembly using: // cargo asm --rust --bin comparison_split elements_are_equal #[inline(never)] // so that we can easily view the assembly fn elements_are_equal(slice1: &[u64], slice2: &[u64], index: usize) -> bool { // This is now a standalone function, and there is no constraint on //...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/comparison_clever.rs
src/bin/comparison_clever.rs
// Inspect the resulting assembly using: // cargo asm --rust --bin comparison_clever is_fibonacci #[inline(never)] // so that we can easily view the assembly fn is_fibonacci(input: &[u64], fibonacci: &[u64]) -> bool { // Cut off one slice up to the length of the other, // so that the compiler knows the lengths ...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/comparison_iterator.rs
src/bin/comparison_iterator.rs
// Inspect the resulting assembly using: // cargo asm --rust --bin comparison_iterator is_fibonacci #[inline(never)] // so that we can easily view the assembly fn is_fibonacci(input: &[u64], fibonacci: &[u64]) -> bool { // this is an iterator; it completely avoids bounds checks input.iter().zip(fibonacci.iter()...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/fibvec_iterator.rs
src/bin/fibvec_iterator.rs
// Inspect the resulting assembly using: // cargo asm --rust --bin fibvec_iterator fibonacci_vec #[inline(never)] // so that we can easily view the assembly fn fibonacci_vec(length: usize) -> Vec<u64> { let mut fib = vec![0; length]; if length > 1 { fib[1] = 1; } if length > 2 { let mut ...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/fibvec_naive_indexing.rs
src/bin/fibvec_naive_indexing.rs
// Inspect the resulting assembly using: // cargo asm --rust --bin fibvec_naive_indexing fibonacci_vec #[inline(never)] // so that we can easily view the assembly fn fibonacci_vec(length: usize) -> Vec<u64> { // Allocate the full length up front to avoid costly reallocations. // Also, `vec![0; length]` just req...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/fibvec_clever_indexing_alt.rs
src/bin/fibvec_clever_indexing_alt.rs
// Inspect the resulting assembly using: // cargo asm --rust --bin fibvec_clever_indexing_alt fibonacci_vec #[inline(never)] // so that we can easily view the assembly fn fibonacci_vec(length: usize) -> Vec<u64> { let mut fib = vec![0; length]; { // Unlike a `Vec`, a slice is not resizable let f...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/nth_branchless.rs
src/bin/nth_branchless.rs
// It's now hardcoded how many numbers fibonacci_array() calculates const FIBONACCI_NUMS: usize = 100; // Inspect the resulting assembly using: // cargo asm --rust --bin nth_branchless nth_fibonacci #[inline(never)] // so that we can easily view the assembly fn nth_fibonacci(n: usize, fibonacci: &[u64]) -> u64 { /...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/fibvec_clever_indexing.rs
src/bin/fibvec_clever_indexing.rs
// Inspect the resulting assembly using: // cargo asm --rust --bin fibvec_clever_indexing fibonacci_vec #[inline(never)] // so that we can easily view the assembly fn fibonacci_vec(length: usize) -> Vec<u64> { let mut fib = vec![0; length]; { // Unlike a `Vec`, a slice is not resizable let fib =...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/comparison_split_inline.rs
src/bin/comparison_split_inline.rs
// #[inline(always)] copies the code of the function into the caller and optimizes them together #[inline(always)] // used to be #[inline(never)] fn elements_are_equal(slice1: &[u64], slice2: &[u64], index: usize) -> bool { // we can no longer view the assembly here because of #[inline(always)] // but we can lo...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/nth_errorless_heap.rs
src/bin/nth_errorless_heap.rs
// It's now hardcoded how many numbers fibonacci_array() calculates const FIBONACCI_NUMS: usize = 100; // round that number up to a power of two // to make our custom bounds checks really cheap const LOOKUP_TABLE_SIZE: usize = FIBONACCI_NUMS.next_power_of_two(); // Inspect the resulting assembly using: // cargo asm --...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/nth_errorless_stack.rs
src/bin/nth_errorless_stack.rs
// It's now hardcoded how many numbers fibonacci_array() calculates const FIBONACCI_NUMS: usize = 100; // round that number up to a power of two // to make our custom bounds checks really cheap const LOOKUP_TABLE_SIZE: usize = FIBONACCI_NUMS.next_power_of_two(); // Inspect the resulting assembly using: // cargo asm --...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/comparison_realistic.rs
src/bin/comparison_realistic.rs
// Inspect the resulting assembly using: // cargo asm --rust --bin comparison_realistic is_fibonacci #[inline(never)] // so that we can easily view the assembly fn is_fibonacci(input: &[u64], fibonacci: &[u64]) -> bool { input == &fibonacci[..input.len()] } fn fibonacci_vec(length: usize) -> Vec<u64> { let mut...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
Shnatsel/bounds-check-cookbook
https://github.com/Shnatsel/bounds-check-cookbook/blob/212de6936f11e785e407b57a3d0ef669e88af60a/src/bin/comparison_naive.rs
src/bin/comparison_naive.rs
// Inspect the resulting assembly using: // cargo asm --rust --bin comparison_naive is_fibonacci #[inline(never)] // so that we can easily view the assembly fn is_fibonacci(input: &[u64], fibonacci: &[u64]) -> bool { for i in 0..input.len() { if input[i] != fibonacci[i] { // two bounds checks! r...
rust
MIT
212de6936f11e785e407b57a3d0ef669e88af60a
2026-01-04T20:23:18.406397Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/der_helper.rs
x509/src/der_helper.rs
/*++ Licensed under the Apache-2.0 license. File Name: der_helper.rs Abstract: Helpers for encoding DER unsigned integers --*/ /// DER Integer Tag const DER_INTEGER_TAG: u8 = 0x02; #[inline(never)] fn trim_leading_zeros(val: &[u8]) -> &[u8] { // Count the leading zeros for i in 0..val.len() { ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/rt_alias_cert_ecc_384.rs
x509/src/rt_alias_cert_ecc_384.rs
/*++ Licensed under the Apache-2.0 license. File Name: rt_alias_cert.rs Abstract: ECC384 RT Alias Certificate related code. --*/ // Note: All the necessary code is auto generated #[cfg(feature = "generate_templates")] include!(concat!(env!("OUT_DIR"), "/rt_alias_cert_tbs_ecc_384.rs")); #[cfg(not(feature ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/rt_alias_cert_mldsa_87.rs
x509/src/rt_alias_cert_mldsa_87.rs
/*++ Licensed under the Apache-2.0 license. File Name: rt_alias_cert.rs Abstract: ML-DSA87 RT Alias Certificate related code. --*/ // Note: All the necessary code is auto generated #[cfg(feature = "generate_templates")] include!(concat!(env!("OUT_DIR"), "/rt_alias_cert_tbs_ml_dsa_87.rs")); #[cfg(not(feat...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/idevid_csr_mldsa_87.rs
x509/src/idevid_csr_mldsa_87.rs
/*++ Licensed under the Apache-2.0 license. File Name: idevid_csr.rs Abstract: Initial Device ID Certificate Signing Request related code. --*/ #[cfg(feature = "generate_templates")] include!(concat!( env!("OUT_DIR"), "/init_dev_id_csr_tbs_ml_dsa_87.rs" )); #[cfg(not(feature = "generate_templates"...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/ldevid_cert_mldsa_87.rs
x509/src/ldevid_cert_mldsa_87.rs
/*++ Licensed under the Apache-2.0 license. File Name: ldevid_cert.rs Abstract: Local Device ID Certificate related code. --*/ // Note: All the necessary code is auto generated #[cfg(feature = "generate_templates")] include!(concat!( env!("OUT_DIR"), "/local_dev_id_cert_tbs_ml_dsa_87.rs" )); #[cf...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/lib.rs
x509/src/lib.rs
/*++ Licensed under the Apache-2.0 license. File Name: lib.rs Abstract: Main entry point for Caliptra X509 related functionality --*/ #![cfg_attr(not(feature = "std"), no_std)] mod cert_bldr; mod der_helper; mod fmc_alias_cert_ecc_384; mod fmc_alias_cert_mldsa_87; mod fmc_alias_csr_ecc_384; mod idevid_c...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/idevid_csr_ecc_384.rs
x509/src/idevid_csr_ecc_384.rs
/*++ Licensed under the Apache-2.0 license. File Name: idevid_csr.rs Abstract: ECC384 Initial Device ID Certificate Signing Request related code. --*/ // Note: All the necessary code is auto generated #[cfg(feature = "generate_templates")] include!(concat!(env!("OUT_DIR"), "/init_dev_id_csr_tbs_ecc_384.r...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/fmc_alias_cert_ecc_384.rs
x509/src/fmc_alias_cert_ecc_384.rs
/*++ Licensed under the Apache-2.0 license. File Name: fmc_alias_cert_ecc_384.rs Abstract: ECC384 FMC Alias Certificate related code. --*/ // Note: All the necessary code is auto generated #[cfg(feature = "generate_templates")] include!(concat!(env!("OUT_DIR"), "/fmc_alias_cert_tbs_ecc_384.rs")); #[cfg(n...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/test_util.rs
x509/src/test_util.rs
/*++ Licensed under the Apache-2.0 license. File Name: test_util.rs Abstract: Test Utilities --*/ #[cfg(all(test, target_family = "unix"))] pub mod tests { use openssl::{ bn::BigNumContext, ec::{EcGroup, EcKey, PointConversionForm}, nid::Nid, pkey::{PKey, Private, Pub...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/ldevid_cert_ecc_384.rs
x509/src/ldevid_cert_ecc_384.rs
/*++ Licensed under the Apache-2.0 license. File Name: ldevid_cert.rs Abstract: ECC384 Local Device ID Certificate related code. --*/ // Note: All the necessary code is auto generated #[cfg(feature = "generate_templates")] include!(concat!( env!("OUT_DIR"), "/local_dev_id_cert_tbs_ecc_384.rs" ));...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/fmc_alias_csr_ecc_384.rs
x509/src/fmc_alias_csr_ecc_384.rs
/*++ Licensed under the Apache-2.0 license. File Name: fmc_alis_csr.rs Abstract: FMC Alias CSR Certificate Signing Request related code. --*/ // Note: All the necessary code is auto generated #[cfg(feature = "generate_templates")] include!(concat!(env!("OUT_DIR"), "/fmc_alias_csr_tbs_ecc_384.rs")); #[cfg...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/cert_bldr.rs
x509/src/cert_bldr.rs
/*++ Licensed under the Apache-2.0 license. File Name: cert_bldr.rs Abstract: X509 API to construct Certificate or Certificate Signing Request from "To Be Signed" blob and ECDSA-384 Signature. --*/ use crate::{der_encode_len, der_encode_uint, der_uint_len}; /// DER Bit String Tag const DER_BIT_STR_T...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/fmc_alias_cert_mldsa_87.rs
x509/src/fmc_alias_cert_mldsa_87.rs
/*++ Licensed under the Apache-2.0 license. File Name: fmc_alias_cert.rs Abstract: ML-DSA87 FMC Alias Certificate related code. --*/ // Note: All the necessary code is auto generated #[cfg(feature = "generate_templates")] include!(concat!(env!("OUT_DIR"), "/fmc_alias_cert_tbs_ml_dsa_87.rs")); #[cfg(not(f...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/src/ocp_lock_hpke_certs.rs
x509/src/ocp_lock_hpke_certs.rs
// Licensed under the Apache-2.0 license pub mod ml_kem_ecc_348 { #[cfg(feature = "generate_templates")] include!(concat!( env!("OUT_DIR"), "/ocp_lock_ml_kem_cert_tbs_ecc_384.rs" )); #[cfg(not(feature = "generate_templates"))] include! {"../build/ocp_lock_ml_kem_cert_tbs_ecc_384.rs...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/fuzz/src/fuzz_target_1.rs
x509/fuzz/src/fuzz_target_1.rs
// Licensed under the Apache-2.0 license #![cfg_attr(feature = "libfuzzer-sys", no_main)] #[cfg(all(not(feature = "libfuzzer-sys"), not(feature = "afl")))] compile_error!("Either feature \"libfuzzer-sys\" or \"afl\" must be enabled!"); #[cfg(feature = "libfuzzer-sys")] use libfuzzer_sys::fuzz_target; #[cfg(feature ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/init_dev_id_csr_tbs_ecc_384.rs
x509/build/init_dev_id_csr_tbs_ecc_384.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct InitDevIdCsrTbsEcc384Params<'a> { pub public_key: &'a [u8; 97usize], pub subject_sn: &'a [u8; 64usiz...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/code_gen.rs
x509/build/code_gen.rs
/*++ Licensed under the Apache-2.0 license. File Name: code_gen.rs Abstract: File contains code generation routines for X509 Templates --*/ use crate::tbs::TbsTemplate; use convert_case::{Case, Casing}; use quote::{__private::TokenStream, format_ident, quote}; use std::{path::Path, process::Command}; //...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/rt_alias_cert_tbs_ml_dsa_87.rs
x509/build/rt_alias_cert_tbs_ml_dsa_87.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct RtAliasCertTbsMlDsa87Params<'a> { pub public_key: &'a [u8; 2592usize], pub subject_sn: &'a [u8; 64us...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/rt_alias_cert_tbs_ecc_384.rs
x509/build/rt_alias_cert_tbs_ecc_384.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct RtAliasCertTbsEcc384Params<'a> { pub public_key: &'a [u8; 97usize], pub subject_sn: &'a [u8; 64usize...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/ocp_lock_ml_kem_cert_tbs_ecc_384.rs
x509/build/ocp_lock_ml_kem_cert_tbs_ecc_384.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct OcpLockMlKemCertTbsEcc384Params<'a> { pub public_key: &'a [u8; 1568usize], pub subject_sn: &'a [u8; ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/ocp_lock_ecdh_384_cert_tbs_ecc_384.rs
x509/build/ocp_lock_ecdh_384_cert_tbs_ecc_384.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct OcpLockEcdh384CertTbsEcc384Params<'a> { pub public_key: &'a [u8; 97usize], pub subject_sn: &'a [u8; ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/build.rs
x509/build/build.rs
/*++ Licensed under the Apache-2.0 license. File Name: build.rs Abstract: File contains the entry point for build time script used for generating various X509 artifacts used by Caliptra Firmware. --*/ #[cfg(feature = "generate_templates")] mod cert; #[cfg(feature = "generate_templates")] mod code_gen...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/tbs.rs
x509/build/tbs.rs
/*++ Licensed under the Apache-2.0 license. File Name: tbs.rs Abstract: File contains definition of types used as templates and parameters. --*/ use hex::ToHex; /// Template parameter #[derive(Debug, Copy, Clone)] pub struct TbsParam { pub name: &'static str, pub offset: usize, pub len: usiz...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/local_dev_id_cert_tbs_ml_dsa_87.rs
x509/build/local_dev_id_cert_tbs_ml_dsa_87.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct LocalDevIdCertTbsMlDsa87Params<'a> { pub public_key: &'a [u8; 2592usize], pub subject_sn: &'a [u8; 6...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/fmc_alias_csr_tbs_ecc_384.rs
x509/build/fmc_alias_csr_tbs_ecc_384.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct FmcAliasCsrTbsEcc384Params<'a> { pub public_key: &'a [u8; 97usize], pub subject_sn: &'a [u8; 64usize...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/fmc_alias_cert_tbs_ecc_384.rs
x509/build/fmc_alias_cert_tbs_ecc_384.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct FmcAliasCertTbsEcc384Params<'a> { pub public_key: &'a [u8; 97usize], pub subject_sn: &'a [u8; 64usiz...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/ocp_lock_ml_kem_cert_tbs_ml_dsa_87.rs
x509/build/ocp_lock_ml_kem_cert_tbs_ml_dsa_87.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct OcpLockMlKemCertTbsMlDsa87Params<'a> { pub public_key: &'a [u8; 1568usize], pub subject_sn: &'a [u8;...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/csr.rs
x509/build/csr.rs
/*++ Licensed under the Apache-2.0 license. File Name: csr.rs Abstract: File contains generation of X509 Certificate Signing Request (CSR) To Be Signed (TBS) template that can be substituted at firmware runtime. --*/ use crate::tbs::{get_tbs, init_param, sanitize, TbsParam, TbsTemplate}; use crate::x...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/ocp_lock_ecdh_384_cert_tbs_ml_dsa_87.rs
x509/build/ocp_lock_ecdh_384_cert_tbs_ml_dsa_87.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct OcpLockEcdh384CertTbsMlDsa87Params<'a> { pub public_key: &'a [u8; 97usize], pub subject_sn: &'a [u8;...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/cert.rs
x509/build/cert.rs
/*++ Licensed under the Apache-2.0 license. File Name: cert.rs Abstract: File contains generation of X509 Certificate To Be Singed (TBS) template that can be substituted at firmware runtime. --*/ use crate::tbs::{get_tbs, init_param, sanitize, TbsParam, TbsTemplate}; use crate::x509::{self, AsymKey, ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/local_dev_id_cert_tbs_ecc_384.rs
x509/build/local_dev_id_cert_tbs_ecc_384.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct LocalDevIdCertTbsEcc384Params<'a> { pub public_key: &'a [u8; 97usize], pub subject_sn: &'a [u8; 64us...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/x509.rs
x509/build/x509.rs
/*++ Licensed under the Apache-2.0 license. File Name: x509.rs Abstract: File contains helper functions for cryptography and X509 object manipulation --*/ use openssl::asn1::{Asn1Object, Asn1OctetString}; use openssl::bn::BigNumContext; use openssl::ec::EcGroup; use openssl::ec::EcKey; use openssl::ec::P...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/init_dev_id_csr_tbs_ml_dsa_87.rs
x509/build/init_dev_id_csr_tbs_ml_dsa_87.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct InitDevIdCsrTbsMlDsa87Params<'a> { pub public_key: &'a [u8; 2592usize], pub subject_sn: &'a [u8; 64u...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/fmc_alias_cert_tbs_ml_dsa_87.rs
x509/build/fmc_alias_cert_tbs_ml_dsa_87.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct FmcAliasCertTbsMlDsa87Params<'a> { pub public_key: &'a [u8; 2592usize], pub subject_sn: &'a [u8; 64u...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/x509/build/fmc_alias_tbs_ml_dsa_87.rs
x509/build/fmc_alias_tbs_ml_dsa_87.rs
#[doc = "++ Licensed under the Apache-2.0 license. Abstract: Regenerate the template by building caliptra-x509-build with the generate-templates flag. --"] #[allow(clippy::needless_lifetimes)] pub struct FmcAliasTbsMlDsa87Params<'a> { pub public_key: &'a [u8; 2592usize], pub subject_sn: &'a [u8; 64usize...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/fpga-boss/src/tty.rs
ci-tools/fpga-boss/src/tty.rs
// Licensed under the Apache-2.0 license use std::{ io::{self, ErrorKind, Read}, mem::MaybeUninit, os::fd::AsRawFd, }; pub struct RawTerminal { old_termios: libc::termios, } impl RawTerminal { pub fn from_stdin() -> io::Result<Self> { let stdin = io::stdin().lock(); unsafe { ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/fpga-boss/src/fpga_jtag.rs
ci-tools/fpga-boss/src/fpga_jtag.rs
// Licensed under the Apache-2.0 license use std::time::Duration; use crate::{ ftdi::{BitMode, FtdiInterface}, FtdiCtx, UsbPortPath, }; pub enum FpgaReset { Reset = 0, Run = 1, } pub struct FpgaJtag { pub ftdi: FtdiCtx, } impl FpgaJtag { pub fn open(port_path: UsbPortPath) -> anyhow::Result<...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/fpga-boss/src/find_usb_block_device.rs
ci-tools/fpga-boss/src/find_usb_block_device.rs
// Licensed under the Apache-2.0 license use std::{ os::unix::prelude::OsStrExt, path::{Path, PathBuf}, }; use crate::UsbPortPath; /// Returns the path to the block device connected to a particular USB port. pub fn find_usb_block_device(usb_path: &UsbPortPath) -> anyhow::Result<PathBuf> { let iface_prefi...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/fpga-boss/src/ftdi.rs
ci-tools/fpga-boss/src/ftdi.rs
// Licensed under the Apache-2.0 license use std::ffi::{c_int, CStr}; use libftdi1_sys::{ftdi_bits_type, ftdi_parity_type, ftdi_stopbits_type}; use rusb::{Device, GlobalContext}; use crate::UsbPortPath; fn device_from_path(port_path: &UsbPortPath) -> anyhow::Result<Device<GlobalContext>> { for dev in rusb::devi...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/fpga-boss/src/ftdi_uart.rs
ci-tools/fpga-boss/src/ftdi_uart.rs
// Licensed under the Apache-2.0 license use std::{ io::{self, ErrorKind}, time::{Duration, Instant}, }; use libftdi1_sys::{ftdi_bits_type, ftdi_interface, ftdi_parity_type, ftdi_stopbits_type}; use std::cell::RefCell; use std::rc::Rc; use crate::{ ftdi::{BitMode, FtdiCtx}, usb_port_path::UsbPortPath...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/fpga-boss/src/usb_port_path.rs
ci-tools/fpga-boss/src/usb_port_path.rs
// Licensed under the Apache-2.0 license use std::fmt::{Debug, Display}; use std::str::FromStr; use anyhow::{anyhow, Context}; /// Identifies a USB device connected to a particular port (For example "3-1.4") #[derive(Clone, Eq, PartialEq)] pub struct UsbPortPath { pub bus: u8, pub ports: Vec<u8>, } impl Usb...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/fpga-boss/src/main.rs
ci-tools/fpga-boss/src/main.rs
// Licensed under the Apache-2.0 license mod find_usb_block_device; mod fpga_jtag; mod ftdi; mod ftdi_uart; mod sd_mux; mod tty; mod usb_port_path; use anyhow::{anyhow, Context}; use clap::{arg, value_parser}; use libftdi1_sys::ftdi_interface; use std::{ ffi::OsString, fs::{File, OpenOptions}, io::{stdou...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/fpga-boss/src/sd_mux.rs
ci-tools/fpga-boss/src/sd_mux.rs
// Licensed under the Apache-2.0 license use anyhow::Context; use std::fs; use std::path::PathBuf; use std::str::FromStr; use clap::PossibleValue; use libftdi1_sys::ftdi_interface; use crate::{find_usb_block_device::find_usb_block_device, ftdi, FtdiCtx, UsbPortPath}; #[derive(Clone, Copy, Debug, Eq, PartialEq)] pub...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/size-history/src/html.rs
ci-tools/size-history/src/html.rs
// Licensed under the Apache-2.0 license use std::{cmp::Ordering, fmt::Write, io}; use serde::{Deserialize, Serialize}; use serde_json::Value; use tinytemplate::TinyTemplate; use crate::{git, SizeRecord, Sizes}; // The GitHub "HTML sanitizer" is incredibly sensitive to whitespace; do not attempt to break newlines. ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/size-history/src/process.rs
ci-tools/size-history/src/process.rs
// Licensed under the Apache-2.0 license use std::{ io, process::{Command, Stdio}, }; pub fn run_cmd(cmd: &mut Command) -> io::Result<()> { let status = cmd.status()?; if status.success() { Ok(()) } else { Err(io::Error::new( io::ErrorKind::Other, format!( ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/size-history/src/http.rs
ci-tools/size-history/src/http.rs
// Licensed under the Apache-2.0 license use std::str::FromStr; use std::{borrow::Cow, io, process::Command}; use crate::util::expect_line_with_prefix_ignore_case; use crate::{ process::run_cmd_stdout, util::{expect_line_with_prefix, other_err}, }; pub struct Content<'a> { mime_type: Cow<'a, str>, da...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/size-history/src/git.rs
ci-tools/size-history/src/git.rs
// Licensed under the Apache-2.0 license use std::{io, path::Path, process::Command}; use serde::{Deserialize, Serialize}; use crate::{ process::{run_cmd, run_cmd_stdout}, util::{bytes_to_string, expect_line, expect_line_with_prefix, other_err}, }; #[derive(Clone, Debug, Eq, PartialEq, Serialize, Deserializ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/size-history/src/cache_gha.rs
ci-tools/size-history/src/cache_gha.rs
// Licensed under the Apache-2.0 license use ghac::v1::{ self as ghac_types, CreateCacheEntryResponse, FinalizeCacheEntryUploadResponse, GetCacheEntryDownloadUrlResponse, }; use prost::Message; use crate::{ http::{self, Content}, util::{hex, other_err}, Cache, }; // The server complains with an u...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/size-history/src/util.rs
ci-tools/size-history/src/util.rs
// Licensed under the Apache-2.0 license use std::io; pub fn expect_line(expected_val: &str, line: Option<&str>) -> io::Result<()> { if let Some(line) = line { if line == expected_val { return Ok(()); } } Err(io::Error::new( io::ErrorKind::Other, format!("Expect...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/size-history/src/main.rs
ci-tools/size-history/src/main.rs
// Licensed under the Apache-2.0 license use std::{ env::{self}, fs, io, path::Path, }; use caliptra_builder::{elf_size, firmware, FwId}; use serde::{Deserialize, Serialize}; mod cache; mod cache_gha; mod git; mod html; mod http; mod process; mod util; use crate::cache::{Cache, FsCache}; use crate::{cac...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/size-history/src/cache.rs
ci-tools/size-history/src/cache.rs
// Licensed under the Apache-2.0 license use std::{fs, io, path::PathBuf}; use crate::util::hex; pub trait Cache { fn set(&self, key: &str, val: &[u8]) -> io::Result<()>; fn get(&self, key: &str) -> io::Result<Option<Vec<u8>>>; } pub struct FsCache { dir: PathBuf, } impl FsCache { pub fn new(dir: Pa...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/bitstream-downloader/src/lib.rs
ci-tools/bitstream-downloader/src/lib.rs
// Licensed under the Apache-2.0 license use std::fs; use std::io; use std::path::{Path, PathBuf}; use anyhow::{bail, Context, Result}; use serde::Deserialize; use sha2::{Digest, Sha256}; #[derive(Debug, Deserialize)] pub struct Bitstream { pub name: String, pub url: String, pub hash: String, pub cal...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/bitstream-downloader/src/main.rs
ci-tools/bitstream-downloader/src/main.rs
// Licensed under the Apache-2.0 license use std::path::PathBuf; use anyhow::Result; use clap::Parser; #[derive(Parser, Debug)] #[command(author, version, about, long_about = None)] struct Cli { /// Path to the bitstream manifest #[arg(long = "bitstream-manifest", value_name = "FILE")] bitstream_manifest...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/file-header-fix/src/main.rs
ci-tools/file-header-fix/src/main.rs
// Licensed under the Apache-2.0 license use std::{ fs::File, io::{BufRead, BufReader, Error, ErrorKind}, path::{Path, PathBuf}, }; const REQUIRED_TEXT: &str = "Licensed under the Apache-2.0 license"; const EXTENSIONS: &[&str] = &["rs", "h", "c", "cpp", "cc", "toml", "sh", "py", "ld", "go"]; const IGNORE...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/file-header-fix/tests/integration_test.rs
ci-tools/file-header-fix/tests/integration_test.rs
// Licensed under the Apache-2.0 license use std::{ env::temp_dir, fs, path::{Path, PathBuf}, process::Stdio, }; const PROGRAM_BIN: &str = env!("CARGO_BIN_EXE_caliptra-file-header-fix"); #[test] fn test_usage() { let out = std::process::Command::new(PROGRAM_BIN) .arg("--help") .st...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/test-matrix/src/html.rs
ci-tools/test-matrix/src/html.rs
// Licensed under the Apache-2.0 license use std::fmt::Write; use octocrab::models::workflows::Run; use serde::Serialize; use std::fmt::Debug; use tinytemplate::{format_unescaped, TinyTemplate}; use crate::{RunInfo, TestMatrix}; // These types are exposed to the HTML template: #[derive(Serialize)] struct TemplateC...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/test-matrix/src/junit.rs
ci-tools/test-matrix/src/junit.rs
// Licensed under the Apache-2.0 license use std::fmt::Write; use serde::Deserialize; use serde_xml_rs as serde_xml; use crate::TestCaseStatus; #[derive(Debug, Deserialize, PartialEq)] pub struct TestSuites { pub name: String, #[serde(default)] #[serde(rename = "testsuite")] pub test_suites: Vec<Te...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/test-matrix/src/main.rs
ci-tools/test-matrix/src/main.rs
// Licensed under the Apache-2.0 license use std::{ collections::BTreeMap, error::Error, io::{Cursor, Read}, path::Path, }; use nextest_metadata::TestListSummary; use octocrab::{ etag::Etagged, models::workflows::Run, params::actions::ArchiveFormat, Octocrab, Page, }; use serde::Serialize; use zip...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ci-tools/test-printer/src/main.rs
ci-tools/test-printer/src/main.rs
// Licensed under the Apache-2.0 license use serde::Deserialize; use std::fs; use clap::Parser; #[derive(Parser)] #[clap(author, version, about, long_about = None)] struct Args { /// The path to the junit.xml file #[clap(short, long)] xml_path: String, } #[derive(Debug, Deserialize, Default)] struct Test...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ureg/src/lib.rs
ureg/src/lib.rs
/*++ Licensed under the Apache-2.0 license. --*/ //! # ureg register abstraction //! //! This crate contains traits and types used by MMIO register-access code //! generated by [`ureg-codegen`]. #![no_std] #[cfg(any(target_arch = "riscv32", target_arch = "riscv64"))] mod opt_riscv; use core::{default::Default, mark...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
true
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ureg/src/opt_riscv.rs
ureg/src/opt_riscv.rs
// Licensed under the Apache-2.0 license use crate::{RealMmio, RealMmioMut, Uint, UintType}; #[inline(always)] pub unsafe fn read_volatile_array<const LEN: usize, T: Uint>(dst: *mut T, src: *mut T) { match (T::TYPE, LEN) { (UintType::U32, 12) => copy_12words(dst as *mut u32, src as *const u32), (U...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ureg/lib/codegen/src/lib.rs
ureg/lib/codegen/src/lib.rs
/*++ Licensed under the Apache-2.0 license. --*/ use std::{collections::HashMap, rc::Rc, str::FromStr}; use proc_macro2::{Ident, Literal, TokenStream}; use quote::{format_ident, quote}; use ureg_schema::{ Enum, EnumVariant, FieldType, Register, RegisterBlock, RegisterSubBlock, RegisterType, RegisterWidth, Val...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
true
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ureg/lib/systemrdl/src/lib.rs
ureg/lib/systemrdl/src/lib.rs
/*++ Licensed under the Apache-2.0 license. --*/ mod error; pub use error::Error; use ureg::{RegisterSubBlock, RegisterType}; use std::rc::Rc; use caliptra_systemrdl::{self as systemrdl, Value}; use caliptra_systemrdl::{ComponentType, ScopeType}; use systemrdl::{AccessType, InstanceRef, ParentScope, RdlError}; use u...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ureg/lib/systemrdl/src/error.rs
ureg/lib/systemrdl/src/error.rs
/*++ Licensed under the Apache-2.0 license. --*/ use std::fmt::Display; use caliptra_systemrdl as systemrdl; #[derive(Clone, Debug, Eq, PartialEq)] pub enum Error { UnexpectedScopeType { expected: systemrdl::ScopeType, actual: systemrdl::ScopeType, }, AddressTooLarge(u64), OffsetNotDef...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ureg/lib/schema/src/lib.rs
ureg/lib/schema/src/lib.rs
/*++ Licensed under the Apache-2.0 license. --*/ use std::{ collections::{HashMap, HashSet}, rc::Rc, }; mod validate; #[derive(Clone, Debug, Default, Eq, Hash, PartialEq)] pub struct RegisterField { pub name: String, pub ty: FieldType, pub default_val: u64, pub comment: String, /// Descr...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/ureg/lib/schema/src/validate.rs
ureg/lib/schema/src/validate.rs
/*++ Licensed under the Apache-2.0 license. --*/ use crate::Enum; use crate::EnumVariant; use crate::Register; use crate::RegisterBlock; use crate::RegisterField; use crate::RegisterSubBlock; use crate::RegisterType; use std::collections::hash_map::DefaultHasher; use std::collections::HashMap; use std::collections::H...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/build.rs
hw-model/build.rs
// Licensed under the Apache-2.0 license fn main() { println!( "cargo:rustc-env=OPENOCD_SYSFSGPIO_ADAPTER_CFG=../../../hw/fpga/openocd_sysfsgpio_adapter.cfg" ); println!("cargo:rustc-env=OPENOCD_TAP_CFG=../../../hw/fpga/openocd_ss.cfg"); }
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/mcu_boot_status.rs
hw-model/src/mcu_boot_status.rs
/*++ Licensed under the Apache-2.0 license. File Name: boot_status.rs Abstract: MCU ROM boot status codes. --*/ use bitflags::bitflags; const ROM_INITIALIZATION_BASE: u16 = 1; const LIFECYCLE_MANAGEMENT_BASE: u16 = 65; const OTP_FUSE_OPERATIONS_BASE: u16 = 129; const CALIPTRA_SETUP_BASE: u16 = 193; cons...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/lib.rs
hw-model/src/lib.rs
// Licensed under the Apache-2.0 license use api::CaliptraApiError; use caliptra_api as api; use caliptra_api::mailbox::MailboxReq; use caliptra_api::SocManager; use caliptra_api_types as api_types; use caliptra_emu_bus::{Bus, Event}; use core::panic; use std::path::PathBuf; use std::str::FromStr; use std::sync::mpsc;...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
true
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/fpga_regs.rs
hw-model/src/fpga_regs.rs
// Licensed under the Apache-2.0 license. #![allow(dead_code)] use tock_registers::registers::{ReadOnly, ReadWrite, WriteOnly}; use tock_registers::{register_bitfields, register_structs}; register_bitfields! { u32, pub Control [ CptraPwrgood OFFSET(0) NUMBITS(1) [], CptraSsRstB OFFSET(1) NUMB...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/model_verilated.rs
hw-model/src/model_verilated.rs
// Licensed under the Apache-2.0 license use crate::bus_logger::{BusLogger, LogFile, NullBus}; use crate::trace_path_or_env; use crate::EtrngResponse; use crate::{HwModel, SocManager, TrngMode}; use caliptra_api_types::Fuses; use caliptra_emu_bus::Bus; use caliptra_emu_bus::BusMmio; use caliptra_emu_bus::Event; use ca...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/rv32_builder.rs
hw-model/src/rv32_builder.rs
// Licensed under the Apache-2.0 license /// The world's most primitive RISC-V assembler #[derive(Default)] pub struct Rv32Builder(Vec<u8>); impl Rv32Builder { pub fn new() -> Self { Default::default() } /// Emit machine code to store val at address addr. pub fn store(mut self, addr: u32, val:...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/model_fpga_realtime.rs
hw-model/src/model_fpga_realtime.rs
// Licensed under the Apache-2.0 license use std::io::{BufRead, BufReader, Write}; use std::marker::PhantomData; use std::process::{Child, Command, Stdio}; use std::sync::atomic::{AtomicBool, Ordering}; use std::sync::mpsc; use std::sync::Arc; use std::thread; use std::{env, slice, str::FromStr}; use bitfield::bitfie...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/model_fpga_subsystem.rs
hw-model/src/model_fpga_subsystem.rs
// Licensed under the Apache-2.0 license #![allow(clippy::mut_from_ref)] #![allow(dead_code)] use crate::api_types::{DeviceLifecycle, Fuses}; use crate::bmc::Bmc; use crate::fpga_regs::{Control, FifoData, FifoRegs, FifoStatus, ItrngFifoStatus, WrapperRegs}; use crate::keys::{DEFAULT_LIFECYCLE_RAW_TOKENS, DEFAULT_MANU...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
true
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/otp_provision.rs
hw-model/src/otp_provision.rs
// Licensed under the Apache-2.0 license #![allow(dead_code)] use crate::otp_digest::{otp_digest, otp_scramble, otp_unscramble}; use caliptra_image_fake_keys::{VENDOR_ECC_KEY_0_PUBLIC, VENDOR_MLDSA_KEY_0_PUBLIC}; use anyhow::{bail, Result}; use sha2::{Digest, Sha384, Sha512}; use sha3::{digest::ExtendableOutput, dig...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
true
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/otp_digest.rs
hw-model/src/otp_digest.rs
// Licensed under the Apache-2.0 license. // Copyright lowRISC contributors (OpenTitan project). #![allow(dead_code)] use core::convert::TryInto; // This section is converted from the OpenTitan project's Python implementation of OTP digest algorithm. /// Scramble a 64bit block with PRESENT cipher. fn present_64bit_...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/jtag.rs
hw-model/src/jtag.rs
// Licensed under the Apache-2.0 license #![allow(dead_code)] pub trait JtagAccessibleReg { fn byte_offset(&self) -> u32; /// Converts the register's byte offset into a word offset for use with DMI. fn word_offset(&self) -> u32 { const BYTES_PER_WORD: u32 = std::mem::size_of::<u32>() as u32; ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/bus_logger.rs
hw-model/src/bus_logger.rs
// Licensed under the Apache-2.0 license use std::{ cell::RefCell, fs::File, io::{BufWriter, Write}, path::Path, rc::Rc, }; use caliptra_emu_bus::{Bus, BusError}; use caliptra_emu_types::{RvAddr, RvData, RvSize}; #[derive(Clone)] pub struct LogFile(Rc<RefCell<BufWriter<File>>>); impl LogFile { ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/bmc.rs
hw-model/src/bmc.rs
// Licensed under the Apache-2.0 license #![allow(dead_code)] use crate::recovery; use caliptra_emu_bus::{Device, Event, EventData, RecoveryCommandCode}; use std::sync::mpsc; pub struct Bmc { events_to_caliptra: mpsc::Sender<Event>, events_from_caliptra: mpsc::Receiver<Event>, events_to_mcu: mpsc::Sender...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/output.rs
hw-model/src/output.rs
// Licensed under the Apache-2.0 license use std::fmt::Display; use std::io::LineWriter; use std::{ cell::{Cell, RefCell}, io::Write, rc::Rc, }; #[derive(Clone, Copy, Debug, Eq, PartialEq)] pub enum ExitStatus { Passed, Failed, } struct OutputSinkImpl { exit_status: Cell<Option<ExitStatus>>, ...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false
chipsalliance/caliptra-sw
https://github.com/chipsalliance/caliptra-sw/blob/d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c/hw-model/src/recovery.rs
hw-model/src/recovery.rs
// Licensed under the Apache-2.0 license use caliptra_emu_bus::{Device, Event, EventData, ReadWriteRegister, RecoveryCommandCode}; use caliptra_emu_periph::dma::recovery::RecoveryStatus; use smlang::statemachine; use std::sync::mpsc; use tock_registers::interfaces::Readable; use tock_registers::register_bitfields; st...
rust
Apache-2.0
d6e4f6fae9e4966ec1f5a52167a60c87fafecf1c
2026-01-04T20:21:36.839730Z
false