Re: [PATCH 3/3 V2] KVM, SEV: Add support for SEV-ES intra host migration
by Dan Carpenter
Hi Peter,
url: https://github.com/0day-ci/linux/commits/Peter-Gonda/Add-AMD-SEV-and-SEV-...
base: 7caa04b36f204a01dac65582b71d26d190a1e022
config: x86_64-randconfig-m001-20210714 (attached as .config)
compiler: gcc-10 (Debian 10.2.1-6) 10.2.1 20210110
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Reported-by: Dan Carpenter <dan.carpenter(a)oracle.com>
New smatch warnings:
arch/x86/kvm/svm/sev.c:1253 create_vmsa_list() warn: possible memory leak of 'node'
Old smatch warnings:
arch/x86/kvm/svm/sev.c:1607 sev_send_update_data() warn: maybe return -EFAULT instead of the bytes remaining?
vim +/node +1253 arch/x86/kvm/svm/sev.c
bec8b6143b5a9c Peter Gonda 2021-07-14 1211 static int create_vmsa_list(struct kvm *kvm,
bec8b6143b5a9c Peter Gonda 2021-07-14 1212 struct sev_info_migration_node *entry)
bec8b6143b5a9c Peter Gonda 2021-07-14 1213 {
bec8b6143b5a9c Peter Gonda 2021-07-14 1214 int i;
bec8b6143b5a9c Peter Gonda 2021-07-14 1215 const int num_vcpus = atomic_read(&kvm->online_vcpus);
bec8b6143b5a9c Peter Gonda 2021-07-14 1216 struct vmsa_node *node;
bec8b6143b5a9c Peter Gonda 2021-07-14 1217 struct kvm_vcpu *vcpu;
bec8b6143b5a9c Peter Gonda 2021-07-14 1218 struct vcpu_svm *svm;
bec8b6143b5a9c Peter Gonda 2021-07-14 1219
bec8b6143b5a9c Peter Gonda 2021-07-14 1220 INIT_LIST_HEAD(&entry->vmsa_list);
bec8b6143b5a9c Peter Gonda 2021-07-14 1221 for (i = 0; i < num_vcpus; ++i) {
bec8b6143b5a9c Peter Gonda 2021-07-14 1222 node = kzalloc(sizeof(*node), GFP_KERNEL);
bec8b6143b5a9c Peter Gonda 2021-07-14 1223 if (!node)
bec8b6143b5a9c Peter Gonda 2021-07-14 1224 goto e_freelist;
bec8b6143b5a9c Peter Gonda 2021-07-14 1225
bec8b6143b5a9c Peter Gonda 2021-07-14 1226 vcpu = kvm->vcpus[i];
bec8b6143b5a9c Peter Gonda 2021-07-14 1227 if (!vcpu->arch.guest_state_protected)
bec8b6143b5a9c Peter Gonda 2021-07-14 1228 goto e_freelist;
kfree(node) before the goto.
bec8b6143b5a9c Peter Gonda 2021-07-14 1229
bec8b6143b5a9c Peter Gonda 2021-07-14 1230 node->vcpu_id = vcpu->vcpu_id;
bec8b6143b5a9c Peter Gonda 2021-07-14 1231 svm = to_svm(vcpu);
bec8b6143b5a9c Peter Gonda 2021-07-14 1232 node->vmsa = svm->vmsa;
bec8b6143b5a9c Peter Gonda 2021-07-14 1233 svm->vmsa = NULL;
bec8b6143b5a9c Peter Gonda 2021-07-14 1234 node->ghcb = svm->ghcb;
bec8b6143b5a9c Peter Gonda 2021-07-14 1235 svm->ghcb = NULL;
bec8b6143b5a9c Peter Gonda 2021-07-14 1236 node->ghcb_gpa = svm->vmcb->control.ghcb_gpa;
bec8b6143b5a9c Peter Gonda 2021-07-14 1237 node->ghcb_sa = svm->ghcb_sa;
bec8b6143b5a9c Peter Gonda 2021-07-14 1238 svm->ghcb_sa = NULL;
bec8b6143b5a9c Peter Gonda 2021-07-14 1239 node->ghcb_sa_len = svm->ghcb_sa_len;
bec8b6143b5a9c Peter Gonda 2021-07-14 1240 svm->ghcb_sa_len = 0;
bec8b6143b5a9c Peter Gonda 2021-07-14 1241 node->ghcb_sa_sync = svm->ghcb_sa_sync;
bec8b6143b5a9c Peter Gonda 2021-07-14 1242 svm->ghcb_sa_sync = false;
bec8b6143b5a9c Peter Gonda 2021-07-14 1243 node->ghcb_sa_free = svm->ghcb_sa_free;
bec8b6143b5a9c Peter Gonda 2021-07-14 1244 svm->ghcb_sa_free = false;
bec8b6143b5a9c Peter Gonda 2021-07-14 1245
bec8b6143b5a9c Peter Gonda 2021-07-14 1246 list_add_tail(&node->list, &entry->vmsa_list);
bec8b6143b5a9c Peter Gonda 2021-07-14 1247 }
bec8b6143b5a9c Peter Gonda 2021-07-14 1248
bec8b6143b5a9c Peter Gonda 2021-07-14 1249 return 0;
bec8b6143b5a9c Peter Gonda 2021-07-14 1250
bec8b6143b5a9c Peter Gonda 2021-07-14 1251 e_freelist:
bec8b6143b5a9c Peter Gonda 2021-07-14 1252 process_vmsa_list(kvm, &entry->vmsa_list);
bec8b6143b5a9c Peter Gonda 2021-07-14 @1253 return -1;
bec8b6143b5a9c Peter Gonda 2021-07-14 1254 }
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
[android-common:android12-5.10 1/1] include/trace/hooks/typec.h:20:1: sparse: sparse: incorrect type in assignment (different address spaces)
by kernel test robot
tree: https://android.googlesource.com/kernel/common android12-5.10
head: abbebf1a3e6ab5a14cf34a2fe03dba7e10c2cf2c
commit: abbebf1a3e6ab5a14cf34a2fe03dba7e10c2cf2c [1/1] ANDROID: usb: typec: tcpci: Migrate restricted vendor hook
config: x86_64-randconfig-s021-20210720 (attached as .config)
compiler: gcc-10 (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
git remote add android-common https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android12-5.10
git checkout abbebf1a3e6ab5a14cf34a2fe03dba7e10c2cf2c
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
include/trace/hooks/sched.h:199:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:199:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:199:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:203:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:203:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:203:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:207:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:207:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:207:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:211:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:211:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:211:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:215:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:215:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:215:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:219:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:219:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:219:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:235:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:235:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:235:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:239:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:239:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:239:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:244:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:244:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:244:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:249:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:249:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:249:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:263:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:263:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:263:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:271:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:271:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:271:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:274:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:274:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:274:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:277:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:277:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:277:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:281:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:281:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:281:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/cpufreq.h):
include/trace/hooks/cpufreq.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/cpufreq.h:23:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/cpufreq.h:23:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/mm.h):
include/trace/hooks/mm.h:16:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:16:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:16:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/preemptirq.h):
include/trace/hooks/preemptirq.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:18:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:18:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:18:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:26:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:26:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:26:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/bug.h):
include/trace/hooks/bug.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/bug.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/bug.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/fault.h):
include/trace/hooks/fault.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:15:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:15:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:23:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:23:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:27:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:27:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:27:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/traps.h):
include/trace/hooks/traps.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:15:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:15:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/traps.h:20:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:20:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:20:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/traps.h:24:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:24:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:24:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/typec.h):
>> include/trace/hooks/typec.h:20:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/typec.h:20:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/typec.h:20:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/typec.h:31:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/typec.h:31:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/typec.h:31:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
vim +20 include/trace/hooks/typec.h
15
16 DECLARE_HOOK(android_vh_typec_tcpci_override_toggling,
17 TP_PROTO(struct tcpci *tcpci, struct tcpci_data *data, int *override_toggling),
18 TP_ARGS(tcpci, data, override_toggling));
19
> 20 DECLARE_RESTRICTED_HOOK(android_rvh_typec_tcpci_chk_contaminant,
21 TP_PROTO(struct tcpci *tcpci, struct tcpci_data *data, int *ret),
22 TP_ARGS(tcpci, data, ret), 1);
23
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
[android-common:android12-5.10 1/2] include/trace/hooks/traps.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces)
by kernel test robot
tree: https://android.googlesource.com/kernel/common android12-5.10
head: 2c728929c10e91152babdf6e4ab8db1aeeeb2908
commit: 9108e9ba66fe26ed7d896febb70b8afafcc2b70f [1/2] ANDROID: arm64: add vendor hooks for unusal abort cases
config: x86_64-randconfig-s021-20210720 (attached as .config)
compiler: gcc-10 (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
git remote add android-common https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android12-5.10
git checkout 9108e9ba66fe26ed7d896febb70b8afafcc2b70f
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
include/trace/hooks/sched.h:175:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:179:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:179:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:179:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:183:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:183:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:183:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:187:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:187:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:187:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:192:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:192:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:192:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:196:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:196:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:196:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:200:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:200:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:200:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:204:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:204:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:204:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:209:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:209:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:209:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:213:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:213:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:213:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:217:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:217:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:217:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:221:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:221:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:221:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:225:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:225:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:225:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:229:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:229:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:229:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:245:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:245:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:245:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:249:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:249:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:249:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:254:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:254:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:254:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:259:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:259:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:259:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:273:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:273:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:273:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/cpufreq.h):
include/trace/hooks/cpufreq.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/cpufreq.h:23:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/cpufreq.h:23:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/mm.h):
include/trace/hooks/mm.h:16:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:16:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:16:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/preemptirq.h):
include/trace/hooks/preemptirq.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:18:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:18:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:18:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:26:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:26:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:26:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/bug.h):
include/trace/hooks/bug.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/bug.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/bug.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/fault.h):
include/trace/hooks/fault.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:15:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:15:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:23:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:23:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:27:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:27:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:27:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/traps.h):
>> include/trace/hooks/traps.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:15:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:15:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/traps.h:20:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:20:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:20:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/traps.h:24:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/traps.h:24:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/traps.h:24:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
vim +15 include/trace/hooks/traps.h
5
6 #if !defined(_TRACE_HOOK_TRAPS_H) || defined(TRACE_HEADER_MULTI_READ)
7 #define _TRACE_HOOK_TRAPS_H
8 #include <linux/tracepoint.h>
9 #include <trace/hooks/vendor_hooks.h>
10 /*
11 * Following tracepoints are not exported in tracefs and provide a
12 * mechanism for vendor modules to hook and extend functionality
13 */
14 struct pt_regs;
> 15 DECLARE_RESTRICTED_HOOK(android_rvh_do_undefinstr,
16 TP_PROTO(struct pt_regs *regs, bool user),
17 TP_ARGS(regs, user),
18 TP_CONDITION(!user));
19
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
[android-common:android12-5.10 6063/10672] include/trace/hooks/cpufreq.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces)
by kernel test robot
tree: https://android.googlesource.com/kernel/common android12-5.10
head: 0497b9601bee1f96c3ef3c169090e1ac4118f15d
commit: 2d45001d598b26a50c8da39814b61f56c42ef608 [6063/10672] ANDROID: cpufreq: Add a restricted vendor hook for freq transition
config: x86_64-randconfig-s021-20210720 (attached as .config)
compiler: gcc-10 (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
git remote add android-common https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android12-5.10
git checkout 2d45001d598b26a50c8da39814b61f56c42ef608
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
include/trace/hooks/sched.h:112:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:112:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:112:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:121:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:121:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:121:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:126:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:126:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:126:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:130:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:130:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:130:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:134:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:134:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:134:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:138:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:138:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:138:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:143:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:143:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:143:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:147:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:147:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:147:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:151:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:151:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:151:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:155:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:155:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:155:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:159:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:159:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:159:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:163:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:163:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:163:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:167:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:167:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:167:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:171:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:171:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:171:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:175:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:175:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:175:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:179:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:179:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:179:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:183:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:183:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:183:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:187:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:187:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:187:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:192:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:192:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:192:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:196:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:196:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:196:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:200:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:200:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:200:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:204:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:204:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:204:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:209:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:209:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:209:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:213:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:213:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:213:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:217:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:217:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:217:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:221:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:221:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:221:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:225:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:225:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:225:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:229:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:229:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:229:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:245:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:245:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:245:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:249:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:249:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:249:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:254:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:254:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:254:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:259:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:259:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:259:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:273:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:273:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:273:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/cpufreq.h):
>> include/trace/hooks/cpufreq.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/cpufreq.h:23:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/cpufreq.h:23:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/mm.h):
include/trace/hooks/mm.h:16:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:16:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:16:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/preemptirq.h):
include/trace/hooks/preemptirq.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:18:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:18:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:18:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:26:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:26:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:26:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/bug.h):
include/trace/hooks/bug.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/bug.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/bug.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/fault.h):
include/trace/hooks/fault.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:15:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:15:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:23:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:23:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:27:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:27:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:27:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
vim +23 include/trace/hooks/cpufreq.h
13
14 DECLARE_HOOK(android_vh_show_max_freq,
15 TP_PROTO(struct cpufreq_policy *policy, unsigned int *max_freq),
16 TP_ARGS(policy, max_freq));
17
18 DECLARE_HOOK(android_vh_freq_table_limits,
19 TP_PROTO(struct cpufreq_policy *policy, unsigned int min_freq,
20 unsigned int max_freq),
21 TP_ARGS(policy, min_freq, max_freq));
22
> 23 DECLARE_RESTRICTED_HOOK(android_rvh_cpufreq_transition,
24 TP_PROTO(struct cpufreq_policy *policy),
25 TP_ARGS(policy), 1);
26 /* macro versions of hooks are no longer required */
27
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
[android-common:android12-5.10 6061/10672] include/trace/hooks/bug.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces)
by kernel test robot
tree: https://android.googlesource.com/kernel/common android12-5.10
head: 0497b9601bee1f96c3ef3c169090e1ac4118f15d
commit: 39fedc3a58f46a8aa8b35e451db9cea67126858a [6061/10672] ANDROID: Fix compilation error when CPU_FREQ is disabled
config: x86_64-randconfig-s021-20210720 (attached as .config)
compiler: gcc-10 (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
git remote add android-common https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android12-5.10
git checkout 39fedc3a58f46a8aa8b35e451db9cea67126858a
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
include/trace/hooks/sched.h:147:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:151:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:151:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:151:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:155:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:155:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:155:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:159:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:159:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:159:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:163:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:163:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:163:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:167:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:167:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:167:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:171:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:171:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:171:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:175:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:175:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:175:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:179:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:179:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:179:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:183:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:183:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:183:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:187:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:187:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:187:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:192:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:192:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:192:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:196:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:196:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:196:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:200:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:200:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:200:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:204:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:204:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:204:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:209:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:209:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:209:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:213:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:213:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:213:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:217:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:217:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:217:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:221:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:221:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:221:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:225:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:225:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:225:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:229:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:229:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:229:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:245:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:245:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:245:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:249:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:249:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:249:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:254:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:254:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:254:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:259:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:259:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:259:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/sched.h:273:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/sched.h:273:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/sched.h:273:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/mm.h):
include/trace/hooks/mm.h:16:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:16:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:16:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/mm.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/mm.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/mm.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/preemptirq.h):
include/trace/hooks/preemptirq.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:18:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:18:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:18:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:22:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:22:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:22:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/preemptirq.h:26:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/preemptirq.h:26:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/preemptirq.h:26:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/bug.h):
>> include/trace/hooks/bug.h:14:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/bug.h:14:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/bug.h:14:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
drivers/android/vendor_hooks.c: note: in included file (through include/trace/define_trace.h, include/trace/hooks/fault.h):
>> include/trace/hooks/fault.h:15:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:15:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:15:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:19:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:19:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:19:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:23:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:23:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:23:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
include/trace/hooks/fault.h:27:1: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct tracepoint_func *it_func_ptr @@ got struct tracepoint_func [noderef] __rcu *funcs @@
include/trace/hooks/fault.h:27:1: sparse: expected struct tracepoint_func *it_func_ptr
include/trace/hooks/fault.h:27:1: sparse: got struct tracepoint_func [noderef] __rcu *funcs
vim +14 include/trace/hooks/bug.h
505e967879727f Sangmoon Kim 2021-01-19 5
505e967879727f Sangmoon Kim 2021-01-19 6 #if !defined(_TRACE_HOOK_BUG_H) || defined(TRACE_HEADER_MULTI_READ)
505e967879727f Sangmoon Kim 2021-01-19 7 #define _TRACE_HOOK_BUG_H
505e967879727f Sangmoon Kim 2021-01-19 8 #include <linux/tracepoint.h>
505e967879727f Sangmoon Kim 2021-01-19 9 #include <trace/hooks/vendor_hooks.h>
505e967879727f Sangmoon Kim 2021-01-19 10 /*
505e967879727f Sangmoon Kim 2021-01-19 11 * Following tracepoints are not exported in tracefs and provide a
505e967879727f Sangmoon Kim 2021-01-19 12 * mechanism for vendor modules to hook and extend functionality
505e967879727f Sangmoon Kim 2021-01-19 13 */
505e967879727f Sangmoon Kim 2021-01-19 @14 DECLARE_RESTRICTED_HOOK(android_rvh_report_bug,
505e967879727f Sangmoon Kim 2021-01-19 15 TP_PROTO(const char *file, unsigned int line, unsigned long bugaddr),
505e967879727f Sangmoon Kim 2021-01-19 16 TP_ARGS(file, line, bugaddr), 1);
505e967879727f Sangmoon Kim 2021-01-19 17
:::::: The code at line 14 was first introduced by commit
:::::: 505e967879727f5c83185c633c7824e900fb2774 ANDROID: bug: add vendor hook for bug trap
:::::: TO: Sangmoon Kim <sangmoon.kim(a)samsung.com>
:::::: CC: Greg Kroah-Hartman <gregkh(a)google.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
[linux-chenxing:mstar_v5_14_rebase 123/352] drivers/spi/spi-msc313.c:154:6: warning: no previous prototype for 'msc313_spi_set_cs'
by kernel test robot
tree: git://github.com/linux-chenxing/linux.git mstar_v5_14_rebase
head: 651efd0e52f225e60faa8b30f9768021e2104d3c
commit: e39640d415b9c96ba82e287dadb7b73138058c76 [123/352] ARM: mstar: MSC313 SPI driver
config: arm-allyesconfig (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 10.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/linux-chenxing/linux/commit/e39640d415b9c96ba82e287dad...
git remote add linux-chenxing git://github.com/linux-chenxing/linux.git
git fetch --no-tags linux-chenxing mstar_v5_14_rebase
git checkout e39640d415b9c96ba82e287dadb7b73138058c76
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross ARCH=arm
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
>> drivers/spi/spi-msc313.c:154:6: warning: no previous prototype for 'msc313_spi_set_cs' [-Wmissing-prototypes]
154 | void msc313_spi_set_cs(struct spi_device *spi, bool enable){
| ^~~~~~~~~~~~~~~~~
drivers/spi/spi-msc313.c: In function 'msc313_spi_remove':
drivers/spi/spi-msc313.c:322:21: warning: unused variable 'spi' [-Wunused-variable]
322 | struct msc313_spi *spi = spi_master_get_devdata(master);
| ^~~
vim +/msc313_spi_set_cs +154 drivers/spi/spi-msc313.c
153
> 154 void msc313_spi_set_cs(struct spi_device *spi, bool enable){
155 struct msc313_spi *mspi = spi_master_get_devdata(spi->master);
156 if(enable)
157 regmap_update_bits(mspi->regmap, REG_CS, CS_MASK, CS_MASK);
158 else
159 regmap_update_bits(mspi->regmap, REG_CS, CS_MASK, 0);
160 }
161
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
[linux-stable-rc:linux-4.4.y 671/1016] drivers/virt/fsl_hypervisor.c:299:17: warning: comparison of integer expressions of different signedness: 'unsigned int' and 'int'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.4.y
head: f299fb634f3b99d7462b2321c3ccf6773812a44e
commit: c0562d5581442d5df3395674f82b80e8c243505f [671/1016] drivers/virt/fsl_hypervisor: Fix error handling path
config: powerpc-randconfig-r005-20210719 (attached as .config)
compiler: powerpc-linux-gcc (GCC) 10.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.gi...
git remote add linux-stable-rc https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git
git fetch --no-tags linux-stable-rc linux-4.4.y
git checkout c0562d5581442d5df3395674f82b80e8c243505f
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross ARCH=powerpc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
In file included from drivers/virt/fsl_hypervisor.c:32:
include/linux/mm.h: In function 'is_vmalloc_addr':
include/linux/mm.h:386:14: warning: comparison of integer expressions of different signedness: 'long unsigned int' and 'long int' [-Wsign-compare]
386 | return addr >= VMALLOC_START && addr < VMALLOC_END;
| ^~
In file included from drivers/virt/fsl_hypervisor.c:33:
include/linux/pagemap.h: In function 'fault_in_multipages_readable':
include/linux/pagemap.h:632:16: warning: variable 'c' set but not used [-Wunused-but-set-variable]
632 | volatile char c;
| ^
In file included from arch/powerpc/include/asm/fsl_hcalls.h:46,
from drivers/virt/fsl_hypervisor.c:44:
arch/powerpc/include/asm/epapr_hcalls.h: In function 'epapr_hypercall':
arch/powerpc/include/asm/epapr_hcalls.h:469:2: warning: 'register' is not at beginning of declaration [-Wold-style-declaration]
469 | unsigned long register r0 asm("r0");
| ^~~~~~~~
arch/powerpc/include/asm/epapr_hcalls.h:470:2: warning: 'register' is not at beginning of declaration [-Wold-style-declaration]
470 | unsigned long register r3 asm("r3") = in[0];
| ^~~~~~~~
arch/powerpc/include/asm/epapr_hcalls.h:471:2: warning: 'register' is not at beginning of declaration [-Wold-style-declaration]
471 | unsigned long register r4 asm("r4") = in[1];
| ^~~~~~~~
arch/powerpc/include/asm/epapr_hcalls.h:472:2: warning: 'register' is not at beginning of declaration [-Wold-style-declaration]
472 | unsigned long register r5 asm("r5") = in[2];
| ^~~~~~~~
arch/powerpc/include/asm/epapr_hcalls.h:473:2: warning: 'register' is not at beginning of declaration [-Wold-style-declaration]
473 | unsigned long register r6 asm("r6") = in[3];
| ^~~~~~~~
arch/powerpc/include/asm/epapr_hcalls.h:474:2: warning: 'register' is not at beginning of declaration [-Wold-style-declaration]
474 | unsigned long register r7 asm("r7") = in[4];
| ^~~~~~~~
arch/powerpc/include/asm/epapr_hcalls.h:475:2: warning: 'register' is not at beginning of declaration [-Wold-style-declaration]
475 | unsigned long register r8 asm("r8") = in[5];
| ^~~~~~~~
arch/powerpc/include/asm/epapr_hcalls.h:476:2: warning: 'register' is not at beginning of declaration [-Wold-style-declaration]
476 | unsigned long register r9 asm("r9") = in[6];
| ^~~~~~~~
arch/powerpc/include/asm/epapr_hcalls.h:477:2: warning: 'register' is not at beginning of declaration [-Wold-style-declaration]
477 | unsigned long register r10 asm("r10") = in[7];
| ^~~~~~~~
arch/powerpc/include/asm/epapr_hcalls.h:478:2: warning: 'register' is not at beginning of declaration [-Wold-style-declaration]
478 | unsigned long register r11 asm("r11") = nr;
| ^~~~~~~~
arch/powerpc/include/asm/epapr_hcalls.h:479:2: warning: 'register' is not at beginning of declaration [-Wold-style-declaration]
479 | unsigned long register r12 asm("r12");
| ^~~~~~~~
drivers/virt/fsl_hypervisor.c: In function 'ioctl_memcpy':
drivers/virt/fsl_hypervisor.c:173:20: warning: comparison of integer expressions of different signedness: '__u32' {aka 'unsigned int'} and 'int' [-Wsign-compare]
173 | if ((param.source == -1) == (param.target == -1))
| ^~
drivers/virt/fsl_hypervisor.c:173:44: warning: comparison of integer expressions of different signedness: '__u32' {aka 'unsigned int'} and 'int' [-Wsign-compare]
173 | if ((param.source == -1) == (param.target == -1))
| ^~
drivers/virt/fsl_hypervisor.c:252:17: warning: comparison of integer expressions of different signedness: '__u32' {aka 'unsigned int'} and 'int' [-Wsign-compare]
252 | (param.source == -1) ? 0 : FOLL_WRITE,
| ^~
drivers/virt/fsl_hypervisor.c:256:17: warning: comparison of integer expressions of different signedness: 'int' and 'unsigned int' [-Wsign-compare]
256 | if (num_pinned != num_pages) {
| ^~
drivers/virt/fsl_hypervisor.c:266:19: warning: comparison of integer expressions of different signedness: '__u32' {aka 'unsigned int'} and 'int' [-Wsign-compare]
266 | if (param.source == -1) {
| ^~
drivers/virt/fsl_hypervisor.c:279:20: warning: comparison of integer expressions of different signedness: '__u32' {aka 'unsigned int'} and 'int' [-Wsign-compare]
279 | if (param.source == -1) {
| ^~
>> drivers/virt/fsl_hypervisor.c:299:17: warning: comparison of integer expressions of different signedness: 'unsigned int' and 'int' [-Wsign-compare]
299 | for (i = 0; i < num_pinned; i++)
| ^
vim +299 drivers/virt/fsl_hypervisor.c
137
138 /*
139 * Ioctl interface for FSL_HV_IOCTL_MEMCPY
140 *
141 * The FH_MEMCPY hypercall takes an array of address/address/size structures
142 * to represent the data being copied. As a convenience to the user, this
143 * ioctl takes a user-create buffer and a pointer to a guest physically
144 * contiguous buffer in the remote partition, and creates the
145 * address/address/size array for the hypercall.
146 */
147 static long ioctl_memcpy(struct fsl_hv_ioctl_memcpy __user *p)
148 {
149 struct fsl_hv_ioctl_memcpy param;
150
151 struct page **pages = NULL;
152 void *sg_list_unaligned = NULL;
153 struct fh_sg_list *sg_list = NULL;
154
155 unsigned int num_pages;
156 unsigned long lb_offset; /* Offset within a page of the local buffer */
157
158 unsigned int i;
159 long ret = 0;
160 int num_pinned = 0; /* return value from get_user_pages_fast() */
161 phys_addr_t remote_paddr; /* The next address in the remote buffer */
162 uint32_t count; /* The number of bytes left to copy */
163
164 /* Get the parameters from the user */
165 if (copy_from_user(¶m, p, sizeof(struct fsl_hv_ioctl_memcpy)))
166 return -EFAULT;
167
168 /*
169 * One partition must be local, the other must be remote. In other
170 * words, if source and target are both -1, or are both not -1, then
171 * return an error.
172 */
173 if ((param.source == -1) == (param.target == -1))
174 return -EINVAL;
175
176 /*
177 * The array of pages returned by get_user_pages_fast() covers only
178 * page-aligned memory. Since the user buffer is probably not
179 * page-aligned, we need to handle the discrepancy.
180 *
181 * We calculate the offset within a page of the S/G list, and make
182 * adjustments accordingly. This will result in a page list that looks
183 * like this:
184 *
185 * ---- <-- first page starts before the buffer
186 * | |
187 * |////|-> ----
188 * |////| | |
189 * ---- | |
190 * | |
191 * ---- | |
192 * |////| | |
193 * |////| | |
194 * |////| | |
195 * ---- | |
196 * | |
197 * ---- | |
198 * |////| | |
199 * |////| | |
200 * |////| | |
201 * ---- | |
202 * | |
203 * ---- | |
204 * |////| | |
205 * |////|-> ----
206 * | | <-- last page ends after the buffer
207 * ----
208 *
209 * The distance between the start of the first page and the start of the
210 * buffer is lb_offset. The hashed (///) areas are the parts of the
211 * page list that contain the actual buffer.
212 *
213 * The advantage of this approach is that the number of pages is
214 * equal to the number of entries in the S/G list that we give to the
215 * hypervisor.
216 */
217 lb_offset = param.local_vaddr & (PAGE_SIZE - 1);
218 if (param.count == 0 ||
219 param.count > U64_MAX - lb_offset - PAGE_SIZE + 1)
220 return -EINVAL;
221 num_pages = (param.count + lb_offset + PAGE_SIZE - 1) >> PAGE_SHIFT;
222
223 /* Allocate the buffers we need */
224
225 /*
226 * 'pages' is an array of struct page pointers that's initialized by
227 * get_user_pages_fast().
228 */
229 pages = kzalloc(num_pages * sizeof(struct page *), GFP_KERNEL);
230 if (!pages) {
231 pr_debug("fsl-hv: could not allocate page list\n");
232 return -ENOMEM;
233 }
234
235 /*
236 * sg_list is the list of fh_sg_list objects that we pass to the
237 * hypervisor.
238 */
239 sg_list_unaligned = kmalloc(num_pages * sizeof(struct fh_sg_list) +
240 sizeof(struct fh_sg_list) - 1, GFP_KERNEL);
241 if (!sg_list_unaligned) {
242 pr_debug("fsl-hv: could not allocate S/G list\n");
243 ret = -ENOMEM;
244 goto free_pages;
245 }
246 sg_list = PTR_ALIGN(sg_list_unaligned, sizeof(struct fh_sg_list));
247
248 /* Get the physical addresses of the source buffer */
249 down_read(¤t->mm->mmap_sem);
250 num_pinned = get_user_pages(current, current->mm,
251 param.local_vaddr - lb_offset, num_pages,
252 (param.source == -1) ? 0 : FOLL_WRITE,
253 pages, NULL);
254 up_read(¤t->mm->mmap_sem);
255
256 if (num_pinned != num_pages) {
257 pr_debug("fsl-hv: could not lock source buffer\n");
258 ret = (num_pinned < 0) ? num_pinned : -EFAULT;
259 goto exit;
260 }
261
262 /*
263 * Build the fh_sg_list[] array. The first page is special
264 * because it's misaligned.
265 */
266 if (param.source == -1) {
267 sg_list[0].source = page_to_phys(pages[0]) + lb_offset;
268 sg_list[0].target = param.remote_paddr;
269 } else {
270 sg_list[0].source = param.remote_paddr;
271 sg_list[0].target = page_to_phys(pages[0]) + lb_offset;
272 }
273 sg_list[0].size = min_t(uint64_t, param.count, PAGE_SIZE - lb_offset);
274
275 remote_paddr = param.remote_paddr + sg_list[0].size;
276 count = param.count - sg_list[0].size;
277
278 for (i = 1; i < num_pages; i++) {
279 if (param.source == -1) {
280 /* local to remote */
281 sg_list[i].source = page_to_phys(pages[i]);
282 sg_list[i].target = remote_paddr;
283 } else {
284 /* remote to local */
285 sg_list[i].source = remote_paddr;
286 sg_list[i].target = page_to_phys(pages[i]);
287 }
288 sg_list[i].size = min_t(uint64_t, count, PAGE_SIZE);
289
290 remote_paddr += sg_list[i].size;
291 count -= sg_list[i].size;
292 }
293
294 param.ret = fh_partition_memcpy(param.source, param.target,
295 virt_to_phys(sg_list), num_pages);
296
297 exit:
298 if (pages && (num_pinned > 0)) {
> 299 for (i = 0; i < num_pinned; i++)
300 put_page(pages[i]);
301 }
302
303 kfree(sg_list_unaligned);
304 free_pages:
305 kfree(pages);
306
307 if (!ret)
308 if (copy_to_user(&p->ret, ¶m.ret, sizeof(__u32)))
309 return -EFAULT;
310
311 return ret;
312 }
313
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
[android-common:android12-5.10 4030/10672] drivers/android/debug_symbols.c:50:9: sparse: sparse: cast removes address space '__percpu' of expression
by kernel test robot
tree: https://android.googlesource.com/kernel/common android12-5.10
head: 0497b9601bee1f96c3ef3c169090e1ac4118f15d
commit: 3fcbb15c1a91a318fb9367bee24603af24648a2d [4030/10672] ANDROID: android: Create debug_symbols driver
config: x86_64-randconfig-s021-20210720 (attached as .config)
compiler: gcc-10 (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0
reproduce:
# apt-get install sparse
# sparse version: v0.6.3-341-g8af24329-dirty
git remote add android-common https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android12-5.10
git checkout 3fcbb15c1a91a318fb9367bee24603af24648a2d
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=x86_64 SHELL=/bin/bash drivers/android/ kernel/
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
>> drivers/android/debug_symbols.c:50:9: sparse: sparse: cast removes address space '__percpu' of expression
vim +/__percpu +50 drivers/android/debug_symbols.c
41
42 /*
43 * ads_per_cpu_entries array contains all the per_cpu variable address information.
44 */
45 static const struct ads_entry ads_per_cpu_entries[ADS_DEBUG_PER_CPU_END] = {
46 #ifdef CONFIG_ARM64
47 ADS_PER_CPU_ENTRY(ADS_IRQ_STACK_PTR, irq_stack_ptr),
48 #endif
49 #ifdef CONFIG_X86
> 50 ADS_PER_CPU_ENTRY(ADS_IRQ_STACK_PTR, hardirq_stack_ptr),
51 #endif
52 };
53
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months
[linux-chenxing:mstar_v5_14_rebase 164/352] drivers/gpu/drm/mstar/mstar_dsi.c:779:6: warning: no previous prototype for 'mstar_dsi_ddp_start'
by kernel test robot
tree: git://github.com/linux-chenxing/linux.git mstar_v5_14_rebase
head: 651efd0e52f225e60faa8b30f9768021e2104d3c
commit: dcdeaae572eb7cde9548e66ebfb3b38719b26a68 [164/352] drm: mstar: dsi
config: arm64-allyesconfig (attached as .config)
compiler: aarch64-linux-gcc (GCC) 10.3.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://github.com/linux-chenxing/linux/commit/dcdeaae572eb7cde9548e66ebf...
git remote add linux-chenxing git://github.com/linux-chenxing/linux.git
git fetch --no-tags linux-chenxing mstar_v5_14_rebase
git checkout dcdeaae572eb7cde9548e66ebfb3b38719b26a68
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross ARCH=arm64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
drivers/gpu/drm/mstar/mstar_dsi.c: In function 'mstar_dsi_bridge_disable':
drivers/gpu/drm/mstar/mstar_dsi.c:760:20: warning: unused variable 'dsi' [-Wunused-variable]
760 | struct mstar_dsi *dsi = bridge_to_dsi(bridge);
| ^~~
drivers/gpu/drm/mstar/mstar_dsi.c: In function 'mstar_dsi_bridge_enable':
drivers/gpu/drm/mstar/mstar_dsi.c:767:20: warning: unused variable 'dsi' [-Wunused-variable]
767 | struct mstar_dsi *dsi = bridge_to_dsi(bridge);
| ^~~
drivers/gpu/drm/mstar/mstar_dsi.c: At top level:
>> drivers/gpu/drm/mstar/mstar_dsi.c:779:6: warning: no previous prototype for 'mstar_dsi_ddp_start' [-Wmissing-prototypes]
779 | void mstar_dsi_ddp_start(struct device *dev)
| ^~~~~~~~~~~~~~~~~~~
>> drivers/gpu/drm/mstar/mstar_dsi.c:786:6: warning: no previous prototype for 'mstar_dsi_ddp_stop' [-Wmissing-prototypes]
786 | void mstar_dsi_ddp_stop(struct device *dev)
| ^~~~~~~~~~~~~~~~~~
drivers/gpu/drm/mstar/mstar_dsi.c:708:13: warning: 'mtk_output_dsi_enable' defined but not used [-Wunused-function]
708 | static void mtk_output_dsi_enable(struct mstar_dsi *dsi)
| ^~~~~~~~~~~~~~~~~~~~~
vim +/mstar_dsi_ddp_start +779 drivers/gpu/drm/mstar/mstar_dsi.c
757
758 static void mstar_dsi_bridge_disable(struct drm_bridge *bridge)
759 {
> 760 struct mstar_dsi *dsi = bridge_to_dsi(bridge);
761
762 //mtk_output_dsi_disable(dsi);
763 }
764
765 static void mstar_dsi_bridge_enable(struct drm_bridge *bridge)
766 {
> 767 struct mstar_dsi *dsi = bridge_to_dsi(bridge);
768
769 //mtk_output_dsi_enable(dsi);
770 }
771
772 static const struct drm_bridge_funcs mstar_dsi_bridge_funcs = {
773 .attach = mstar_dsi_bridge_attach,
774 .disable = mstar_dsi_bridge_disable,
775 .enable = mstar_dsi_bridge_enable,
776 .mode_set = mstar_dsi_bridge_mode_set,
777 };
778
> 779 void mstar_dsi_ddp_start(struct device *dev)
780 {
781 struct mstar_dsi *dsi = dev_get_drvdata(dev);
782
783 mstar_dsi_poweron(dsi);
784 }
785
> 786 void mstar_dsi_ddp_stop(struct device *dev)
787 {
788 struct mstar_dsi *dsi = dev_get_drvdata(dev);
789
790 mstar_dsi_poweroff(dsi);
791 }
792
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 2 months