Use put_user API to write the data from kernel space to
userspace to avoid accessing userspace memory directly
in kernel space.
Change-Id: I649fe2597e80ccad50cf16b355e220734810e94c
Signed-off-by: Brahmaji K <bkomma@codeaurora.org>
If minidump is not enabled, minidump add region api returns
error number, clients can log the error to log buffer, which
flood the log buffer unnecessarily.
So return quietly if minidump support is not enabled.
Change-Id: I9c6428015ca40c5233f80471896bacecd0872bf7
Signed-off-by: Lingutla Chandrasekhar <clingutla@codeaurora.org>
Add support for hardware that can switch both parent clocks and divider
at the same time. This avoids generating intermediate frequencies from
either the old parent clock and new divider or new parent clock and
old divider combinations.
Change-Id: I1b3f7e9422f5c27eeb391d309374167dc139e8ca
Signed-off-by: Georgi Djakov <georgi.djakov@linaro.org>
Git-commit: 549f1a4028350851f73837ad8cce3ac5fd2abd11
Git-repo: https://git.quicinc.com/?p=kernel/msm-4.4.git
[anischal@codeaurora.org: Fix compilation issue with
mux_div_get_safe_parent]
Signed-off-by: Amit Nischal <anischal@codeaurora.org>
The patch defines the per peripheral packet length
inside the per peripheral structure replacing
corresponding global variables.
CRs-Fixed: 2050301
Change-Id: I0bb732d93cd98aa46c69c81eeae9872a801a9e18
Signed-off-by: Manoj Prabhu B <bmanoj@codeaurora.org>
Move error logs from interrupt context to process context to
avoid blocking other interrupts and reduce latencies in
ISR handling.
Also keep error check for BAM rx completion.
Change-Id: Ibf355561495b35702118eaf9a0f38c0fdc9310b3
Signed-off-by: Shrey Vijay <shreyv@codeaurora.org>
This file seems to have a BOM sequence to indicate the file is
UTF-8. There aren't any UTF sequences in the file though, and
this trips up sparse when running on files that include this
header. Remove the BOM so sparse is happy.
Change-Id: Ie25ce60077d1f2b4eb51bf0792635f02d1b33ae7
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: Mohit Aggarwal <maggarwa@codeaurora.org>
Current DRM adds offset when making IOVA but failed to add it when
making kernel address. This makes DRM write queue_s and submit_s to
wrong place if the profile buffer is not at the head of
a chunk of buffer.
Change-Id: I5af9c3050f4c6c5e0a54ed495bf79053f08f0bab
Signed-off-by: Kasin Li <donglil@codeaurora.org>
Currently power Delivery (PD) is enabled by default which sends
PD Hard reset in SINK mode to negogiate PD contract with host machine
after connect, if no capabilities message is received from other device.
This impacts with compliance for example: PMI ignores type-c disconnects
during PD Hard Reset. Add module parameter to disable PD so that it
doesn't enable PD communication during USB3.1 compliance testing.
Change-Id: Ia3e39cee1e65895402c18b380b650f0a34fb0cec
Signed-off-by: Vijayavardhan Vennapusa <vvreddy@codeaurora.org>
If stream is inactive then there is no need to update lpm mode
for the stream since the stream is non operational.
Change-Id: I5c719211dc2bfdc67365a3716bd79c7fa54a818f
Signed-off-by: Shubhraprakash Das <sadas@codeaurora.org>
Host wlan driver needs to know if the drive has been
reloaded and wiphy re-registered with the kernel.
Therefore add APIs to retrieve this information.
CRs-Fixed: 2058292
Change-Id: Ia323e31e9b6779e2f5279f42b6e1860a9259a189
Signed-off-by: Amar Singhal <asinghal@codeaurora.org>
Enable CONFIG_MMC_RING_BUFFER flag to support ring buffer
logging of mmc driver events for msm8998.
Change-Id: I910b2610e89813f8e398ad42689d20b3fd59bf0b
Signed-off-by: Veerabhadrarao Badiganti <vbadigan@codeaurora.org>
While executing tuning in case CMD19 fails, the driver sends CMD13
multiple times to ensure the card is ready to receive the next tuning
command. If this status command fails with CRC error, it will trigger
tuning. This will result in back to back tuning multiple times.
To avoid this situation, ignore CRCs error generated with CMD13 while
executing tuning.
Change-Id: Ife338768264ebebebc655fe11874e905abdf7482
Signed-off-by: Veerabhadrarao Badiganti <vbadigan@codeaurora.org>
Perform cache operations on decoder input and encoder output
data plane only on filled length, rather than allocated length
Change-Id: I21e1bc3ce442e902dab97d0c661168dfb5507012
Signed-off-by: Surajit Podder <spodder@codeaurora.org>
Provide complete resolution details in a sysfs node "res_info"
limited to PAGE_SIZE. Different modules can query for multiple
resolution details based on the resolution ids received from
EDID of the TV. In case resolution details exceed PAGE_SIZE,
reuse res_info to get remaining timing details by provide page
details. Check page id is within the max supported resolution
ids to avoid reading extra memory than required.
Change-Id: I7cdd071ba462080fe5bb302d0da824ed95b50f15
Signed-off-by: Ashish Garg <ashigarg@codeaurora.org>
There is no validation of the "count" parameter, which is controlled
by the user and used as a size of allocated memory. If the user
provides a value of "0" for "count", then kmalloc would not return
NULL, but also there will be a memory block of "zero" size. This can
lead to buffer overflows. Also trying to access invalid memory will
cause kernel crashes. Ensure to check that the number of bytes to be
written is non-zero. If zero, return invalid input.
Change-Id: I9613043881a91fd5a5f99337119c4a3d41493b54
Signed-off-by: Ashish Garg <ashigarg@codeaurora.org>
Number of cea blocks are read from edid buffer which comes from the
user. If the number of cea blocks are more than the supported blocks
kernel information leak is possible by reading more data than is
present in edid_buf.
Change-Id: I03b8456ff1e1a7b15d711f06908bd5c83f83cc02
Signed-off-by: Ashish Garg <ashigarg@codeaurora.org>
To update custom edid through sysfs node, there was no check
on the edid size passed. The user can overwrite the edid buffer.
To prevent buffer overflow, ensure that edid size is validated
with the edid buffer size before writing to the buffer.
Change-Id: I8604ea2d25f3a4985749bd037497d242b0621519
Signed-off-by: Ashish Garg <ashigarg@codeaurora.org>
This change adds the secure context bank child node in mdss
driver, this is required for having both the secure and non-secure
smmu context bank support in the driver. This change also renames
the child nodes to avoid compilation issues on the builds where
fb driver mdss device file is also present. As a part of this
change the smmu driver registration is called as a part of
msm driver probe.
CRs-Fixed: 2053654
Change-Id: I90cd31fd792b0fd9772689dc6561bb0b429e1e3a
Signed-off-by: Abhijit Kulkarni <kabhijit@codeaurora.org>
64K page pool is currently unused because it doesn't have
any reserved pages and also dynamic page allocation for
this pool is disabled.
Add qcom,mempool-allocate property to allow pool to grow
dynamically and hence being used.
Change-Id: Ie7c41939f45af58ca1ac7a8f07ea29605aced798
Signed-off-by: Deepak Kumar <dkumar@codeaurora.org>
Enable CFG80211_INTERNAL_REGDB to support WiFi 5G channels.
Change-Id: I7d53d2a09c30173d121368ec2e3584217ddc5093
Signed-off-by: Zhaoyang Liu <zhaoyang@codeaurora.org>
When using QGIC MSI, the MSI controller is GIC not PCIe host
driver. Only set irq chip data if PCIe host is the MSI
controller.
Change-Id: I0ba9e78127424ab3da4b1f46b3ed3fa5d65d05f6
Signed-off-by: Tony Truong <truong@codeaurora.org>
Handle the clk API return value so that it’s easy
to catch un clocked GPU register access.
Change-Id: I5a1a9a6cbd673394f126bb17b849393268a22b1b
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
fix one potential out of boundary query of stats info.
CRs-Fixed: 2041066
Change-Id: I13e4bf8802fcce529f9268c272e4727619d5ad8f
Signed-off-by: Fei Zhang <feizhang@codeaurora.org>
Enable secondary USB port for HDK660 platform which use
host only mode.
Remove TCSR_QUSB2_PHY_CLAMP_DIG_N_1P8 resource entry for SDM660
which is not required to set now during disconnect as writing to this
register causes USB3.0 port and USB2.0 ports working independently.
Change-Id: I936a4012c30e0cd84144b12e34fb780cada541ae
Signed-off-by: Liangliang Lu <luliang@codeaurora.org>
Mhi node needs additional information for driver
probe to get success. This generic node is not
required and hence disable unwanted dtsi node for
msm8996.
Change-Id: I4dffd3d668ac065fc800e5e7d3b52fdf2733e03f
Signed-off-by: Rama Krishna Phani A <rphani@codeaurora.org>
Add 500ms before MDM enumeration, this delay is needed for
link establishment between switch and MDM.
Change-Id: I32c4a4f9ef68b7672465ced0401fbf6dc0db0002
Signed-off-by: Rama Krishna Phani A <rphani@codeaurora.org>
For targets with multiple UDCs having DRD feature, two UDCs
may be in peripheral mode. In that case, create and bind
android device corresponding to each gadget as and when
mkdir gadget is run. Keep global structure android_device as
android0 (or g1's device) for ease of use by f_midi and
f_audio_source.
Change-Id: Idae6f6d0d8811f27e836f5f6399395a15fbf3c2f
Signed-off-by: Ajay Agarwal <ajaya@codeaurora.org>