public inbox for linux-mmc@vger.kernel.org
 help / color / mirror / Atom feed
From: "Uwe Kleine-König" <u.kleine-koenig@pengutronix.de>
To: Holger Schurig <holgerschurig@gmail.com>,
	"Theodore Y. Ts'o" <tytso@mit.edu>
Cc: linux-mmc@vger.kernel.org
Subject: Re: eMMC and "mkfs.ext3" hangs without "-E nodiscard"
Date: Thu, 9 Oct 2014 20:44:06 +0200	[thread overview]
Message-ID: <20141009184406.GA30071@pengutronix.de> (raw)
In-Reply-To: <CAOpc7mF+9DgEeikB-gjGphPnsC_Ku+9=AtdGUaQEZYK6Jm77vA@mail.gmail.com>

Hello,

On Mon, Sep 29, 2014 at 03:46:10PM +0200, Holger Schurig wrote:
> on kernel 3.16.3 running on an i.MX6 with an eMMC card formatting a
> partition won't work, it hangs. With an added -v the last thing it
> spit out is "Discarding device blocks: 4096/196608".
> 
> When I run mkfs with "-E nodiscard", formatting & booting works.
I had the exact same issue on an i.MX6 machine (via amos820) with
mkfs.ext2.  When cross checking on a different i.MX6 machine the problem
didn't happen there. It seems it didn't try to discard blocks, at least
it didn't say something about "Discarding device blocks:".

I tried to understand how mkfs.ext* decides if it can/should try to
discard blocks, but failed to do so. Theodore: Maybe you can help out
here? The relevant line seems to be:

	discard = get_bool_from_profile(fs_types, "discard" , discard);

Unfortunately I don't have access to the failing machine anymore, still
it would be great to understand the problem.

Apart from that even if the block device somehow announces that it can
or cannot discard blocks, the process doing it anyhow shouldn't hang.
(For me it wasn't interruptible by Ctrl-C, so probably hung in a system
call.)

Best regards
Uwe

-- 
Pengutronix e.K.                           | Uwe Kleine-König            |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |

  parent reply	other threads:[~2014-10-09 18:44 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-29 13:46 eMMC and "mkfs.ext3" hangs without "-E nodiscard" Holger Schurig
2014-09-29 14:12 ` Arnd Bergmann
2014-09-30  7:05   ` Holger Schurig
2014-09-30 10:16     ` Arnd Bergmann
2014-10-09 18:44 ` Uwe Kleine-König [this message]
2014-10-09 20:40 ` Fabio Estevam

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=20141009184406.GA30071@pengutronix.de \
    --to=u.kleine-koenig@pengutronix.de \
    --cc=holgerschurig@gmail.com \
    --cc=linux-mmc@vger.kernel.org \
    --cc=tytso@mit.edu \
    /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