Age | Commit message (Collapse) | Author |
|
Update vmeta to use the dma_buf handling now provided by libbmm v2.
This permits more flexible buffer management, as the buffers can now
be passed via a standardized mechanism to other subsystems (such as
DRM), and image data to be encoded can be accepted directly from
other subsystems without needing to be copied.
Signed-off-by: Russell King <rmk@arm.linux.org.uk>
|
|
* Convert to use bmm_malloc_aligned_phys() API
* Turn on compiler warnings and fix them
* Open /dev/vmeta with O_CLOEXEC
* Clean up vmeta IRQ control
Signed-off-by: Russell King <rmk@arm.linux.org.uk>
|
|
Rather than having two functions, one to enable and another to disable,
we can combine the two and take an argument to indicate what action is
required. As these aren't part of the library API, we're free to make
this change.
|
|
Ensure that the vmeta file descriptor gets closed if the application
exec()'s another program.
|
|
|
|
BMM internally allocates memory by physical address, and then maps it
to a virtual address.
Rather than using an API which returns the virtual address which then
has to be re-translated back to a physical address, use an API which
gets us all the information we need in one go.
This gets rid of the bmm_get_paddr() step when allocating memory.
|
|
|
|
|
|
|
|
|
|
The bmm subsystem can now provide us with pre-aligned memory
allocations, so let's use the new interface to avoid having to do
our own alignment in the vmeta library.
|
|
|
|
|
|
|
|
|
|
|
|
All references from this library should be resolvable when the
library is created; this is not a stand-alone module. All symbols
should be found in either libc or libbmm.
|
|
This removes all support for the uio-based interface from libvmeta,
replacing it with the new miscdevice interface code. This represents
a substantial cleanup of this code.
|
|
The kernel folk don't like the uio ioctl idea, so we can't use uio for
this driver. Instead, switch it to be a self-contained miscdevice.
This adds support to this library for the miscdevice interface.
|
|
Move the user id management into the kernel driver. This removes the
necessity to export operations on kernel semaphores to userspace, along
with the kernel shared memory.
|
|
|
|
|
|
|
|
|
|
Provide a common function to read the size and physical address from a
UIO map, and to mmap() the UIO map if desired. This avoids a lot of
repeated code in several functions.
|
|
|
|
|
|
There's no need to have two functions doing exactly the same thing;
consolidate these into one function - and adjust the error reporting
to report the file which we failed on.
|
|
No point in repeating all the logic multiple times. Just convert the
direction argument and then call the appropriate function according to
the size.
|
|
|
|
|
|
|
|
|
|
This avoids a whole raft of completely unnecessary casts.
|
|
|
|
|
|
|
|
Signed-off-by: Li Li <lea.li@marvell.com>
|
|
Change-Id: Ic90317435c8b6d5cd6358f0a862daa7058dc595e
Signed-off-by: RaymondWu <xywu@marvell.com>
|
|
Since we use child thread to monitor parent thread. The child thread
will not release resources created by parent. So we detach it manually.
Change-Id: Ia7cf2f595cfd2215bdfafca6ca3da2677978d815
Signed-off-by: RaymondWu <xywu@marvell.com>
|
|
Unmap useless virtual memory in user space.
Code clean: replace all printf() with dbg_printf().
Add gst fix.
Change-Id: I34ca001b093225de4d60b6ed92fc0399ea785aa0
Signed-off-by: RaymondWu <xywu@marvell.com>
|
|
Signed-off-by: Li Li <lea.li@marvell.com>
|
|
|
|
|
|
Root causes are : a) In QA's test case, it only calls driver init()
and clean(). So some variables have not been initialized yet. b)
init() and clean() are not protected by mutexes in multi-threads case.
Change-Id: I0b0f36d2d840c23e4848f8b1a89522eb42660be0
Signed-off-by: RaymondWu <xywu@marvell.com>
|
|
Root cause is IPP/application cannot garantee that vmeta clock
or power can be turned off before exit. So add code in vdec_os_driver_clean()
to handle this.
Change-Id: I60d89def830bba5124309d320e54fc8788cc4d0d
Signed-off-by: RaymondWu <xywu@marvell.com>
|
|
Root cause is monitor and playback are in different threads. When vmeta
exits, monitor will use some resourcs shared by the playback thread, which
may have been released.
This fix removes the private_lock(), which will use shared "fd". I think
it's safe because when code enters here, it means an abnormal exit, so the
instance will come to and end, we can safely release it's resources.
Change-Id: Idc837e8135e393c2700961423258109706d20589
Signed-off-by: RaymondWu <xywu@marvell.com>
|
|
Currently, we only check the lock status. In fact, we should check the
register or used status, too. So changed the logic in code. This can
help to clear the unwanted lock or instance entry when abnormal exit happens.
|
|
Under Android, we cannot use printf. So we write to a debug file instead.
It's useful under Android.
|
|
|