1. update get_sensor_info function to send sensor type
to the upper layers
2. update table ack pending flag in case of table ack
received
3. add ov5647 sensor power down function
Change-Id: I92c8e25d377d2fee09276b72119eb95adfcc79f8
Signed-off-by: Raju P.L.S.S.S.N <rplsssn@codeaurora.org>
The ion_phys API is being deprecated. Instead there
is a new set of API that does the same thing as ion_phys
if the system has no IOMMU enabled. Otherwise, it
returns an IOMMU device virtual address.
Change-Id: I1f01d33cbc6d236d28c9193a90e48377b9fb35cc
Signed-off-by: Ankit Premrajka <ankitp@codeaurora.org>
Merge Upstream's stable 3.0.21 branch into msm-3.0
This consists 814 commits and some merge conflicts.
The merge conflicts are because of some local changes to
msm-3.0 as well as some conflicts between google's tree and
the upstream tree.
Conflicts:
arch/arm/kernel/head.S
drivers/bluetooth/ath3k.c
drivers/bluetooth/btusb.c
drivers/mmc/core/core.c
drivers/tty/serial/serial_core.c
drivers/usb/host/ehci-hub.c
drivers/usb/serial/qcserial.c
fs/namespace.c
fs/proc/base.c
Change-Id: I62e2edbe213f84915e27f8cd6e4f6ce23db22a21
Signed-off-by: Rohit Vaswani <rvaswani@codeaurora.org>
Using the typical timer_list to keep track of frame queue timeout was
not accurate enough. In 60 FPS case, 16.6 ms translated into 1
jiffy causing inaccurate FPS and performance problems. Hence switching
to hrtimer for more accurate timeouts.
Change-Id: I49facc6846d6795bcb61674a23b113d6b7f04f1d
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
1.enable csi lanes based on lane count and Update
csi irq to IRQF_TRIGGER_HIGH
2.update vfe driver not to send any command when
the table command is in progress
Change-Id: If35c673e432ff54ce9ac5a20350fc0e7068d18e4
Signed-off-by: Raju P.L.S.S.S.N <rplsssn@codeaurora.org>
Migrate WFD to IOMMU APIs. Commit contains following changes:
- Switch from allocate buffer model to use buffer model in order
to have the flexibility to map buffers into seperate domains.
- Use the ION caching APIs to flush buffers in case they are cached.
Earlier on, we used uncached buffers, hence we didn't have a need
to flush.
Change-Id: I959027ee94a5d6074005f1de420c66cbe55db776
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
This driver includes voltage regulator configuration,
clock configuration, sensor gpio settings and sensor
register settings to enable preview and snapshot for
Sony IMX091 sensor.
Change-Id: Ib974e78bdb4310350c27eda20e0cc49e4c34916e
Signed-off-by: Sreesudhan Ramakrish Ramkumar <srramku@codeaurora.org>
When YV12 preview format is set,due to timing reasons the viewfinder frame
status is inconsistent.so skip such frames to avoid preview freeze.
Change-Id: Iac65277b76b1c32eefe95b0932149b7152e4b2e7
Signed-off-by: Monika Alekhya <malekh@codeaurora.org>
Instead of relying on the client to enable this option, enable it by
default internally.
Change-Id: I4d2c7e241a7e5b87ccdea25f876f0eb5732aff74
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
After camera probe, releasing LCD_CAMERA_LDO_2V8 &
SKU3_LCD_CAMERA_LDO_1V8 gpios for power on lcd
Change-Id: I2c03f045b0eb5302962145d7466ac2231eea0c83
Signed-off-by: Raju P.L.S.S.S.N <rplsssn@codeaurora.org>
This change stops the VFE first, before unmapping the buffers
registered in the kernel in the scenario of a mediaserver
crash.
Change-Id: I16c7c3b8dcd7a2f9c0ad98cf93cb1980c3a675fa
Signed-off-by: Ankit Premrajka <ankitp@codeaurora.org>
Add a few logs that are useful for debugging. In addition, enabling
WFD_MSG_DBG unconditionally so that we can take advantage of dynamic
debug.
Change-Id: Id1b616aef1554f04b750207ee14b818e19319b6e
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
1) reset csiphy during init to make sure it is in known state
2) reset csid during init to make sure it is in known state
3) remove DBG_CSID flag to get the reset irq after csid_reset
Change-Id: I66b4da08b300a2e43655544cff4db64d9fbe5b19
Signed-off-by: Hody Hung <hhung@codeaurora.org>
1) Move csi lane params from kernel driver to board
file to support same kernel drivers for different
sensors with different csi parameters (in case of
3D, same kernel driver can support both sensors
with different csi configuration)
2) In msm sensor driver, extract lane assign and
lane mask from plaform info and store in sensor
control structure before passing to csi phy
3) Change csi phy config logic to configure mipi
lanes in any order using lane mask
Change-Id: Iba26640f28d957b17631c98286dba37b7774b42b
Signed-off-by: Hody Hung <hhung@codeaurora.org>
In non zsl camera preview mode, two vfe outputs are configured as
preview and video outputs. Greater of the two is output from main
scaler and the lower one from the secondary scaler. In Camera preview mode,
application matches preview dimensions aspect ratio to snapshot
dimensions and in camcordermode it is matched to video.
In Current design, We have below scenarios for Non ZSL Camera Preview
Case1: Main Scaler is preview and secondary scalar is video
In this scenario no error is observed
Case2: Main scalar is video and secondary scalar is preview
In this scenario since preview output in derived from video but the
aspect ratio may not match in camera mode, so we see stretch in camera
preview.
This issue is fixed by configuring only single VFE output as per
display dimensions in Camera Preview since the second video output
is never used
CRs-Fixed: 343884
Change-Id: I25a82b417a3ed1b28ea243c6ce988c23d5fed4a7
Signed-off-by: Nishant Pandit <npandit@codeaurora.org>
This adds support for sps/pps to be prepended to all I-frames provided
by the core. This support needs to be provided by the core as in HDCP
use case, userspace can no longer prepend the sps/pps to I-frames, as
required by WFD spec.
Change-Id: If13437c6eae4088f913a9a7016a477a4342e8c35
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
Add media device node for each camera sensor
Sensor and video node info will be used
for device discovery from userspace
Change-Id: Id8c2f3e952c83259bb6b273cb6b3f04ed93d0ef3
Signed-off-by: Kevin Chan <ktchan@codeaurora.org>
More information needs to pass to userspace.
Change-Id: Ia7c5a5cf9a7f48e1c6167fd3ca2ddd56fbdbf8c9
Signed-off-by: Mingcheng Zhu <mingchen@codeaurora.org>
Add support to mt9e013 and ov9726 sensors for v4l2 camera
architecture
Change-Id: Ie0e12bb0b8f1d80c0aa40800f5578208ca86efcb
Signed-off-by: Sandeep Kodimela <skodimela@codeaurora.org>
WFD driver now rejects non-16 byte aligned widths as MDP cannot add the
necessary padding. For height, as the hardware will access up to the
next 16 aligned address, we need to allocate a bigger buffer to prevent
page faults.
Change-Id: Ib8aa6ecc827c31eb20c9cd3428d82a62f3668e5b
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
The video driver index is not passed to daemon in some code
Change-Id: Ie3074fe3590228d8fdd7bd8b7de608820a36627a
Signed-off-by: Mingcheng Zhu <mingchen@codeaurora.org>
Ensure clocks are turned off after tasklet is kill
and device is not in active state. This is to
prevent bus lockdown if the device is accessing
the bus and clock is turn off
Also ensure clocks are on, when accessing hardware
registers.
Change-Id: I4010b96709f48b8cf2bf532e57442152f2e30de9
Signed-off-by: Kevin Chan <ktchan@codeaurora.org>
When camera userspace daemon crashes, the server fd
will be close, which trigger the msm_server_close
function, we will check if there is an active camera
session. If camera is active, we will send a v4l2
event to HAL layer to signal an error. Application
will exit gracefully and close other open fds and
exit camera session.
Change-Id: I14ebc864d6cace7ca6f4dbfb935623a76eeccaa8
Signed-off-by: Kevin Chan <ktchan@codeaurora.org>
The sequence of unlocking, encoding, and locking again was dangerous
since it is unpredictable when the lock can be reacquired in the input
thread. In most cases, this was fine as the encoder took long enough to
return buffers back to VSG that we were able to re-acquire the lock.
However, in cases that encoder is faster than expected, VSG receives an
EBD call back before the input thread can reacquire the lock and put the
encoded buffer into the busy queue. This causes the output thread to
complain about unexpected buffers and drop the frame, which eventually
causes 100% frame drop.
CRs-Fixed: 339432
Change-Id: I29731cfb4a51ffc8f362426d570482ad7f6394b6
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
In the sequence of vsg_start(), vsg_stop() and vsg_start(), the second
vsg_start() wouldn't generate buffers as the timer thread would
immediately stop due to to VSG still being in a stopped state.
Change-Id: I0b2d31c81d46e91b898a6210ad2c50d5c9200f1c
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
The autofocus function fails under certain test condition
due to restriction on the total number of steps available
for moving the lens. The issue is seen only with piezo
type of actuators. This fix ensures the piezo actuator can
move upto its mechanical limits.
Change-Id: Ic718b4a55016a1cc4a3aecea332e98ba326226c5
Signed-off-by: Rajakumar Govindaram <rajakuma@codeaurora.org>
CRs-Fixed: 332887
Setting last_buffer to the last encoded buffer in the output callback was
causing problems in concurrent encode/decode scenarios where the core would
take extra time in returning buffers. As a result, the timer would fire
and queue a stale frame to the encoder. This would result in the encoder
eventually returning a stale frame and video stream generator choosing
the stale frame as the last buffer.
CRs-Fixed: 330432
Change-Id: I50da57b1376c7811ec7255b501c4cc918133580b
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>
Change board settings and compile order to change
MT9M114 from back to front sensor
Change-Id: Ib992684baf28472ca3d391b680e92e26b89d273c
Signed-off-by: Sreesudhan Ramakrish Ramkumar <srramku@codeaurora.org>
Add support for controls that allow for userspace to set and get
the I-frame period and QP values for I, P, and B frames.
Change-Id: Ia535291872b671f001fec6bf23601022f7712af0
Signed-off-by: Deva Ramasubramanian <dramasub@codeaurora.org>