Skip to content

Commit

Permalink
ion: allow cached mappings of chunk and system heap buffers
Browse files Browse the repository at this point in the history
Now that ion_vm_fault uses vm_insert_pfn instead of vm_insert_page
cached buffers can be supported in any heap.  Remove the checks
in the chunk and system heaps.

Signed-off-by: Colin Cross <[email protected]>
Signed-off-by: John Stultz <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
  • Loading branch information
colincross authored and gregkh committed Dec 14, 2013
1 parent a305690 commit a053b6a
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 6 deletions.
3 changes: 0 additions & 3 deletions drivers/staging/android/ion/ion_chunk_heap.c
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,6 @@ static int ion_chunk_heap_allocate(struct ion_heap *heap,
unsigned long num_chunks;
unsigned long allocated_size;

if (ion_buffer_fault_user_mappings(buffer))
return -ENOMEM;

allocated_size = ALIGN(size, chunk_heap->chunk_size);
num_chunks = allocated_size / chunk_heap->chunk_size;

Expand Down
3 changes: 0 additions & 3 deletions drivers/staging/android/ion/ion_system_heap.c
Original file line number Diff line number Diff line change
Expand Up @@ -148,9 +148,6 @@ static int ion_system_heap_allocate(struct ion_heap *heap,
if (align > PAGE_SIZE)
return -EINVAL;

if (ion_buffer_fault_user_mappings(buffer))
return -EINVAL;

INIT_LIST_HEAD(&pages);
while (size_remaining > 0) {
info = alloc_largest_available(sys_heap, buffer, size_remaining, max_order);
Expand Down

0 comments on commit a053b6a

Please sign in to comment.