---
title: IOFree
framework: kernel
role: symbol
role_heading: Function
path: kernel/1575290-iofree
---

# IOFree

Frees memory allocated with IOMalloc.

## Declaration

```occ
void IOFree(void *address, vm_size_t size);
```

## Parameters

- `address`: Pointer to the allocated memory. Must be identical to result @of a prior IOMalloc.
- `size`: Size of the memory allocated. Must be identical to size of @the corresponding IOMalloc

## Discussion

Discussion This function frees memory allocated with IOMalloc, it may block and so should not be called from interrupt level or while a simple lock is held.

## See Also

### Deallocation

- [IOFreeAligned](kernel/1575330-iofreealigned.md)
- [IOFreePageable](kernel/1575300-iofreepageable.md)
