summaryrefslogtreecommitdiff
path: root/sys/dev/ic/twe.c
diff options
context:
space:
mode:
authorKenneth R Westerback <krw@cvs.openbsd.org>2020-02-15 18:02:01 +0000
committerKenneth R Westerback <krw@cvs.openbsd.org>2020-02-15 18:02:01 +0000
commit7f575b2b90078628c0244d2ad6ee8966d19a2500 (patch)
tree104e763abd59dc41ad47208cb0ecb0dfe9ecb9e1 /sys/dev/ic/twe.c
parent041333ded23476ee20b2d905937694662dc6849b (diff)
*_minphys() functions that cap i/o sizes at a value larger than the
value minphys() uses (MAXPHYS) are pointless since minphys() is always called after the *_minphys() function. MAXPHYS (64 * 1024) == 16 * 4096. 4096 is the smallest PAGE_SIZE we have. So a *_minphys() function that caps the i/o size at N * PAGE_SIZE where N is > 16 is just wasting cycles. Nuke adv_minphys (40 * PAGE_SIZE), adw_minphys (254 * PAGE_SIZE), ahc_minphys (128 * PAGE_SIZE), ahd_minphys (128 * PAGE_SIZE), ami_minphys (26 * PAGE_SIZE), cac_minphys (65535 (!!!) * 512), iha_minphsy (32 * PAGE_SIZE), trm_minphys (31 * PAGE_SIZE), twe_minphys (62 * PAGE_SIZE). uha_minphys (32 * PAGE_SIZE),
Diffstat (limited to 'sys/dev/ic/twe.c')
-rw-r--r--sys/dev/ic/twe.c11
1 files changed, 2 insertions, 9 deletions
diff --git a/sys/dev/ic/twe.c b/sys/dev/ic/twe.c
index 61637da28cb..6b6a8a6f30a 100644
--- a/sys/dev/ic/twe.c
+++ b/sys/dev/ic/twe.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: twe.c,v 1.50 2020/01/26 00:53:31 krw Exp $ */
+/* $OpenBSD: twe.c,v 1.51 2020/02/15 18:02:00 krw Exp $ */
/*
* Copyright (c) 2000-2002 Michael Shalayeff. All rights reserved.
@@ -65,7 +65,7 @@ struct cfdriver twe_cd = {
void twe_scsi_cmd(struct scsi_xfer *);
struct scsi_adapter twe_switch = {
- twe_scsi_cmd, twe_minphys, NULL, NULL, NULL
+ twe_scsi_cmd, NULL, NULL, NULL, NULL
};
void *twe_get_ccb(void *);
@@ -753,13 +753,6 @@ twe_done(sc, ccb)
}
void
-twe_minphys(struct buf *bp, struct scsi_link *sl)
-{
- if (bp->b_bcount > TWE_MAXFER)
- bp->b_bcount = TWE_MAXFER;
-}
-
-void
twe_copy_internal_data(xs, v, size)
struct scsi_xfer *xs;
void *v;