* Out of tree module build errors since v4.20-rc1
@ 2018-11-21 20:56 Liam R. Howlett
2018-11-21 21:12 ` Nadav Amit
0 siblings, 1 reply; 4+ messages in thread
From: Liam R. Howlett @ 2018-11-21 20:56 UTC (permalink / raw)
To: Ard Biesheuvel
Cc: Thomas Gleixner, Ingo Molnar, Borislav Petkov, H. Peter Anvin,
x86, Peter Zijlstra (Intel),
Nadav Amit, linux-kernel
My out of tree driver build is now reporting issues with the jump table:
./include/linux/jump_label.h: In function ‘jump_entry_code’:
./include/linux/jump_label.h:153:14: error: dereferencing pointer to incomplete type ‘const struct jump_entry’
return entry->code;
^~
./include/linux/jump_label.h: In function ‘jump_entry_set_init’:
./include/linux/jump_label.h:180:7: error: dereferencing pointer to incomplete type ‘struct jump_entry’
entry->key |= 2;
^~
./include/linux/jump_label.h: At top level:
./include/linux/jump_label.h:212:26: error: array type has incomplete element type ‘struct jump_entry’
extern struct jump_entry __start___jump_table[];
^~~~~~~~~~~~~~~~~~~~
./include/linux/jump_label.h:213:26: error: array type has incomplete element type ‘struct jump_entry’
extern struct jump_entry __stop___jump_table[];
^~~~~~~~~~~~~~~~~~~
This happens in v4.20-rc3 as well, so I bisected between v4.19 to
v4.20-rc1 which resulted in the following commit:
b34006c4258c9c86597b6b7123d6a9a3513d6cd7 is the first bad commit
commit b34006c4258c9c86597b6b7123d6a9a3513d6cd7
Author: Ard Biesheuvel <ard.biesheuvel@linaro.org>
Date: Tue Sep 18 23:51:41 2018 -0700
x86/jump_table: Use relative references
Initially I assumed this was my own fault, but my module does not have
these issues when using v4.19. Is there anything I should try/change in
my module makefile, includes, etc to support this relative reference
code?
Thank you,
Liam
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Out of tree module build errors since v4.20-rc1
2018-11-21 20:56 Out of tree module build errors since v4.20-rc1 Liam R. Howlett
@ 2018-11-21 21:12 ` Nadav Amit
2018-11-21 21:14 ` Liam R. Howlett
0 siblings, 1 reply; 4+ messages in thread
From: Nadav Amit @ 2018-11-21 21:12 UTC (permalink / raw)
To: Liam R. Howlett
Cc: Ard Biesheuvel, Thomas Gleixner, Ingo Molnar, Borislav Petkov,
H. Peter Anvin, x86, Peter Zijlstra (Intel),
linux-kernel
> On Nov 21, 2018, at 12:56 PM, Liam R. Howlett <Liam.Howlett@Oracle.com> wrote:
>
>
> My out of tree driver build is now reporting issues with the jump table:
>
> ./include/linux/jump_label.h: In function ‘jump_entry_code’:
> ./include/linux/jump_label.h:153:14: error: dereferencing pointer to incomplete type ‘const struct jump_entry’
> return entry->code;
> ^~
> ./include/linux/jump_label.h: In function ‘jump_entry_set_init’:
> ./include/linux/jump_label.h:180:7: error: dereferencing pointer to incomplete type ‘struct jump_entry’
> entry->key |= 2;
> ^~
> ./include/linux/jump_label.h: At top level:
> ./include/linux/jump_label.h:212:26: error: array type has incomplete element type ‘struct jump_entry’
> extern struct jump_entry __start___jump_table[];
> ^~~~~~~~~~~~~~~~~~~~
> ./include/linux/jump_label.h:213:26: error: array type has incomplete element type ‘struct jump_entry’
> extern struct jump_entry __stop___jump_table[];
> ^~~~~~~~~~~~~~~~~~~
>
>
> This happens in v4.20-rc3 as well, so I bisected between v4.19 to
> v4.20-rc1 which resulted in the following commit:
>
> b34006c4258c9c86597b6b7123d6a9a3513d6cd7 is the first bad commit
> commit b34006c4258c9c86597b6b7123d6a9a3513d6cd7
> Author: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> Date: Tue Sep 18 23:51:41 2018 -0700
>
> x86/jump_table: Use relative references
>
>
>
>
> Initially I assumed this was my own fault, but my module does not have
> these issues when using v4.19. Is there anything I should try/change in
> my module makefile, includes, etc to support this relative reference
> code?
Do you see HAVE_ARCH_JUMP_LABEL_RELATIVE set in your kernel config?
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Out of tree module build errors since v4.20-rc1
2018-11-21 21:12 ` Nadav Amit
@ 2018-11-21 21:14 ` Liam R. Howlett
2018-11-21 21:44 ` Ard Biesheuvel
0 siblings, 1 reply; 4+ messages in thread
From: Liam R. Howlett @ 2018-11-21 21:14 UTC (permalink / raw)
To: Nadav Amit
Cc: Ard Biesheuvel, Thomas Gleixner, Ingo Molnar, Borislav Petkov,
H. Peter Anvin, x86, Peter Zijlstra (Intel),
linux-kernel
* Nadav Amit <namit@vmware.com> [181121 16:12]:
> > On Nov 21, 2018, at 12:56 PM, Liam R. Howlett <Liam.Howlett@Oracle.com> wrote:
> >
> >
> > My out of tree driver build is now reporting issues with the jump table:
> >
> > ./include/linux/jump_label.h: In function ‘jump_entry_code’:
> > ./include/linux/jump_label.h:153:14: error: dereferencing pointer to incomplete type ‘const struct jump_entry’
> > return entry->code;
> > ^~
> > ./include/linux/jump_label.h: In function ‘jump_entry_set_init’:
> > ./include/linux/jump_label.h:180:7: error: dereferencing pointer to incomplete type ‘struct jump_entry’
> > entry->key |= 2;
> > ^~
> > ./include/linux/jump_label.h: At top level:
> > ./include/linux/jump_label.h:212:26: error: array type has incomplete element type ‘struct jump_entry’
> > extern struct jump_entry __start___jump_table[];
> > ^~~~~~~~~~~~~~~~~~~~
> > ./include/linux/jump_label.h:213:26: error: array type has incomplete element type ‘struct jump_entry’
> > extern struct jump_entry __stop___jump_table[];
> > ^~~~~~~~~~~~~~~~~~~
> >
> >
> > This happens in v4.20-rc3 as well, so I bisected between v4.19 to
> > v4.20-rc1 which resulted in the following commit:
> >
> > b34006c4258c9c86597b6b7123d6a9a3513d6cd7 is the first bad commit
> > commit b34006c4258c9c86597b6b7123d6a9a3513d6cd7
> > Author: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> > Date: Tue Sep 18 23:51:41 2018 -0700
> >
> > x86/jump_table: Use relative references
> >
> >
> >
> >
> > Initially I assumed this was my own fault, but my module does not have
> > these issues when using v4.19. Is there anything I should try/change in
> > my module makefile, includes, etc to support this relative reference
> > code?
>
> Do you see HAVE_ARCH_JUMP_LABEL_RELATIVE set in your kernel config?
>
Yes:
$ grep HAVE_ARCH_JUMP_LABEL_RELATIVE .config
CONFIG_HAVE_ARCH_JUMP_LABEL_RELATIVE=y
I should have mentioned I ran 'make defoldconfig' between each bisect.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Out of tree module build errors since v4.20-rc1
2018-11-21 21:14 ` Liam R. Howlett
@ 2018-11-21 21:44 ` Ard Biesheuvel
0 siblings, 0 replies; 4+ messages in thread
From: Ard Biesheuvel @ 2018-11-21 21:44 UTC (permalink / raw)
To: namit, Thomas Gleixner, Ingo Molnar, Borislav Petkov,
H. Peter Anvin, the arch/x86 maintainers, Peter Zijlstra,
Linux Kernel Mailing List
On Wed, 21 Nov 2018 at 22:15, Liam R. Howlett <Liam.Howlett@oracle.com> wrote:
>
> * Nadav Amit <namit@vmware.com> [181121 16:12]:
> > > On Nov 21, 2018, at 12:56 PM, Liam R. Howlett <Liam.Howlett@Oracle.com> wrote:
> > >
> > >
> > > My out of tree driver build is now reporting issues with the jump table:
> > >
> > > ./include/linux/jump_label.h: In function ‘jump_entry_code’:
> > > ./include/linux/jump_label.h:153:14: error: dereferencing pointer to incomplete type ‘const struct jump_entry’
> > > return entry->code;
> > > ^~
> > > ./include/linux/jump_label.h: In function ‘jump_entry_set_init’:
> > > ./include/linux/jump_label.h:180:7: error: dereferencing pointer to incomplete type ‘struct jump_entry’
> > > entry->key |= 2;
> > > ^~
> > > ./include/linux/jump_label.h: At top level:
> > > ./include/linux/jump_label.h:212:26: error: array type has incomplete element type ‘struct jump_entry’
> > > extern struct jump_entry __start___jump_table[];
> > > ^~~~~~~~~~~~~~~~~~~~
> > > ./include/linux/jump_label.h:213:26: error: array type has incomplete element type ‘struct jump_entry’
> > > extern struct jump_entry __stop___jump_table[];
> > > ^~~~~~~~~~~~~~~~~~~
> > >
> > >
> > > This happens in v4.20-rc3 as well, so I bisected between v4.19 to
> > > v4.20-rc1 which resulted in the following commit:
> > >
> > > b34006c4258c9c86597b6b7123d6a9a3513d6cd7 is the first bad commit
> > > commit b34006c4258c9c86597b6b7123d6a9a3513d6cd7
> > > Author: Ard Biesheuvel <ard.biesheuvel@linaro.org>
> > > Date: Tue Sep 18 23:51:41 2018 -0700
> > >
> > > x86/jump_table: Use relative references
> > >
> > >
> > >
> > >
> > > Initially I assumed this was my own fault, but my module does not have
> > > these issues when using v4.19. Is there anything I should try/change in
> > > my module makefile, includes, etc to support this relative reference
> > > code?
> >
> > Do you see HAVE_ARCH_JUMP_LABEL_RELATIVE set in your kernel config?
> >
>
> Yes:
> $ grep HAVE_ARCH_JUMP_LABEL_RELATIVE .config
> CONFIG_HAVE_ARCH_JUMP_LABEL_RELATIVE=y
>
>
> I should have mentioned I ran 'make defoldconfig' between each bisect.
That is puzzling. linux/jump_label.h defines a type struct
jump_label_entry if CONFIG_HAVE_ARCH_JUMP_LABEL_RELATIVE is #define'd,
and so the error suggests that it is not.
Can you share the command line (with V=1) and the preprocessed result?
(Re-execute the failing GCC command but replace -c with -E)
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-11-21 21:44 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-21 20:56 Out of tree module build errors since v4.20-rc1 Liam R. Howlett
2018-11-21 21:12 ` Nadav Amit
2018-11-21 21:14 ` Liam R. Howlett
2018-11-21 21:44 ` Ard Biesheuvel
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®