Turning symbol_get() to EXPORT_SYMBOL_GPL() would create an ABI breakage
in the 6.5 kernels that we have already released, introducing potential
regressions with external out-of-tree kernel modules.
In line with our kernel policy, which aims to avoid any potential ABI
disruptions, temporarily revert this commit for the v6.5 series.
This change will be restored starting with the v6.6 kernels, re-aligning
with upstream.
Ignore: yes
Signed-off-by: Andrea Righi <andrea.righi@canonical.com>
(cherry picked from commit
dd6ceb908cff6b02c18ba447d980a3f9460e2c2c mantic)
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
};
preempt_disable();
- if (!find_symbol(&fsa))
- goto fail;
- if (fsa.license != GPL_ONLY) {
- pr_warn("failing symbol_get of non-GPLONLY symbol %s.\n",
- symbol);
- goto fail;
+ if (!find_symbol(&fsa) || strong_try_module_get(fsa.owner)) {
+ preempt_enable();
+ return NULL;
}
- if (strong_try_module_get(fsa.owner))
- goto fail;
preempt_enable();
return (void *)kernel_symbol_value(fsa.sym);
-fail:
- preempt_enable();
- return NULL;
}
EXPORT_SYMBOL_GPL(__symbol_get);