Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/ata Drop the old discard/trim ioctls from wd.c.



details:   https://anonhg.NetBSD.org/src/rev/32fb684a2a7e
branches:  trunk
changeset: 330917:32fb684a2a7e
user:      dholland <dholland%NetBSD.org@localhost>
date:      Fri Jul 25 08:34:27 2014 +0000

description:
Drop the old discard/trim ioctls from wd.c.

diffstat:

 sys/dev/ata/wd.c |  22 ++--------------------
 1 files changed, 2 insertions(+), 20 deletions(-)

diffs (43 lines):

diff -r 0126f5298253 -r 32fb684a2a7e sys/dev/ata/wd.c
--- a/sys/dev/ata/wd.c  Fri Jul 25 08:32:21 2014 +0000
+++ b/sys/dev/ata/wd.c  Fri Jul 25 08:34:27 2014 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: wd.c,v 1.410 2014/07/25 08:22:08 dholland Exp $ */
+/*     $NetBSD: wd.c,v 1.411 2014/07/25 08:34:27 dholland Exp $ */
 
 /*
  * Copyright (c) 1998, 2001 Manuel Bouyer.  All rights reserved.
@@ -54,7 +54,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: wd.c,v 1.410 2014/07/25 08:22:08 dholland Exp $");
+__KERNEL_RCSID(0, "$NetBSD: wd.c,v 1.411 2014/07/25 08:34:27 dholland Exp $");
 
 #include "opt_ata.h"
 
@@ -1552,24 +1552,6 @@
                return 0;
            }
 
-       case DIOCGDISCARDPARAMS: {
-               struct disk_discard_params * tp;
-
-               if (!(wd->sc_params.atap_ata_major & WDC_VER_ATA7)
-                   || !(wd->sc_params.support_dsm & ATA_SUPPORT_DSM_TRIM))
-                       return ENOTTY;
-               tp = (struct disk_discard_params *)addr;
-               tp->maxsize = 0xffff; /*wd->sc_params.max_dsm_blocks*/
-               aprint_debug_dev(wd->sc_dev, "TRIM maxsize %ld\n", tp->maxsize);
-               return 0;
-       }
-       case DIOCDISCARD: {
-               struct disk_discard_range *dr;
-
-               dr = addr;
-               return wd_trim(wd, WDPART(dev), dr->bno, dr->size);
-       }
-
        default:
                return ENOTTY;
        }



Home | Main Index | Thread Index | Old Index