Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1322267

[PATCH 9/9] staging: ion: Fix page pool cache policy

From John Stultz <john.stultz@linaro.org>
Newsgroups linux.kernel
Subject [PATCH 9/9] staging: ion: Fix page pool cache policy
Date 2016-01-30 07:10 +0100
Message-ID <qWwTo-6Ud-11@gated-at.bofh.it> (permalink)
References <qWwTn-6Ud-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


From: Amit Pundir <amit.pundir@linaro.org>

Fix redundant "buffer->private_flags & ION_PRIV_FLAG_SHRINKER_FREE"
checks in if(!cached ...) condition block.

The previous patch, "ion: Handle the memory mapping correctly on
x86", is broken on android-3.18+ kernels. It conflicts with
upstream commit commit 53a91c68fa7b ("staging: ion: Add private
buffer flag to skip page pooling on free"), and breaks the
ION_PRIV_FLAG_SHRINKER_FREE private flag check logic.

Cc: Android Kernel Team <kernel-team@android.com>
Cc: Greg KH <gregkh@linuxfoundation.org>
Cc: Laura Abbott <labbott@redhat.com>
Cc: Sumit Semwal <sumit.semwal@linaro.org>
Reported-by: chenfeng <puck.chen@hisilicon.com>
Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
Signed-off-by: John Stultz <john.stultz@linaro.org>
---
 drivers/staging/android/ion/ion_system_heap.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/android/ion/ion_system_heap.c b/drivers/staging/android/ion/ion_system_heap.c
index fa62cc4..57d115d 100644
--- a/drivers/staging/android/ion/ion_system_heap.c
+++ b/drivers/staging/android/ion/ion_system_heap.c
@@ -83,7 +83,7 @@ static void free_buffer_page(struct ion_system_heap *heap,
 	unsigned int order = compound_order(page);
 	bool cached = ion_buffer_cached(buffer);
 
-	if (!cached && !(buffer->private_flags & ION_PRIV_FLAG_SHRINKER_FREE)) {
+	if (!cached) {
 		struct ion_page_pool *pool = heap->pools[order_to_index(order)];
 		if (buffer->private_flags & ION_PRIV_FLAG_SHRINKER_FREE)
 			ion_page_pool_free_immediate(pool, page);
-- 
1.9.1

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 0/9] staging: Updates from the Android tree John Stultz <john.stultz@linaro.org> - 2016-01-30 07:10 +0100
  [PATCH 7/9] staging: ion: Handle the memory mapping correctly on x86 John Stultz <john.stultz@linaro.org> - 2016-01-30 07:10 +0100
  [PATCH 2/9] staging: ashmem: Add missing include John Stultz <john.stultz@linaro.org> - 2016-01-30 07:10 +0100
  [PATCH 9/9] staging: ion: Fix page pool cache policy John Stultz <john.stultz@linaro.org> - 2016-01-30 07:10 +0100
  [PATCH 8/9] staging: ion: Add X86 dependency for ION_POOL_CACHE_POLICY John Stultz <john.stultz@linaro.org> - 2016-01-30 07:10 +0100
  [PATCH 1/9] staging: ashmem: Avoid deadlock with mmap/shrink John Stultz <john.stultz@linaro.org> - 2016-01-30 07:10 +0100
  [PATCH 4/9] staging: lowmemorykiller: Make default lowmemorykiller debug message useful John Stultz <john.stultz@linaro.org> - 2016-01-30 07:20 +0100
  [PATCH 5/9] staging: lowmemorykiller: Trace kill events. John Stultz <john.stultz@linaro.org> - 2016-01-30 07:20 +0100
  [PATCH 3/9] staging: lowmemorykiller: Fix task_struct leak John Stultz <john.stultz@linaro.org> - 2016-01-30 07:20 +0100
    Re: [PATCH 3/9] staging: lowmemorykiller: Fix task_struct leak Greg KH <gregkh@linuxfoundation.org> - 2016-02-07 23:50 +0100
      Re: [PATCH 3/9] staging: lowmemorykiller: Fix task_struct leak John Stultz <john.stultz@linaro.org> - 2016-02-08 20:00 +0100
  [PATCH 6/9] staging: ion: Set minimum carveout heap allocation order to PAGE_SHIFT John Stultz <john.stultz@linaro.org> - 2016-01-30 07:20 +0100
    Re: [PATCH 6/9] staging: ion: Set minimum carveout heap allocation  order to PAGE_SHIFT Laura Abbott <labbott@redhat.com> - 2016-02-01 21:30 +0100
  Re: [PATCH 0/9] staging: Updates from the Android tree Laura Abbott <labbott@redhat.com> - 2016-02-01 22:20 +0100
    Re: [PATCH 0/9] staging: Updates from the Android tree John Stultz <john.stultz@linaro.org> - 2016-02-01 22:30 +0100
  Re: [PATCH 0/9] staging: Updates from the Android tree Greg KH <gregkh@linuxfoundation.org> - 2016-02-08 00:00 +0100

csiph-web