From b7512263be02265988a32c4920bba4c61b766688 Mon Sep 17 00:00:00 2001 From: Wei Liu Date: Tue, 23 Jul 2024 19:34:21 +0000 Subject: [PATCH] virtio-devices: iommu: use inspect_err instead of map_err Signed-off-by: Wei Liu --- virtio-devices/src/iommu.rs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/virtio-devices/src/iommu.rs b/virtio-devices/src/iommu.rs index fce796d4b..28594dfe5 100644 --- a/virtio-devices/src/iommu.rs +++ b/virtio-devices/src/iommu.rs @@ -352,9 +352,8 @@ impl Request { let desc = desc_chain .next() .ok_or(Error::DescriptorChainTooShort) - .map_err(|e| { + .inspect_err(|_| { error!("Missing head descriptor"); - e })?; // The descriptor contains the request type which MUST be readable.