From 2bd78861daf04f2a8a138592f716ee616c54cb44 Mon Sep 17 00:00:00 2001 From: Kenneth R Westerback Date: Wed, 5 Feb 2020 16:29:31 +0000 Subject: Nuke unnecessary abstraction 'scsi_minphys()' which just calls 'minphys()'. Just use & check for NULL instead, since 'minphys()' is always called on the code path ([cd|sd|st]minphys) that calls physio(). --- sys/scsi/st.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'sys/scsi/st.c') diff --git a/sys/scsi/st.c b/sys/scsi/st.c index 027a31fb262..81138969d5f 100644 --- a/sys/scsi/st.c +++ b/sys/scsi/st.c @@ -1,4 +1,4 @@ -/* $OpenBSD: st.c,v 1.175 2020/01/27 07:41:02 krw Exp $ */ +/* $OpenBSD: st.c,v 1.176 2020/02/05 16:29:30 krw Exp $ */ /* $NetBSD: st.c,v 1.71 1997/02/21 23:03:49 thorpej Exp $ */ /* @@ -1008,9 +1008,10 @@ stminphys(struct buf *bp) return; link = sc->sc_link; - (*link->adapter->dev_minphys)(bp, link); - if (link->adapter->dev_minphys != scsi_minphys) - scsi_minphys(bp, link); + if (link->adapter->dev_minphys != NULL) + (*link->adapter->dev_minphys)(bp, link); + + minphys(bp); device_unref(&sc->sc_dev); } -- cgit v1.2.3