isdn: don't mark kcapi_proc_exit as __exit
Subsystems (2)
PATCH 1/1 isdn: don't mark kcapi_proc_exit as __exit
As everybody pointed out by now, my patch to clean up CAPI introduced a link time warning, as the two parts of the capi driver are now in one module and the exit function may need to be called in the error path of the init function:
Quoted 1 line
Quoted 1 line
WARNING: drivers/isdn/capi/kernelcapi.o(.text+0xea4): Section mismatch in reference from the function
kcapi_exit()to the function .exit.text:kcapi_proc_exit()
The function kcapi_exit() references a function in an exit section. Often the function kcapi_proc_exit() has valid usage outside the exit section and the fix is to remove the __exit annotation of kcapi_proc_exit.
Remove the incorrect __exit annotation.
--- drivers/isdn/capi/kcapi_proc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/isdn/capi/kcapi_proc.c +1 -1
@@ -217,7 +217,7 @@ kcapi_proc_init(void)proc_create ("capi/driver" ,0 ,NULL , &empty_fops); } -void __exit +void kcapi_proc_exit (void ) {remove_proc_entry ("capi/driver" ,NULL );
Signature · 1 line
2.20.0
Quoted 12 lines · Arnd Bergmann
As everybody pointed out by now, my patch to clean up CAPI introduced a link time warning, as the two parts of the capi driver are now in one module and the exit function may need to be called in the error path of the init function:
Quoted 1 line
Quoted 1 line
WARNING: drivers/isdn/capi/kernelcapi.o(.text+0xea4): Section mismatch in reference from the function
kcapi_exit()to the function .exit.text:kcapi_proc_exit()The function
kcapi_exit()references a function in an exit section. Often the functionkcapi_proc_exit()has valid usage outside the exit section and the fix is to remove the__exitannotation ofkcapi_proc_exit.Remove the incorrect
__exitannotation.
Quoted 8 lines
Reported-by kbuild test robot <[email protected]>Reported-by kernelci.org bot <[email protected]>Reported-by Olof's autobuilder <[email protected]>Reported-by Stephen Rothwell <[email protected]>Signed-off-by Arnd Bergmann <[email protected]>--- drivers/isdn/capi/kcapi_proc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Thanks for this, now applied.
greg k-h