[RFCv2][PATCH 1/5] Documentation: Introduce kernel_force_cache_* APIs

2016-08-08 Thread Laura Abbott
Some frameworks (e.g. Ion) may need to do explicit cache management to meet performance/correctness requirements. Rather than piggy-back on another API and hope the semantics don't change, introduce a set of APIs to force a page to be cleaned/invalidated in the cache. Signed-off-by: Laura Abbott

[RFCv2][PATCH 2/5] arm: Implement ARCH_HAS_FORCE_CACHE

2016-08-08 Thread Laura Abbott
arm may need the kernel_force_cache APIs to guarantee data consistency. Implement versions of these APIs based on the DMA APIs. Signed-off-by: Laura Abbott <labb...@redhat.com> --- arch/arm/include/asm/cacheflush.h | 4 ++ arch/arm/mm/dma-mapping.c

[RFCv2][PATCH 0/5] Cleanup Ion mapping/caching

2016-08-08 Thread Laura Abbott
driver could potentially be converted with the addition of an x86 implementation. Feedback appreciated as always. Thanks, Laura [1] https://lkml.kernel.org/g/<1464205684-5587-1-git-send-email-labb...@redhat.com> Laura Abbott (5): Documentation: Introduce kernel_force_cache_* APIs

[RESEND][PATCH 4/5] staging: android: ion: Drop ion_carveout_allocate definitions

2016-08-08 Thread Laura Abbott
ion_carveout_allocate and ion_carveout_free aren't used outside of the carveout heap. Get rid of the definitions. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion_carveout_heap.c | 2 ++ drivers/staging/android/ion/ion_priv.h | 14 ---

[RESEND][PATCH 5/5] staging: android: ion: Get rid of ion_reserve

2016-08-08 Thread Laura Abbott
ion_reserve was supposed to be used to reserve memory in board files. These days, board files are no more and there are other more controlled mechanisms for reserving memory. Get rid of this function. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion.

[RESEND][PATCH 2/5] staging: android: ion: Drop ion_phys interface

2016-08-08 Thread Laura Abbott
ion_phys was an interface used for older legacy behavior. sg_tables are the standard now. Get rid of it. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion.c | 26 - drivers/staging/android/ion/ion.h

[RESEND][PATCH 3/5] staging: android: ion: Get rid of map_dma/unmap_dma

2016-08-08 Thread Laura Abbott
The map_dma API interface was designed to generate an sg_table. Currently, every client just creates the table at allocation time and then returns the one table. Nothing happens on unmap_dma either. Just get rid of the API and assign the sg_table directly. Signed-off-by: Laura Abbott <l

[RESEND][PATCH 1/5] staging: android: ion: Get rid of ion_sg_table

2016-08-08 Thread Laura Abbott
The ion_sg_table interface is mostly a reimplementation of what dma_buf is doing. Clients should be using dma_buf APIs instead. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion.c | 20 drivers/staging/android/ion/ion.h | 11

Re: [PATCH 33/33] Staging: android: ion: ion.c: Compression of lines for

2016-07-31 Thread Laura Abbott
On 07/30/2016 09:11 AM, Nadim almas wrote: This patch compresses two lines in to a single line in file ion.c if immediate return statement is found. It also removes variable bytes_written as it is no longer needed. This still says bytes_written. None of the patches after your first one apply

[PATCH 5/5] staging: android: ion: Get rid of ion_reserve

2016-06-17 Thread Laura Abbott
ion_reserve was supposed to be used to reserve memory in board files. These days, board files are no more and there are other more controlled mechanisms for reserving memory. Get rid of this function. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion.

[PATCH 3/5] staging: android: ion: Get rid of map_dma/unmap_dma

2016-06-17 Thread Laura Abbott
The map_dma API interface was designed to generate an sg_table. Currently, every client just creates the table at allocation time and then returns the one table. Nothing happens on unmap_dma either. Just get rid of the API and assign the sg_table directly. Signed-off-by: Laura Abbott <l

[PATCH 2/5] staging: android: ion: Drop ion_phys interface

2016-06-17 Thread Laura Abbott
ion_phys was an interface used for older legacy behavior. sg_tables are the standard now. Get rid of it. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion.c | 26 - drivers/staging/android/ion/ion.h

[PATCH 4/5] staging: android: ion: Drop ion_carveout_allocate definitions

2016-06-17 Thread Laura Abbott
ion_carveout_allocate and ion_carveout_free aren't used outside of the carveout heap. Get rid of the definitions. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion_carveout_heap.c | 2 ++ drivers/staging/android/ion/ion_priv.h | 14 ---

[PATCH 1/5] staging: android: ion: Get rid of ion_sg_table

2016-06-17 Thread Laura Abbott
The ion_sg_table interface is mostly a reimplementation of what dma_buf is doing. Clients should be using dma_buf APIs instead. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion.c | 20 drivers/staging/android/ion/ion.h | 11

[PATCH 0/5] Ion cleanup

2016-06-17 Thread Laura Abbott
to be extended. Thanks, Laura Laura Abbott (5): staging: android: ion: Get rid of ion_sg_table staging: android: ion: Drop ion_phys interface staging: android: ion: Get rid of map_dma/unmap_dma staging: android: ion: Drop ion_carveout_allocate definitions staging: android: ion: Get rid

Re: [RFC][PATCH 6/6] staging: android: ion: Introduce new ioctls for dynamic heaps

2016-06-08 Thread Laura Abbott
n comments not about the heap ID mapping because I'm leaning towards dropping the heap ID mapping. I've a few inline comments below. -Brian On Mon, Jun 06, 2016 at 11:23:33AM -0700, Laura Abbott wrote: From: Laura Abbott <labb...@fedoraproject.org> The Ion ABI for heaps is limiting to work with

Re: [RFC][PATCH 0/6] ion: improved ABI

2016-06-08 Thread Laura Abbott
On 06/08/2016 08:15 AM, Brian Starkey wrote: Hi Laura, On Mon, Jun 06, 2016 at 11:23:27AM -0700, Laura Abbott wrote: The ABI for Ion's ioctl interface are a pain to work with. The heap IDs are a 32-bit non-discoverable namespace that form part of the ABI. There's no way to determine what ABI

Re: [RFC][PATCH 6/6] staging: android: ion: Introduce new ioctls for dynamic heaps

2016-06-08 Thread Laura Abbott
On 06/08/2016 06:50 AM, Liviu Dudau wrote: On Mon, Jun 06, 2016 at 11:23:33AM -0700, Laura Abbott wrote: From: Laura Abbott <labb...@fedoraproject.org> The Ion ABI for heaps is limiting to work with for more complex systems. Heaps have to be registered at boot time with known ids ava

Re: [Linaro-mm-sig] [RFC][PATCH 0/6] ion: improved ABI

2016-06-08 Thread Laura Abbott
? Thanks, Laura But beyond this, The new alloc2 with not-handle flag is good. And the pull out of ioctl interface is also a good cleanup. On 2016/6/7 2:23, Laura Abbott wrote: The ABI for Ion's ioctl interface are a pain to work with. The heap IDs are a 32-bit non-discoverable namespace that form

[RFC][PATCH 5/6] staging: android: ion: Add an ioctl for ABI checking

2016-06-06 Thread Laura Abbott
The current Ion ioctls lack a good way to tell what ioctls are available. Introduce an ioctl to give an ABI version. This way when the ABI inevitably gets screwed up userspace will have a way to tell what version of the screw up is available. Signed-off-by: Laura Abbott <labb...@redhat.

[RFC][PATCH 6/6] staging: android: ion: Introduce new ioctls for dynamic heaps

2016-06-06 Thread Laura Abbott
From: Laura Abbott <labb...@fedoraproject.org> The Ion ABI for heaps is limiting to work with for more complex systems. Heaps have to be registered at boot time with known ids available to userspace. This becomes a tight ABI which is prone to breakage. Introduce a new mechanism for regis

[RFC][PATCH 4/6] staging: android: ion: Pull out ion ioctls to a separate file

2016-06-06 Thread Laura Abbott
The number of Ion ioctls may continue to grow along with necessary validation. Pull it out into a separate file for easier management and review. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/Makefile| 3 +- drivers/staging/android/ion/ion-ioctl.c

[RFC][PATCH 3/6] staging: android: ion: Drop heap type masks

2016-06-06 Thread Laura Abbott
From: Laura Abbott <labb...@fedoraproject.org> There is no advantage to having heap types be a mask. The ion client has long since dropped the mask. Drop the notion of heap type masks as well. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/uapi/ion.h |

[RFC][PATCH 2/6] staging: android: ion: Switch to using an idr to manage heaps

2016-06-06 Thread Laura Abbott
From: Laura Abbott <labb...@fedoraproject.org> In anticipation of dynamic registration of heaps, switch to using an idr for heaps. The idr makes it easier to control the assignment and management + lookup of heap numbers. Signed-off-by: Laura Abbott <labb...@redhat.com> --- dri

[RFC][PATCH 1/6] staging: android: ion: return error value for ion_device_add_heap

2016-06-06 Thread Laura Abbott
From: Laura Abbott <labb...@fedoraproject.org> ion_device_add_heap doesn't return an error value. Change it to return information to callers. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion.c | 7 +-- drivers/staging/android/ion/io

[RFC][PATCH 0/6] ion: improved ABI

2016-06-06 Thread Laura Abbott
is established. Thanks, Laura P.S. Not to turn this into a bike shedding session but if you have suggestions for a name for this framework other than Ion I would be interested to hear them. Too many other things are already named Ion. Laura Abbott (6): staging: android: ion: return error value

[RFC][PATCH 1/3] staging: ion: Move away from the DMA APIs for cache flushing

2016-05-25 Thread Laura Abbott
to call cache operations outside of the DMA API. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/Kconfig | 14 - drivers/staging/android/ion/Makefile| 3 + drivers/staging/android/ion/ion-arm.c

[RFC][PATCH 0/3] Clean up Ion mapping/caching

2016-05-25 Thread Laura Abbott
to the underlying DMA APIs so the final patch in the series adds the appropriate calls. Feedback is appreciated. Thanks, Laura Laura Abbott (3): staging: ion: Move away from the DMA APIs for cache flushing staging: ion: Add support for syncing with DMA_BUF_IOCTL_SYNC staging: ion: Add dma_map

[RFC][PATCH 3/3] staging: ion: Add dma_map/dma_unmap calls to dma_buf calls

2016-05-25 Thread Laura Abbott
call backs. Signed-off-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion.c | 12 1 file changed, 12 insertions(+) diff --git a/drivers/staging/android/ion/ion.c b/drivers/staging/android/ion/ion.c index 2096592..52dbea4 100644 --- a/drivers/staging/andro

[RFC][PATCH 2/3] staging: ion: Add support for syncing with DMA_BUF_IOCTL_SYNC

2016-05-25 Thread Laura Abbott
dma_buf added support for a userspace syncing ioctl. It is implemented by calling dma_buf_begin_cpu_access and dma_buf_end_cpu_access. Ion currently lacks cache operations on this code path. Add them for compatibility with the dma_buf ioctl. Signed-off-by: Laura Abbott <labb...@redhat.

Re: [PATCH 01/54] MAINTAINERS: Add file patterns for ion device tree bindings

2016-05-23 Thread Laura Abbott
On 05/22/2016 02:05 AM, Geert Uytterhoeven wrote: Submitters of device tree binding documentation may forget to CC the subsystem maintainer if this is missing. Signed-off-by: Geert Uytterhoeven <ge...@linux-m68k.org> Cc: Laura Abbott <labb...@redhat.com> Cc: Sumit Semwa

Re: [PATCH v2] ION: Sys_heap: Add cached pool to spead up cached buffer alloc

2016-05-23 Thread Laura Abbott
licon.com> Reviewed-by: Fu Jun <oliver...@hisilicon.com> Acked-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion_page_pool.c | 10 +- drivers/staging/android/ion/ion_priv.h| 5 +- drivers/staging/android/ion/ion_system_heap.c | 183 +++

Re: [RESEND PATCH] ION: Sys_heap: Add cached pool to spead up cached buffer alloc

2016-05-09 Thread Laura Abbott
On 05/09/2016 01:37 AM, Chen Feng wrote: Add ion cached pool in system heap. Signed-off-by: Chen Feng Signed-off-by: Xia Qing Reviewed-by: Fu Jun --- drivers/staging/android/ion/ion_system_heap.c | 145

Re: [PATCH] ION: Sys_heap: Makes ion buffer always alloc from page pool

2016-05-06 Thread Laura Abbott
On 05/05/2016 07:48 PM, Chen Feng wrote: On 2016/5/6 1:09, Laura Abbott wrote: On 05/04/2016 08:27 PM, Chen Feng wrote: Makes the ion buffer always alloced from page pool, no matter it's cached or not. In this way, it can improve the efficiency of it. Currently, there is no difference from

Re: [PATCH] ION: Sys_heap: Makes ion buffer always alloc from page pool

2016-05-05 Thread Laura Abbott
On 05/04/2016 08:27 PM, Chen Feng wrote: Makes the ion buffer always alloced from page pool, no matter it's cached or not. In this way, it can improve the efficiency of it. Currently, there is no difference from cached or non-cached buffer for the page pool. The advantage of the uncached

Re: [PATCH v2 4/4] drivers: staging: remove BUG_ON

2016-04-18 Thread Laura Abbott
On 04/17/2016 05:35 PM, Tobin C Harding wrote: drivers/staging/android/ion/ion.c calls BUG_ON in places where WARN_ON will suffice. This patch replaces two such occurences. Two other occurences remain. You got the logic flow correct but I'd prefer to keep the BUG_ON. It's catching actual

[PATCHv2] MAINTAINERS: Add Android Ion as a separate entry

2016-04-11 Thread Laura Abbott
The android drivers have a few other people reviewing patches. Add a separate entry to ensure patches go to the right people. Signed-off-by: Laura Abbott <labb...@redhat.com> --- v2: Drop RFC tag --- MAINTAINERS | 9 + 1 file changed, 9 insertions(+) diff --git a/MAINTAI

[RFC][PATCH] MAINTAINERS: Add Android Ion as a separate entry

2016-04-08 Thread Laura Abbott
The android drivers have a few other people reviewing patches. Add a separate entry to ensure patches go to the right people. Signed-off-by: Laura Abbott <labb...@redhat.com> --- Sumit and I have been doing review anyway so I think it makes sense for us to be cc-ed on patches in ad

Re: [PATCH] ion: scatterlist offset not used for buffer map

2016-04-08 Thread Laura Abbott
On 04/07/2016 11:56 PM, John Einar Reitan wrote: On Thu, Apr 07, 2016 at 12:37:50PM -0700, Laura Abbott wrote: On 04/07/2016 04:29 AM, John Einar Reitan wrote: ion's default user/kernel page mapping code don't honor the offset option for scatterlists. It uses sg_page and expect the whole page

Re: [PATCH] staging: android: ion: make locally used functions static

2016-04-07 Thread Laura Abbott
rkus Böhme <markus.boe...@mailbox.org> Reviewed-by: Laura Abbott <labb...@redhat.com> --- drivers/staging/android/ion/ion.c |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/staging/android/ion/ion.c b/drivers/staging/android/ion/ion.c index d

Re: [PATCH] staging: android: ion: dummy: fix dereference of ERR_PTR

2016-04-07 Thread Laura Abbott
On 04/07/2016 09:32 AM, Sudip Mukherjee wrote: ion_device_create() can fail and if it fails then it returns the error value in ERR_PTR. Reviewed-by: Laura Abbott <labb...@redhat.com> Signed-off-by: Sudip Mukherjee <sudip.mukher...@codethink.co.uk> --- drivers/staging

Re: [PATCH] ion: scatterlist offset not used for buffer map

2016-04-07 Thread Laura Abbott
On 04/07/2016 04:29 AM, John Einar Reitan wrote: ion's default user/kernel page mapping code don't honor the offset option for scatterlists. It uses sg_page and expect the whole page to be mapped, while the offset could dictate an offset within a large page. sg_phys correctly accounts for the

Re: [RFC 0/2] staging: ion: of_ion_device_get

2016-03-22 Thread Laura Abbott
On 03/22/2016 04:08 PM, Moritz Fischer wrote: Hi Laura, On Tue, Mar 22, 2016 at 3:51 PM, Laura Abbott <labb...@redhat.com> wrote: In the past what drivers have done is a foo_ion_client_create which has the reference to the ion_device created from ion_device_create. Drivers the

Re: [RFC 0/2] staging: ion: of_ion_device_get

2016-03-22 Thread Laura Abbott
On 03/22/2016 03:33 PM, Moritz Fischer wrote: Hi all, probably I'm doing this all wrong. I'm playing around with a bunch of accelerators and I need to share buffers between them. I have my heaps implemented as a platform device and from what I understand I'll need a reference to the struct

Re: [PATCH RESEND 1/1] staging: ion: debugfs invalid gfp mask

2016-02-26 Thread Laura Abbott
probably best if you send out a v3 version with the commit message fixed up. For the actual patch itself, you can add Reviewed-by: Laura Abbott <labb...@redhat.com> when you resend. Thanks, Laura Signed-off-by: Derek Yerger <d...@drexel.edu> --- diff --git a/drivers/staging/android/

Re: [PATCH v3] staging/android/ion : fix a race condition in the ion driver

2016-02-25 Thread Laura Abbott
d the > ion driver decrements the reference after it has been > freed. > > To fix this problem client->lock mutex is extended > to protect all the codes that uses the handle. > > Signed-off-by: Eun Taik Lee <eun.taik@samsung.com> Reviewed-by: Laura Abbott <labb...@redha

Re: [PATCH 1/1] staging: ion: debugfs sparse warning, proper mask

2016-02-22 Thread Laura Abbott
On 02/20/2016 07:15 PM, Derek Yerger wrote: From drivers/staging/android TODO file - sparse errors. The current code attempts assignment of -1 to unsigned type gfp_t. Assignment should be an enumerated type of GFP_KERNEL, GFP_ATOMIC, GFP_HIGHMEM, or __GFP_HIGH. The original 2014 patch by Gioh

Re: [PATCH v2] staging/android/ion : fix a race condition in the ion driver

2016-02-19 Thread Laura Abbott
On 02/19/2016 04:03 AM, EunTaik Lee wrote: > There is a use-after-free problem in the ion driver. > This is caused by a race condition in the ion_ioctl() > function. > > A handle has ref count of 1 and two tasks on different > cpus calls ION_IOC_FREE simultaneously. > > cpu 0

Re: [RFC PATCH] staging/android/ion : fix a race condition in the ion driver

2016-02-17 Thread Laura Abbott
On 02/16/2016 10:32 PM, EunTaik Lee wrote: > There was a use-after-free problem in the ion driver. > > The problem is detected as an unaligned access in the > spin lock functions since it uses load exclusive > instruction. In some cases it corrupts the slub's > free pointer which causes a

Re: [PATCHv2] staging: android: ion: use the manged version of DMA memory allocation

2016-02-03 Thread Laura Abbott
On 02/03/2016 04:03 AM, Robin Murphy wrote: On 03/02/16 06:49, Gujulan Elango, Hari Prasath (H.) wrote: From: Hari Prasath Gujulan Elango Use the managed version of the dma_alloc_coherent() i.e. the dmam_alloc_coherent() & accordingly cleanup the error handling

Re: [PATCH] staging: android: ion: Set the length of the DMA sg entries in buffer

2016-01-21 Thread Laura Abbott
On 01/21/2016 03:57 AM, Jon Medhurst (Tixy) wrote: From: Liviu Dudau ion_buffer_create() will allocate a buffer and then create a DMA mapping for it, but it forgot to set the length of the page entries. Signed-off-by: Liviu Dudau Signed-off-by: Jon

Re: [PATCH] staging: android: ion: Set the length of the DMA sg entries in buffer

2016-01-21 Thread Laura Abbott
On 01/21/2016 12:19 PM, Jon Medhurst (Tixy) wrote: On Thu, 2016-01-21 at 09:39 -0800, Laura Abbott wrote: On 01/21/2016 03:57 AM, Jon Medhurst (Tixy) wrote: From: Liviu Dudau <liviu.du...@arm.com> ion_buffer_create() will allocate a buffer and then create a DMA mapping for it, but it

Re: [PATCH] staging: ion: make the pte default none PTE_RDONLY

2016-01-15 Thread Laura Abbott
(adding linux-arm and a few people) On 01/14/2016 06:42 PM, Chen Feng wrote: The page is already alloc at ion_alloc function, ion_mmap map the alloced pages to user-space. The default prot can be PTE_RDONLY. Take a look at here: set_pte_at() arch/arm64/include/asm: if

Re: [PATCH] staging: ion : Donnot wakeup kswapd in ion system alloc

2016-01-12 Thread Laura Abbott
he data presented here. Reviewed-by: Laura Abbott <labb...@redhat.com> ___ devel mailing list de...@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

[RESEND][PATCHv2 3/3] NOMERGE: Sample driver

2016-01-11 Thread Laura Abbott
Small sample driver to show what setup would look like with the dt bindings Signed-off-by: Laura Abbott <la...@labbott.name> --- drivers/staging/android/ion/Kconfig | 6 ++ drivers/staging/android/ion/Makefile| 1 + drivers/staging/android/ion/ion_of_sample.

[RESEND][PATCHv2 2/3] staging: ion: Add files for parsing the devicetree

2016-01-11 Thread Laura Abbott
Devicetree is the preferred mechanism for platform definition these days. Add a set of files for supporting Ion with devicetree. This is a set of functions for drivers to call to parse the Ion devicetree along with definitons for defining heaps. Signed-off-by: Laura Abbott <la...@labbott.n

[RESEND][PATCHv2 1/3] ion: Devicetree bindings for Ion

2016-01-11 Thread Laura Abbott
This adds a base set of devicetree bindings for the Ion memory manager. This supports setting up the generic set of heaps and their properties. Signed-off-by: Laura Abbott <la...@labbott.name> --- drivers/staging/android/ion/devicetree.txt | 50 ++ 1 file chang

Re: [RESEND][PATCHv2 1/3] ion: Devicetree bindings for Ion

2016-01-11 Thread Laura Abbott
On 1/11/16 3:28 PM, Rob Herring wrote: On Mon, Jan 11, 2016 at 3:39 PM, Laura Abbott <la...@labbott.name> wrote: This adds a base set of devicetree bindings for the Ion memory manager. This supports setting up the generic set of heaps and their properties. Signed-off-by: Laura Abbo

[RESEND][PATCHv2 0/3] Devicetree bindings for Ion

2016-01-11 Thread Laura Abbott
Hi, There was some recent discussion (http://thread.gmane.org/gmane.linux.ports.arm.kernel/468051/) about Ion DT bindings and a request that I resend my proposal for common DT bindings. This is a straight resend, no bux fixed that were pointed out. Previous thread:

Re: [PATCHv2 1/1] staging/ion: Add support to get ion handle from dma buf

2016-01-06 Thread Laura Abbott
Laura Abbott <labb...@redhat.com> --- v2: Updated commit message with use case explanation, as suggested by Laura Abbott<labb...@redhat.com> drivers/staging/android/ion/ion.c | 21 +++-- drivers/staging/android/ion/ion.h | 20 2

Re: [PATCH] staging/ion: Add support to get ion handle from dma buf

2016-01-05 Thread Laura Abbott
On 01/05/2016 05:03 AM, Rohit kumar wrote: Currently we can only import dma buf fd's to get ion_handle. Adding support to import dma buf handles to support kernel specific use cases. Signed-off-by: Rohit kumar --- Currently, ION is the memory manager for graphics in

Re: [PATCHv2 0/3] Devicetree bindings for Ion

2015-11-17 Thread Laura Abbott
On 11/17/15 7:15 AM, Arnd Bergmann wrote: On Monday 16 November 2015 16:57:32 Laura Abbott wrote: Hi, This is another attempt at devicetree bindings for Ion. The big complaint from v1 was that too much unnecessary data was being pushed into devicetree. v2 takes a different approach of using

[PATCHv2 2/3] staging: ion: Add files for parsing the devicetree

2015-11-16 Thread Laura Abbott
Devicetree is the preferred mechanism for platform definition these days. Add a set of files for supporting Ion with devicetree. This is a set of functions for drivers to call to parse the Ion devicetree along with definitons for defining heaps. Signed-off-by: Laura Abbott <la...@labbott.n

[PATCHv2 3/3] NOMERGE: Sample driver

2015-11-16 Thread Laura Abbott
Small sample driver to show what setup would look like with the dt bindings Signed-off-by: Laura Abbott <la...@labbott.name> --- drivers/staging/android/ion/Kconfig | 6 ++ drivers/staging/android/ion/Makefile| 1 + drivers/staging/android/ion/ion_of_sample.

[PATCHv2 0/3] Devicetree bindings for Ion

2015-11-16 Thread Laura Abbott
might look like. As always, your comments and reviews are appreciated. Thanks, Laura Laura Abbott (3): ion: Devicetree bindings for Ion staging: ion: Add files for parsing the devicetree (WIP) NOMERGE: Sample driver drivers/staging/android/ion/Kconfig | 16 +++ drivers/staging

[PATCHv2 1/3] ion: Devicetree bindings for Ion

2015-11-16 Thread Laura Abbott
This adds a base set of devicetree bindings for the Ion memory manager. This supports setting up the generic set of heaps and their properties. Signed-off-by: Laura Abbott <la...@labbott.name> --- drivers/staging/android/ion/devicetree.txt | 50 ++ 1 file chang

Re: [PATCH] Staging: android: uapi: fixed comment block coding style error in ion.h

2015-10-26 Thread Laura Abbott
On 10/25/15 3:16 PM, Dzonatans Melgalvis wrote: Fixed checkpatch.pl warning about comment block coding style. The right aligned comments aren't great style. How about moving the comments (with the correct style) right above the macro they are describing. Signed-off-by: Dzonatans Melgalvis

Re: [RFC][PATCH 1/2] WIP: Devicetree bindings for Ion

2015-10-22 Thread Laura Abbott
:35:41 PM, Rob Herring <robherri...@gmail.com> wrote: On Tue, Oct 6, 2015 at 3:47 PM, Laura Abbott <labb...@fedoraproject.org> wrote: [...] +Example: + + ion { + compatbile = "linux,ion"; + #address-cells = <1>; + #size-cells = <0>; + + ion-system-heap { + li

Re: [RFC][PATCH 1/2] WIP: Devicetree bindings for Ion

2015-10-07 Thread Laura Abbott
On 10/7/15 11:36 AM, Rob Herring wrote: On Wed, Oct 7, 2015 at 5:36 AM, Andrew <and...@ncrmnt.org> wrote: On 2015-10-07 02:01, Laura Abbott wrote: On 10/6/15 3:35 PM, Rob Herring wrote: On Tue, Oct 6, 2015 at 3:47 PM, Laura Abbott <labb...@fedoraproject.org> wrote: From: Laur

[RFC][PATCH 1/2] WIP: Devicetree bindings for Ion

2015-10-06 Thread Laura Abbott
From: Laura Abbott <la...@labbott.name> This adds a base set of devicetree bindings for the Ion memory manager. This supports setting up the generic set of heaps and their properties. Signed-off-by: Laura Abbott <la...@labbott.name> Signed-off-by: Andrew Andrianov <an

[RFC][PATCH 0/2] Devicetree bindings for Ion

2015-10-06 Thread Laura Abbott
From: Laura Abbott <la...@labbott.name> Hi, At the last Plumbers and Linaro Connect, there was some discussion related to Ion. One of the items that came up towards eventually getting Ion out of staging was some concept of stable devicetree bindings. This is a proof of concept for bi

[RFC][PATCH 2/2] staging: ion: Add files for parsing the devicetree (WIP)

2015-10-06 Thread Laura Abbott
From: Laura Abbott <la...@labbott.name> Devicetree is the preferred mechanism for platform definition these days. Add a set of files for supporting Ion with devicetree. This includes a set of bindings for heaps common across all devices and parsing methods. Clients may use the standard bi

Re: [RFC][PATCH 1/2] WIP: Devicetree bindings for Ion

2015-10-06 Thread Laura Abbott
On 10/6/15 3:35 PM, Rob Herring wrote: On Tue, Oct 6, 2015 at 3:47 PM, Laura Abbott <labb...@fedoraproject.org> wrote: From: Laura Abbott <la...@labbott.name> This adds a base set of devicetree bindings for the Ion memory manager. This supports setting up the generic

Re: [PATCH 1/1] staging: ion: Fix error handling in ion_buffer_create

2015-09-30 Thread Laura Abbott
On 09/29/2015 10:37 PM, Rohit kumar wrote: This patch fixes error handling case when buffer->pages allocation fails. Also, it removes unreachable code of checking ret variable although it is not updated. Reviewed-by: Laura Abbott <labb...@redhat.com> Signed-off-by: Rohit kum

Re: [PATCH] staging: ion: fix corruption of ion_import_dma_buf

2015-09-10 Thread Laura Abbott
On 09/09/2015 10:41 PM, Colin Cross wrote: On Wed, Sep 9, 2015 at 10:19 AM, Laura Abbott <labb...@redhat.com> wrote: (adding Colin and John) On 09/09/2015 12:41 AM, Shawn Lin wrote: we found this issue but still exit in lastest kernel. Simply keep ion_handle_create under mutex_lock to

Re: [PATCH] staging: ion: fix corruption of ion_import_dma_buf

2015-09-09 Thread Laura Abbott
(adding Colin and John) On 09/09/2015 12:41 AM, Shawn Lin wrote: we found this issue but still exit in lastest kernel. Simply keep ion_handle_create under mutex_lock to avoid this race. WARNING: CPU: 2 PID: 2648 at drivers/staging/android/ion/ion.c:512 ion_handle_add+0xb4/0xc0()

Re: [PATCH] ion: Handle the memory mapping correctly on x86

2015-08-07 Thread Laura Abbott
On 08/03/2015 05:21 PM, Radhakrishna, Pradeep wrote: From b4069e7fe1b2aa1660b3f944e246c13b4947db21 Mon Sep 17 00:00:00 2001 From: Zhebin Jin zhebin@intel.com Date: Wed, 8 Jul 2015 10:35:06 +0800 Subject: [PATCH] ion: Handle the memory mapping correctly on x86 This patch modifies the ion

Re: [PATCH] staging: ion: ion_cma_heap: Don't directly use dma_common_get_sgtable

2015-07-17 Thread Laura Abbott
On 07/17/2015 08:21 AM, Robin Murphy wrote: Hi Tixy, On 17/07/15 12:01, Jon Medhurst (Tixy) wrote: Use dma_get_sgtable rather than dma_common_get_sgtable so a device's dma_ops aren't bypassed. This is essential in situations where a device uses an IOMMU and the physical memory is not

Re: [PATCHv3 1/2] staging: ion: shrink page-pool by page unit

2015-07-02 Thread Laura Abbott
ion_page_pool_shrink() to count only pages, not chunks. And then ion_system_heap_shrink() to work on pages. Signed-off-by: Gioh Kim gioh@lge.com Reviewed-by: Laura Abbott labb...@redhat.com --- drivers/staging/android/ion/ion_page_pool.c |5 +++-- drivers/staging/android/ion/ion_system_heap.c

Re: [PATCHv3 2/2] staging: ion: debugfs to shrink pool

2015-07-02 Thread Laura Abbott
pool size. It is already implemented but not complete. This patch completes and enables it. Reading the file returns pool size in page unit and writing the number of pages shrinks pool. It flushes all pages to write zero at the file. Signed-off-by: Gioh Kim gioh@lge.com Reviewed-by: Laura

Re: [PATCH v5.1 2/2] staging: ion: Add ion-physmem documentation

2015-06-30 Thread Laura Abbott
(adding devicetree mailing list since I didn't see it cc-ed) Please also remember to cc the staging list since Ion is still a staging framework. On 06/30/2015 08:34 AM, Andrew Andrianov wrote: Signed-off-by: Andrew Andrianov and...@ncrmnt.org ---

Re: [PATCH v5.1 1/2] staging: ion: Add generic ion-physmem driver

2015-06-30 Thread Laura Abbott
On 06/30/2015 08:34 AM, Andrew Andrianov wrote: This patch adds a generic ion driver that allows ion heaps to be added via devicetree. It provides a simple and generic way to feed physical memory regions to ion without writing a custom driver, e.g. ion_sram: ion@0x0010 {

Re: [PATCH] staging: ion : ion_cma_heap: fix bug for highmem cma

2014-12-01 Thread Laura Abbott
On 11/28/2014 5:31 PM, Zeng Tao wrote: when cma is located in highmem, virt_to_page will not work the right way, use pfn_to_page instead. Signed-off-by: Zeng Tao prime.z...@huawei.com --- drivers/staging/android/ion/ion_cma_heap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

Re: Why does ion_cma_allocate need GFP_HIGHUSER | __GFP_ZERO flags?

2014-11-13 Thread Laura Abbott
On 11/12/2014 11:18 PM, Gioh Kim wrote: Hi, I'm wondering why dma_alloc_coherent needs GFP_HIGHUSER | __GFP_ZERO flags in ion_cma_allocate(). I think dma_alloc_coherent can go to __dma_alloc if the system has CMA area. If __GFP_WAIT flag is set, it allocates memory from atomic pool. So

Re: [RFC] stating: ion: use hot page first in pool

2014-10-29 Thread Laura Abbott
On 10/28/2014 9:57 PM, Gioh Kim wrote: Hello, I found that ion insert freed-page at the tail of list and extract at the head. I think it is good for cache to use the most recently used page but these pages in pool are not cached memory. So I'm not sure using hot page is better or not

Re: [RFCv2 1/3] staging: ion: shrink page-pool by page unit

2014-10-24 Thread Laura Abbott
Hi, On 10/23/2014 11:47 PM, Gioh Kim wrote: This patch shrink page-pool by page unit. Can you explain a bit more about what this patch is fixing? The description in the cover letter would be helpful here. Thanks, Laura -- Qualcomm Innovation Center, Inc. Qualcomm Innovation Center, Inc. is

Re: [RFCv2 2/3] staging: ion: debugfs to shrink pool

2014-10-24 Thread Laura Abbott
Hi, On 10/23/2014 11:47 PM, Gioh Kim wrote: This patch creates debugfs files, /sys/kernel/debug/ion/heaps/system_shrink, to shrink pool or get pool size. Reading the file returns pool size and writing occurs to shrink pool. Can you clarify here that you are updating the existing debugfs

Re: [RFCv2 3/3] staging: ion: limit pool size

2014-10-24 Thread Laura Abbott
Hi, On 10/23/2014 11:47 PM, Gioh Kim wrote: This patch limits pool size by page unit. This looks useful. Might be nice to add a debugfs option to change this at runtime as well. Signed-off-by: Gioh Kim gioh@lge.com --- drivers/staging/android/ion/Kconfig |4

Re: [PATCH 1/1] [ion]: system-heap use PAGE_ALLOC_COSTLY_ORDER for high order

2014-10-06 Thread Laura Abbott
On 10/6/2014 3:27 AM, Heesub Shin wrote: Hello Kumar, On 10/06/2014 05:31 PM, Pintu Kumar wrote: The Android ion_system_heap uses allocation fallback mechanism based on 8,4,0 order pages available in the system. It changes gfp flags based on higher order allocation request. This higher order

Re: [PATCH] drivers: android: fix watermark when cma enabled

2014-08-12 Thread Laura Abbott
On 8/10/2014 7:06 PM, Zengtao (B) wrote: From: Zeng Tao prime.z...@hisilicon.com Date: Tue, 5 Aug 2014 17:58:10 +0800 Subject: [PATCH] drivers: android: fix watermark when cma enabled when cma is enabled, the watermark caculation will include the cma pages, while it can't use cma pages.

Re: [patch] Documentation/email-clients.txt: add a section about git

2014-05-07 Thread Laura Abbott
On 5/7/2014 4:17 AM, Dan Carpenter wrote: These days most people don't use git to send patches so I have added a section about that. Do you mean most people *do* use git to send patches? Or most people don't use e-mail clients? Laura -- Qualcomm Innovation Center, Inc. is a member of Code

[RFC PATCHv3 05/11] staging: lustre: Use is_vmalloc_addr

2014-01-02 Thread Laura Abbott
Instead of manually checking the bounds of VMALLOC_START and VMALLOC_END, just use is_vmalloc_addr. That's what the function was designed for. Signed-off-by: Laura Abbott lau...@codeaurora.org --- .../staging/lustre/lnet/klnds/o2iblnd/o2iblnd_cb.c |3 +-- 1 files changed, 1 insertions(+), 2

<    1   2   3   4