]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
libata: force disable trim for SuperSSpeed S238
authorArne Fitzenreiter <arne_f@ipfire.org>
Wed, 15 Jul 2015 11:54:37 +0000 (13:54 +0200)
committerZefan Li <lizefan@huawei.com>
Mon, 21 Mar 2016 01:17:45 +0000 (09:17 +0800)
commit cda57b1b05cf7b8b99ab4b732bea0b05b6c015cc upstream.

This device loses blocks, often the partition table area, on trim.
Disable TRIM.
http://pcengines.ch/msata16a.htm

Signed-off-by: Arne Fitzenreiter <arne_f@ipfire.org>
Signed-off-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Zefan Li <lizefan@huawei.com>
drivers/ata/libata-core.c

index b5d532f1e431cd7ea668b4c86752c13845b3af68..5a3b08bf651fe41b38efacd58cc5d96e010c6cfb 100644 (file)
@@ -4144,6 +4144,9 @@ static const struct ata_blacklist_entry ata_device_blacklist [] = {
        { "WD My Book",                 NULL,   ATA_HORKAGE_1_5_GBPS, },
        { "Seagate FreeAgent GoFlex",   NULL,   ATA_HORKAGE_1_5_GBPS, },
 
+       /* devices that don't properly handle TRIM commands */
+       { "SuperSSpeed S238*",          NULL,   ATA_HORKAGE_NOTRIM, },
+
        /*
         * Devices which choke on SETXFER.  Applies only if both the
         * device and controller are SATA.