When a kernel was rebuilt, the previous Module.markers was not cleared. It caused markers with different format strings to appear as duplicates when a markers was changed. This problem is present since scripts/mod/modpost.c started to generate Module.markers, commit b2e3e658b344c6bcfb8fb694100ab2f2b5b2edb0 It therefore applies to 2.6.25, 2.6.26 and linux-next. I merely merged the patches from Roland, Wenji and Takashi here. Credits to Roland McGrath <roland@redhat.com> Wenji Huang <wenji.huang@oracle.com> and Takashi Nishiie <t-nishiie@np.css.fujitsu.com> for providing the individual fixes. - Changelog : - Integrated Takashi's Makefile modification to clear Module.markers upon make clean.
Showing the changes to scripts (2 of 3 files). Show all
Unified · Split
| @@ -101,6 +101,7 @@ quiet_cmd_kernel-mod = MODPOST $@ · 100 unmodified lines | ||
| 101 | 101 | cmd_kernel-mod = $(modpost) $@ |
| 102 | 102 | |
| 103 | 103 | vmlinux.o: FORCE |
| 104 | + @rm -fr $(kernelmarkersfile) | |
| 104 | 105 | $(call cmd,kernel-mod) |
| 105 | 106 | |
| 106 | 107 | # Declare generated files as targets for modpost |
| @@ -1992,7 +1992,8 @@ static void read_markers(const char *fname) · 1991 unmodified lines | ||
| 1992 | 1992 | mod->skip = 1; |
| 1993 | 1993 | } |
| 1994 | 1994 | |
| 1995 | − add_marker(mod, marker, fmt); | |
| 1995 | + if (!mod->skip) | |
| 1996 | + add_marker(mod, marker, fmt); | |
| 1996 | 1997 | } |
| 1997 | 1998 | return; |
| 1998 | 1999 | fail: |