hwmon: qpnp-adc: Fix potential errors

There is a possibility of potential out of bound array
access errors and uninitialized variable access from code
inspection. Add additional checks in voltage ADC and
TSENS to check for such errors.

Change-Id: I1213cd76fb636aa457c88d3bdc3740b692f01cce
Signed-off-by: Siddartha Mohanadoss <smohanad@codeaurora.org>
Merge "hwmon: qpnp-adc: Fix potential errors"
defconfig: msm9625: Enable Filtering modules

Enable IP filtering based on tcp state & Enable ip filtering modules
for ebtables.

Change-Id: Ifbc031bc0275b6ea6710ccbd6ceb963974f6a135
Signed-off-by: Tyler Wear <twear@codeaurora.org>
Merge "defconfig: msm9625: Enable Filtering modules"
diag: Fix incorrect handling of buffers

In diag driver, processing dci transaction takes place even if the
incoming buffer is invalid. Also, we are handling the memory pools
incorrectly. This patch fixes these two issues

Change-Id: Ibdcc9759e3e1030f34f82c4e6b0315a8e5c79ab7
Signed-off-by: Ravi Aravamudhan <aravamud@codeaurora.org>
ion: msm: Add null-pointer check to info struct

Add null-pointer check after allocation to avoid null-pointer
deference and subsequent crash of the kernel.

Change-Id: Idba61f5047225323d83425863222808522e89f53
Signed-off-by: Olav Haugan <ohaugan@codeaurora.org>
ion: Add null-pointer check to info structure

Add null-pointer check to info structure to avoid null-pointer
dereference and subsequent kernel crash.

Change-Id: I88135c1efa0b6ddc333e16511016d3618d9d5cf3
Signed-off-by: Olav Haugan <ohaugan@codeaurora.org>
msm: remove fmem support

This functionality is no longer supported.

Change-Id: I52df01acc7deebcfd84e78c333d860e3f3c2eb32
Signed-off-by: Larry Bassel <lbassel@codeaurora.org>
msm: Add NULL pointer check before ion cache operation

If the ion buffer is of size zero, NULL pointer
dereferencing may take place. Avoid it by adding
a check before function call.

Change-Id: If6c19a94f70f3658c5323a0742399ec977944da7
Signed-off-by: Neeti Desai <neetid@codeaurora.org>
spmi and gpio: qpnp: add pointer check in qpnp drivers

This patch is to fix KW errors in drivers. It's
neccessary to check NULL pointer before dereferencing it.
There're 4 issues related to it in qpnp-int.c and
qpnp-pin.c. Fix them by checking before.

CRs-Fixed: 505322
Change-Id: I2f82d1b24c219ef7e6b0977091fc353dac579cbc
Signed-off-by: Zhenhua Huang <zhenhuah@codeaurora.org>
Merge "diag: Fix incorrect handling of buffers"
Merge "ion: msm: Add null-pointer check to info struct"
Merge "ion: Add null-pointer check to info structure"
Merge "msm: remove fmem support"
Merge "msm: Add NULL pointer check before ion cache operation"
Merge "spmi and gpio: qpnp: add pointer check in qpnp drivers"
gpio: msm: Remove software handling for dual-edge interrupts for TLMM_V2

The TLMM_V2 did not have hardware support for dual-edge interrupts.
This was handled in software using an algorithm to detect the current
edge and switch the interrupt polarity. This does not work after keeping
the RAW_STATUS_EN always enabled as switching the interrupt polarity
causes a spurious interrupt.
The TLMM_v3 has hardware support for dual-edge interrupts and this
continues to work as expected.
Thus, this patch removes dual-edge interrupt support for TLMM_V2.

Change-Id: I31651dea0b262adff3c3e0eede2ae83241dfe16b
CRs-Fixed: 520199
Signed-off-by: Rohit Vaswani <rvaswani@codeaurora.org>
usb: usb_bam: Code quality checking fix

Fixed a code-quality checking issue:
In usb_bam_a2_reset() function, the bam local variable is defined as
an unsigned char, but it is initialized by an enumeration value. Used a
conversion for fixing it.

Change-Id: I5f35476694ba6520eff77a6504d041eb70d7f5ac
Signed-off-by: Daniel Segal <dsegal@codeaurora.org>
IPA: fix ipv6 TOS traffic routing fail

For ipv6 traffic filter rules with meta equation
32 is not working. All traffic is taking SW path.
To filter TC ip packets change to use  meta equation
128 instead of 32

Change-Id: I8cf34264b65584d5ef1bb73c239413ebb9083345
Signed-off-by: Skylar Chang <chiaweic@codeaurora.org>
ARM: dts: msm-pm8019: Switch VADC to polling

Switch VADC to use polling mode to check if the
conversion request is complete by checking the status
bits for the corresponding VADC registers to
indicate the conversion is complete.

Change-Id: I7a28d0e36bbbad465cbbfe716069d88af88534ba
Signed-off-by: Siddartha Mohanadoss <smohanad@codeaurora.org>