---
title: unmap
framework: kernel
role: pseudoSymbol
path: kernel/iostorage/1811145-unmap
---

# unmap

## Declaration

```occ
virtual IOReturn unmap(
 IOService *client, 
 IOStorageExtent *extents, 
 UInt32extentsCount, 
 UInt32 options = 0); 
```

## Parameters

- `client`: Client requesting the operation.
- `extents`: List of extents. See IOStorageExtent. It is legal for the callee to overwrite the contents of this buffer in order to satisfy the request.
- `extentsCount`: Number of extents.

## Return Value

Return Value Returns the status of the operation.

## Overview

Overview Delete unused data from the storage object at the specified byte offsets, synchronously.

## See Also

### Miscellaneous

- [complete](kernel/iostorage/1810767-complete.md)
- [copyPhysicalExtent](kernel/iostorage/1810820-copyphysicalextent.md)
- [handleClose](kernel/iostorage/1810866-handleclose.md)
- [handleIsOpen](kernel/iostorage/1810905-handleisopen.md)
- [handleOpen](kernel/iostorage/1810948-handleopen.md)
- [lockPhysicalExtents](kernel/iostorage/1810985-lockphysicalextents.md)
- [open](kernel/iostorage/1811013-open.md)
- [read()](kernel/iostorage/1811038-read.md)
- [read()](kernel/iostorage/1811068-read.md)
- [synchronizeCache](kernel/iostorage/1811091-synchronizecache.md)
- [unlockPhysicalExtents](kernel/iostorage/1811117-unlockphysicalextents.md)
- [write()](kernel/iostorage/1811168-write.md)
- [write()](kernel/iostorage/1811185-write.md)
