[Bug 1224402] New: /usr/src/kernel-modules/nvidia-390.157-default/nvidia/nv-procfs.o: warning: objtool: nv_register_procfs() falls through to next function nv_unregister_procfs()
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402 Bug ID: 1224402 Summary: /usr/src/kernel-modules/nvidia-390.157-default/nvidia/ nv-procfs.o: warning: objtool: nv_register_procfs() falls through to next function nv_unregister_procfs() Classification: openSUSE Product: openSUSE Distribution Version: Leap 15.5 Hardware: Other OS: Other Status: NEW Severity: Normal Priority: P5 - None Component: Kernel Assignee: kernel-bugs@opensuse.org Reporter: msuchanek@suse.com QA Contact: qa-bugs@suse.de Target Milestone: --- Found By: --- Blocker: --- Is this a bug in objtool? How would you even go about writing such function? -- You are receiving this mail because: You are on the CC list for the bug.
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c1
--- Comment #1 from Michal Suchanek
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
Miroslav Beneš
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c2
Miroslav Beneš
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c3
Michal Suchanek
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c4
--- Comment #4 from Michal Suchanek
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c5
--- Comment #5 from Michal Suchanek
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c6
Miroslav Beneš
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c7
--- Comment #7 from Michal Suchanek
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c8
--- Comment #8 from Martin Jambor
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c9
--- Comment #9 from Miroslav Beneš
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c10
--- Comment #10 from Michal Suchanek
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c11
--- Comment #11 from Martin Jambor
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c12
--- Comment #12 from Miroslav Beneš
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c13
--- Comment #13 from Martin Jambor
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c14
--- Comment #14 from Martin Jambor
Having said that the support for noreturn functions in objtool is not great. There have been talks about improving it but it needs to happen in cooperation with GCC because there is currently no way to know that GCC decided to place unreachable somewhere (decided that a function is noreturn). I do not know if there is a progress on this front behind the scenes.
Once we start building our enterprise kernels with GCC 13+, asking our performance team to evaluate the option -funreachable-traps might be worthwhile. -- You are receiving this mail because: You are on the CC list for the bug.
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c15
Michal Suchanek
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c16
Stefan Dirsch
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c17
Michal Suchanek
Which warning do you mean exactly?
The one shown in the bug title which is displayed every time the package is installed on the user's system and builds the kernel modules. This part of the conftest.sh ends up in the generated code, confuses gcc which fails to eliminate some dead code which then confuses objtool. -- You are receiving this mail because: You are on the CC list for the bug.
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c18
Stefan Dirsch
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c19
Miroslav Beneš
GCC 13 (at least) does not automagically promote the array to const because of the -flive-patching=inline-clone option (which disables the pure-const pass). It is even natural, we need to be ready for some unknown live-patch to possibly leak the address even when such a leak is not present in the code at hand.
Bah, right. I wonder if we should just get rid of the option eventually as upstream did and somehow detect dangerous changes in our tooling. Adding Petr for his awareness. Thanks a lot for the explanation. (In reply to Stefan Dirsch from comment #18)
Ok. BTW, there is no such warning when building against Tumbleweed, just against Leap 15.5 and 15.6. Check this
https://build.suse.de/project/monitor/Proprietary:X11:Drivers
nvidia-driver-G06 nvidia-gfxG05 nvidia-gfxG04 (this bug G04 = 390.157)
All these are affected by this objtool warning on Leap. mabye one should figure out what's different in objtool for Tumbleweed?
Upstream objtool reports the same warning on the object file so there is no difference. TW does not use the GCC option mentioned above so the object code is different. -- You are receiving this mail because: You are on the CC list for the bug.
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c20
--- Comment #20 from Stefan Dirsch
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c21
Miroslav Beneš
@Miroslav So I apply this patch and we're done? Then please assign this ticket to me.
(Then I will also try to push this patch upstream)
Yes, if you apply the patch, GCC will remove the dead code and everything will be all right from objtool perspective. -- You are receiving this mail because: You are on the CC list for the bug.
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
Stefan Dirsch
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
Stefan Dirsch
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
Stefan Dirsch
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
https://bugzilla.suse.com/show_bug.cgi?id=1224402#c22
--- Comment #22 from Stefan Dirsch
![](https://seccdn.libravatar.org/avatar/a895f78a81a109471893519443e4d933.jpg?s=120&d=mm&r=g)
https://bugzilla.suse.com/show_bug.cgi?id=1224402
Stefan Dirsch
participants (1)
-
bugzilla_noreply@suse.com