Created attachment 301053 [details] Some logs of the kernel when it oops'd Using gentoo-sources, linux-3.2.1-gentoo-r2, I get a kernel oops when I eject my sd card, after using it normally (mount, use, unmount, eject). I am attaching my kernel .config, as well as two examples of the kernel panic/oops from /var/log/messages
Created attachment 301055 [details] Another example of oops
Created attachment 301057 [details] my kernel config file
speedy src # emerge --info Portage 2.1.10.44 (default/linux/amd64/10.0/desktop, gcc-4.5.3, glibc-2.13-r4, 3.2.1-gentoo-r2_MINE_V01 x86_64) ================================================================= System uname: Linux-3.2.1-gentoo-r2_MINE_V01-x86_64-Intel-R-_Core-TM-_i3_CPU_M_370_@_2.40GHz-with-gentoo-2.0.3 Timestamp of tree: Mon, 06 Feb 2012 16:15:01 +0000 app-shells/bash: 4.1_p9 dev-java/java-config: 2.1.11-r3 dev-lang/python: 2.7.2-r3, 3.1.4-r3 dev-util/cmake: 2.8.6-r4 dev-util/pkgconfig: 0.26 sys-apps/baselayout: 2.0.3 sys-apps/openrc: 0.9.4 sys-apps/sandbox: 2.5 sys-devel/autoconf: 2.13, 2.68 sys-devel/automake: 1.9.6-r3, 1.10.3, 1.11.1 sys-devel/binutils: 2.21.1-r1 sys-devel/gcc: 4.5.3-r1 sys-devel/gcc-config: 1.4.1-r1 sys-devel/libtool: 2.4-r1 sys-devel/make: 3.82-r1 sys-kernel/linux-headers: 2.6.39 (virtual/os-headers) sys-libs/glibc: 2.13-r4 Repositories: gentoo pd-overlay sabayon x-portage ACCEPT_KEYWORDS="amd64" ACCEPT_LICENSE="* -@EULA" CBUILD="x86_64-pc-linux-gnu" CFLAGS="-march=native -O2 -pipe" CHOST="x86_64-pc-linux-gnu" CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /var/lib/hsqldb" CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.3/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/cli-php5.3/ext-active/ /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="-march=native -O2 -pipe" DISTDIR="/usr/portage/distfiles" FEATURES="assume-digests binpkg-logs distlocks ebuild-locks fixlafiles news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch" FFLAGS="" GENTOO_MIRRORS="ftp://gentoo.arcticnetwork.ca/pub/gentoo/ http://gentoo.arcticnetwork.ca/ rsync://mirror.the-best-hosting.net/gentoo-distfiles http://mirror.the-best-hosting.net" LDFLAGS="-Wl,-O1 -Wl,--as-needed" MAKEOPTS="-j1" 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/pd-overlay /var/lib/layman/sabayon /usr/local/portage" SYNC="rsync://rsync5.ca.gentoo.org/gentoo-portage" USE="X \ a52 aac acl acpi alsa amd64 aperfmperf apic arat arch_perfmon bash-completion berkdb bluetooth branding bts bzip2 cairo cdda cdr clflush cli cmov consolekit constant_tsc cracklib crypt cups cx16 cx8 cxx dbus de doc dri ds_cpl dtes64 dts dvd dvdr emboss encode ept est evdev exif fam firefox flac flexpriority fortran fpu fxsr gdbm gdu gif gpm gtk ht iconv intel ipv6 jack jpeg kde lahf_lm lame lcms ldap libnotify lm lock mad mca mce mmx mmxext mng modules monitor mp3 mp4 mpeg msr mtrr mudflap multilib ncurses nls nonstop_tsc nptl nptlonly nx ogg opengl openmp pae pam pango pat pbe pcre pdcm pdf pebs pge png pni policykit popcnt ppds pppd pse pse36 python qt qt3support qt4 rdtscp readline rep_good rtmp sdl sep session spell ss sse sse2 sse4_1 sse4_2 ssl ssse3 startup-notification svg synaptics syscall sysfs tcpd thunar tiff tm tm2 tpr_shadow truetype tsc udev unicode usb vaapi vme vmx vnmi vorbis vpid x264 xcb xcomposite xinerama xml xorg xtopology xtpr xulrunner xv xvid zlib zsh-completion" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" 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" CALLIGRA_FEATURES="kexi words flow plan stage tables krita karbon braindump" CAMERAS="ptp2" 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="evdev synaptics" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" PHP_TARGETS="php5-3" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="intel" 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, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS
Note that this issue happens with kernel=3.2.5 as well, but not kernel<=3.0.6
Note that this problem does not happen when virtualbox drivers are not loaded. The following links also address this issue http://marc.info/?l=linux-scsi&m=132388619710052 http://marc.info/?l=linux-scsi&m=132909845126932&w=2
Fedora bugzilla has this too https://bugzilla.redhat.com/show_bug.cgi?id=754518
Sorry, it does happen still (even without vbox drivers)
There is a patch that was written by Jun'ichi Nomura for the 3.3 kernel which fixes this issue. I have tested it with 3.3-rc5. The patch is available here: https://lkml.org/lkml/2012/2/22/1 In that same mailing list thread, Dave Jones posted a backport of the patch to the 3.2 kernel. I have tested that patch with 3.2.1-gentoo-r2 and it also works. I am attaching the 3.2 backported patch to this bug-ticket as well.
Created attachment 303761 [details] Dave Jones backport of Jun'ichi Nomura
Comment on attachment 303761 [details] Dave Jones backport of Jun'ichi Nomura This fixes the issue I experienced with ejecting the SD card crashing/oopsing my kernel, it is a modified version of a linux-3.3 patch proposed by Jun'ichi Nomura
The referenced patch appears to be in kernels >= 3.3.0. Can you please test with a later kernel and post the results.
3.2.12 from the gentoo portage tree is what I run now, didn't need to be patched, I think the code was merged upstream by this version. I will try something newer next week and post the results. Cheers, Naveen
So, after testing, it seems the bug is also resolved in gentoo sources for the linux 3.4.3 kernel
Thanks for testing