93 Commits

Author SHA1 Message Date
Shubhraprakash Das
c7c72810d0 libgralloc-qsd8k: Port part of change Ice6a7c28
Port over part of change Ice6a7c28 that frees ashmem
memory.

Change-Id: I467617f3bc35a0e448fbf41207853e669aed657a
2011-01-18 18:12:13 -07:00
Naomi Luis
140db9dc03 Add support for S3D content over HDMI
Add support in the overlay to display 3D content on the HDMI.
The 3D input and out formats are passed along with the regular color format.

Change-Id: I85d96928f1fc43de8b8eafab8526af4e716099a5
2011-01-10 16:23:22 -08:00
Saurabh Shah
de03d0ec9f hardware/msm7k: Fix position, aspect ratio on HDMI UI
Fix position, aspect ratio of HDMI UI when the
primary panel type is MIPI, 8660 Panel or 7x30 Panel

Change-Id: I8e9824520317e3facb4ef25bc25dd9b1de60b4ce
CRs-fixed: 263690, 269433
2011-01-04 09:18:06 -08:00
Naomi Luis
68827e74ed libgralloc-qsd8k: Close the gralloc module
Close the gralloc module in the fb_device_open api.

CRs-fixed: 269234

Change-Id: Ifcb1909e0cf8bf40f2b505716cb624531309556b
2011-01-03 12:54:05 -08:00
Naomi Luis
736092e772 libgralloc-qsd8k: Update the gralloc HAL for Gingerbread
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: I36183bf1fa68e5c8ed80f1efbb5c535a060e0db0
2010-12-20 16:36:01 +05:30
Ajay Dudani
39a41afa0b hardware/msm7k: Initial changes to libgralloc-qsd8k
Change-Id: I59b23aac04b32c5a5ab09b920bdf93fdbbfcd7ce
2010-12-19 01:15:17 -08:00
Mathias Agopian
c4374041ac reject odd widths or heights for YV12 format
Change-Id: I66cbb5fbc20630218947cd41552a95503b58e15e
2010-09-10 14:40:10 -07:00
Mathias Agopian
e8a8dc32fd don't revert to ashmem if HW usage bits are set
this wouldn't make sense, since the h/w wouldn't be able
to use the buffer. in this case it it better to fail to
let the caller a change to try again with different usage bits.

Change-Id: Ibecaf069b6b58ee9c026affc95a45512660d5881
2010-08-20 16:02:29 -07:00
Mathias Agopian
361e52090e only set the PRIV_FLAGS_NEEDS_FLUSH flag on PMEM buffers
PRIV_FLAGS_NEEDS_FLUSH will trigger an ioctl call into the PMEM
driver in unlock(), so it makes not sense to set this flag for
non pmem buffers.

Change-Id: Ie1e077c10df86d3689b82fa6ce5d6c856fc95688
2010-08-20 11:47:44 -07:00
Mathias Agopian
6abac7a69e add qcom specific pixelformats
Change-Id: I70395b93afc4dee13e805649ee2307ffe895aaf1
2010-08-19 13:15:39 -07:00
Jamie Gennis
3fe6e4e25d Change the constant name identifying the NV21 Adreno format.
This updates the qsd8k gralloc to support the new name for the NV21 Adreno
pixel format.

Change-Id: I358bf12db058d3740a5e49ee30d95c2afb708295
2010-08-06 12:09:15 -07:00
Mathias Agopian
71cce53197 fix [2855380] GRG19 monkey native crash in GraphicBufferAllocator
we were dereferencing the null pointer when freeing ashmem buffers.

Change-Id: I7be6e1ae064148bea1076193c21a73b5a3f90297
2010-07-28 18:12:39 -07:00
Mathias Agopian
018f4b572c Remove the YV16 format.
Change-Id: I3f7995ba0cf41bcde995df293bea78bce7d82fc9
2010-07-14 16:29:43 -07:00
Mathias Agopian
b2ec750a53 make the gralloc test linux only
Change-Id: Ib245f7936bbe71b34903172629e09763dd725d80
2010-07-02 16:37:27 -07:00
Jamie Gennis
253d8b6ec7 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
382d393fa8 remove unused YUV formats
Change-Id: Ia590a9cb9a02bf62f35da344f29775d1256e3da7
2010-07-01 21:19:31 -07:00
Mathias Agopian
1f5ceac69a NV12 tiled needs 8K plane alignment
Change-Id: I8f2ca6f058ff9d7dd666871a696428c55dbe6cf1
2010-06-22 22:06:12 -07:00
Mathias Agopian
318fb2ddc4 remove unused YUV formats
Change-Id: I41c18551a61bec9f928399544a12024c81947ed0
2010-06-22 16:15:31 -07:00
Mathias Agopian
5c7a083493 fix typo in ALIGN macro
Change-Id: Idaddf65f0b726a158f47639223f4281fd07447a7
2010-06-22 16:15:10 -07:00
Mathias Agopian
741a95cdd3 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
f239678637 Revert "Add support for allocating YUV formats"
This reverts commit 7b1f00a95490552131d06a13b78c279f6c779a1a.
2010-06-22 13:32:55 -04:00
Mike Lockwood
71b0030f5a Revert "remove unused YUV formats"
This reverts commit 05ea9ede5600fef7a8fdf416b44ec98e58fb224b.
2010-06-22 13:32:36 -04:00
Mathias Agopian
7a089c0a12 remove unused YUV formats
Change-Id: I47769af34112856e6a2ef177a966f6e8e6242031
2010-06-21 18:23:23 -07:00
Mathias Agopian
ce184f8dbc 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
Jean-Baptiste Queru
3c14f08a66 Add tags and notices where appropriate.
Also tweak copyright notices as appropriate.

Bug: 2084753
Change-Id: Ifbf795b8b16dbc45cf5ac9a72b97f2b74cbf3550
2010-03-19 15:50:23 -07:00
Dima Zavin
9df504747b libgralloc-qsd8k: flush SW_WRITE cached pmem regions in unlock
Change-Id: I31d1257f031c6b9b8dae604c2c1a8aa246ce3b84
Signed-off-by: Dima Zavin <dima@android.com>
2010-03-02 15:14:57 -08:00
Mathias Agopian
a1b401cc89 fix [2444483] gralloc size for YUV formats 2010-02-16 14:04:36 -08:00
The Android Open Source Project
2c045c9893 am 88457c5c: am 3530ef81: reconcile main tree with open-source eclair
Merge commit '88457c5c5d4abdf0f99f19612db5d29c1f45ffa1'

* commit '88457c5c5d4abdf0f99f19612db5d29c1f45ffa1':
  android-2.1_r1 snapshot
2010-02-05 14:26:00 -08:00
The Android Open Source Project
4d9f4905a9 am 3530ef81: reconcile main tree with open-source eclair
Merge commit '3530ef81d13e243bb568b8d33327f5fdda8a5b1a' into eclair-plus-aosp

* commit '3530ef81d13e243bb568b8d33327f5fdda8a5b1a':
  android-2.1_r1 snapshot
2010-02-05 08:49:52 -08:00
The Android Open Source Project
814f64bbcb reconcile android-2.1_r1 snapshot 2010-01-29 14:09:19 -08:00
Mathias Agopian
7c6f96ceee part of fix for [2363506] [Sapphire] Video playback broken
make sure to reject incompatible buffers in special function
  GRALLOC_MODULE_PERFORM_CREATE_HANDLE_FROM_BUFFER

we use ioctl(PMEM_GET_SIZE) to validate that the given buffer is indeed
a pmem buffer.
2010-01-20 13:22:35 -08:00
The Android Open Source Project
f1d633b78c android-2.1_r1 snapshot 2010-01-12 15:19:05 -08:00
Android Git Automerger
80b830715e Merge commit 'goog/eclair-plus-aosp' 2009-12-15 00:44:45 -08:00
Dima Zavin
7a3651bf1a am 57d3b368: am 6a6befc0: am 2754389d: gralloc-qsd8k: make sure that we never try to allocatio 0 bytes
Merge commit '57d3b3680a6d37ffe04e1f24be25b4907bcbaa20'

* commit '57d3b3680a6d37ffe04e1f24be25b4907bcbaa20':
  gralloc-qsd8k: make sure that we never try to allocatio 0 bytes
2009-12-10 23:45:13 -08:00
Dima Zavin
82380f87c8 am 6a6befc0: am 2754389d: gralloc-qsd8k: make sure that we never try to allocatio 0 bytes
Merge commit '6a6befc0430820ab5d837694f1b71b63c34f8b14' into eclair-mr2-plus-aosp

* commit '6a6befc0430820ab5d837694f1b71b63c34f8b14':
  gralloc-qsd8k: make sure that we never try to allocatio 0 bytes
2009-12-10 18:08:20 -08:00
Dima Zavin
c96f1d6f52 am 2754389d: gralloc-qsd8k: make sure that we never try to allocatio 0 bytes
Merge commit '2754389d0e7638b3065ecb3c965b1f262d2205ed' into eclair-mr2

* commit '2754389d0e7638b3065ecb3c965b1f262d2205ed':
  gralloc-qsd8k: make sure that we never try to allocatio 0 bytes
2009-12-10 17:56:59 -08:00
Mathias Agopian
449b3b0120 am 96a46011: am 8efc64ae: am f7e40a33: improve cache behavior of gralloc allocations on qsd8k
Merge commit '96a460114cfb663789c6990e56a17325bea1ecda'

* commit '96a460114cfb663789c6990e56a17325bea1ecda':
  improve cache behavior of gralloc allocations on qsd8k
2009-12-10 17:15:30 -08:00
Mathias Agopian
e14b827d60 am 8efc64ae: am f7e40a33: improve cache behavior of gralloc allocations on qsd8k
Merge commit '8efc64aec14e80e7dff8eb4e7708195c6d693ec8' into eclair-mr2-plus-aosp

* commit '8efc64aec14e80e7dff8eb4e7708195c6d693ec8':
  improve cache behavior of gralloc allocations on qsd8k
2009-12-10 16:58:39 -08:00
Mathias Agopian
49791e47b6 am f7e40a33: improve cache behavior of gralloc allocations on qsd8k
Merge commit 'f7e40a3311ae78b3edd9259980c224a5a9d91653' into eclair-mr2

* commit 'f7e40a3311ae78b3edd9259980c224a5a9d91653':
  improve cache behavior of gralloc allocations on qsd8k
2009-12-10 16:43:17 -08:00
Dima Zavin
8e3a3dc441 am 2754389d: gralloc-qsd8k: make sure that we never try to allocatio 0 bytes
Merge commit '2754389d0e7638b3065ecb3c965b1f262d2205ed' into eclair-plus-aosp

* commit '2754389d0e7638b3065ecb3c965b1f262d2205ed':
  gralloc-qsd8k: make sure that we never try to allocatio 0 bytes
2009-12-09 21:19:13 -08:00
Dima Zavin
5844bf9d82 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
4e4bf04839 am f7e40a33: improve cache behavior of gralloc allocations on qsd8k
Merge commit 'f7e40a3311ae78b3edd9259980c224a5a9d91653' into eclair-plus-aosp

* commit 'f7e40a3311ae78b3edd9259980c224a5a9d91653':
  improve cache behavior of gralloc allocations on qsd8k
2009-12-09 05:36:20 -08:00
Mathias Agopian
a36265815f 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
bd01b19264 am 798bd593: am 288cb24b: am dc80f522: gralloc-qsd8k: If using gpu composition, request rgba8888 instead of rgbx8888
Merge commit '798bd5939d62e6c064832880830476735d9ea52d'

* commit '798bd5939d62e6c064832880830476735d9ea52d':
  gralloc-qsd8k: If using gpu composition, request rgba8888 instead of rgbx8888
2009-12-07 14:57:42 -08:00
Dima Zavin
0a539ea7e9 am 4842a5ea: am 7422163d: am c3f00492: gralloc-qsd8k: Change composition_complete being a glfinish from stopship to a TODO
Merge commit '4842a5eaee0b93950297f52dd1ce56d13f7628eb'

* commit '4842a5eaee0b93950297f52dd1ce56d13f7628eb':
  gralloc-qsd8k: Change composition_complete being a glfinish from stopship to a TODO
2009-12-07 14:57:22 -08:00
Dima Zavin
af9a41610e am 288cb24b: am dc80f522: gralloc-qsd8k: If using gpu composition, request rgba8888 instead of rgbx8888
Merge commit '288cb24be01d065843a2a98ed6c0fdbb5faa8268' into eclair-mr2-plus-aosp

* commit '288cb24be01d065843a2a98ed6c0fdbb5faa8268':
  gralloc-qsd8k: If using gpu composition, request rgba8888 instead of rgbx8888
2009-12-04 20:28:16 -08:00
Dima Zavin
9d636cdcf6 am dc80f522: gralloc-qsd8k: If using gpu composition, request rgba8888 instead of rgbx8888
Merge commit 'dc80f522f23ecda902bf8ddf5de68d6fe10e2c05' into eclair-plus-aosp

* commit 'dc80f522f23ecda902bf8ddf5de68d6fe10e2c05':
  gralloc-qsd8k: If using gpu composition, request rgba8888 instead of rgbx8888
2009-12-04 20:26:03 -08:00
Dima Zavin
34f37bb0e8 am dc80f522: gralloc-qsd8k: If using gpu composition, request rgba8888 instead of rgbx8888
Merge commit 'dc80f522f23ecda902bf8ddf5de68d6fe10e2c05' into eclair-mr2

* commit 'dc80f522f23ecda902bf8ddf5de68d6fe10e2c05':
  gralloc-qsd8k: If using gpu composition, request rgba8888 instead of rgbx8888
2009-12-04 20:25:50 -08:00
Dima Zavin
42230c70df gralloc-qsd8k: If using gpu composition, request rgba8888 instead of rgbx8888
Change-Id: Ic41d4854d6acbc21c85a03e82bd63af234273886
Signed-off-by: Dima Zavin <dima@android.com>
2009-12-04 20:22:41 -08:00
Dima Zavin
e4e40e9c17 am 7422163d: am c3f00492: gralloc-qsd8k: Change composition_complete being a glfinish from stopship to a TODO
Merge commit '7422163dfcbad4997d30274bb7c438997269ae4d' into eclair-mr2-plus-aosp

* commit '7422163dfcbad4997d30274bb7c438997269ae4d':
  gralloc-qsd8k: Change composition_complete being a glfinish from stopship to a TODO
2009-12-04 17:50:21 -08:00