On failure we need to make sure the page we free has wb cache
attribute. Do this pas call the proper ttm page helper function.
Signed-off-by: Jerome Glisse <[email protected]>
Reviewed-by: Konrad Rzeszutek Wilk <[email protected]>
Reviewed-by: Thomas Hellstrom <[email protected]>
}
return p;
out_err:
- put_page(p);
+ INIT_LIST_HEAD(&h);
+ list_add(&p->lru, &h);
+ ttm_put_pages(&h, 1, ttm->page_flags,
+ ttm->caching_state, &ttm->dma_address[index]);
return NULL;
}