---
name: "truncate_inode_pages"
section: "9"
platform: "linux"
package: "linux-manual-4.9"
version: "4.9.228-1"
release: "Debian 9 (Stretch)"
platforms: ["linux"]
url: "https://new.carta.tech/truncate_inode_pages"
---

# truncate\_inode\_pages(9)

truncate \*all\* the pages from an offset

## NAME

truncate\_inode\_pages - truncate \*all\* the pages from an offset

## SYNOPSIS

**void truncate\_inode\_pages(struct address\_space \*** *mapping***, loff\_t** *lstart***);**

## ARGUMENTS

*mapping*

mapping to truncate

*lstart*

offset from which to truncate

## DESCRIPTION

Called under (and serialised by) inode-\>i\_mutex.

## NOTE

When this function returns, there can be a page in the process of deletion (inside **\_\_delete\_from\_page\_cache**) in the specified range. Thus mapping-\>nrpages can be non-zero when this function returns even after truncation of the whole mapping.

## COPYRIGHT
