When unload app fails, return the correct return
value that we get from TZ and not translate it to
EFAULT. This will make sure that proper handling is
done at the calling side.
Change-Id: Ie850967e5c44b502b888324291a878d0a467b46b
Signed-off-by: Anmolpreet Kaur <anmolpre@codeaurora.org>
Rename WDSP to WPSS, as per new naming requirement.
Change-Id: If44d6d2e2233b0f2c1cd754216e121494ab005f0
Signed-off-by: Neeraj Upadhyay <neeraju@codeaurora.org>
Whenever a new neighbour is added with the state
NUD_PERMANENT, the ARP probing is removed since
it is not needed.
Change-Id: Id92b24d1b99b8deff91a8e105f7310efc2f21b39
Signed-off-by: Paras Singh Jain <parassin@codeaurora.org>
Release the neighbor lock when timer expires for a neighbor entry
when neigh_probe flag is enabled.
Change-Id: I25aa82bfbba32908b093b53fff85a52d1fd894b2
Signed-off-by: Paras Singh Jain <parassin@codeaurora.org>
Send ARP probe and generate RTM_NEWNEIGH if the neighbor
state is not NUD_REACHABLE. Also featurize changes for
sending neighbor probe.
Change-Id: I633285b8e0cbcd49291d5e52136f11e20f2388bc
Signed-off-by: Paras Singh Jain <parassin@codeaurora.org>
SIP ALG mangles contact address only when both address and port are
mentioned. Some clients send only address information in which case
the contact address does not get mangled an hence SIP call does not
get established.
Change-Id: Ie760f6fcc6dd8e269b057488414b23beff4e8fc3
Signed-off-by: Paras Singh Jain <parassin@codeaurora.org>
Post function is called from interrupt context. Returning same
error code in all cases rsults in excessive prints which can
cause irq throttling.
Return -ENODEV when port lookup fails in post function.
CRs-Fixed: 2790559
Change-Id: I75384b2116cb2fe1bbeaa2dac91157345f0bab54
Signed-off-by: Deepak Kumar Singh <deesin@codeaurora.org>
Log the ep0 dma map/unmap request in the IPC log buffer
for debugging SMMU faults.
Logs can be accessed using below command
cat /sys/kernel/debug/ipc_logging/a600000.dwc3.ep_events/log.
Change-Id: If5587b8ba59451593968999b59cd61f2a469fe1c
Signed-off-by: Elson Roy Serrao <eserrao@codeaurora.org>
Signed-off-by: Udipto Goswami <ugoswami@codeaurora.org>
'Commit f62b4c27d0df ("usb: phy: snps: Enable auto-resume during
host mode bus suspend")' started enabling USB auto resume for
peripheral mode bus suspend as well. If the auto resume feature
is enabled in device mode, the device is unable to detect the
resume signalling by the host in some cases. And the auto resume
feature is applicable only in host mode.
So, enable the auto resume feature only in host mode.
Change-Id: I59155bc122ac4f5c9bb04cb4ff487c7a6ba89e47
Signed-off-by: Ajay Agarwal <ajaya@codeaurora.org>
ioctl to receive mac addr list and parental control
flag from QCMAP to enable data offload to HW or
exception path.
Change-Id: Ifaec105e4970f0418bac43e2ce4eba9c5b7fa5be
Signed-off-by: Armaan Siddiqui <asiddiqu@codeaurora.org>
The GPUCC PLL needs to lock at 2x the RCG frequency, thus update the RCG
divider to '2' to lock the PLL at 2x.
Change-Id: Iadeb8b03cf10c170efa8b11bf9aadc35f67ce736
Signed-off-by: Taniya Das <tdas@codeaurora.org>
When receiving USB_QDSS_CONNECT notification, 255 USB requests
are allocated before starting the worker thread to begin writing
to USB QDSS function driver. Conversely when USB_QDSS_DISCONNECT
is received, these requests need to be freed. Without doing so,
besides causing a slow memory leak, the existing requests would get
incorrectly re-used and may fail if the USB endpoint changed due
to a composition switch.
Change-Id: I328e110719fab374827ac69c8b60274f65ec81e2
Signed-off-by: Jack Pham <jackp@codeaurora.org>
Add constants for voltage levels: LOW_SVS_D1, TURBO_L2,
SUPER_TURBO, and SUPER_TURBO_NO_CPR.
Change-Id: I0ef80f3d0d45df259ba24a8b942538b706b07ede
Signed-off-by: David Collins <collinsd@codeaurora.org>
Read calculated cmacs on SUBSYS_AFTER_POWERUP event.
Allow user space to get the calc cmac regardless of ioctl.
Change-Id: I91d87c657a2217f467d3630e0dce41c98497d8bd
Signed-off-by: Amir Samuelov <amirs@codeaurora.org>
With hwscheduling, we need to communicate the preemption parameters
to GMU. Also, we need to use GET_VALUE hfi packet to get the
number of preemptions since last SLUMBER exit.
Change-Id: I2ab342817a3cea4e1d1797369aa272895730357b
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
This paves the way to hook preemption sysfs nodes to hwscheduling
which need to talk to GMU when changing preemption parameters
via sysfs.
Change-Id: I6940dbf294ad71a18b2dcded207cbacf18ba661d
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
Send the HFI feature control packet to the GMU in order to enable
preemption.
Change-Id: Ic00e3943bceb29feb28740dbadd3fb7c6fdc562b
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
This is to allow GMU to request secure gpu global buffers.
Change-Id: Iacef726ee3abe02b56178f475ebe9835649a868c
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
The result of GENMASK needs to be inverted so that the
handler doesn't report OOB bits as unknown bits.
Change-Id: I3e39334a6dd79343109591b043c9aa30a8bdff9d
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
With hwscheduling, the flags are requested by GMU outside
of kgsl domain. Printing these flags helps to know the flags
as requested by GMU.
Change-Id: I71d19ead02e115c0a4ead9861de9afd2a0dd2608
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
Say a context has only one submission i.e. it has only one dispatch
job. And say gpu encounters a fault and sets dispatcher fault. The
dispatch job will be free'd and post recovery, the context will never
get to the ringbuffer until it queues another submission. This behaviour
holds true in cases where dispatcher is halted for example during
suspend. So in either case, add back the job the the dispatcher jobs
list to make sure the job is not lost.
Change-Id: Iec0a0abfbdcf2535d7f82ec1e286581e1c93a3ea
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
To help debug, enable serial console for GKI
images.
Change-Id: Idfa6803b71bc19625875e0ae1bb2b93295760010
Signed-off-by: Ashish Bhimanpalliwar <abhiman@codeaurora.org>
For rimps_log and qcom_rimps platform driver does not
support the manual bind / unbind feature through sysfs,
Suppress the bind / unbind calls using driver attribute.
Change-Id: I9734d62e19ef16b01039757a92ef2489baea91b3
Signed-off-by: Santosh Mardi <gsantosh@codeaurora.org>
Correct the idle task check, to be done on 'next'
task, instead of current task, while registering
current task's stack.
Change-Id: I8c4fde434b3eca0543c5748234ebabbd40da8672
Signed-off-by: Neeraj Upadhyay <neeraju@codeaurora.org>
When we import an ION buffer, we call the dma_buf_map_attachment().
The intent is to not map it to the dma device(which in this case is the
KGSl device), but to only get the sg_table. Once we have the sg_table
we later map the physical pages to the GPU SMMU manually and not by using
the dma device ops.
The ION driver as part of the partial cache maintenance requires that
all the sg_tables of the attached devices to the buffer have a single
segment. This creates a problem for KGSL since in this case the kgsl is
a dummy device, so the buffer for KGSL always has multiple segments.
This patch calls the dma_buf_unmap_attachment() as soon we get a hold of
the sg_table as doing so a) we don't need the buffer to be mapped to a
dummy device, b) removes the buffer from the cache maintenance constraints
of the ION driver.
Change-Id: I0675e62c4a27b4e368d53ea6310c9244b687baa6
Signed-off-by: Sharat Masetty <smasetty@codeaurora.org>
Signed-off-by: Puranam V G Tejaswi <pvgtejas@codeaurora.org>
Add SOC ID to support socinfo for Yupik SOC.
Change-Id: Ie552bdff85f9ada478b3e102addc365e624c310c
Signed-off-by: Neeraj Upadhyay <neeraju@codeaurora.org>
In some cases issuing end_transfer command as part
of remove requests to eps is taking around 2ms for
the endpoint command complete interrupt(EPCMDCMPLT).
And before EPCMDCMPLT interrupt driver has already
unmapped the request which controller may access leading
to SMMU fault. Fix this by adding delay before giving
back the requests to gadget driver.
Change-Id: Iba10f5337a43c5f7db702321f6dce3b5e1b1af44
Signed-off-by: Pratham Pratap <prathampratap@codeaurora.org>
It is required to SET block doorbell to GSI to avoid USB wrapper
from ringing doorbell before queuing stop xfer command to GSI
endpoint as part of stopping controller and CLR block doorbell to
GSI after queuing start xfer command to GSI endpoint.
Since ipa_work_handler runs in workqueue context there is a possiblity
that CLR block doorbell will happen even after run/stop is
cleared which may lead to SMMU fault. Avoid this by adding a check
for pullups_connected before clearing block doorbell.
Change-Id: Iedb8a96da197834169bdabae6381c974d50c95de
Signed-off-by: Pratham Pratap <prathampratap@codeaurora.org>
Enable CONFIG_KPROBES_DEBUG for holi to enhance debugging.
Change-Id: I9737cd61526685627031e4edaf7d7cd5e36de706
Signed-off-by: Vijayanand Jitta <vjitta@codeaurora.org>
Some controller hardware, such as DWC3, need a minimum delay
between removing and re-applying the pullups in order for the
host to properly detect a soft disconnect and for subsequent
re-enumeration to succeed. Keep track of the last time run_stop
was updated and delay if necessary so that enough time will
have elapsed before calling run_stop clear/set again.
Change-Id: I8ca13304edf4c9fcc3093a063a6004bd8b76ed44
Signed-off-by: Ajay Agarwal <ajaya@codeaurora.org>
Signed-off-by: Sriharsha Allenki <sallenki@codeaurora.org>
A spinlock recursion happens if fsm state is dumped in irq
context. Only dump the fsm state in task context.
Change-Id: I73f38607b97ddb693c9bd1c885ffe6b297dc9aea
Signed-off-by: Asutosh Das <asutoshd@codeaurora.org>
If worker is not processing packets on control port fast enough,
socket buffer may get full and result in drop of control packets.
Creating dedicated worker thread to process control packets.
CRs-Fixed: 2763561
Change-Id: I4585015cef2a507a9ba13014cd93f40e60f8a25a
Signed-off-by: Deepak Kumar Singh <deesin@codeaurora.org>
This change is to ensure that modem notifier callback for
icnss2 driver gets called before it gets called for IPA.
In one scenerio, wlan driver holds rtnl lock before
trying to send WMI message to wlan fw, During same time
watchdog bite happened on modem and IPA received modem
notifier callback. Here IPA is also trying to hold rtnl lock
which is held by wlan driver which never got released as driver
is not aware of watchdog bite on modem. In this case
icnss driver is not getting modem notifier callback.This
change ensures modem notifier gets called for wlan first
and rtnl lock held by wlan driver gets released.
Change-Id: I9effd300f6b22138baec59a03a9c4bceb87a8130
Signed-off-by: Sandeep Singh <sandsing@codeaurora.org>
While rpm driver flushing messages in lpm mode, use
rpmsg_trysend instead of rpmsg_send to avoid the dump stack.
qcom_smd driver is going to sleep when tx ring buffer is full
if rpmsg_send is used while flushing. rpm-smd is using spinlock
while flushing the messages. Under spinlock it should not go to sleep.
dump stack is shown because of this. Use rpmsg_trysend to avoid
showing dump stack.
Change-Id: I02ac6c273d49bbfd329c1be9820c53f637052b41
Signed-off-by: Prasadarao Durvasula <pdurvasu@codeaurora.org>
Signed-off-by: Sivasri Kumar Vanka <sivasri@codeaurora.org>
As rpmsg takes care of locking when sending data, this patch
removes the redundant locking by removing the smd_write spinlock.
Also this patch reverts the 'commit 808861b856d1 ("drivers: rpmsg:
fix to avoid dump stack in rpm-smd driver")' which is not required
after removing extra spinlocks.
It removes the unsed smd_read spinlock aswell.
Change-Id: I7b15d19add2c4da876aa127be233331b58d3c8ae
Signed-off-by: Raghavendra Kakarla <rkakarla@codeaurora.org>