Add gpu_frequency trace during SLUMBER entry and exit. This is
needed to track GPU frequency across idle and active state
transitions.
Change-Id: Ib782805a1776e4c0fb879fc34dc2e1cd11cf6791
Signed-off-by: Deepak Kumar <dkumar@codeaurora.org>
Signed-off-by: Indira Biruduraju <ibirudur@codeaurora.org>
Add a tracepoint to the power trace system to report GPU
frequency change. Format for this is identical to cpu_frequency
event and compatible with Android tools such as Perfetto.
Change-Id: I6207f45f506ab595bd261a297abdd8f40990c8de
Signed-off-by: Deepak Kumar <dkumar@codeaurora.org>
Signed-off-by: Indira Biruduraju <ibirudur@codeaurora.org>
* refs/heads/tmp-3a9b53b
Revert "binder: Prevent context manager from incrementing ref 0"
Revert "drm/drm_fb_helper: fix fbdev with sparc64"
ANDROID: fix redefinition error for restricted vendor hooks
Linux 5.4.58
nfsd: Fix NFSv4 READ on RDMA when using readv
ima: move APPRAISE_BOOTPARAM dependency on ARCH_POLICY to runtime
tcp: apply a floor of 1 for RTT samples from TCP timestamps
selftests/net: relax cpu affinity requirement in msg_zerocopy test
Revert "vxlan: fix tos value before xmit"
openvswitch: Prevent kernel-infoleak in ovs_ct_put_key()
net: thunderx: use spin_lock_bh in nicvf_set_rx_mode_task()
net: gre: recompute gre csum for sctp over gre tunnels
hv_netvsc: do not use VF device if link is down
dpaa2-eth: Fix passing zero to 'PTR_ERR' warning
appletalk: Fix atalk_proc_init() return path
net: lan78xx: replace bogus endpoint lookup
vxlan: Ensure FDB dump is performed under RCU
rxrpc: Fix race between recvmsg and sendmsg on immediate call failure
net: ethernet: mtk_eth_soc: fix MTU warnings
ipv6: Fix nexthop refcnt leak when creating ipv6 route info
ipv6: fix memory leaks on IPV6_ADDRFORM path
ipv4: Silence suspicious RCU usage warning
PCI: tegra: Revert tegra124 raw_violation_fixup
Revert "powerpc/kasan: Fix shadow pages allocation failure"
xattr: break delegations in {set,remove}xattr
Drivers: hv: vmbus: Ignore CHANNELMSG_TL_CONNECT_RESULT(23)
tools lib traceevent: Fix memory leak in process_dynamic_array_len
atm: fix atm_dev refcnt leaks in atmtcp_remove_persistent
igb: reinit_locked() should be called with rtnl_lock
cfg80211: check vendor command doit pointer before use
firmware: Fix a reference count leak.
ALSA: hda: fix NULL pointer dereference during suspend
net: ethernet: mtk_eth_soc: Always call mtk_gmac0_rgmii_adjust() for mt7623
usb: hso: check for return value in hso_serial_common_create()
i2c: slave: add sanity check when unregistering
i2c: slave: improve sanity check when registering
drm/drm_fb_helper: fix fbdev with sparc64
nvme-pci: prevent SK hynix PC400 from using Write Zeroes command
drm/nouveau/fbcon: zero-initialise the mode_cmd2 structure
drm/nouveau/fbcon: fix module unload when fbcon init has failed for some reason
net/9p: validate fds in p9_fd_open
leds: 88pm860x: fix use-after-free on unbind
leds: lm3533: fix use-after-free on unbind
leds: da903x: fix use-after-free on unbind
leds: lm36274: fix use-after-free on unbind
leds: wm831x-status: fix use-after-free on unbind
mtd: properly check all write ioctls for permissions
vgacon: Fix for missing check in scrollback handling
scripts: add dummy report mode to add_namespace.cocci
Smack: fix use-after-free in smk_write_relabel_self()
binder: Prevent context manager from incrementing ref 0
omapfb: dss: Fix max fclk divider for omap36xx
Bluetooth: Prevent out-of-bounds read in hci_inquiry_result_with_rssi_evt()
Bluetooth: Prevent out-of-bounds read in hci_inquiry_result_evt()
Bluetooth: Fix slab-out-of-bounds read in hci_extended_inquiry_result_evt()
Staging: rtl8188eu: rtw_mlme: Fix uninitialized variable authmode
staging: rtl8712: handle firmware load failure
staging: android: ashmem: Fix lockdep warning for write operation
ALSA: seq: oss: Serialize ioctls
ALSA: hda/ca0132 - Fix AE-5 microphone selection commands.
ALSA: hda/ca0132 - Fix ZxR Headphone gain control get value.
ALSA: hda/ca0132 - Add new quirk ID for Recon3D.
ALSA: hda/realtek: Add alc269/alc662 pin-tables for Loongson-3 laptops
Revert "ALSA: hda: call runtime_allow() for all hda controllers"
io_uring: Fix use-after-free in io_sq_wq_submit_work()
io_uring: prevent re-read of sqe->opcode
usb: xhci: Fix ASMedia ASM1142 DMA addressing
usb: xhci: define IDs for various ASMedia host controllers
USB: iowarrior: fix up report size handling for some devices
perf/core: Fix endless multiplex timer
USB: serial: qcserial: add EM7305 QDL product ID
ANDROID: GKI: update abi based on wifi 6GHz changes
BACKPORT: cfg80211: require HE capabilities for 6 GHz band
BACKPORT: cfg80211: reject HT/VHT capabilities on 6 GHz band
BACKPORT: cfg80211: treat 6 GHz channels as valid regardless of capability
BACKPORT: mac80211: Add HE 6GHz capabilities element to probe request
BACKPORT: mac80211: add HE 6 GHz Band Capability element
BACKPORT: cfg80211: add and expose HE 6 GHz band capabilities
BACKPORT: cfg80211: handle 6 GHz capability of new station
BACKPORT: ieee80211: add HE ext EIDs and 6 GHz capability defines
BACKPORT: ieee80211: add code to obtain and parse 6 GHz operation field
BACKPORT: cfg80211: add a helper to identify 6 GHz PSCs
BACKPORT: cfg80211: adapt to new channelization of the 6GHz band
BACKPORT: cfg80211: fix 6 GHz frequencies to kHz
BACKPORT: cfg80211: express channels with a KHz component
Revert "Revert "Revert "ANDROID: ALSA: jack: Update supported ja..."
UPSTREAM: loop: Fix wrong masking of status flags
UPSTREAM: loop: Add LOOP_CONFIGURE ioctl
UPSTREAM: loop: Clean up LOOP_SET_STATUS lo_flags handling
UPSTREAM: loop: Rework lo_ioctl() __user argument casting
UPSTREAM: loop: Move loop_set_status_from_info() and friends up
BACKPORT: loop: Factor out configuring loop from status
UPSTREAM: loop: Remove figure_loop_size()
UPSTREAM: loop: Refactor loop_set_status() size calculation
UPSTREAM: loop: Factor out setting loop device size
UPSTREAM: loop: Remove sector_t truncation checks
UPSTREAM: loop: Call loop_config_discard() only after new config is applied
ANDROID: Revert "module: Refactor section attr into bin attribute"
ANDROID: Revert "module: Do not expose section addresses to non-CAP_SYSLOG"
FROMLIST: rpmsg: Guard against null endpoint ops in destroy
ANDROID: GKI: Add some symbols to symbol list
Conflicts:
android/abi_gki_aarch64_qcom
Change-Id: I626db7277bb4eb964d24336294e6a2a5ce3fab0a
Signed-off-by: Blagovest Kolenichev <bkolenichev@codeaurora.org>
If ACD fails to send its state through the QMP mailbox, we do not get
the power saving as expected. An error message will do and need not
fail probe.
Change-Id: I821d0d3c774cc45726a8c7b281d226ff5da83fa5
Signed-off-by: Mohammed Mirza Mandayappurath Manzoor <mmandaya@codeaurora.org>
Update the logic that checks maximum allowed power level to
accommodate new frequency corners.
Change-Id: I85c9db7e39c75b14ee77464ca6fcdf5855653b25
Signed-off-by: Mohammed Mirza Mandayappurath Manzoor <mmandaya@codeaurora.org>
ACD is a power saving feature to mitigate voltage droops.
Change-Id: I43502bd44946463f7db30011e233255217cb02e0
Signed-off-by: Mohammed Mirza Mandayappurath Manzoor <mmandaya@codeaurora.org>
Update the logic to include data from all powerlevels in ACD table for
ACD to be enabled on all levels.
Change-Id: I0da7ab5e4449bbe38bc292c63f0d1a72c3991a0f
Signed-off-by: Mohammed Mirza Mandayappurath Manzoor <mmandaya@codeaurora.org>
Add per a6xx target member to specify the preemption record size
in case it is different than the default size for all a6xx.
Change-Id: I6e5579eae47dc4ee6707437d858b8b969fe573ea
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
gpu_busy is an unsigned 64 bit int and accumulates overtime
while running gpu intensive application(no slumber)
which eventually results in overflow.
Change-Id: Ifda376918ac58fa393a1958101d3d4b161bdd3c0
Signed-off-by: Nitheesh Muthuraj <nmuthuraj@codeaurora.org>
Power ctrl_flags will prevent the GPU power collapse when the
user has overwritten the force_rail_on, force_clk_on etc. This
will result into GPU wakeup problems in case power collapse
hasn’t happened during the hang recovery.
Change-Id: Ib1e86bbb70b2b71b8f8820692d13ce3ab6200db0
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
There is a possibility of cx gdsc off timeout when stall on fault
is enabled. smmu fault handler is blocked on device mutex to keep
cx vote and dispatcher trying to turn it off for recovery. To avoid
this race condition, return from fault handler when there is contention
for device mutex.
Change-Id: Ia895152f8cf1ce9bdcfecf256558ba291dabc978
Signed-off-by: gkiranku <gkiranku@codeaurora.org>
Make the debug function target specific since
it was anyways used in only two places and it also
simplifies a bunch of indirect register reads
we had to do because of ADRENO_REG enum.
Change-Id: I20fcd91339639d999d475dae60f95a357721b71d
Signed-off-by: Urvashi Agrawal <urvaagra@codeaurora.org>
Add some bits of LPAC information to snapshot.
Change-Id: I4786e4817c9fa1fe778ee769c019069923b46024
Signed-off-by: Urvashi Agrawal <urvaagra@codeaurora.org>
Some registers only exist on A660, add logic to capture
these into the snapshot.
Change-Id: I21bef72768cdb9597906ae9996c8988de1a00f7f
Signed-off-by: Urvashi Agrawal <urvaagra@codeaurora.org>
In kgsl_ioctl_gpuobj_import(), user memory of type KGSL_USER_MEM_TYPE_ADDR
can also lead to setting up a dma buffer. When attaching mem entry to
process fails, dma buffer attachment is cleaned up only in case of
KGSL_USER_MEM_TYPE_DMABUF. Similar situation can arise in case of
kgsl_ioctl_map_user_mem(). Fix this by obtaining user memory type from
the memdesc flags.
Change-Id: I502bd0ae19241802e8f835f20391b2ce67999418
Signed-off-by: Puranam V G Tejaswi <pvgtejas@codeaurora.org>
Signed-off-by: Deepak Kumar <dkumar@codeaurora.org>
Add gpu_cc_cx_gmu, gpu_cc_hub_aon & gpu_cc_hub_cx_int clock to the
list of clocks to vote for in order to access the KGSL SMMU register
space.
Change-Id: I84ff20b1c05c9045c3b271cd85ea98957fc4a6ce
Signed-off-by: Raghu Ananya Arabolu <rarabolu@codeaurora.org>
For a619_holi GPU, use RBBM_GBIF_HALT registers to halt GX
traffic and poll for the ack.
Change-Id: Iaae9084a04a5acc05ae5561d0a3c44da0ab5cebb
Signed-off-by: Pankaj Gupta <gpankaj@codeaurora.org>
For all A615 GPU family GMEM base start with 1MB as
per requirement.
Change-Id: Ie4ca5b9d264492f10eff39daf758d5c72d32c653
Signed-off-by: Hareesh Gundu <hareeshg@codeaurora.org>
This needs to be explicitly added to the new slumber entry sequence
for gmu and rgmu based targets.
Change-Id: I582067d065b1c58cab3d1d149292dd94e182bd66
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
There can exist a race where we clear the A6XX_RBBM_INT_0_MASK
register while the gpu is going into IFPC. Fix this by clearing this
register before clearing the OOB.
Change-Id: I08e9dbccbfdbee93ba7ef35fbbc673938ee033da
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
This ensures that dcvs runs while the gpu is still actively working
on the same submission for longer than the idle timer.
Change-Id: I85f2ff21dc19a9e589d6ed918bebea4c42b2a39d
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
This property is used to enable dcvs or disable both dcvs and slumber
using kgsl power state transitions. Since gmu or rgmu based targets
don't use the power states, add and use gmu core flag to enable and disable
slumber for those targets.
Change-Id: Iace3af9427c7b84509c9041604972cf14e7cd675
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
Disable gpu interrupt inline instead of changing power states as gmu
based targets do not implement the power state machine. Make sure we
skip turning off the gpu interrupt during reset after stall on fault.
Change-Id: I49c1702005f88eab523f00b25923c9c65193c7ca
Signed-off-by: Harshdeep Dhatt <hdhatt@codeaurora.org>
User should not be provided address out of SVM region.
Return error for any such requests from user.
Change-Id: If149044039b156f8192f405714f5c1a0571004e7
Signed-off-by: gkiranku <gkiranku@codeaurora.org>
When VM_MAYWRITE flag is used during mmap(), mprotect()
can be used later to change the protection of memstore
to allow write. Make sure this does not happen by
removing VM_MAYWRITE from the vm_flags of vma.
Change-Id: I6f69f05858ea40611d512cfa796caabeaa88cdb5
Signed-off-by: Indira Biruduraju <ibirudur@codeaurora.org>
This reverts commit 4bba72b72c which is
commit 2a1658bf922ffd9b7907e270a7d9cdc9643fc45d upstream.
It breaks the abi of some Android drivers and can be safely reverted as
Android does not currently run on sparc64 systems :)
Bug: 161946584
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I5245629207bf163908a72aeea92495494b71e92c
-----BEGIN PGP SIGNATURE-----
iQIzBAABCAAdFiEEZH8oZUiU471FcZm+ONu9yGCSaT4FAl8ynngACgkQONu9yGCS
aT5cPw/9GiiNZCLyjB3jVyalmN9uDYKQ+eS8H97GG7IBVYyg9whOKIrOCZHcLINH
DV5s/qnhRWJPzmQ47410ySuPb6QMvkhWTK7i5Xf+K7BOvoz/snfFGcmdu1CA4KxR
CuuH449Y4l3sH+5fPv7+EToovBqA2cfeiz/i5d5Di/N4yODWBCbHHAsZIt0oGvuK
sI1aI1K//R7vKZQvQo85tvENbWJWQwDN7eYVQj3aSbvnq8JqVpwTKTBpKfshzgzB
RmMSOVpQoQYNivW9oleG0NTQeHqj7alG8anFs3Drgu1hs5dzQhqAFlKddhtRS69j
mtrSJuf0GgJEYA6n+PfacoM4l7kHUZcQH9+bglbCXTA3nH24DLT7h0Lybm+ETPXc
ZAYo7cHqrS1BWv8VHZggSbqPr6YNKvgeflgS394wAgNEFcaJmaPfS6+elmc0qf2t
VPSas7QQruRS1Bqwb6CF2tHsl4N+VdvxX1a2JjHHcF5N3z5aqDm1qaVVQHxAg2rE
gXepFNGkEIBhWRxPz+5quxN1XBcUDiQYrzdoaKHxwY+OcdCf635P5Ob+1WK3w1oa
qhl/2scs44D67wZSgXHo5N4vMi9HhPOSV77jklgFcg75IzM9YWwYnJADQRHxo7nT
25XEgUlMfxm0ngw+CZWR0ssaP6rB9V1rRLDqb1W5HbqA7lp2YE8=
=Fe6H
-----END PGP SIGNATURE-----
Merge 5.4.58 into android11-5.4
Changes in 5.4.58
USB: serial: qcserial: add EM7305 QDL product ID
perf/core: Fix endless multiplex timer
USB: iowarrior: fix up report size handling for some devices
usb: xhci: define IDs for various ASMedia host controllers
usb: xhci: Fix ASMedia ASM1142 DMA addressing
io_uring: prevent re-read of sqe->opcode
io_uring: Fix use-after-free in io_sq_wq_submit_work()
Revert "ALSA: hda: call runtime_allow() for all hda controllers"
ALSA: hda/realtek: Add alc269/alc662 pin-tables for Loongson-3 laptops
ALSA: hda/ca0132 - Add new quirk ID for Recon3D.
ALSA: hda/ca0132 - Fix ZxR Headphone gain control get value.
ALSA: hda/ca0132 - Fix AE-5 microphone selection commands.
ALSA: seq: oss: Serialize ioctls
staging: android: ashmem: Fix lockdep warning for write operation
staging: rtl8712: handle firmware load failure
Staging: rtl8188eu: rtw_mlme: Fix uninitialized variable authmode
Bluetooth: Fix slab-out-of-bounds read in hci_extended_inquiry_result_evt()
Bluetooth: Prevent out-of-bounds read in hci_inquiry_result_evt()
Bluetooth: Prevent out-of-bounds read in hci_inquiry_result_with_rssi_evt()
omapfb: dss: Fix max fclk divider for omap36xx
binder: Prevent context manager from incrementing ref 0
Smack: fix use-after-free in smk_write_relabel_self()
scripts: add dummy report mode to add_namespace.cocci
vgacon: Fix for missing check in scrollback handling
mtd: properly check all write ioctls for permissions
leds: wm831x-status: fix use-after-free on unbind
leds: lm36274: fix use-after-free on unbind
leds: da903x: fix use-after-free on unbind
leds: lm3533: fix use-after-free on unbind
leds: 88pm860x: fix use-after-free on unbind
net/9p: validate fds in p9_fd_open
drm/nouveau/fbcon: fix module unload when fbcon init has failed for some reason
drm/nouveau/fbcon: zero-initialise the mode_cmd2 structure
nvme-pci: prevent SK hynix PC400 from using Write Zeroes command
drm/drm_fb_helper: fix fbdev with sparc64
i2c: slave: improve sanity check when registering
i2c: slave: add sanity check when unregistering
usb: hso: check for return value in hso_serial_common_create()
net: ethernet: mtk_eth_soc: Always call mtk_gmac0_rgmii_adjust() for mt7623
ALSA: hda: fix NULL pointer dereference during suspend
firmware: Fix a reference count leak.
cfg80211: check vendor command doit pointer before use
igb: reinit_locked() should be called with rtnl_lock
atm: fix atm_dev refcnt leaks in atmtcp_remove_persistent
tools lib traceevent: Fix memory leak in process_dynamic_array_len
Drivers: hv: vmbus: Ignore CHANNELMSG_TL_CONNECT_RESULT(23)
xattr: break delegations in {set,remove}xattr
Revert "powerpc/kasan: Fix shadow pages allocation failure"
PCI: tegra: Revert tegra124 raw_violation_fixup
ipv4: Silence suspicious RCU usage warning
ipv6: fix memory leaks on IPV6_ADDRFORM path
ipv6: Fix nexthop refcnt leak when creating ipv6 route info
net: ethernet: mtk_eth_soc: fix MTU warnings
rxrpc: Fix race between recvmsg and sendmsg on immediate call failure
vxlan: Ensure FDB dump is performed under RCU
net: lan78xx: replace bogus endpoint lookup
appletalk: Fix atalk_proc_init() return path
dpaa2-eth: Fix passing zero to 'PTR_ERR' warning
hv_netvsc: do not use VF device if link is down
net: gre: recompute gre csum for sctp over gre tunnels
net: thunderx: use spin_lock_bh in nicvf_set_rx_mode_task()
openvswitch: Prevent kernel-infoleak in ovs_ct_put_key()
Revert "vxlan: fix tos value before xmit"
selftests/net: relax cpu affinity requirement in msg_zerocopy test
tcp: apply a floor of 1 for RTT samples from TCP timestamps
ima: move APPRAISE_BOOTPARAM dependency on ARCH_POLICY to runtime
nfsd: Fix NFSv4 READ on RDMA when using readv
Linux 5.4.58
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Change-Id: I0e89e2c0faf90bdf1f6ac37f9a2c2395cacab054
Mark the scratch buffer as privileged so that it can only be accessed by
GPU through the ringbuffer. To accomplish this, we need to:
1. Disable the shadow rptr feature.
2. Trigger RPTR update from GPU using a WHERE_AM_I packet.
3. Add support for the new ucode.
Change-Id: I9b388f55f53b69028b9bbb2306cb43fd1297c52f
Signed-off-by: Akhil P Oommen <akhilpo@codeaurora.org>