From: Prasanna NAVARATNA Subject: help with 'discard' mount option on eMMC Date: Thu, 10 Oct 2013 06:44:57 +0000 (UTC) Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Return-path: Received: from plane.gmane.org ([80.91.229.3]:37593 "EHLO plane.gmane.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751269Ab3JJGpU (ORCPT ); Thu, 10 Oct 2013 02:45:20 -0400 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1VU9zq-00042O-8P for linux-mmc@vger.kernel.org; Thu, 10 Oct 2013 08:45:18 +0200 Received: from 202.122.18.226 ([202.122.18.226]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 10 Oct 2013 08:45:18 +0200 Received: from prasanna.navaratna by 202.122.18.226 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 10 Oct 2013 08:45:18 +0200 Sender: linux-mmc-owner@vger.kernel.org List-Id: linux-mmc@vger.kernel.org To: linux-mmc@vger.kernel.org Hello, I'm using Hynix eMMC4.41 with Linux kernel 3.4.5. After mounting ext4 partition /userdata with 'discard' mount option enabled, fs triggers TRIM commands to eMMC after every file deletion. With this setup, for a continuous reboot test (5s awake and issue reboot and repeat) with 10 or 20 iterations, i see data corruption in eMMC consistently. mount options are :- noatime,nosuid,nodev,noauto_da_alloc,discard encryptable="path" What am i missing here? if 'discard' mount option is removed, then no data corruption in eMMC for more than 200 iterations. Does TRIM needs some extra care? BKOPS is not enabled in eMMC (is bkops mandatory if using TRIM?) Apologies, if this is not proper platform to ask such question. Please guide and throw some light. Thanks, Prasanna NAVARATNA