Commit graph

110 commits

Author SHA1 Message Date
idkwhoiam322
3d23626712 Revert "msm: camera: isp: Handle frame drop due to delay "
Breaks GCAM This reverts commit 5bf83ce8c3.

Change-Id: I632497550243e9fc4b69ba4a0199d8a3e939fd36
2019-04-19 09:17:53 +02:00
Meera Gande
5bf83ce8c3 msm: camera: isp: Handle frame drop due to delay
In few scenarios, the request frame may get
delayed and current and request frame id may
become same. To handle such scenarios, made
changes to inform user to delay a frame and
process the request.

Change-Id: I31fa04c386922c48a043c511a163c76316e21987
Signed-off-by: Meera Gande <mgande@codeaurora.org>
2018-12-13 06:11:21 -08:00
Linux Build Service Account
bf90c1b1f5 Merge "msm: camera: sensor: Add support for front aux sensor" 2018-08-02 07:10:34 -07:00
Linux Build Service Account
c48c535a72 Merge "msm: vidc: Addition of enums for HLG and HDR10" 2018-07-20 02:38:07 -07:00
Paras Nagda
98f28d031d msm: vidc: Addition of enums for HLG and HDR10
Add HLG and ST2084 Transfer characteristics enum values as
specified in the latest HEVC spec.

Change-Id: Iff19ff5c13c4861f4d97ab0433214fe95fa84459
Signed-off-by: Paras Nagda <pnagda@codeaurora.org>
2018-07-20 10:12:07 +05:30
Vijay kumar Tumati
dd8f83fee4 msm: camera: sensor: Add support for front aux sensor
Allow front aux sensor to be connected on device.

Change-Id: I0386c23c77b38200c20581cd85b20c96bf074547
Signed-off-by: Vijay kumar Tumati <vtumati@codeaurora.org>
2018-07-17 14:46:42 +05:30
Andy Sun
ab4b239854 ais: support frame drop configuration for auto
Set hardware frame drop config in the start_stream().
New command for user to set frame drop during streaming.

Change-Id: I523c96366ebbe6d664262e66d3bf7ee2d1b28ee3
Signed-off-by: Andy Sun <bins@codeaurora.org>
2018-06-19 11:07:00 +08:00
Chunhuan Zhan
b97610ffa1 msm : ais : diagnostic feature
provide the functions:
1. record the all camera related clocks' status
2. provide the get clock status interfaces
3. provide the read registers interfaces
4. provide read the regulators' status
5. provide set/get the specified gpio
6. get the ISP buffer states

Change-Id: I5ddb6ac5488aa46914a5fc6b642d8330e72d9b70
Signed-off-by: Chunhuan Zhan <zhanc@codeaurora.org>
2018-06-10 22:40:17 -07:00
Suprith Malligere Shankaregowda
1fb990c0b3 adv7481: Add support for AVI Infoframe
AVI Infoframe provides the aspect ratio and video
identification code information. Add support to read
this from ADV7481 registers and to return it to user space
through an ioctl call.

Change-Id: Ia64fbc736b548633b34a9bd96f7a78700afb3db5
Signed-off-by: Suprith Malligere Shankaregowda <supgow@codeaurora.org>
2018-05-30 21:21:40 -07:00
Samyukta Mogily
fd4aade756 msm: camera: Change data type of data rate
Change data rate to uint64, to ensure that the value sent
to kernel is not corrupted.

Change-Id: I692c1c3e591cbac24931078e0fb8938900fc991c
Signed-off-by: Samyukta Mogily <smogily@codeaurora.org>
2018-04-27 10:28:51 +05:30
Linux Build Service Account
afefc3eab6 Merge "msm: camera: sensor: Program SDR mask delay based on data rate" 2018-04-20 14:20:49 -07:00
Vijay kumar Tumati
169e423524 msm: camera: sensor: Receive sensor output data rate information
Program data rate specific camera hardware registers using this
information.

Change-Id: I0a64fd6f5b0e9ae0a5edee836998d8fea0e7478d
Signed-off-by: Vijay kumar Tumati <vtumati@codeaurora.org>
2018-04-18 10:18:27 +05:30
Linux Build Service Account
0d75fa8af2 Merge "msm: camera: Framedrop notification" 2018-04-13 04:52:20 -07:00
annamraj
5925180360 msm: camera: Framedrop notification
Notify the frame drop using ioctl
VIDIOC_MSM_BUF_MNGR_BUF_ERROR

Change-Id: Ide54d98fd05e19f5e2d7e88b6b65e151aa257334
Signed-off-by: annamraj <annamraj@codeaurora.org>
2018-04-09 14:09:04 +05:30
Andy Sun
366c6fbe65 ais: report csid error event to user
Enable CSID error interrupts, and sending the error status
to user mode components as v4l2 event.

Change-Id: I62a08a88ebc39e1192136ba1c9179f709f5439f5
Signed-off-by: Andy Sun <bins@codeaurora.org>
2018-04-06 08:31:01 +08:00
Andy Sun
0f75061830 ais: sync clk status and tasklet
1. add set_clk_status user interface;
2. exit delayed tasklet without processing if clk disabled;
3. protect process_halt_irq();

Change-Id: I66c933ac9b9e2dacd4dec20b646ef297cd18920d
Signed-off-by: Andy Sun <bins@codeaurora.org>
2018-03-14 17:36:46 +08:00
Trishansh Bhardwaj
789eccbec6 msm: camera_v2: Define new mcros for result success
Defines below macros.
 MSM_CAMERA_CMD_SUCCESS
 MSM_CAMERA_BUF_MAP_SUCCESS

Change-Id: Ied4cf83a129dacbcaa2acb83d3dbcd10e2d5d886
Signed-off-by: Trishansh Bhardwaj <tbhardwa@codeaurora.org>
2018-02-23 16:50:27 +05:30
Vijay kumar Tumati
385d9c8750 msm: camera: Add RAW12 support for meta data
Adding support to decode 12 bit raw metadata
at CSID.

Change-Id: I89bb9f69f3f004df29b1498761e9a54fb88cdef0
Signed-off-by: Vijay kumar Tumati <vtumati@codeaurora.org>
2018-02-07 15:30:48 +05:30
Linux Build Service Account
9a9a759c82 Merge "ais: support field info report to user space" 2018-01-24 09:12:44 -08:00
Andy Sun
ea9d0315e3 ais: support field info report to user space
1. send real SOF event to user space per SOF irq;
   original SOF event per:
     CAMIF port: epoch irq
     RDI port: reg_update irq
2. provide interface for user space to query field type;
3. provide frame id from stream_info not src_info for user;

Change-Id: Ied446b81a84d95c7273d1aa3918a474ac739971f
Signed-off-by: Andy Sun <bins@codeaurora.org>
2018-01-22 16:03:01 +08:00
Rahul Sharma
a211778552 msm: ais: Camera clock voting fixes for LA XO
AIS camera voting on VFE and ISPIF clocks cause XO shutdown failure.
So, add new AIS manager driver, to control AIS camera clock votes.
Also add a new method in early camera driver to turn on/off clocks
when it's needed.

Change-Id: I43090b51cb29ca9de62dfa191f77b7aa9dae8613
Signed-off-by: Rahul Sharma <sharah@codeaurora.org>
2018-01-12 02:44:57 -08:00
Rahul Sharma
720aa591f4 ADV7481: Query lane_count and settle_count from device tree
Get lane count and settle count from device tree.
Add VIDIOC_G_CSI_PARAMS ioctl to pass lane count
and settle count values to userspace.

Change-Id: Ic0e0b7b402908c9970fd1771cf9bf19627f5a5d8
Signed-off-by: Rahul Sharma <sharah@codeaurora.org>
2017-12-22 07:21:04 -08:00
Andy Sun
c884da03cc Revert "ais: query field info and pass to user space"
This reverts commit 3375a292ea.
Need to change the solution and re-implement this feature.

Change-Id: Iabd38bd5c0c062590215c3f22e9383853efa889c
Signed-off-by: Andy Sun <bins@codeaurora.org>
2017-11-21 09:23:16 +08:00
Andy Sun
3375a292ea ais: query field info and pass to user space
Current path to query field info: SOF ISR -> tasklet -> query thread
with high priority -> ba driver -> adv7481.

Pass field type to user space if they are valid after verification.

Change-Id: Id9926236389200446092dc9abb688ee1f83ab0c3
Signed-off-by: Andy Sun <bins@codeaurora.org>
2017-11-15 16:21:28 +08:00
Linux Build Service Account
eb1237204c Merge "msm: camera: Add laser LED support for depth sensor" 2017-09-23 11:51:00 -07:00
Xu Han
414a690797 msm: camera: sensor: Add OIS read functionality
Adding capability to read OIS data, provided in the driver
register settings.

CRs-Fixed: 2114654
Change-Id: Ie10b55f597a4daa29267c6d4333ce9d9c7702d63
Signed-off-by: Xu Han <hanxu@codeaurora.org>
2017-09-21 23:35:03 -07:00
Vijay kumar Tumati
63f5792c5c msm: camera: Add laser LED support for depth sensor
Adding new submodule for lased LED and APIs to
support register WRITE/READ operations.

Change-Id: I7e6dc27a01985c223be791b16e6b7da4bbc1be74
Signed-off-by: Vijay kumar Tumati <vtumati@codeaurora.org>
2017-09-18 16:05:57 +05:30
Terence Ho
36463959af msm: ais: Register and listen to bridge-chip interrupts
Changes that help facilitate sending the FPD-III to CSI bridge chip's
input signal status to the user-mode components.

Change-Id: I5e39c75b61f05edc8a1dc77677b9cad85fc563eb
Signed-off-by: Terence Ho <terenceh@codeaurora.org>
Signed-off-by: Andy Sun <bins@codeaurora.org>
2017-09-01 10:27:55 +08:00
Vijay kumar Tumati
54c5eaaaf9 msm: camera: Add support for TOF sensor on msm8998 QVR
Necessary documentation and driver changes for few
custom GPIOs to support depth sensor.

Change-Id: Id545a25b31e29a3f017acc1a65ad00250da72ca6
Signed-off-by: Vijay kumar Tumati <vtumati@codeaurora.org>
2017-07-24 02:42:22 -07:00
Andy Sun
182ec0b2bc ais: refine some code style issues
1. function/variable static declare;
2. dereference of noderef expression;
3. cast removes address space of expression;
4. using plain integer as NULL pointer;

Change-Id: If11a29aca93380de68a323880d55597bf320470f
Signed-off-by: Andy Sun <bins@codeaurora.org>
2017-06-21 09:43:11 +08:00
Terence Ho
96e3d4de6d msm: Initial ais driver for automotive camera
Initial driver directory setup for automotive
imaging subsystem - ais. The camera kernel drivers
for mobile and automotive platforms have been decoupled
and placed in separate directories as automotive usecases
will require significant divergence from mobile drivers.
The changes to the imaging pipeline drivers enable
automotive imaging subsystem interface from userspace.

This snapshot is taken as of msm-3.18 'commit c3d5931bbc51
("msm: Initial ais driver for automotive camera")'


Change-Id: I49b8e827818994d0a8b320ffe92f8031ffbb69ca
Signed-off-by: Terence Ho <terenceh@codeaurora.org>
Signed-off-by: Andy Sun <bins@codeaurora.org>
2017-05-15 15:55:03 +08:00
Petar Sivenov
cb9a11cd75 msm: camera: ispif: extend interface with line width
During ISPIF 3D merge configuration, line width is needed in order to
properly determine stereo merge 3D threshold register value. This
change adds line width to ISPIF extended configuration struct.

Change-Id: Iaa8ca00b4a69559d42b58a42cb61a0aa8f7a355b
Signed-off-by: Petar Sivenov <psiven@codeaurora.org>
2017-04-27 00:08:27 -07:00
Linux Build Service Account
4a17c9bb0a Merge "msm: camera: Bypass redundant creation of video node in stereo" 2017-04-14 07:29:03 -07:00
Linux Build Service Account
be634a49f4 Merge "msm: camera: ispif: adds 3D support" 2017-04-14 07:29:01 -07:00
Vikash Garodia
6f03056232 msm: media: Allocate extra memory after alignment
Existing memory allocation considers alignment after
adding the extra lines needed by hardware. This does
not increase the buffer size by the required size
increment. Add the increment after aligning the
scanlines to prevent out-of-bounds access.

Change-Id: I5f6ff7cec99e4cb5f94edda506bd1740b9b38242
Signed-off-by: Vikash Garodia <vgarodia@codeaurora.org>
2017-03-24 12:39:53 +05:30
Linux Build Service Account
41ad85e5be Merge "input: vl53l0: Enable laser sensor Kconfig and Makefile entries" 2017-03-19 20:46:16 -07:00
Petar Sivenov
cea9ac19b9 msm: camera: ispif: adds 3D support
Extend the interface to include CSID and CID to be routed to VFE PIX1
interface for 3D support in ISPIF driver.

Change-Id: Ibc001c5d52f1d2bc9c4639c8c40e320a5af2324a
Signed-off-by: Petar Sivenov <psiven@codeaurora.org>
2017-03-16 19:26:40 +02:00
Bikas Gurung
abf70e5c9d input: vl53l0: Enable laser sensor Kconfig and Makefile entries
Laser sensor is connected using CCI interface.
Add support to configure and enable laser
sensor driver.

CRs-fixed: 1051771
Change-Id: Ia9eab96862b1c2a657d40272867f015a0a91e0ed
Signed-off-by: Bikas Gurung <bgurung@codeaurora.org>
2017-03-16 16:38:12 +08:00
Iliya Varadzhakov
f977e44aea msm: camera: Bypass redundant creation of video node in stereo
In stereo mode two sensors use one video node so we need
to bypass the creation of second one.

Change-Id: I4a16d664afd3d2f67ff13cb62cd8265144d64caf
Signed-off-by: Angel Hitov <ahitov@codeaurora.org>
Signed-off-by: Iliya Varadzhakov <ivarad@codeaurora.org>
2017-03-15 18:48:42 +02:00
Venu Yeshala
127c4c22e7 msm: isp: Add support for VFE dual camera resolution limit
Read VFE resolution limitation from VFE fuse register
and restrict support for dual camera resolution.

Change-Id: I5f1c8878bd1039a40c7c8ecc5934757707e0123e
Signed-off-by: Venu Yeshala <vyeshala@codeaurora.org>
2017-03-13 08:20:28 -07:00
Linux Build Service Account
51740526b9 Merge "msm: camera: isp: support LPM on dualcamera" 2017-03-11 10:08:13 -08:00
Linux Build Service Account
81de7e7c6e Merge "msm: media: Allocate extra memory for YUV buffers" 2017-03-10 02:07:15 -08:00
Ramesh V
8739af7361 msm: camera: isp: support LPM on dualcamera
Handle LPM when one of the session goes to sleep.
when LPM enable unvote ab/ib of inative session and
vice versa.

Change-Id: I72ab333b24d7ad5ae4deafa758e7e2d92f3cc9d2
Signed-off-by: Ramesh V <ramev@codeaurora.org>
2017-03-09 10:50:00 +05:30
Pratap Nirujogi
b5ac2b42fd msm: camera: cpp: Fixing Heap overflow in output buffer
Issue:
Missing bound check when writing into the output array
buffer, which can lead to out-of-bound heap write.

Fix:
Addding hardcoded constant 8 in the MSM_OUTPUT_BUF_CNT
macro and size check to the place where the array is
accessed. Returning '0' if exceeds MSM_OUTPUT_BUF_CNT.
Caller will return -EINVAL for '0'.

Change-Id: Ic03f86e3e47ece9ca7069527e741a75ad9a0f83f
CRs-Fixed: 2004036
Signed-off-by: Pratap Nirujogi <pratapn@codeaurora.org>
2017-03-02 02:02:24 -08:00
Vikash Garodia
86f73bc1da msm: media: Allocate extra memory for YUV buffers
Allocate extra memory for UBWC color format to
prevent out-of-bounds access by hardware.

Change-Id: Iff1e06b4cb16e0a3e41b667eb9334af87d52cfb5
CRs-Fixed: 2013474
Signed-off-by: Vikash Garodia <vgarodia@codeaurora.org>
2017-03-01 19:40:55 +05:30
Manikanta Sivapala
37245e8b29 msm: vidc: Correct enum value for vpx colorspace extradata
Change  enum value of vpx colorspace extradata to align with
the hfi value of vpx colorspace extradata

Change-Id: I3f32842d3ed6d6aa427d5c80a9078efce6c11012
Signed-off-by: Manikanta Sivapala <msivap@codeaurora.org>
2017-02-02 04:48:17 -08:00
Junzhe Zou
8081806088 mm: camera: isp: send PD stats buffer earlier
Save pdaf buf address in sof event and send it with stats
notify event.

Change-Id: If147a229f3f007f30ef563469d11b678b887ed57
Signed-off-by: Shubhraprakash Das <sadas@codeaurora.org>
Signed-off-by: Junzhe Zou <jnzhezou@codeaurora.org>
2017-01-12 11:24:40 -08:00
Rohit Kulkarni
2eb05c86d3 uapi/media: add buffer size calculation for P010 ubwc
Add support for P010 ubwc format in media buffer size
calculation API.

Change-Id: I3e99bb37ff3353b77dc1aa892ca017a7af28ec00
Signed-off-by: Rohit Kulkarni <rkulkarn@codeaurora.org>
2016-12-28 13:11:17 -08:00
Linux Build Service Account
6a7da89b84 Merge "msm: sde: add compression ratio support to v4l2 rotator" 2016-12-21 07:30:00 -08:00
Linux Build Service Account
89936c94ec Merge "msm: sde: secure camera changes for v4l2 rotator" 2016-12-21 07:29:56 -08:00