mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Zdenek Kabelac <zdenek.kabelac@gmail.com>
To: OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>
Cc: Christoph Hellwig <hch@lst.de>, "Rafael J. Wysocki" <rjw@sisk.pl>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	linux-mmc@vger.kernel.org, viro@zeniv.linux.org.uk
Subject: Re: Regression in suspend to ram in 2.6.31-rc kernels
Date: Tue, 8 Sep 2009 10:10:32 +0200	[thread overview]
Message-ID: <c4e36d110909080110t21dd1402l35bf50360ba0b525@mail.gmail.com> (raw)
In-Reply-To: <873a7157zu.fsf@devron.myhome.or.jp>

2009/9/6 OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>:
> Zdenek Kabelac <zdenek.kabelac@gmail.com> writes:
>
>> 2009/9/5 OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>:
>>> Zdenek Kabelac <zdenek.kabelac@gmail.com> writes:
>>>
>>>> 2009/9/4 OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>:
>>>>> Christoph Hellwig <hch@lst.de> writes:
>>>>>
>>>>>> Note that when you rever this patch on a current kernel you do actually
>>>>>> get different behvaviour than when going back to before this commit.
>>>>>>
>>>>>> In 2.6.30 we called ->write_super in the various sync functions and
>>>>>> then ->sync_fs, in 2.6.31-rc8 you would not call any syncing at all
>>>>>> anymore.  I think this patch might just be a symptom for a situation
>>>>>> where the suspend code causes a sync and the mmc driver can't handle
>>>>>> it anymore.
>>>>
>>>> So - here is the console trace from suspend when I've added
>>>> dump_stack() to the fat_sync_fs()   (and also added debug prints
>>>> around each call in this function -so its obvious the function is
>>>> actually left - but then it freezes later somewhere.)
>>>>
>>>> It's interesting that 3 calls to sync happens.
>>>
>>> It seems
>>>
>>>    1) sync() (probabry "sync" command)
>>>    2) sync as part of suspend sequence
>>>    3) sync_filesystem() by mmc remove event
>>>
>>> I guess the root-cause of the problem would be 3). However, it would not
>>> be easy to fix, at least, we would need to think about what we want to
>>> do for it. So, to workaround it for now, I've made this patch.
>>>
>>> Can you try whether this patch fixes this problem?
>>>
>>
>> So I've tested your patch - it seems to fix the problem in suspend -
>> the machine sleeps - however after resume the mmc SD card becomes
>> unusable to the system and appended call trace filled my message log
>> very quickly:
>>
>> After reboot the filesystem appeared to be usable again without errors.
>
> Thanks for testing.  "logical block size: 27499" is wrong value
> completely. Of course, fatfs is assuming the blocksize is not changed.
> (mmc wasn't resumed correctly?)
>
> Well, this problem seems to be completely different problem, and it
> seems the problem of suspend or mmc (or block?) stuff, or something.
>
> It would need to be analyzed by those people.
>
> Meanwhile, I'll apply this patch to workaround suspend problem and to
> remove unneeded write for next window.
>
> Thanks.
>
>> Call Trace:
>>  [<ffffffff81134f6b>] __getblk+0x2cb/0x300
>>  [<ffffffff813dcb58>] ? _spin_unlock_irqrestore+0x38/0x80
>>  [<ffffffff81135122>] __breadahead+0x12/0x40
>>  [<ffffffffa0520cb7>] fat_count_free_clusters+0x307/0x320 [fat]
>>  [<ffffffff81103a58>] ? check_object+0xd8/0x260
>>  [<ffffffff8107d83d>] ? trace_hardirqs_on+0xd/0x10
>>  [<ffffffffa0522d55>] fat_statfs+0xf5/0x110 [fat]
>>  [<ffffffff8110be5c>] vfs_statfs+0x7c/0xa0
>>  [<ffffffff8110c0b0>] vfs_statfs_native+0x20/0xb0
>>  [<ffffffff8110c243>] sys_statfs+0x73/0xb0
>>  [<ffffffff8122ab2b>] ? __up_write+0xcb/0x120
>>  [<ffffffff8100c18c>] ? sysret_check+0x27/0x62
>>  [<ffffffff8109eb8b>] ? audit_syscall_entry+0x28b/0x2b0
>>  [<ffffffff8107d7ed>] ? trace_hardirqs_on_caller+0x15d/0x1a0
>>  [<ffffffff813dbf1e>] ? trace_hardirqs_on_thunk+0x3a/0x3f
>>  [<ffffffff8100c15b>] system_call_fastpath+0x16/0x1b
>> getblk(): invalid block size 512 requested
>> logical block size: 27499
>>
>>  [<ffffffff81135122>] __breadahead+0x12/0x40
>>  [<ffffffffa0520cb7>] fat_count_free_clusters+0x307/0x320 [fat]
>>  [<ffffffff81103a58>] ? check_object+0xd8/0x260
>>  [<ffffffff8107d83d>] ? trace_hardirqs_on+0xd/0x10
>>  [<ffffffffa0522d55>] fat_statfs+0xf5/0x110 [fat]
>>  [<ffffffff8110be5c>] vfs_statfs+0x7c/0xa0
>>  [<ffffffff8110c0b0>] vfs_statfs_native+0x20/0xb0
>>  [<ffffffff8110c243>] sys_statfs+0x73/0xb0
>>  [<ffffffff8122ab2b>] ? __up_write+0xcb/0x120
>>  [<ffffffff8100c18c>] ? sysret_check+0x27/0x62
>>  [<ffffffff8109eb8b>] ? audit_syscall_entry+0x28b/0x2b0
>>  [<ffffffff8107d7ed>] ? trace_hardirqs_on_caller+0x15d/0x1a0
>>  [<ffffffff813dbf1e>] ? trace_hardirqs_on_thunk+0x3a/0x3f
>>  [<ffffffff8100c15b>] system_call_fastpath+0x16/0x1b
> --
> OGAWA Hirofumi <hirofumi@mail.parknet.co.jp>


Just a side note - Could be there any connection with my previous report?

http://lkml.org/lkml/2009/8/28/90


Zdenek

  reply	other threads:[~2009-09-08  8:10 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-31 11:51 Zdenek Kabelac
2009-08-31 19:19 ` Rafael J. Wysocki
2009-09-01  9:34   ` Zdenek Kabelac
2009-09-03 22:29     ` Zdenek Kabelac
2009-09-03 23:23       ` Christoph Hellwig
2009-09-04  0:47         ` OGAWA Hirofumi
2009-09-04  9:13           ` Zdenek Kabelac
2009-09-05 17:22             ` OGAWA Hirofumi
2009-09-05 19:53               ` Zdenek Kabelac
2009-09-05 22:42                 ` OGAWA Hirofumi
2009-09-08  8:10                   ` Zdenek Kabelac [this message]
2009-09-09 13:15                     ` OGAWA Hirofumi
2009-09-07 12:51               ` Pavel Machek
2009-09-09 13:21                 ` OGAWA Hirofumi
2009-09-10 19:23                   ` Pavel Machek
2009-09-11  6:39                     ` OGAWA Hirofumi
2009-09-11 20:09                       ` Pavel Machek
2009-09-11 21:14                         ` Zdenek Kabelac
2009-09-11 21:32                           ` Pavel Machek
2009-09-11 21:45                             ` Zdenek Kabelac
2009-09-11 21:51                               ` Pavel Machek
2009-09-11 22:22                                 ` Rafael J. Wysocki
2009-09-14 20:05                                 ` Pierre Ossman
2009-09-14 20:25                                   ` Pavel Machek
2009-09-11 22:29                               ` Chris Ball
2009-09-11 22:36                                 ` Rafael J. Wysocki
2009-09-14  8:39                                   ` Zdenek Kabelac
2009-09-14 19:17                                     ` Rafael J. Wysocki
2009-09-14 20:27                                     ` Pavel Machek
2009-09-18 11:15                                   ` OGAWA Hirofumi
2009-09-18 21:39                                     ` Rafael J. Wysocki
2009-09-11 22:22                           ` Chris Ball
2009-09-11 22:04                       ` Rafael J. Wysocki
2009-09-11 22:21                         ` Pavel Machek
2009-09-11 22:32                           ` Rafael J. Wysocki
2009-09-08 19:06           ` Christoph Hellwig
2009-09-08 19:48             ` Rafael J. Wysocki
2009-09-09 13:52             ` OGAWA Hirofumi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c4e36d110909080110t21dd1402l35bf50360ba0b525@mail.gmail.com \
    --to=zdenek.kabelac@gmail.com \
    --cc=hch@lst.de \
    --cc=hirofumi@mail.parknet.co.jp \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=rjw@sisk.pl \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®