|
Bugzilla – Full Text Bug Listing |
| Summary: | kernel panic after resume in fat_detach | ||
|---|---|---|---|
| Product: | [openSUSE] openSUSE 12.3 | Reporter: | Juergen Weigert <jw> |
| Component: | Hotplug | Assignee: | Jan Kara <jack> |
| Status: | RESOLVED FIXED | QA Contact: | E-mail List <qa-bugs> |
| Severity: | Normal | ||
| Priority: | P5 - None | CC: | jeffm, oneukum |
| Version: | RC 1 | ||
| Target Milestone: | --- | ||
| Hardware: | Other | ||
| OS: | Other | ||
| Whiteboard: | |||
| Found By: | --- | Services Priority: | |
| Business Priority: | Blocker: | --- | |
| Marketing QA Status: | --- | IT Deployment: | --- |
| Bug Depends on: | |||
| Bug Blocks: | 357354 | ||
|
Description
Juergen Weigert
2013-03-03 13:36:46 UTC
Ok, the real problem here isn't the oops, it's this: [29234.992434] VFS: Busy inodes after unmount of mmcblk0p1. Self-destruct in 5 seconds. Have a nice day... ... anything can happen once we see that message. Yeah, and I'd also add that before that is line: [29234.954065] mmc0: card b368 removed So what likely happened is that after resume, we've got event about removal of the card, that tried to unmount the filesystem on the card but some inodes were busy (it is enough there were e.g. open files on the fs) so that failed. I'm not sure if the remove request from the card reader is OK - it makes some sense since while the machine was suspended, someone could have removed the card and put there a different one but OTOH we have no way of unmounting a filesystem when it's used (we'd need revoke support for that) so a removal event in such case will likely result in oopses like above. Maybe Oliver will know whether removal event from the card reader is expected or not. Oliver? (In reply to comment #2) > Maybe Oliver will know whether removal event from the card reader is expected > or not. Oliver? USB card reader almost invariably report a medium change. PCI readers usually do. But in any case surprise removal must never crash the system, for whatever reason it may happen. A removal event shouldn't result in a crashed kernel -- it should be handled like a disk path being lost. Spew I/O errors all day, but we shouldn't be getting to the point where we're allowing a umount to succeed with open inodes. That seems like we're missing some refcounting. Yeah, right. The umount should have failed in the first place. Seeing that we oopsed when running sys_inotify_rm_watch() it seems that inotify was holding the inode reference that prevented evict_inodes() from removing all the inodes. However fsnotify_unmount_inodes() should have dropped all the references that inotify was holding... except if there's a bug in fsnotify code and we can grab inode reference twice. But then I would guess we would see the same bug more often (it's not limited to fat & suspend). Strange. Anyway, I'll check inotify code in more detail tomorrow. OK, so this is really a bug in fsnotify and it has been fixed upstream by changing locking of fsnotify (merge commit 96680d2b9174668100824d763382240c71baa811). Since they went into 3.8-rc1, it should be relatively easy to backport (although it's quite a few patches). OK, I've just pushed 11 relevant patches from the merge to openSUSE-12.3 tree. Since this is hard to trigger race, I don't think waiting for reproduction is reasonable. So I'm closing the bug now. Ah, forgot to set proper state after mid-air collision... openSUSE-SU-2013:1971-1: An update that solves 34 vulnerabilities and has 19 fixes is now available. Category: security (moderate) Bug References: 799516,801341,802347,804198,807153,807188,807471,808827,809906,810144,810473,811882,812116,813733,813889,814211,814336,814510,815256,815320,816668,816708,817651,818053,818561,821612,821735,822575,822579,823267,823342,823517,823633,823797,824171,824295,826102,826350,826374,827749,827750,828119,828191,828714,829539,831058,831956,832615,833321,833585,834647,837258,838346 CVE References: CVE-2013-0914,CVE-2013-1059,CVE-2013-1819,CVE-2013-1929,CVE-2013-1979,CVE-2013-2141,CVE-2013-2148,CVE-2013-2164,CVE-2013-2206,CVE-2013-2232,CVE-2013-2234,CVE-2013-2237,CVE-2013-2546,CVE-2013-2547,CVE-2013-2548,CVE-2013-2634,CVE-2013-2635,CVE-2013-2851,CVE-2013-2852,CVE-2013-3222,CVE-2013-3223,CVE-2013-3224,CVE-2013-3226,CVE-2013-3227,CVE-2013-3228,CVE-2013-3229,CVE-2013-3230,CVE-2013-3231,CVE-2013-3232,CVE-2013-3233,CVE-2013-3234,CVE-2013-3235,CVE-2013-3301,CVE-2013-4162 Sources used: openSUSE 12.3 (src): kernel-docs-3.7.10-1.24.1, kernel-source-3.7.10-1.24.1, kernel-syms-3.7.10-1.24.1 |