Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 348782 - relocatable x86 kernel panics on boot when built with sys-devel/binutils-2.21
Summary: relocatable x86 kernel panics on boot when built with sys-devel/binutils-2.21
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 Linux
: High critical with 1 vote (vote)
Assignee: Gentoo Toolchain Maintainers
URL:
Whiteboard: linux-2.6.36.2-regression
Keywords:
: 354339 (view as bug list)
Depends on: 378485
Blocks:
  Show dependency tree
 
Reported: 2010-12-15 12:18 UTC by Graham Murray
Modified: 2011-09-18 05:53 UTC (History)
6 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Kernel Configuration (.config,67.00 KB, text/plain)
2010-12-15 12:19 UTC, Graham Murray
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Graham Murray 2010-12-15 12:18:36 UTC
enabled ExtINT on CPU#0

ESR value before enabling vector: 0x00000040  after: 0x00000000

ENABLING IO-APIC IRQs

..TIMER: vector=0x30 apic1=0 pin1=2 apic2=-1 pin2=-1

..MP-BIOS bug: 8254 timer not connected to IO-APIC

...trying to set up timer (IRQ0) through the 8259A ...

..... (found apic 0 pin 2) ...

....... failed.

...trying to set up timer as Virtual Wire IRQ...

..... failed.

...trying to set up timer as ExtINT IRQ...

..... failed :(.

Kernel panic - not syncing: IO-APIC + timer doesn't work!  Boot with apic=debug and send a report.  Then try booting with the 'noapic' option.



Pid: 1, comm: swapper Not tainted 2.6.36-gentoo-r5 #1

Call Trace:

 [<c0604dc5>] ? printk+0x18/0x1a

 [<c0604cb0>] panic+0x57/0x154

 [<c0880973>] setup_IO_APIC+0x73a/0x76e

 [<c087cbc9>] native_smp_prepare_cpus+0x343/0x3a5

 [<c0102bc6>] ? ret_from_fork+0x6/0x1c

 [<c0874742>] ? kernel_init+0x0/0x1a2

 [<c0874789>] kernel_init+0x47/0x1a2

 [<c0874742>] ? kernel_init+0x0/0x1a2

 [<c01031be>] kernel_thread_helper+0x6/0x18



gentoo-sources-2.6.36-r4 boots and runs perfectly. I see the same problem on another system using the latest git kernel.

 emerge --info
Portage 2.2.0_alpha8 (default/linux/x86/10.0/desktop/gnome, gcc-4.5.1, glibc-2.12.1-r3, 2.6.36-gentoo-r4 i686)
=================================================================
System uname: Linux-2.6.36-gentoo-r4-i686-Intel-R-_Core-TM-2_Duo_CPU_E8200_@_2.66GHz-with-gentoo-2.0.1
Timestamp of tree: Wed, 15 Dec 2010 07:30:23 +0000
app-shells/bash:     4.1_p9
dev-java/java-config: 2.1.11-r3
dev-lang/python:     2.6.6-r1, 2.7.1, 3.1.3
dev-util/cmake:      2.8.1-r2
sys-apps/baselayout: 2.0.1-r1
sys-apps/openrc:     0.6.8
sys-apps/sandbox:    2.4
sys-devel/autoconf:  2.13, 2.68
sys-devel/automake:  1.8.5-r4, 1.9.6-r3, 1.10.3, 1.11.1
sys-devel/binutils:  2.21
sys-devel/gcc:       4.3.5, 4.4.5, 4.5.1-r1
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.4-r1
sys-devel/make:      3.82
virtual/os-headers:  2.6.36.1 (sys-kernel/linux-headers)
Repositories: gentoo sunrise x11 Grahams_local_portage
ACCEPT_KEYWORDS="x86 ~x86"
ACCEPT_LICENSE="*"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=native -mtune=native -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /var/bind /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/eselect/postgresql /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-O2 -march=native -mtune=native -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--with-bdeps y"
FEATURES="assume-digests binpkg-logs buildsyspkg distlocks fixlafiles fixpackages news parallel-fetch preserve-libs protect-owned sandbox sfperms splitdebug strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
GENTOO_MIRRORS="http://de-mirror.org/distro/gentoo/ http://gentoo.tiscali.nl/ http://mirror.ovh.net/gentoo-distfiles/ http://ftp.uni-erlangen.de/pub/mirrors/gentoo http://ftp.snt.utwente.nl/pub/os/linux/gentoo"
LANG="en_GB.UTF-8"
LC_ALL="en_GB.UTF-8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="en_GB en"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/sunrise /var/lib/layman/x11 /usr/portage/local"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa apache2 avahi bash-completion berkdb branding bzip2 cairo caps cdr cli consolekit cracklib crypt cups curl cvs cxx dbus doc dri dts dvd dvdr eds emacs emboss encode evo examples exif expat fam ffmpeg flac fortran gd gdbm gdu geoip gif gnome gnome-keyring gnutls gpm gstreamer gtk gtkhtml hal htmlhandbook iconv icu idn imagemagick imlib ipv6 java jpeg kde kdehiddenvisibility lcms ldap libnotify libsamplerate logrotate lzma lzo mad mikmod mmap mmx mng modules mono mp3 mp4 mpeg mudflap nautilus ncurses nls nptl nptlonly nsplugin ogg opengl openmp pam pango pcre pdf perl png policykit postgres ppds pppd pulseaudio python qt3support qt4 readline samba sdl semantic-desktop session speex spell sqlite sqlite3 sse sse2 ssl startup-notification subversion svg sysfs tcl tcpd theora threads tiff tk truetype unicode usb vim-syntax vorbis x264 x86 xattr xcb xcomposite xml xorg xulrunner xv xvid zlib" ALSA_CARDS="intel-hda" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" APACHE2_MPMS="worker" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="en_GB en" PHP_TARGETS="php5-2" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="vesa fbdev nv nouveau" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account" 
Unset:  CPPFLAGS, CTARGET, FFLAGS, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 Graham Murray 2010-12-15 12:19:29 UTC
Created attachment 257220 [details]
Kernel Configuration
Comment 2 Markos Chandras (RETIRED) gentoo-dev 2010-12-15 12:35:13 UTC
is this the first kernel with this problem? What is the latest working kernel?
Comment 3 Graham Murray 2010-12-15 12:37:12 UTC
(In reply to comment #2)
> is this the first kernel with this problem? What is the latest working kernel?
> 

This is the first kernel with the problem. gentoo-sources-2.6.36-r4 is the latest working kernel.
Comment 4 Dirk 2010-12-15 15:51:39 UTC
Same thing, same symptoms here. 2.6.36-r4 is working but 2.6.36-r5 is not. The config had not changed in between.

I installed also git-sources-2.6.37_rc5-r4 with the same problem.

I tried to boot without splash, did not change and with "noapic" in the kernel parameters. With "noapic" the kernel panic is not coming, but booting does halt in the middle.

For the time being I will stick with 2.6.36-r4.

Thanks for your help
Dirk
Comment 5 Mike Pagano gentoo-dev 2010-12-17 13:12:41 UTC
Can you test with vanilla-sources-2.6.36.2 and let me know if it fails in the same manner?

Comment 6 Graham Murray 2010-12-17 14:06:23 UTC
It looks as though this is NOT a kernel problem, but a binutils problem. While trying to identify the failing commit using git bisect, I found that even previously working kernel versions would exhibit the failure. So, I tried reverting to using gcc-4.4.5 but this still failed. So I reverted back to sys-devel/binutils-2.20.1-r1 and rebuilt gentoo-sources-2.6.36-r5 and it boots and runs sucessfully.
Comment 7 Mike Pagano gentoo-dev 2010-12-17 15:39:21 UTC
Adding toolchain for their thoughts
Comment 8 Ryan Hill (RETIRED) gentoo-dev 2010-12-18 07:48:45 UTC
http://sourceware.org/bugzilla/show_bug.cgi?id=12327 maybe?  Relevant thread is http://thread.gmane.org/gmane.comp.gnu.binutils/48959, but no one posted the actual panic message so I don't know if it's the same issue.
Comment 9 Ryan Hill (RETIRED) gentoo-dev 2010-12-18 08:12:56 UTC
2.21.51.0.4 has a fix for that bug if you want to try it.
Comment 10 SpanKY gentoo-dev 2010-12-19 04:46:43 UTC
i dont think it's that big of a deal.  the relocatable option is rarely useful to the vast majority of people.

once upstream has merged a fix, we'll pull it in, but i dont see us doing anything beyond waiting.

a change merged into the "linux binutils" isnt something i'd like added to the "gnu binutils" either.
Comment 11 Vladimir Berezhnoy 2011-02-15 10:40:46 UTC
*** Bug 354339 has been marked as a duplicate of this bug. ***
Comment 12 Vladimir Berezhnoy 2011-02-15 10:49:48 UTC
Please unmask a version of binutils which is not affected by this bug (I've tested sucessfully with 2.21.51.0.4) or either mask 2.21
Comment 13 Martin Dummer 2011-03-03 14:01:24 UTC
(In reply to comment #6)
> So I reverted back to
> sys-devel/binutils-2.20.1-r1 and rebuilt gentoo-sources-2.6.36-r5 and it boots
> and runs sucessfully.
> 

I have exactly the same symptom and after lots of attempts to fix I found this bug and can confirm that downgrading binutils to 2.20.1-r1 fixes the problem!
Comment 14 SpanKY gentoo-dev 2011-03-03 22:58:03 UTC
i'm not masking binutils-2.21, and it's ridiculous to even suggest it

if someone wants to verify this fixes things for them with binutils-2.21, i can add it to the tree fairly easily:
http://sourceware.org/git/?p=binutils.git;a=commit;h=5daebc6a6606a30e60716f5bdee3d2018b560e8e
Comment 15 Vladimir Berezhnoy 2011-03-04 00:51:57 UTC
The bug is in main tree for two months already. I see nothing good in making users fight with known bugs, especially as this bug is rather hard to track.
Comment 16 SpanKY gentoo-dev 2011-03-04 02:12:59 UTC
if you want to help, try the patch i already posted and post your results.  otherwise, take your complaints to the forums.  they have no business here.
Comment 17 sulfinu 2011-03-12 23:55:40 UTC
I encountered exactly the same problem, but in another setup: binutils-2.21 collaborated just fine with gcc-4.4.4-r2 into buiding a relocatable kernel. The issue showed up only after upgrading to the (stable now) gcc-4.4.5...

I lost tons of time chasing the guilty package, because I only related the fault to the compiler upgrade (and you know the implications, i.e. emerge -e system and such). All my thanks to the original reporter!
Comment 18 SpanKY gentoo-dev 2011-04-07 01:15:56 UTC
seems the upstream 2.21 branch merged a diff patch than was merged into CVS head, so extracting just the relevant pieces might be troublesome.

perhaps just wait for the 2.21.1 release.
Comment 19 SpanKY gentoo-dev 2011-09-18 05:53:49 UTC
we're stabilizing 2.21.1