Skip to content

Commit

Permalink
Add pang15 to special Pang EC type
Browse files Browse the repository at this point in the history
  • Loading branch information
leviport authored and jackpot51 committed Nov 18, 2024
1 parent 70cd13e commit 826fb72
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/app/ec.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ pub enum EcKind {

impl EcKind {
pub unsafe fn new(primary: bool) -> Self {
// Special case for pang12, pang13, and pang14
// Special case for pang12, pang13, pang14, and pang15
{
let mut system_version = String::new();

Expand All @@ -74,7 +74,8 @@ impl EcKind {
}
}

if system_version == "pang12" || system_version == "pang13" || system_version == "pang14" {
if system_version == "pang12" || system_version == "pang13" || system_version == "pang14" ||
system_version == "pang15" {
return EcKind::Pang(
ectool::Pmc::new(0x62, UefiTimeout::new(100_000)),
system_version
Expand Down Expand Up @@ -223,7 +224,7 @@ impl EcComponent {
}

pub fn validate_data(&self, data: Vec<u8>) -> bool {
// Special case for pang12, pang13, and pang14
// Special case for pang12, pang13, pang14, and pang15
match &self.ec {
EcKind::Pang(_pmc, _system_version) => {
// XXX: Get flash size programatically?
Expand Down

0 comments on commit 826fb72

Please sign in to comment.