pvmfw: Expand the allowed numbers of opp tables

Using 16 was too small for the number of opp tables for some devices,
extend it to 20 for now. Also fix a bug where it was incorrectly using
DeviceTreeInfo::MAX_CPU as size.

Bug: 284369518
Test: m pvmfw, boot protected microdroid and tested vcpufreq end-to-end
Change-Id: I6b03e84af0ae2cac5a1f2253b7b7e07b0c272537
Signed-off-by: David Dai <davidai@google.com>
diff --git a/pvmfw/src/fdt.rs b/pvmfw/src/fdt.rs
index 65b46c0..f20451a 100644
--- a/pvmfw/src/fdt.rs
+++ b/pvmfw/src/fdt.rs
@@ -185,7 +185,7 @@
 }
 
 impl CpuInfo {
-    const MAX_OPPTABLES: usize = 16;
+    const MAX_OPPTABLES: usize = 20;
 }
 
 fn read_opp_info_from(
@@ -267,7 +267,7 @@
 
 fn patch_opptable(
     node: FdtNodeMut,
-    opptable: Option<ArrayVec<[u64; DeviceTreeInfo::MAX_CPUS]>>,
+    opptable: Option<ArrayVec<[u64; CpuInfo::MAX_OPPTABLES]>>,
 ) -> libfdt::Result<()> {
     let oppcompat = cstr!("operating-points-v2");
     let next = node.next_compatible(oppcompat)?.ok_or(FdtError::NoSpace)?;