Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Resume from suspend causes harddrive error
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
nukem996
l33t
l33t


Joined: 13 Nov 2003
Posts: 776

PostPosted: Thu Jul 13, 2006 7:35 pm    Post subject: Resume from suspend causes harddrive error Reply with quote

When ever I resume from suspend or hibernate my harddrive starts spinning and I cannt do anything that requires access to the harddrive I can only access things that are in memory. My dmesg is fill with the following in it after it resumes, this error only happens when I come back from resume, if I dont resume I never see this error.

Code:

ide: failed opcode was: unknown
hda: task_out_intr: status=0x51 { DriveReady SeekComplete Error }
hda: task_out_intr: error=0x10 { SectorIdNotFound }, LBAsect=74853287, sector=74853287


Thinking my harddrive may be dying I scanned it with the IBM hardware analysis tools(I have a Thinkpad T40) which said the drive was fine. I then scanned it with the Hitachi Drive Fitness extended Test which also said the drive was fine. Upon closer look of the error I discoved that my drive only has 72037362 sectors while the error is on sector 74853287.

This happens with or without DMA and Ive tried disabling wireless, alsa, and hdparm. I also tried the kernel option use multi-mode by default which is supposted to fix this error but it dosnt. I currently use the Gentoo-sources but this also happens in the Suspend2-sources

Laptop: IBM Thinkpad T40
IDE Controller: Intel Corporation 82801DBM (ICH4-M) IDE Controller (rev 01)
Harddrive: Hitachi IC25N040ATCS05-0
Kernel: Gentoo-sources 2.6.17-r2

Can someone please help me?

Thanks,

nuke
Back to top
View user's profile Send private message
davidgurvich
Veteran
Veteran


Joined: 23 Apr 2004
Posts: 1063

PostPosted: Thu Jul 13, 2006 9:09 pm    Post subject: Reply with quote

If you have a hitachi hard drive, it's probably going bad.
Back to top
View user's profile Send private message
nukem996
l33t
l33t


Joined: 13 Nov 2003
Posts: 776

PostPosted: Thu Jul 13, 2006 9:44 pm    Post subject: Reply with quote

But I did the tests with two different harddrive testing programs and both said they were fine.
Back to top
View user's profile Send private message
devsk
Advocate
Advocate


Joined: 24 Oct 2003
Posts: 3003
Location: Bay Area, CA

PostPosted: Thu Jul 13, 2006 10:36 pm    Post subject: Reply with quote

neither you nor your drive is going crazy. Its the IDE driver which is not suspend-resume cycle safe. Head over to suspend2-users/devel list and I have reported similar problems with IDE drivers. One thing to see would be if DMA is disabled after resume (for me it was *mdma1 whereas it should be *udma5 in 'hdparm -I /dev/hda'). If it is , then enable it using hdparm and see if it makes any difference. The whole suspend thing is just not safe as yet, until of course the drivers become fully resumable.
Back to top
View user's profile Send private message
nukem996
l33t
l33t


Joined: 13 Nov 2003
Posts: 776

PostPosted: Fri Jul 14, 2006 12:44 am    Post subject: Reply with quote

On mine it stays at udma5. Disabling dma before I goto sleep mode helps a little and infact I thought it fixed it but after a few min of usage the error was back. The weird part about this is that when I first got this laptop I can Fedora which was fine with suspend I turned it into a Gentoo machine to take around the house I and I really didnt have a need for sleep mode. I noticed it wasnt working the other day which is how I discovered this error. Would you happen to know how to make it suspend aware?
Back to top
View user's profile Send private message
devsk
Advocate
Advocate


Joined: 24 Oct 2003
Posts: 3003
Location: Bay Area, CA

PostPosted: Fri Jul 14, 2006 1:09 am    Post subject: Reply with quote

There are other problems (apart from DMA settings) with IDE drivers. It seems to be fixed in 2.6.18-rc1, but that would unreliable in other ways. I have almost given up on suspend for now.
Back to top
View user's profile Send private message
nukem996
l33t
l33t


Joined: 13 Nov 2003
Posts: 776

PostPosted: Fri Jul 14, 2006 1:41 am    Post subject: Reply with quote

I used suspend on Fedora everyday for about a year and a half and never had a problem, I just havnt used it recently since my laptop is always on. Im going to need suspend again next September since im going to college, do you think it will be ready by then?
Back to top
View user's profile Send private message
devsk
Advocate
Advocate


Joined: 24 Oct 2003
Posts: 3003
Location: Bay Area, CA

PostPosted: Fri Jul 14, 2006 1:49 am    Post subject: Reply with quote

I used it during 2.6.9 days pretty reliably for about a year as well. Its just that upgrades break something or the other. I hope it gets better with 2.6.18. There is also a concerted effort to get suspend2 into mm and mainline kernel. Lets' how far that goes.
Back to top
View user's profile Send private message
nukem996
l33t
l33t


Joined: 13 Nov 2003
Posts: 776

PostPosted: Fri Jul 14, 2006 2:25 am    Post subject: Reply with quote

While experimenting with all this stuff I tired the suspend2-sources and I really didnt see a difference between them and the Gentoo sources. So if I may ask, what is the difference?
Back to top
View user's profile Send private message
nukem996
l33t
l33t


Joined: 13 Nov 2003
Posts: 776

PostPosted: Fri Jul 14, 2006 3:38 am    Post subject: Reply with quote

I was just looking through the 2.6.18-rc1 patches and it seems that there is a fix for power management going in. If you look at ide-io.c there is a hole bunch of stuff for power management. I might try just that patch tomarrow but it seems that pretty much every IDE driver has been updated(although according to the comments that has nothing to do with power management)
Back to top
View user's profile Send private message
devsk
Advocate
Advocate


Joined: 24 Oct 2003
Posts: 3003
Location: Bay Area, CA

PostPosted: Fri Jul 14, 2006 3:45 am    Post subject: Reply with quote

nukem996 wrote:
While experimenting with all this stuff I tired the suspend2-sources and I really didnt see a difference between them and the Gentoo sources. So if I may ask, what is the difference?
the difference is exactly equal to suspend2 patch. i.e.
patch gentoo-sources with suspend2 patch from suspend2.net and you get suspend2-sources.
Back to top
View user's profile Send private message
nukem996
l33t
l33t


Joined: 13 Nov 2003
Posts: 776

PostPosted: Fri Jul 14, 2006 3:48 am    Post subject: Reply with quote

devsk wrote:
nukem996 wrote:
While experimenting with all this stuff I tired the suspend2-sources and I really didnt see a difference between them and the Gentoo sources. So if I may ask, what is the difference?
the difference is exactly equal to suspend2 patch. i.e.
patch gentoo-sources with suspend2 patch from suspend2.net and you get suspend2-sources.


What I mean to ask is that I have all the features suspend2 has while using the Gentoo-sources(suspend to ram and suspend to disk both work) so what is suspend2 giving me?
Back to top
View user's profile Send private message
devsk
Advocate
Advocate


Joined: 24 Oct 2003
Posts: 3003
Location: Bay Area, CA

PostPosted: Fri Jul 14, 2006 4:32 am    Post subject: Reply with quote

well if you are not using suspend2-sources or gentoo-sources patched with suspend2 patches, then you are using in-kernel swsusp. swsusp is more unreliable and has never worked for me. When I said I used it for a year, I used suspend2. suspend2 works better, faster and more reliably compared to in-kernel swsusp.

if any of your experiments with 2.6.18-rc1 succeed, please don't forget to post it here.
Back to top
View user's profile Send private message
nukem996
l33t
l33t


Joined: 13 Nov 2003
Posts: 776

PostPosted: Fri Jul 14, 2006 5:59 pm    Post subject: Reply with quote

I just tried 2.6.18-rc1 with the suspend2 patch and I get the same error. It seem this is not fixed(at least yet). Is there a kernel bug or a link about this that you know of?
Back to top
View user's profile Send private message
devsk
Advocate
Advocate


Joined: 24 Oct 2003
Posts: 3003
Location: Bay Area, CA

PostPosted: Fri Jul 14, 2006 7:15 pm    Post subject: Reply with quote

darn!

one which related to my problem:

http://bugzilla.kernel.org/show_bug.cgi?id=2039

can you please file another bug report with your exact errors? It will be better to open a new issue becase your errors are slightly different from mine.
Back to top
View user's profile Send private message
pgolik
Tux's lil' helper
Tux's lil' helper


Joined: 24 Nov 2004
Posts: 125
Location: Warsaw, Poland

PostPosted: Fri Jul 14, 2006 8:05 pm    Post subject: Reply with quote

See my thread with similar problems. There is a patch in mm sources that helps with SATA (see the thread above), but I still have ATA isues on resume (like cdrom losing DMA). I'm glad to hear that there is an effort to resolve this in future kernels.
Back to top
View user's profile Send private message
nukem996
l33t
l33t


Joined: 13 Nov 2003
Posts: 776

PostPosted: Sun Jul 16, 2006 1:38 am    Post subject: Reply with quote

I posted a kernel bug which can be found at http://bugzilla.kernel.org/show_bug.cgi?id=6840
Back to top
View user's profile Send private message
pgolik
Tux's lil' helper
Tux's lil' helper


Joined: 24 Nov 2004
Posts: 125
Location: Warsaw, Poland

PostPosted: Sun Jul 16, 2006 6:21 pm    Post subject: Reply with quote

nukem996 wrote:
I posted a kernel bug which can be found at http://bugzilla.kernel.org/show_bug.cgi?id=6840

I added my case to your bug, hope this will be dealt with - inability to suspend-to-ram on a modern system is a showstopper.
Back to top
View user's profile Send private message
pgolik
Tux's lil' helper
Tux's lil' helper


Joined: 24 Nov 2004
Posts: 125
Location: Warsaw, Poland

PostPosted: Sun Jul 16, 2006 8:34 pm    Post subject: Reply with quote

devsk wrote:
well if you are not using suspend2-sources or gentoo-sources patched with suspend2 patches, then you are using in-kernel swsusp. swsusp is more unreliable and has never worked for me

Does suspend2 do anything to S3 ACPI sleep (suspend to RAM)? I always thought it was for suspending to disk only. I saw absolutely no difference between regular and suspend2 kernel in behaviour on S3 sleep.
Back to top
View user's profile Send private message
devsk
Advocate
Advocate


Joined: 24 Oct 2003
Posts: 3003
Location: Bay Area, CA

PostPosted: Mon Jul 17, 2006 2:53 pm    Post subject: Reply with quote

you are right about that. There are some subtle differences in the freezer code (shared) in the suspend2 patch, which might make suspend2 slightly different. But I don't think it would be drastically different as in suspend-to-disk case.
Back to top
View user's profile Send private message
pgolik
Tux's lil' helper
Tux's lil' helper


Joined: 24 Nov 2004
Posts: 125
Location: Warsaw, Poland

PostPosted: Fri Nov 10, 2006 8:39 pm    Post subject: Reply with quote

Just bringing this old thread back to life. This patch finaly fixed my problem. It was the ide chipset driver allright. Now I have S3 suspend to ram fully working.[/url]
Back to top
View user's profile Send private message
devsk
Advocate
Advocate


Joined: 24 Oct 2003
Posts: 3003
Location: Bay Area, CA

PostPosted: Sat Nov 11, 2006 8:57 am    Post subject: Reply with quote

pgolik wrote:
Just bringing this old thread back to life. This patch finaly fixed my problem. It was the ide chipset driver allright. Now I have S3 suspend to ram fully working.[/url]
thanks for posting. This patch applies cleanly to 2.6.17 series as well. Now over to testing it to see if it resolves the intermittent DMA and stuff working IDE drives stuck in 'D' state problems.
Back to top
View user's profile Send private message
pgolik
Tux's lil' helper
Tux's lil' helper


Joined: 24 Nov 2004
Posts: 125
Location: Warsaw, Poland

PostPosted: Sat Nov 11, 2006 9:15 am    Post subject: Reply with quote

devsk wrote:
This patch applies cleanly to 2.6.17 series as well.

I forgot to mention that I'm using this patch with regular gentoo-sources-2.6.17-r8 (newest stable on amd64) without any problem. I've been through about a dozen of suspend-resume cycles cycles over the last 24 hours and so far everything works fine. But I'm not sure this is going to do anything to you, in the first post you mention that you have an Intel ide controller, while I have nforce3 for amd (amd74xx kernel driver). But the solution for your chipset might be similar.
Back to top
View user's profile Send private message
devsk
Advocate
Advocate


Joined: 24 Oct 2003
Posts: 3003
Location: Bay Area, CA

PostPosted: Sat Nov 11, 2006 3:44 pm    Post subject: Reply with quote

Quote:
But I'm not sure this is going to do anything to you, in the first post you mention that you have an Intel ide controller
that's the OP. I have an nForce4 mobo and hence the same driver (amd74xx) is used for nforce IDE and hence totally relevant for me. So far, the patch seems to work.
Back to top
View user's profile Send private message
pgolik
Tux's lil' helper
Tux's lil' helper


Joined: 24 Nov 2004
Posts: 125
Location: Warsaw, Poland

PostPosted: Sat Nov 11, 2006 7:03 pm    Post subject: Reply with quote

devsk wrote:
that's the OP. I have an nForce4 mobo and hence the same driver (amd74xx) is used for nforce IDE and hence totally relevant for me. So far, the patch seems to work.

Good for you! Anyway, it seems that much work is going into making ACPI work on linux the way it should, so solutions for other hardware are going to happen soon. Probably has to do with the growing share of laptops on the market (although desktops benefit from it as well).
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum