[Bug middle-end/77964] [7 Regression] Linux kernel firmware loader miscompiled
pinskia at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Oct 13 19:55:00 GMT 2016
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77964
--- Comment #6 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
That is change:
extern struct builtin_fw __start_builtin_fw[];
extern struct builtin_fw __end_builtin_fw[];
static bool fw_get_builtin_firmware(struct firmware *fw, const char *name,
void *buf, size_t size)
{
struct builtin_fw *b_fw;
for (b_fw = __start_builtin_fw; b_fw != __end_builtin_fw; b_fw++) {
--------------- CUT ------------------
to (there might already be a macro in linux which does the asm like below
already):
extern struct builtin_fw __start_builtin_fw[];
extern struct builtin_fw __end_builtin_fw[];
static bool fw_get_builtin_firmware(struct firmware *fw, const char *name,
void *buf, size_t size)
{
struct builtin_fw *b_fw;
struct builtin_fw *b_fw_start = __start_builtin_fw, b_fw_end =
__end_builtin_fw;
asm("":"+r"(b_fw_start));
asm("":"+r"(b_fw_end));
for (b_fw = b_fw_start; b_fw != b_fw_end; b_fw++) {
More information about the Gcc-bugs
mailing list