sparseirq: work around compiler optimizing away __weak functions
Impact: fix panic on null pointer with sparseirq Some GCC versions seem to inline the weak global function, when that function is empty. Work it around, by making the functions return a (dummy) integer. Signed-off-by: Yinghai <yinghai@kernel.org> Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:
@@ -539,13 +539,14 @@ void __init __weak thread_info_cache_init(void)
|
||||
{
|
||||
}
|
||||
|
||||
void __init __weak arch_early_irq_init(void)
|
||||
int __init __weak arch_early_irq_init(void)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
void __init __weak early_irq_init(void)
|
||||
int __init __weak early_irq_init(void)
|
||||
{
|
||||
arch_early_irq_init();
|
||||
return arch_early_irq_init();
|
||||
}
|
||||
|
||||
asmlinkage void __init start_kernel(void)
|
||||
|
||||
Reference in New Issue
Block a user