Commit Graph

1155895 Commits

Author SHA1 Message Date
jianzhou
dd83e88d4d Merge keystone/android14-6.1-keystone-qcom-release.6.1.25 (bd65f1b) into qcom-6.1
* refs/heads/tmp-bd65f1b:
  ANDROID: uid_sys_stats: Use llist for deferred work
  UPSTREAM: usb: typec: ucsi: Fix command cancellation
  ANDROID: GKI: update symbol list file for xiaomi
  UPSTREAM: erofs: avoid infinite loop in z_erofs_do_read_page() when reading beyond EOF
  UPSTREAM: erofs: avoid useless loops in z_erofs_pcluster_readmore() when reading beyond EOF
  UPSTREAM: erofs: Fix detection of atomic context
  UPSTREAM: erofs: fix compact 4B support for 16k block size
  UPSTREAM: erofs: kill hooked chains to avoid loops on deduplicated compressed images
  UPSTREAM: erofs: fix potential overflow calculating xattr_isize
  UPSTREAM: erofs: stop parsing non-compact HEAD index if clusterofs is invalid
  UPSTREAM: erofs: initialize packed inode after root inode is assigned
  ANDROID: GKI: Update ABI for zsmalloc fixes
  BACKPORT: zsmalloc: fix races between modifications of fullness and isolated
  UPSTREAM: zsmalloc: consolidate zs_pool's migrate_lock and size_class's locks
  ANDROID: consolidate.fragment: Enable slub debug in consolidate-fragment
  BACKPORT: FROMGIT: mm: handle faults that merely update the accessed bit under the VMA lock
  FROMLIST: mm: Allow fault_dirty_shared_page() to be called under the VMA lock
  FROMGIT: mm: handle swap and NUMA PTE faults under the VMA lock
  FROMGIT: mm: run the fault-around code under the VMA lock
  FROMGIT: mm: move FAULT_FLAG_VMA_LOCK check down from do_fault()
  FROMGIT: mm: move FAULT_FLAG_VMA_LOCK check down in handle_pte_fault()
  BACKPORT: FROMGIT: mm: handle some PMD faults under the VMA lock
  BACKPORT: FROMGIT: mm: handle PUD faults under the VMA lock
  FROMGIT: mm: move FAULT_FLAG_VMA_LOCK check from handle_mm_fault()
  BACKPORT: FROMGIT: mm: allow per-VMA locks on file-backed VMAs
  FROMGIT: mm: remove CONFIG_PER_VMA_LOCK ifdefs
  FROMGIT: mm: fix a lockdep issue in vma_assert_write_locked
  FROMGIT: mm: handle userfaults under VMA lock
  FROMGIT: mm: handle swap page faults under per-VMA lock
  FROMGIT: mm: change folio_lock_or_retry to use vm_fault directly
  BACKPORT: FROMGIT: mm: drop per-VMA lock when returning VM_FAULT_RETRY or VM_FAULT_COMPLETED
  BACKPORT: FROMGIT: mm: move vma locking out of vma_prepare and dup_anon_vma
  BACKPORT: FROMGIT: mm: always lock new vma before inserting into vma tree
  FROMGIT: mm: lock vma explicitly before doing vm_flags_reset and vm_flags_reset_once
  FROMGIT: mm: replace mmap with vma write lock assertions when operating on a vma
  FROMGIT: mm: for !CONFIG_PER_VMA_LOCK equate write lock assertion for vma and mmap
  FROMGIT: mm: don't drop VMA locks in mm_drop_all_locks()
  BACKPORT: riscv: mm: try VMA lock-based page fault handling first
  BACKPORT: FROMGIT: mm: enable page walking API to lock vmas during the walk
  BACKPORT: mm: lock VMA in dup_anon_vma() before setting ->anon_vma
  UPSTREAM: mm: fix memory ordering for mm_lock_seq and vm_lock_seq
  FROMGIT: usb: host: ehci-sched: try to turn on io watchdog as long as periodic_count > 0
  FROMGIT: BACKPORT: usb: ehci: add workaround for chipidea PORTSC.PEC bug
  UPSTREAM: tty: n_gsm: fix UAF in gsm_cleanup_mux
  UPSTREAM: mm/mmap: Fix extra maple tree write
  FROMGIT: Multi-gen LRU: skip CMA pages when they are not eligible
  UPSTREAM: mm: skip CMA pages when they are not available
  UPSTREAM: dma-buf: fix an error pointer vs NULL bug
  UPSTREAM: dma-buf: keep the signaling time of merged fences v3
  UPSTREAM: netfilter: nf_tables: skip bound chain on rule flush
  UPSTREAM: net/sched: sch_qfq: account for stab overhead in qfq_enqueue
  UPSTREAM: net/sched: sch_qfq: refactor parsing of netlink parameters
  UPSTREAM: netfilter: nft_set_pipapo: fix improper element removal
  ANDROID: Add checkpatch target.
  UPSTREAM: USB: Gadget: core: Help prevent panic during UVC unconfigure
  ANDROID: GKI: Update symbols to symbol list
  ANDROID: vendor_hook: fix the error record position of mutex
  ANDROID: ABI: add allowed list for galaxy
  ANDROID: gfp: add __GFP_CMA in gfpflag_names
  ANDROID: ABI: Update to fix slab-out-of-bounds in xhci_vendor_get_ops
  ANDROID: usb: host: fix slab-out-of-bounds in xhci_vendor_get_ops
  ANDROID: GKI: update pixel symbol list for xhci
  FROMGIT: fs: drop_caches: draining pages before dropping caches
  ANDROID: GKI: update symbol list file for xiaomi
  ANDROID: uid_sys_stats: Use a single work for deferred updates
  ANDROID: ABI: Update symbol for Exynos SoC
  ANDROID: GKI: Add symbols to symbol list for vivo
  ANDROID: vendor_hooks: Add tune scan type hook in get_scan_count()
  FROMGIT: BACKPORT: Multi-gen LRU: Fix can_swap in lru_gen_look_around()
  FROMGIT: Multi-gen LRU: Avoid race in inc_min_seq()
  FROMGIT: Multi-gen LRU: Fix per-zone reclaim
  ANDROID: ABI: update symbol list for galaxy
  ANDROID: oplus: Update the ABI xml and symbol list
  ANDROID: vendor_hooks: Add hooks for lookaround
  ANDROID: ABI: Update STG ABI to format version 2
  ANDROID: ABI: Update symbol list for imx
  FROMGIT: erofs: fix wrong primary bvec selection on deduplicated extents
  UPSTREAM: media: Add ABGR64_12 video format
  BACKPORT: media: Add BGR48_12 video format
  UPSTREAM: media: Add YUV48_12 video format
  UPSTREAM: media: Add Y212 v4l2 format info
  UPSTREAM: media: Add Y210, Y212 and Y216 formats
  UPSTREAM: media: Add Y012 video format
  UPSTREAM: media: Add P012 and P012M video format
  ANDROID: GKI: Create symbol files in include/config
  ANDROID: fuse-bpf: Use stored bpf for create_open
  ANDROID: fuse-bpf: Add bpf to negative fuse_dentry
  ANDROID: fuse-bpf: Check inode not null
  ANDROID: fuse-bpf: Fix flock test compile error
  ANDROID: fuse-bpf: Add partial ioctl support
  ANDROID: ABI: Update oplus symbol list
  UPSTREAM: mm/mempolicy: Take VMA lock before replacing policy
  BACKPORT: mm: lock_vma_under_rcu() must check vma->anon_vma under vma lock
  BACKPORT: FROMGIT: irqchip/gic-v3: Workaround for GIC-700 erratum 2941627
  ANDROID: GKI: update xiaomi symbol list
  UPSTREAM: mm: lock newly mapped VMA with corrected ordering
  UPSTREAM: fork: lock VMAs of the parent process when forking
  UPSTREAM: mm: lock newly mapped VMA which can be modified after it becomes visible
  UPSTREAM: mm: lock a vma before stack expansion
  ANDROID: GKI: bring back find_extend_vma()
  BACKPORT: mm: always expand the stack with the mmap write lock held
  BACKPORT: execve: expand new process stack manually ahead of time
  ANDROID: abi_gki_aarch64_qcom: ufshcd_mcq_poll_cqe_lock
  UPSTREAM: mm: make find_extend_vma() fail if write lock not held
  UPSTREAM: powerpc/mm: convert coprocessor fault to lock_mm_and_find_vma()
  UPSTREAM: mm/fault: convert remaining simple cases to lock_mm_and_find_vma()
  UPSTREAM: arm/mm: Convert to using lock_mm_and_find_vma()
  UPSTREAM: riscv/mm: Convert to using lock_mm_and_find_vma()
  UPSTREAM: mips/mm: Convert to using lock_mm_and_find_vma()
  UPSTREAM: powerpc/mm: Convert to using lock_mm_and_find_vma()
  BACKPORT: arch/arm64/mm/fault: Fix undeclared variable error in do_page_fault()
  BACKPORT: arm64/mm: Convert to using lock_mm_and_find_vma()
  UPSTREAM: mm: make the page fault mmap locking killable
  ANDROID: Inherit "user-aware property" across rtmutex.
  BACKPORT: blk-crypto: use dynamic lock class for blk_crypto_profile::lock
  ANDROID: ABI: update symbol list for Xclipse GPU
  ANDROID: drm/ttm: export ttm_tt_unpopulate()
  ANDROID: GKI: Add ABI symbol list(devlink) for MTK
  ANDROID: devlink: Select CONFIG_NET_DEVLINK in Kconfig.gki
  ANDROID: KVM: arm64: Fix memory ordering for pKVM module callbacks
  BACKPORT: mm: introduce new 'lock_mm_and_find_vma()' page fault helper
  BACKPORT: maple_tree: fix potential out-of-bounds access in mas_wr_end_piv()
  UPSTREAM: x86/smp: Cure kexec() vs. mwait_play_dead() breakage
  UPSTREAM: x86/smp: Use dedicated cache-line for mwait_play_dead()
  UPSTREAM: x86/smp: Remove pointless wmb()s from native_stop_other_cpus()
  UPSTREAM: x86/smp: Dont access non-existing CPUID leaf
  UPSTREAM: x86/smp: Make stop_other_cpus() more robust
  UPSTREAM: x86/microcode/AMD: Load late on both threads too
  BACKPORT: mm, hwpoison: when copy-on-write hits poison, take page offline
  UPSTREAM: mm, hwpoison: try to recover from copy-on write faults
  BACKPORT: mm/mmap: Fix error return in do_vmi_align_munmap()
  BACKPORT: mm/mmap: Fix error path in do_vmi_align_munmap()
  UPSTREAM: HID: logitech-hidpp: add HIDPP_QUIRK_DELAYED_INIT for the T651.
  UPSTREAM: HID: hidraw: fix data race on device refcount
  UPSTREAM: can: isotp: isotp_sendmsg(): fix return error fix on TX path
  UPSTREAM: fbdev: fix potential OOB read in fast_imageblit()
  ANDROID: GKI: add function symbols for unisoc
  ANDROID: cgroup: Cleanup android_rvh_cgroup_force_kthread_migration
  UPSTREAM: net/sched: cls_fw: Fix improper refcount update leads to use-after-free
  UPSTREAM: netfilter: nf_tables: fix chain binding transaction logic
  ANDROID: abi_gki_aarch64_qcom: update abi
  UPSTREAM: fs/ntfs3: Check fields while reading
  ANDROID: GKI: Update abi_gki_aarch64_qcom
  ANDROID: ABI: Update pixel symbol list
  ANDROID: GKI: Move GKI module headers to generated includes
  ANDROID: set kmi_symbol_list_add_only for Kleaf builds.
  ANDROID: GKI: Add Android ABI padding to wwan_port_ops
  ANDROID: GKI: Add Android ABI padding to wwan_ops
  ANDROID: update symbol list for unisoc regmap vendor hook
  ANDROID: GKI: Update mtk ABI symbol list
  UPSTREAM: media: dvb-core: Fix kernel WARNING for blocking operation in wait_event*()
  ANDROID: abi_gki_aarch64_qcom: Update QCOM symbol list
  ANDROID: ABI: Update pixel symbol list
  ANDROID: GKI: add ABI symbol for xiaomi
  ANDROID: vendor_hooks: add vendor hook to support SAGT
  FROMLIST: fuse: revalidate: don't invalidate if interrupted
  ANDROID: GKI: Update pixel symbol list for thermal
  ANDROID: thermal: Add vendor thermal genl check
  ANDROID: GKI: Update the pixel symbol list
  ANDROID: GKI: Update protected exports
  FROMGIT: mm: add missing VM_FAULT_RESULT_TRACE name for VM_FAULT_COMPLETED
  FROMGIT: swap: remove remnants of polling from read_swap_cache_async
  UPSTREAM: io_uring/poll: serialize poll linked timer start with poll removal

Change-Id: Ib4aaa987f777d4cdb0897af78aecb19aaee8d68b
Upstream-Build: ks_qcom-android14-6.1-keystone-qcom-release@10801570 UKQ2.230913.001
Signed-off-by: jianzhou <quic_jianzhou@quicinc.com>
2023-09-14 23:00:37 -07:00
qctecmdr
485dc8a77c Merge "Merge keystone/android14-6.1-keystone-qcom-release.6.1.25 (6c948d5) into qcom-6.1" 2023-09-14 04:59:21 -07:00
qctecmdr
9e255d1711 Merge "build: bazel: Enable compilation for Niobe SoC" 2023-09-13 01:29:36 -07:00
qctecmdr
0609fc4d66 Merge "iio: spmi-adc5: Add DT based option to specify scale-fn-type" 2023-09-12 20:10:46 -07:00
qctecmdr
50c0d0722f Merge "serial: msm_geni_serial: Check if workqueue allocation fails" 2023-09-12 20:10:45 -07:00
qctecmdr
90756a8655 Merge "ufs: qcom: Add ESI affinity for the hwq 0" 2023-09-12 20:10:45 -07:00
qctecmdr
c431f7dfe8 Merge "dma-heap: qcom: correct msm_dma_map_sgtable return value" 2023-09-12 11:02:52 -07:00
qctecmdr
ee98c266b0 Merge "slimbus: qcom-ngd-ctrl: Clear enabled IRQ's during power off" 2023-09-12 04:25:29 -07:00
qctecmdr
21099a2c52 Merge "serial: msm_geni_serial: Resource cleanup in rmmod path" 2023-09-12 04:25:28 -07:00
Amrit Anand
814976be07 build: bazel: Enable compilation for Niobe SoC
Add initial files to build Niobe with bazel.

Change-Id: I2c0a2872d589ef6d328088a2b3f879644d8ea60c
Signed-off-by: Amrit Anand <quic_amrianan@quicinc.com>
2023-09-12 15:02:39 +05:30
qctecmdr
9433fc2a02 Merge "clk: qcom: clk-alpha-pll: Snapshot of lucid pll ops update" 2023-09-12 01:58:49 -07:00
qctecmdr
2d62931ed3 Merge "wcd-usbss: Force reset RCO on surge event" 2023-09-12 01:58:49 -07:00
Aniket Randive
3de941672b serial: msm_geni_serial: Check if workqueue allocation fails
Pointer wakeup_irq_wq can be NULL if workqueue allocation
fails and may be dereferenced later.

To avoid this returned error if workqueue allocation fails.

Change-Id: Ic70c862e75c2594171c6a4f165ea87f21524cd40
Signed-off-by: Aniket Randive <quic_arandive@quicinc.com>
2023-09-12 14:18:26 +05:30
Android Build Coastguard Worker
bd65f1be37 Snap for 10793481 from e401e169ba to android14-6.1-keystone-qcom-release
Change-Id: I842c64e6a36cc1d107dced38b253a91335187776
2023-09-12 07:20:29 +00:00
Kassey Li
5f9d49eb40 dma-heap: qcom: correct msm_dma_map_sgtable return value
__alloc_and_insert_iova_range return -ENOMEM  when there is no
suitable size, where dma_buf_map_attachment return -EINVAL which
is not accurate info.

Call trace:
alloc_iova+0x2cc/0x318
alloc_iova_fast+0x190/0x2c4
iommu_dma_alloc_iova+0xc0/0x180
iommu_dma_map_sg+0x1cc/0x3a0
dma_map_sg_attrs+0x44/0xbc
msm_dma_map_sg_attrs+0x398/0x6a4 [msm_dma_iommu_mapping]
qcom_sg_map_dma_buf+0xe4/0x14c [qcom_dma_heaps]
dma_buf_map_attachment+0xcc/0x1d8
fastrpc_mmap_create+0x3a8/0x938 [frpc_adsprpc]
fastrpc_internal_mmap+0x100/0x268 [frpc_adsprpc]
fastrpc_device_ioctl+0x620/0x2078 [frpc_adsprpc]
__arm64_sys_ioctl+0xa8/0xe4
invoke_syscall+0x58/0x11c
el0_svc_common+0xb4/0xf4
do_el0_svc+0x2c/0xb0
el0_svc+0x2c/0xa4
el0t_64_sync_handler+0x68/0xb4
el0t_64_sync+0x1a0/0x1a4

change this to follow upstream usage in
kernel/dma/mapping.c dma_map_sgtable.

Change-Id: I5cec3005a8759de820705c268fef18addb2a8899
Signed-off-by: Kassey Li <quic_yingangl@quicinc.com>
2023-09-12 08:33:31 +08:00
Omkar Sai Sandeep Katadi
e401e169ba Merge remote-tracking branch into HEAD
* keystone/mirror-android14-6.1-2023-08: (162 commits)
  ANDROID: uid_sys_stats: Use llist for deferred work
  UPSTREAM: usb: typec: ucsi: Fix command cancellation
  ANDROID: GKI: update symbol list file for xiaomi
  UPSTREAM: erofs: avoid infinite loop in z_erofs_do_read_page() when reading beyond EOF
  UPSTREAM: erofs: avoid useless loops in z_erofs_pcluster_readmore() when reading beyond EOF
  UPSTREAM: erofs: Fix detection of atomic context
  UPSTREAM: erofs: fix compact 4B support for 16k block size
  UPSTREAM: erofs: kill hooked chains to avoid loops on deduplicated compressed images
  UPSTREAM: erofs: fix potential overflow calculating xattr_isize
  UPSTREAM: erofs: stop parsing non-compact HEAD index if clusterofs is invalid
  UPSTREAM: erofs: initialize packed inode after root inode is assigned
  ANDROID: GKI: Update ABI for zsmalloc fixes
  BACKPORT: zsmalloc: fix races between modifications of fullness and isolated
  UPSTREAM: zsmalloc: consolidate zs_pool's migrate_lock and size_class's locks
  BACKPORT: FROMGIT: mm: handle faults that merely update the accessed bit under the VMA lock
  FROMLIST: mm: Allow fault_dirty_shared_page() to be called under the VMA lock
  FROMGIT: mm: handle swap and NUMA PTE faults under the VMA lock
  FROMGIT: mm: run the fault-around code under the VMA lock
  FROMGIT: mm: move FAULT_FLAG_VMA_LOCK check down from do_fault()
  FROMGIT: mm: move FAULT_FLAG_VMA_LOCK check down in handle_pte_fault()
  ...

Change-Id: Ic33be5a9dae71958c187029751cb599a83110ab9
2023-09-11 22:08:38 +00:00
qctecmdr
1d2894c3cd Merge "Revert "ANDROID: build: Add --nocheck_bzl_visibility"" 2023-09-11 08:16:39 -07:00
Rakesh Kota
af4e33377e iio: spmi-adc5: Add DT based option to specify scale-fn-type
Based on the board designs, same ADC channel for a PMIC may be required
to use with a different scale function.

eg -
PM7250B PMIC's VADC channel for reading slave charger temperature will
require different scaling function to calculate the voltage to
temperature based on the slave charger used on that board(SMB1390/SMB1398).

Add DT based option to specify scale-fn-type to handle such
kind of requirements.

Change-Id: I52d7b8afb5b6b6ef0419740bdb67ed3f48108cde
Signed-off-by: Rakesh Kota <quic_kotarake@quicinc.com>
2023-09-11 04:00:35 -07:00
Ziqi Chen
f32f2cacba ufs: qcom: Add ESI affinity for the hwq 0
Since the dedicated hwq for dev command has been removed
by upstream commit 680cfe91d1 ("UPSTREAM: scsi: ufs:
core: Remove dedicated hwq for dev command"), we need to
add ESI affinity for this hwq.

Change-Id: Ia25ac6d34b78ca2598eb40fc6a1374e4c8704e60
Signed-off-by: Ziqi Chen <quic_ziqichen@quicinc.com>
2023-09-11 02:11:21 -07:00
qctecmdr
448c4d6649 Merge "clk: qcom: dispcc-pineapple: Add support for cliffs platform" 2023-09-11 00:47:48 -07:00
jianzhou
3424390dea Merge keystone/android14-6.1-keystone-qcom-release.6.1.25 (6c948d5) into
qcom-6.1

* refs/heads/tmp-6c948d5:
  ANDROID: GKI: Update ABI for zsmalloc fixes
  BACKPORT: zsmalloc: fix races between modifications of fullness and isolated
  UPSTREAM: zsmalloc: consolidate zs_pool's migrate_lock and size_class's locks
  FROMGIT: usb: host: ehci-sched: try to turn on io watchdog as long as periodic_count > 0
  FROMGIT: BACKPORT: usb: ehci: add workaround for chipidea PORTSC.PEC bug
  UPSTREAM: dma-buf: fix an error pointer vs NULL bug
  UPSTREAM: dma-buf: keep the signaling time of merged fences v3
  FROMGIT: Multi-gen LRU: Fix per-zone reclaim
  UPSTREAM: USB: Gadget: core: Help prevent panic during UVC unconfigure

Change-Id: I6a32e00d90e1cb950fec95db001a7cb01b61ee36
Upstream-Build: ks_qcom-android14-6.1-keystone-qcom-release@10773472
UKQ2.230907.001
Signed-off-by: jianzhou <quic_jianzhou@quicinc.com>
2023-09-10 22:44:23 -07:00
John Moon
3162b9648a Revert "ANDROID: build: Add --nocheck_bzl_visibility"
This reverts commit 71e862d942.

After properly switching to public kleaf APIs, we no longer need to
pass --nocheck_bzl_visibility to the build.

Change-Id: I3ff04efd2cbebdeb176f6b67b099f7a6ff6b2fab
Signed-off-by: John Moon <quic_johmoo@quicinc.com>
2023-09-09 14:00:35 -07:00
John Moon
787b33600b ANDROID: build: Switch to Kleaf super_image implementation
Currently, we use an in-tree definition of the super_image rule to
generate our super.img files. This rule depends on a private kleaf
API which is no longer visible to msm-kernel after an upstream
change.

To fix, we've upstreamed the super_image rule to kleaf which allows
usage of the private API. Accordingly, we need to make an update here
which uses the new super_image API from kleaf.

Change-Id: Ie904958a773061c83e33190cc9ad89a5467c738e
Signed-off-by: John Moon <quic_johmoo@quicinc.com>
2023-09-09 11:40:10 -07:00
qctecmdr
0f32661228 Merge "qcom: sysmon: Add support to skip transaction_id on old ssctl event" 2023-09-09 03:31:10 -07:00
qctecmdr
82f4bbd352 Merge "drivers: dcvs: pmu_lib: Pass physical CPUs to CPUCP" 2023-09-09 03:31:10 -07:00
qctecmdr
0c2f2f2893 Merge "serial: msm_geni_serial: check ioctl_count with auto_suspend enabled" 2023-09-09 03:31:09 -07:00
qctecmdr
97b216f3dd Merge "mpm: update config flag check for msm_mpm_enter_sleep" 2023-09-09 03:31:09 -07:00
qctecmdr
a5ffb04fa8 Merge "serial: msm_geni_serial: reconfigure baud rate and port setup" 2023-09-09 03:31:09 -07:00
qctecmdr
922f68faaf Merge "power: supply: Fix pmic-voter list duplication issue on kernel-6.1" 2023-09-09 03:31:08 -07:00
qctecmdr
512d0d96f9 Merge "drivers: Restore kaslr offset during hibernation" 2023-09-09 03:31:07 -07:00
qctecmdr
b5cf721e17 Merge "virt: gunyah: Pin every page in a contiguous block" 2023-09-09 01:15:58 -07:00
qctecmdr
5166dd1c79 Merge "soc: qcom: socinfo: Add soc-id support for Niobe" 2023-09-09 01:15:58 -07:00
qctecmdr
61d99e5c31 Merge "i2c: i2c-msm-geni: Add shutdown callback for i2c" 2023-09-09 01:15:57 -07:00
qctecmdr
46db71fc58 Merge "soc: qcom: Add insufficient memory check in cdsprm driver" 2023-09-09 01:15:57 -07:00
qctecmdr
4c273052b1 Merge "serial: msm_geni_serial: Make HW Flow off if CRSTCTS flag not set" 2023-09-09 01:15:56 -07:00
qctecmdr
a3035fa1f7 Merge "slimbus: qcom-ngd: Handle SSR and xfer message scenario" 2023-09-09 01:15:56 -07:00
John Stultz
f580df859b ANDROID: uid_sys_stats: Use llist for deferred work
A use-after-free bug was found in the previous custom lock-free list
implementation for the deferred work, so switch functionality to llist
implementation.

While the previous approach atomically handled the list head, it did not
assure the new node's next pointer was assigned before the head was
pointed to the node, allowing the consumer to traverse to an invalid
next pointer.

Additionally, in switching to llists, this patch pulls the entire list
off the list head once and processes it separately, reducing the number
of atomic operations compared with the custom lists's implementation
which pulled one node at a time atomically from the list head.

BUG: KASAN: use-after-free in process_notifier+0x270/0x2dc
Write of size 8 at addr d4ffff89545c3c58 by task Blocking Thread/3431
Pointer tag: [d4], memory tag: [fe]

call trace:
 dump_backtrace+0xf8/0x118
 show_stack+0x18/0x24
 dump_stack_lvl+0x60/0x78
 print_report+0x178/0x470
 kasan_report+0x8c/0xbc
 kasan_tag_mismatch+0x28/0x3c
 __hwasan_tag_mismatch+0x30/0x60
 process_notifier+0x270/0x2dc
 notifier_call_chain+0xb4/0x108
 blocking_notifier_call_chain+0x54/0x80
 profile_task_exit+0x20/0x2c
 do_exit+0xec/0x1114
 __arm64_sys_exit_group+0x0/0x24
 get_signal+0x93c/0xa78
 do_notify_resume+0x158/0x3fc
 el0_svc+0x54/0x78
 el0t_64_sync_handler+0x44/0xe4
 el0t_64_sync+0x190/0x194

Bug: 294468796
Bug: 295787403
Bug: 299197985
Fixes: 8e86825eec ("ANDROID: uid_sys_stats: Use a single work for deferred updates")
Change-Id: Id377348c239ec720a5237726bc3632544d737e3b
Signed-off-by: John Stultz <jstultz@google.com>
[nkapron: Squashed with other changes and rewrote the commit message]
Signed-off-by: Neill Kapron <nkapron@google.com>
(cherry picked from commit 87647c0c54)
2023-09-08 11:11:08 +00:00
qctecmdr
9a79ef7f41 Merge "ANDROID: build: Add --nocheck_bzl_visibility" 2023-09-08 02:11:44 -07:00
Android Build Coastguard Worker
cdaa28e9b7 Snap for 10779591 from 4bf8da8992 to android14-6.1-keystone-qcom-release
Change-Id: I3614c815e6a9f3fff787b89a79bc7998ad2d8977
2023-09-08 07:35:41 +00:00
Prakruthi Deepak Heragu
783de06308 virt: gunyah: Pin every page in a contiguous block
Pin all the pages when physically contiguous pages are coalesced.

Change-Id: I91bc45130dd63a45b4e84f1de847db85ef5efacc
Signed-off-by: Prakruthi Deepak Heragu <quic_pheragu@quicinc.com>
2023-09-07 22:06:29 -07:00
Kalpak Kawadkar
48e93f459e clk: qcom: clk-alpha-pll: Snapshot of lucid pll ops update
Snapshot of updating lucid prepare callback to check pll calibration
status properly. Also add logic to properly slew the PLL when
HW_UPDATE_LOGIC_BYPASS bit is not set
commit 6e270ebf5893 ("clk: qcom: clk-alpha-pll: Update the lucid
pll ops").

Change-Id: I4ae488d8df6e60dcefdddcc3ab2a696f66e4a594
Signed-off-by: Kalpak Kawadkar <quic_kkawadka@quicinc.com>
2023-09-07 20:46:34 -07:00
Elliot Berman
4bf8da8992 Merge "ANDROID: consolidate.fragment: Enable slub debug in consolidate-fragment" into android14-6.1-keystone-qcom-dev 2023-09-07 15:10:06 +00:00
Visweswara Tanuku
bca469ebff i2c: i2c-msm-geni: Add shutdown callback for i2c
If the hardware is still accessing memory after SMMU translation
is disabled (as part of smmu shutdown callback), then the
IOVAs (I/O virtual address) which it was using will go on the bus
as the physical addresses which will result in unknown crashes
like NoC/interconnect errors.

So, implement shutdown callback for i2c driver to suspend the bus
during system "reboot" or "shutdown".

Change-Id: I58b719082a8d8beed4317b33691115c9e7031ec1
Signed-off-by: Srikanth Nanavalla <quic_snanaval@quicinc.com>
Signed-off-by: Visweswara Tanuku <quic_vtanuku@quicinc.com>
2023-09-07 07:40:15 -07:00
qctecmdr
cabc322a44 Merge "memshare: Prevent possible integer overflow" 2023-09-06 23:52:07 -07:00
qctecmdr
c5969be0f3 Merge "pinctrl: Add support in VM for Cliffs SoC" 2023-09-06 23:52:07 -07:00
qctecmdr
d71e3b7116 Merge "ANDROID: build: avb_boot_img: Use hermetic tools" 2023-09-06 23:52:06 -07:00
qctecmdr
c41ded12ac Merge "i2c: i2c-msm-geni: handle clear of tx water mark" 2023-09-06 23:52:06 -07:00
Amrit Anand
81b0ce73a5 soc: qcom: socinfo: Add soc-id support for Niobe
Add niobe target support to SoC name-id mapping list.

Change-Id: I1a881f3104ebac4387eb53ac0b88178ed0b71b58
Signed-off-by: Amrit Anand <quic_amrianan@quicinc.com>
2023-09-06 20:33:08 -07:00
Venkatakrishnaiah Pari
63c9ac8dbd drivers: Restore kaslr offset during hibernation
kaslr offset in IMEM is required to decode the ram dumps with
kaslr enabled kernel. Add hibernation callback to update IMEM cookie
during hibernation restore. Use syscore callbacks in this
case to restore the value as soon as possible.

Change-Id: I3fe618c56385362e796e52deb423a035f0e03707
Signed-off-by: Venkatakrishnaiah Pari <quic_vpari@quicinc.com>
Signed-off-by: Shreyas K K <quic_shrekk@quicinc.com>
2023-09-06 20:02:20 -07:00
Shreyas K K
c767d68585 soc: qcom: memory_dump: Restore memory_dump table during hibernation
Add hibernation callback to reinitialize memory_dump table
in IMEM during hibernation restore. Use syscore callbacks in
this case to reinitialize the value as soon as possible.

Change-Id: I243a354ce6ccb9f349684eb9b649d43d5b3ed519
Signed-off-by: Arun KS <arunks@codeaurora.org>
Signed-off-by: Shreyas K K <quic_shrekk@quicinc.com>
2023-09-06 20:01:58 -07:00