[Bug 1092456] 4.17 regression loading custom SPI module
![](https://seccdn.libravatar.org/avatar/3035b38ff33cf86f480bb169b8500b80.jpg?s=120&d=mm&r=g)
http://bugzilla.suse.com/show_bug.cgi?id=1092456
http://bugzilla.suse.com/show_bug.cgi?id=1092456#c7
--- Comment #7 from Michal Kubeček
Another thought: is it possible that the config with which the module(s) were compiled differs slightly from that of the running kernel (while controlling for kernel version)? That may potentially produce a differently sized module struct whose fields could have slightly different offsets..
Looks like you are right. I checked the layout of struct module in vmlinux and compiled module (compiled on SLE15 but that shouldn't make a difference) and indeed, they differ: --- m2.vmlinux 2018-05-14 06:15:09.710000000 -0400 +++ m2.module 2018-05-14 06:13:39.130000000 -0400 @@ -168,8 +168,9 @@ /* | 4 */ unsigned int percpu_size; /* | 4 */ unsigned int num_tracepoints; /* | 8 */ struct tracepoint * const *tracepoints_ptrs; +/* | 8 */ struct jump_entry *jump_entries; +/* | 4 */ unsigned int num_jump_entries; /* | 4 */ unsigned int num_trace_bprintk_fmt; -/* XXX 4-byte hole */ /* | 8 */ const char **trace_bprintk_fmt_start; /* | 8 */ struct trace_event_call **trace_events; /* | 4 */ unsigned int num_trace_events; As a result, the module thinks module::refcnt should be at offset 808 while kernel expects it at offset 800. module's structure has module::exit at offset 800 and the numbers shown in comments 0 and 5 could pretty well be lower 32 bits of these callbacks. The two extra members in module's version indicate a HAVE_JUMP_LABEL was enabled when building the module but not kernel so the next question is where does this difference come from. -- You are receiving this mail because: You are on the CC list for the bug.
participants (1)
-
bugzilla_noreply@novell.com