mirror of
https://github.com/google/alioth.git
synced 2024-11-24 04:09:36 +00:00
fix(vfio): clear the multi-function device bit
Signed-off-by: Changyuan Lyu <changyuanl@google.com>
This commit is contained in:
parent
a64c445e4c
commit
022d4535b2
1 changed files with 1 additions and 0 deletions
|
@ -427,6 +427,7 @@ where
|
|||
cdev.dev.fd().read_at(&mut buf, region_config.offset)?;
|
||||
|
||||
let (mut dev_header, _) = DeviceHeader::read_from_prefix(&buf).unwrap();
|
||||
dev_header.common.header_type &= !(1 << 7);
|
||||
if dev_header.common.header_type != HeaderType::Device as u8 {
|
||||
return error::NotSupportedHeader {
|
||||
ty: dev_header.common.header_type,
|
||||
|
|
Loading…
Reference in a new issue