From 4cf89d373d93727407db6d997162f70c2093e9cb Mon Sep 17 00:00:00 2001 From: Qiu Wenbo Date: Thu, 20 Feb 2020 23:55:22 +0800 Subject: [PATCH] pci: handle extended configuration space properly This is critical to support extended capabilitiy list. Signed-off-by: Qiu Wenbo --- pci/src/configuration.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pci/src/configuration.rs b/pci/src/configuration.rs index 15654e55e..71e583854 100755 --- a/pci/src/configuration.rs +++ b/pci/src/configuration.rs @@ -9,8 +9,8 @@ use crate::{MsixConfig, PciInterruptPin}; use byteorder::{ByteOrder, LittleEndian}; use std::fmt::{self, Display}; -// The number of 32bit registers in the config space, 256 bytes. -const NUM_CONFIGURATION_REGISTERS: usize = 64; +// The number of 32bit registers in the config space, 4096 bytes. +const NUM_CONFIGURATION_REGISTERS: usize = 1024; const STATUS_REG: usize = 1; const STATUS_REG_CAPABILITIES_USED_MASK: u32 = 0x0010_0000;