Replace all the occurrences of FIELD_SIZEOF() with sizeof_field() except
at places where these are defined. Later patches will remove the unused
definition of FIELD_SIZEOF().
This patch is generated using following script:
EXCLUDE_FILES="include/linux/stddef.h|include/linux/kernel.h"
git grep -l -e "\bFIELD_SIZEOF\b" | while read file;
do
if [[ "$file" =~ $EXCLUDE_FILES ]]; then
continue
fi
sed -i -e 's/\bFIELD_SIZEOF\b/sizeof_field/g' $file;
done
Change-Id: I24296633f28fea05d12618c8e47dc8acb8df18d8
Signed-off-by: Pankaj Bharadiya <pankaj.laxminarayan.bharadiya@intel.com>
Link: https://lore.kernel.org/r/20190924105839.110713-3-pankaj.laxminarayan.bharadiya@intel.com
Co-developed-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Kees Cook <keescook@chromium.org>
Acked-by: David Miller <davem@davemloft.net> # for net
* sm8250/lineage-20:
msm: camera: Fix isp_vma_fault function signature
msm: ipa2: Fix ipa_nat_vma_fault_remap function signature
UPSTREAM: ipv4: Fix NULL pointer dereference in ipv4_neigh_lookup()
UPSTREAM: ipv4: remove sparse error in ip_neigh_gw4()
UPSTREAM: net: ipv4: Fix NULL pointer dereference in route lookup
BACKPORT: gre: Don't accidentally set RTO_ONLINK in gre_fill_metadata_dst()
UPSTREAM: net: add missing READ_ONCE(sk->sk_rcvbuf) annotation
UPSTREAM: bpf: Sockmap/tls, fix pop data with SK_DROP return code
UPSTREAM: bpf: net: Set sk_bpf_storage back to NULL for cloned sk
UPSTREAM: net: set SOCK_RCU_FREE before inserting socket into hashtable
UPSTREAM: bpf: Fix bpf socket lookup from tc/xdp to respect socket VRF bindings
UPSTREAM: udp: Set SOCK_RCU_FREE earlier in udp_lib_get_port().
BACKPORT: apparmor: Use pointer to struct aa_label for lbs_cred
BACKPORT: lockdown: Allow unprivileged users to see lockdown status
BACKPORT: LSM: add SafeSetID module that gates setid calls
UPSTREAM: LSM: fix return value check in safesetid_init_securityfs()
UPSTREAM: security, lsm: dentry_init_security() Handle multi LSM registration
BACKPORT: lsm: fix default return value of the socket_getpeersec_*() hooks
BACKPORT: lsm: make security_socket_getpeersec_stream() sockptr_t safe
UPSTREAM: lsm: fix default return value for vm_enough_memory
...
Change-Id: Ib23bc908253fd652d5e2fa0a7bea189c0d475a86
Return type of ext4_page_mkwrite and ext4_filemap_fault are
changed to use vm_fault_t type.
With this patch all the callers of block_page_mkwrite_return()
are changed to handle vm_fault_t. So converting the return type
of block_page_mkwrite_return() to vm_fault_t.
Add these changes for msm drivers as well.
Change-Id: I4a274cc17da41dfbe34f4eaefff22db4a1754329
Signed-off-by: Souptick Joarder <jrdr.linux@gmail.com>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Reviewed-by: Matthew Wilcox <willy@infradead.org>
* Include bathena device to build this module.
* Clean-up Makefile to avoid duplicate modules.
* Use guamauto.conf / guamautoconf.h to build.
Co-authored-by: Deivid21 <david.parra.ignacio@gmail.com>
Change-Id: Ib606ce7d4ef37a40e445eab03868a313f4ffdf2b
* sm8250/lineage-20:
Revert "ANDROID: modpost: add an exception for CFI stubs"
ANDROID: Update CFI patchset from android11-5.4
ANDROID: adding __nocfi to cpuidle_enter_state
ANDROID: arm64: Fix the address of ftrace_call compiled with CFI_CLANG
ANDROID: arm64: add __va_function
arm64: bpf: Don't use module memory for the BPF JIT CFI check.
arm64/bpf: don't allocate BPF JIT programs in module memory
bpf: add __weak hook for allocating executable memory
clk/qcom/clk-alpha-pll: Fix pll post div mask when width is not set
bpf: Use dedicated bpf_trace_printk event instead of trace_printk()
BACKPORT: audio-kernel: Disable clock voting logs
msm: kgsl: introduce CONFIG_CORESIGHT_ADRENO.
Change-Id: I6ea6bdae1d2efa2be9620b5f68d9ae7e78dcdf4a
trace_printk is recommended for debugging purpose as it
requires temporary memory to handle strings. If used
anywhere within the kernel, memory will be allocated to it.
Hence removed it to avoid any unnecessary memory allocation.
Change-Id: If7b0cada91c97b21987f91e0ff7b7a15ce2145e2
Signed-off-by: Faiz Nabi Kuchay <quic_fkuchay@quicinc.com>
Signed-off-by: Hridaya Prajapati <info.hridayaprajapati@gmail.com>
* sm8250/lineage-20:
qcacld-5.0: Fix the possible OOB write in country IE unpack
disp: msm: dsi: add null pointer check in dsi_display_dev_remove
Change-Id: I0067d570daaf449d58b6e6be6630c303cb3cb0aa
* sm8250/lineage-20:
ANDROID: android-verity: Prevent double-freeing metadata
UPSTREAM: f2fs: fix UAF in f2fs_available_free_memory
msm: ipa2: Add check to validate rule_cnt
msm: eva: Copy back the validated size to avoid security issue
msm: adsprpc: Avoid double free on map
msm: npu: Fix use after free issue
msm: npu: Fix use after free issue
clk: qcom: lpasscc-scuba: Add Support for AON & AUDIO clock drivers
dt-bindings: clk: lpasscc-scuba: Add support for LPASS AONCC and AUDIOCC
msm: ipa: clean up netdev resources in AFTER_SHUTDOWN cb
msm: camera: isp: Copy the userdata in kernel to avoid TOCTOU
asoc: codec: avoid out of bound write to map array
asoc: codec: avoid out of bound write to map array
Slimbus: slim-msm-ngd: Avoid accessing deallocated stack
dsp: q6voice: Changing data type from %d to %ld
dsp: q6voice: Add buf size check for cvp cal data
Change-Id: I82dc4d87d7cfe64c21a014d59d318fd5dd7e65c0
"LA.UM.9.15.2.r1-11100-KAMORTA.QSSI14.0"
* tag 'LA.UM.9.15.2.r1-11100-KAMORTA.QSSI14.0' of https://git.codelinaro.org/clo/la/platform/vendor/opensource/audio-kernel:
asoc: codec: avoid out of bound write to map array
asoc: codec: avoid out of bound write to map array
dsp: q6voice: Changing data type from %d to %ld
dsp: q6voice: Add buf size check for cvp cal data
Conflicts:
techpack/audio/asoc/codecs/wcd938x/wcd938x.c
Change-Id: I7d1385928f2945ca39e10a6d5a8b7cc497ea9d26
LA.UM.9.12.r1-18500-SMxx50.QSSI14.0
* tag 'LA.UM.9.12.r1-18500-SMxx50.QSSI14.0' of https://git.codelinaro.org/clo/la/platform/vendor/opensource/camera-kernel:
msm: camera: sensor: handling condition for random read
msm: camera: memmgr: Remove the mutex lock for kref variable
Change-Id: If9f25f4c833965e83ea19a60de3bbd515dc81144
* sm8250/lineage-20:
Revert "ANDROID: ALSA: jack: Update supported jack switch types"
Revert "ALSA: jack: Add support to report second microphone"
ASOC: Remove support for ANC headphones
qcacmn: Update no. of DWORDs for htt_tx_msdu_desc_ext2_t
Change-Id: Ice64d788ffdc579eb2788f4f40e9eb0e6220b0ea
ANC headphones are no longer supported, removed dead code related to the feature.
Change-Id: I3dd51b5b1d9f77fd870947608f8a14fc3f7aeed0
Signed-off-by: Akhil Karuturi <akarutur@codeaurora.org>
"LA.UM.9.15.2.r1-10600-KAMORTA.QSSI14.0"
* tag 'LA.UM.9.15.2.r1-10600-KAMORTA.QSSI14.0' of https://git.codelinaro.org/clo/la/platform/vendor/opensource/camera-kernel:
msm: camera: memmgr: Remove the mutex lock for kref variable
msm: camera: memmgr: Add refcount to track umd in use buffers
msm: camera: sensor: Handling race condition in util api
msm: camera: common: Fix possible OOB reads and writes operations
Change-Id: Ic30b7c9d5683965ee182c28681387a9725a83b17
"LA.UM.9.15.2.r1-10600-KAMORTA.QSSI14.0"
* tag 'LA.UM.9.15.2.r1-10600-KAMORTA.QSSI14.0' of https://git.codelinaro.org/clo/la/platform/vendor/opensource/audio-kernel:
dsp: q6lsm: Check size of payload before access
asoc: codecs: Fix for the SSR issue on qcm2150
dsp: q6voice: Adds checks for an integer overflow
asoc: Fix out-of-bound write
dsp: q6voice: Adds checks for an integer overflow
Fix for OOB access issue
dsp: q6lsm: Check size of payload before access
Change-Id: I708a0be36841731d8c5126b8135123b642a8a7d7
"LA.UM.9.12.1.r1-09700-SMxx50.QSSI12.0"
* tag 'LA.UM.9.12.1.r1-09700-SMxx50.QSSI12.0' of https://git.codelinaro.org/clo/la/platform/vendor/opensource/audio-kernel:
dsp: q6voice: Adds checks for an integer overflow
asoc: Fix out-of-bound write
dsp: q6voice: Adds checks for an integer overflow
dsp: q6lsm: Check size of payload before access
Fix for OOB access issue
Audio legacy: Integer overflow in msm_lsm_ioctl_compat during audio playback usecase. size = sizeof(p_info_32) + p_info_32.param_size; This overflow issue may result heap overflow during copying the data: memcpy(param_info_rsp, &p_info_32, sizeof(p_info_32));
ASoC: Resolve use after free in listen sound client
dsp: q6lsm: Add check for payload buffer
ASoC: msm-pcm-voip: Avoid interger underflow
soc: swr-mstr: Store and compare dev_addr along with dev_num
Conflicts:
techpack/audio/asoc/msm-compress-q6-v2.c
techpack/audio/asoc/msm-pcm-routing-v2.c
Change-Id: I76045565c18bea94657ac7bbb46a49058f108f8d
* sm8250/lineage-20:
arm64: cputype: Remove duplicate A77 definitions
qcacld-3.0: Remove use-after-free of frame in tx mgmt send
smcinvoke: Rename size_add to smci_size_add
video: driver: Return proper error code
video: driver: Return proper error code
Linux 4.19.322
Revert "parisc: Use irq_enter_rcu() to fix warning at kernel/context_tracking.c:367"
netns: restore ops before calling ops_exit_list
cx82310_eth: fix error return code in cx82310_bind()
net, sunrpc: Remap EPERM in case of connection failure in xs_tcp_setup_socket
rtmutex: Drop rt_mutex::wait_lock before scheduling
drm/i915/fence: Mark debug_fence_free() with __maybe_unused
drm/i915/fence: Mark debug_fence_init_onstack() with __maybe_unused
ACPI: processor: Fix memory leaks in error paths of processor_add()
ACPI: processor: Return an error if acpi_processor_get_info() fails in processor_add()
ila: call nf_unregister_net_hooks() sooner
netns: add pre_exit method to struct pernet_operations
nilfs2: protect references to superblock parameters exposed in sysfs
nilfs2: replace snprintf in show functions with sysfs_emit
tracing: Avoid possible softlockup in tracing_iter_reset()
...
Change-Id: I7954f59d42b987203aacc473a6637bc792b68a79
Return correct error code when session
is not supported since remaining memory
is not sufficient to proceed current session
Bug: 273301608
Test: CtsMediaMiscTestCases:android.media.misc.cts.ResourceManagerTest#testAVCVideoCodecReclaimHighResolution
Change-Id: Ib989b7ad41606303f2ff3359768105b10cf9393d
Return correct error code when session
is not supported when max mbpf limit
is reached.
Bug: 273301608
Test: CtsMediaMiscTestCases android.media.misc.cts.ResourceManagerTest#testReclaimResourceMixVsNonsecureHighResolution
Change-Id: I50739758df36d534970101977a1f64a465ba3e77
Cross-checked with msm-4.14 and msm-5.15 tags. The change does not exist
as a separate commit and is squashed into the initial import.
Change-Id: Ib3defedf0fbd5b7cdccdfba26383313ff05b4ef0
Signed-off-by: Alexander Winkowski <dereference23@outlook.com>
Cross-checked with msm-5.15 tag. The change does not exist as a separate
commit and is squashed into the initial import.
Change-Id: Ie922c512d7ea24661d3179cfd156ab8eb6fcc363
Signed-off-by: Alexander Winkowski <dereference23@outlook.com>
During Dynamic mode switch case, input_register_handler
is called even after it is registered leading to
list double add warnings and panic.
Change-Id: I312112deb08c998af516252f2117bc629eb13b37
* sm8250/lineage-20:
BACKPORT: memshare: Prevent possible integer overflow
erofs: fix lz4 inplace decompression
Revert "erofs: support decompress big pcluster for lz4 backend"
erofs: ensure that the post-EOF tails are all zeroed
erofs: fix compact 4B support for 16k block size
erofs: avoid infinite loop in z_erofs_do_read_page() when reading beyond EOF
erofs: fix potential overflow calculating xattr_isize
erofs: stop parsing non-compact HEAD index if clusterofs is invalid
erofs: avoid consecutive detection for Highmem memory
qcacmn: Fix out of bound read issue in ESP ie parse
soc: qcom: smem: Add boundary checks for partitions
msm: camera: sensor: Proper handling of race condition in util api
msm: kgsl: Do not release dma and anon buffers if unmap fails
msm: kgsl: Keep the timeline fence valid for logging
msm: camera: sensor: Proper handling of race condition in util api
fw-api: CL 25873460 - update fw common interface files
fw-api: CL 25869885 - update fw common interface files
fw-api: CL 25866433 - update fw common interface files
fw-api: CL 25840790 - update fw common interface files
fw-api: CL 25839627 - update fw common interface files
...
Change-Id: I579ac7798efc4d829d213516580746b1f2adc748