cpufreq: ondemand: Remove input boost

A probably imperfect extermination of ondemand's input boost.
We rely on the universal cpu boost input handler now.
cpufreq: ondemand: Remove sync thread feature

Syncing threads in the cpu-boost driver is sufficient.
cpufreq: ondemand: Calculate load_at_max_freq based on current policy->max

Change-Id: I06b311b343f8137f276ec561c4b598722f663750
soc: qcom: rq_stats: remove the redundant iowait check

Iowait_time check is redundant and it would lead to heavy load
due to miscaluculation of idle time. Hence remove this check
as iowait will considered based on io_busy flag.

[myfluxi: Adapt to msm 8974]

Change-Id: I4dd9f9c79205eca588daea8cc0fe892394a83391
CRs-fixed: 662052
Signed-off-by: Anji Jonnala <anjir@codeaurora.org>
defconfig: Reenable TSPP

Change-Id: I834ca0b53dfcb1fed3a796e7358166a4ee25daff
msm: camera:v2: Fix for broken video HDR

If there is RDI stream, we should continue the loop,
iotherwise pix_stream_count is never incremented for PIX stream.

Change-Id: I3dad2a1c52926bf02cde7695ee5e7127dba2fde7
Signed-off-by: Sagar Gore <csgore@codeaurora.org>
msm: camera: Enqueue native buffer directly

For native buffer, when userspace queue back
the buffer from userspace, whether the buffer
is clean/dirty, the buffer should go back to
the native buffer queue, otherwise the buffer
will be in invalid state.

Change-Id: Ia41bb950d39e144e251d0feea099d4a517a11852
Signed-off-by: Kevin Chan <ktchan@codeaurora.org>
msm: Add support for JPEG RAW & META RAW cam format

Add num of planes, size, xbar config and v4l2 support for
JPEG and META RAW formats

Change-Id: I940c72c43321390fe95deb3e0a0e649fa9a98a1e
Signed-off-by: Harsh Shah <harshs@codeaurora.org>
msm: camera_v2: Use stream cnt for unique stream id

Add new atomic counter for keeping track of stream counts.
The exisitng open_cnt counter is not full-proff since there could
be multiple streams with the stream id in the folowing
scenario:
a) Create stream 1, 2, and 3
b) Destroy stream 2
c) Add new stream; will result in another stream with id 3.

CRs-fixed: 493632
Change-Id: Icfa3cb2fd2c34c6da7e5f09d016fef4577331264
Signed-off-by: Ankit Premrajka <ankitp@codeaurora.org>
msm_sensor: fix vreg dt parsing logic

Previously, dt parsing code for sensor power up sequence assumes certain
value and order in "qcom,cam-vreg-name".  Such assumption can't be
enforced by dt itself.  It leads to kernel panic when enum value of a vreg
is larger than total number of specified vregs.

New implementation dynamically search and match available vregs, instead of
relying on order and enum assumptions.

Change-Id: Iea519f2e4b4d805fecf6dd699ade2af4a00caa43
Signed-off-by: Junjie Wu <junjiew@codeaurora.org>
msm: camera: Improve interface for large SPI reads

For each SPI read, two buffers of read size + header need to be
allocated.  These allocation might fail if read size is large.  It's also
expensive to allocate memory each time for repeated transfers.
Therefore, msm_camera_spi_read_seq_l() is provided to use pre-allocated
buffers instead of allocating them each time.

Change-Id: Ibd52fd26bb0a4fdd913bef9c2bfc410152245c3b
Signed-off-by: Junjie Wu <junjiew@codeaurora.org>
msm: camera: Add advanced feature for yuv sensor

Add set auto focus and call back for auto focus for yuv
sensor. Enable the features saturation, brightness,
sharpness for the YUV sensors.

Change-Id: I8003465f337848d8728dcc6cd073eb5047e26e77
Signed-off-by: Lokesh Kumar Aakulu <lkumar@codeaurora.org>
msm:camera: change to add the gpio control Vreg enable

Some auto focus module has PWDM pin to be enabled by gpio, and we
also need to add gpio enable vreg to support different customers.

Change-Id: Id9b230c855a7665697d1ddc80fa845e44ba6f4b0
Signed-off-by: feim <Flynn@codeaurora.org>
msm: camera2: Enhance processed divert in cpp driver.

The processed divert frames from cpp driver can be queued back
to free queue or queued in done queue. This change enhances
cpp driver to support both modes of operation.

Change-Id: I2ec08bd9c25fdb1db089d974c935e97898840e39
Signed-off-by: Rajakumar Govindaram <rajakuma@codeaurora.org>
msm:cpp: Check number of buffers before allocate stream_info

Number of buffers used by cpp is defined by user space. In
case this number is ZERO the allocated memory space will be
pointed by ZERO_SIZE_PTR. Referencing ZERO_SIZE_PTR, causes
same type of behavior as referencing the NULL pointer

Change-Id: I42665225c7d055cda6749198c35e94c1442c6d3e
Signed-off-by: Iliya Varadzhakov <ivarad@codeaurora.org>
msm: camera2: Validate frame during timeout in cpp driver

During long stability stress runs, invalid frames are encountered
in timeout processing. When frame acknowledgement is delayed by
firmware due to various reasons the timeout handler could hit
frame that are already processed. Hence adding NULL condition
check to avoid invalid frame access.

Change-Id: Icaa5e630d5190a7bf0a4e07a95d08e116cb304db
Signed-off-by: Rajakumar Govindaram <rajakuma@codeaurora.org>
msm: camera: Use default value if CSIPHY param is NULL

Use default value if CSIPHY lane mask is NULL. This value will be
0x0 if open camera fails and releases CSIPHY driver in error
handling case.

Change-Id: I2ba1e2f3559de208974deb2598278298909ce208
Signed-off-by: Sreesudhan Ramakrish Ramkumar <srramku@codeaurora.org>
msm: camera: Update CPP driver for new hardware version

Update CPP driver for 0x10010001 version which is used in 8974 v3
pro.

Change-Id: Iefb7d4fa852a3548e866f460994a0c1744578e36
Signed-off-by: Sreesudhan Ramakrish Ramkumar <srramku@codeaurora.org>
msm: camera: Fix VFE IOMMU page faults

To avoid VFE IOMMU page faults in case of
vfe write masters bus overflows, enable
bus overflow override flag to allow
non overflowing write masters to continue
thier operation.

Change-Id: I9452acac2b70786217b3d65029e1b68cee2fdf3e
Signed-off-by: Suresh Vankadara <svankada@codeaurora.org>
camera_v2: jpeg: Use buf_cmd.offset for v2p size calculation

Start using buf_cmd.offset when calculating the memory map
size for v2p. This is needed to enable ION input buffer support
for JPEG decoding.The input buffer has a header before the actual
bitstream.

Signed-off-by: Kamen Kirov <kkirov@codeaurora.org>
Change-Id: If9bdcefe3628bd21c9e76916e4d7e3dc3cc39447