MCPcopy Create free account
hub / github.com/cloud-hypervisor/cloud-hypervisor / try_clone

Method try_clone

block/src/qcow_disk.rs:148–156  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

146
147impl disk_file::AsyncDiskFile for QcowDisk {
148 fn try_clone(&self) -> BlockResult<Box<dyn disk_file::AsyncDiskFile>> {
149 Ok(Box::new(QcowDisk {
150 metadata: Arc::clone(&self.metadata),
151 backing_file: self.backing_file.as_ref().map(Arc::clone),
152 sparse: self.sparse,
153 data_raw_file: self.data_raw_file.clone(),
154 use_io_uring: self.use_io_uring,
155 }))
156 }
157
158 fn create_async_io(&self, ring_depth: u32) -> BlockResult<Box<dyn AsyncIo>> {
159 if self.use_io_uring {

Callers 3

make_qcow_fileFunction · 0.45

Calls 3

newFunction · 0.85
mapMethod · 0.45
cloneMethod · 0.45