* Fix compilation warnings while using GCC LTO
In function 'eir_append_data',
inlined from 'read_local_oob_ext_data_complete' at ../net/bluetooth/mgmt.c:5741:13:
../net/bluetooth/hci_request.h:116:2: warning: writing 16 bytes into a region of size 1 [-Wstringop-overflow=]
116 | memcpy(&eir[eir_len], data, data_len);
| ^
../net/bluetooth/mgmt.c: In function 'read_local_oob_ext_data_complete':
../include/net/bluetooth/mgmt.h:517: note: at offset 0 to object 'eir' with size 1 declared here
517 | __u8 eir[1];
|
In function 'eir_append_data',
inlined from 'read_local_oob_ext_data_complete' at ../net/bluetooth/mgmt.c:5743:13:
../net/bluetooth/hci_request.h:116:2: warning: writing 16 bytes into a region of size 1 [-Wstringop-overflow=]
116 | memcpy(&eir[eir_len], data, data_len);
| ^
../net/bluetooth/mgmt.c: In function 'read_local_oob_ext_data_complete':
../include/net/bluetooth/mgmt.h:517: note: at offset 0 to object 'eir' with size 1 declared here
517 | __u8 eir[1];
|
In function 'wlan_hdd_add_age_ie',
inlined from 'wlan_hdd_inform_bss_frame' at ../drivers/staging/qcacld-3.0/core/hdd/src/wlan_hdd_cfg80211.c:19244:2:
../drivers/staging/qcacld-3.0/core/hdd/src/wlan_hdd_cfg80211.c:19167:2: warning: writing 8 bytes into a region of size 0 [-Wstringop-overflow=]
19167 | memcpy(&qie_age->beacon_tsf, bss_desc->timeStamp,
| ^
../drivers/staging/qcacld-3.0/core/hdd/src/wlan_hdd_cfg80211.c: In function 'wlan_hdd_inform_bss_frame':
../include/linux/ieee80211.h:952: note: at offset 0 to object 'variable' with size 0 declared here
952 | u8 variable[0];
|
In function 'wlan_hdd_add_age_ie',
inlined from 'wlan_hdd_inform_bss_frame' at ../drivers/staging/qcacld-3.0/core/hdd/src/wlan_hdd_cfg80211.c:19244:2:
../drivers/staging/qcacld-3.0/core/hdd/src/wlan_hdd_cfg80211.c:19169:2: warning: writing 2 bytes into a region of size 0 [-Wstringop-overflow=]
19169 | memcpy(&qie_age->seq_ctrl, &bss_desc->seq_ctrl,
| ^
../drivers/staging/qcacld-3.0/core/hdd/src/wlan_hdd_cfg80211.c: In function 'wlan_hdd_inform_bss_frame':
../include/linux/ieee80211.h:952: note: at offset 0 to object 'variable' with size 0 declared here
952 | u8 variable[0];
|
../kernel/bpf/core.c: In function 'bpf_patch_insn_single':
../kernel/bpf/core.c:257:3: warning: writing 8 bytes into a region of size 0 [-Wstringop-overflow=]
257 | memcpy(prog->insnsi + off, patch, sizeof(*patch));
| ^
../include/linux/filter.h:474:19: note: at offset 0 to object 'insnsi' with size 0 declared here
474 | struct bpf_insn insnsi[0];
| ^
In function 'bpf_patch_insn_single',
inlined from 'bpf_patch_insn_data' at ../kernel/bpf/verifier.c:4581:13:
../kernel/bpf/core.c:257:3: warning: writing 8 bytes into a region of size 0 [-Wstringop-overflow=]
257 | memcpy(prog->insnsi + off, patch, sizeof(*patch));
| ^
../kernel/bpf/verifier.c: In function 'bpf_patch_insn_data':
../include/linux/filter.h:474:19: note: at offset 0 to object 'insnsi' with size 0 declared here
474 | struct bpf_insn insnsi[0];
Signed-off-by: UtsavBalar1231 <utsavbalar1231@gmail.com>