summaryrefslogtreecommitdiffstats
path: root/kernel/drivers/block/xen-blkfront.c
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/drivers/block/xen-blkfront.c')
-rw-r--r--kernel/drivers/block/xen-blkfront.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/kernel/drivers/block/xen-blkfront.c b/kernel/drivers/block/xen-blkfront.c
index 2c61cf8c6..89c7371ab 100644
--- a/kernel/drivers/block/xen-blkfront.c
+++ b/kernel/drivers/block/xen-blkfront.c
@@ -1118,8 +1118,10 @@ static void blkif_completion(struct blk_shadow *s, struct blkfront_info *info,
* Add the used indirect page back to the list of
* available pages for indirect grefs.
*/
- indirect_page = pfn_to_page(s->indirect_grants[i]->pfn);
- list_add(&indirect_page->lru, &info->indirect_pages);
+ if (!info->feature_persistent) {
+ indirect_page = pfn_to_page(s->indirect_grants[i]->pfn);
+ list_add(&indirect_page->lru, &info->indirect_pages);
+ }
s->indirect_grants[i]->gref = GRANT_INVALID_REF;
list_add_tail(&s->indirect_grants[i]->node, &info->grants);
}