22 Commits

Author SHA1 Message Date
Naomi Luis
a709f0300c libgralloc-qsd8k: Initial gralloc commit
Update the gralloc HAL to match commit:

        commit 4d3c9ca6fabf2b0111ef6b567df7d244e124b9c2
        Author: Arun Kumar K.R <akkr@codeaurora.org>
        Date:   Fri Dec 17 13:14:58 2010 -0800

            libgralloc-qsd8k: Add support for non-aligned width on HDMI

            While creating overlay channel for HDMI consider the aligned
            width and set the crop rectangle to the actual width and height.

Change-Id: I8858d71bb10b2be4c57edb605b5da680f53051dc
2011-09-19 19:16:32 -05:00
Jamie Gennis
5bc176b1a6 Refactor the qsd8k gralloc implementation.
The purpose of this change is to add support for allocating gralloc buffers
from either /dev/pmem or /dev/pmem_adsp depending on the usage flags.  It does
this by factoring out and abstracting the interactions with the pmem device.
For /dev/pmem allocations, the kernel allocator is not used, so a single master
fd is opened, and all the allocations are sub-allocated from that by gralloc.
For /dev/pmem_adsp the kernel allocator is used, so it simply opens a new fd
for each allocation.

A very basic unit test that can be run on the host is included.  It requires
gtest, so to run it on a host system gtest must (currently) be compiled with
BUILD_WITH_ASTL=true.

Change-Id: If2ae0151698fad8107e18e808a3fa012a846263f
2010-07-02 12:57:36 -07:00
Mathias Agopian
6c2bc88a03 remove unused YUV formats
Change-Id: Ia590a9cb9a02bf62f35da344f29775d1256e3da7
2010-07-01 21:19:31 -07:00
Mathias Agopian
d3c18d4938 NV12 tiled needs 8K plane alignment
Change-Id: I8f2ca6f058ff9d7dd666871a696428c55dbe6cf1
2010-06-22 22:06:12 -07:00
Mathias Agopian
0adc045aa2 remove unused YUV formats
Change-Id: I41c18551a61bec9f928399544a12024c81947ed0
2010-06-22 16:15:31 -07:00
Mathias Agopian
a82aad454a fix typo in ALIGN macro
Change-Id: Idaddf65f0b726a158f47639223f4281fd07447a7
2010-06-22 16:15:10 -07:00
Mathias Agopian
0f6dc7ea55 Add support for allocating YUV formats
Currently they're all allocated in pmem, instead of pmem_adsp.

Change-Id: Ibc3edf2da4155d2f086d81dee8940270f9cb9f6b
2010-06-22 16:14:35 -07:00
Mike Lockwood
151d2b884b Revert "Add support for allocating YUV formats"
This reverts commit 7b1f00a95490552131d06a13b78c279f6c779a1a.
2010-06-22 13:32:55 -04:00
Mike Lockwood
5d471952a5 Revert "remove unused YUV formats"
This reverts commit 05ea9ede5600fef7a8fdf416b44ec98e58fb224b.
2010-06-22 13:32:36 -04:00
Mathias Agopian
ce599f6e8d remove unused YUV formats
Change-Id: I47769af34112856e6a2ef177a966f6e8e6242031
2010-06-21 18:23:23 -07:00
Mathias Agopian
b43cd9549f Add support for allocating YUV formats
Currently they're all allocated in pmem, instead of pmem_adsp.

Change-Id: Ief367a64667dc0b67fdeabeabbf9f201082d6ad2
2010-06-16 14:27:27 -07:00
Mathias Agopian
48000e415a fix [2444483] gralloc size for YUV formats 2010-02-16 14:04:36 -08:00
Dima Zavin
7e8932dad3 gralloc-qsd8k: make sure that we never try to allocatio 0 bytes
Change-Id: Ic05b895c09a55d746c737aa0c3356edc511d7c96
Signed-off-by: Dima Zavin <dima@android.com>
2009-12-09 21:13:44 -08:00
Mathias Agopian
e17d093d0c improve cache behavior of gralloc allocations on qsd8k
make sure to use cached buffers only when frequent cpu access is needed.
also, always flush buffers after they are allocated and cleared.
2009-12-08 19:34:43 -08:00
Dima Zavin
be6f97aad3 libgralloc-qsd8k: Do not use the physical address of surfaces/framebuffer
The GPU now correctly maps everything throug hthe MMU so physical addresses
are no longer needed.

Change-Id: Id16a690f63d7141c8ee6694b246b1955f450b8ed
Signed-off-by: Dima Zavin <dima@android.com>
2009-12-02 21:15:33 -08:00
Mathias Agopian
1e1a87f0a5 part of fix [2186418] switch qsd8k devices to 24-bits framebuffer
Add support for 32 bits framebuffers
2009-11-23 23:19:54 -08:00
Mathias Agopian
b73f40535f fix[2222341] Soft reset while going back from camcorder settings
add a way to convert a mapped "pushbuffer" buffer to a gralloc handle
which then can be safely used by surfaceflinger

also make sure to not send empty rectangles to the MDP.
2009-10-30 14:52:52 -07:00
Simon Wilson
fde8e11201 Enforce 32 pixel alignment for Adreno 200 2009-08-25 14:01:36 -07:00
Mathias Agopian
717cf60b7a fix gralloc qsd8k. we actually don't need to use /pmem/gpu1, since the gpu is now able to use regular PMEM.
this module is now closer to the generic gralloc module, although it will have to evolve in the near future.
2009-08-20 15:41:34 -07:00
Mathias Agopian
78087b2664 make gralloc-qsd8k closer to the generic gralloc so it's easier to maintain 2009-08-19 13:14:55 -07:00
Dima Zavin
0c7b6963a6 gralloc8k: make sure to set the physical address of the framebuffer
Signed-off-by: Dima Zavin <dima@android.com>
2009-08-13 16:43:21 -07:00
Dima Zavin
4799671722 qsd8k: add gralloc for 8k
Signed-off-by: Dima Zavin <dima@android.com>
2009-08-13 16:43:18 -07:00