From 130de5bcaba592a98aaf71d8c9398e1448b20383 Mon Sep 17 00:00:00 2001 From: Mark Kettenis Date: Wed, 2 Aug 2023 19:58:53 +0000 Subject: Set a low water mark on scsi_xfer_pool and prime the pool. This way there will always be some scsi_xfer structures around. Hopefully that means the pagedaemon can actually write out pages to swap if we're out of physical memory. ok krw@ --- sys/scsi/scsi_base.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sys/scsi/scsi_base.c b/sys/scsi/scsi_base.c index 559df94fcfb..110b49628ab 100644 --- a/sys/scsi/scsi_base.c +++ b/sys/scsi/scsi_base.c @@ -1,4 +1,4 @@ -/* $OpenBSD: scsi_base.c,v 1.282 2023/07/06 10:17:43 visa Exp $ */ +/* $OpenBSD: scsi_base.c,v 1.283 2023/08/02 19:58:52 kettenis Exp $ */ /* $NetBSD: scsi_base.c,v 1.43 1997/04/02 02:29:36 mycroft Exp $ */ /* @@ -138,6 +138,8 @@ scsi_init(void) /* Initialize the scsi_xfer pool. */ pool_init(&scsi_xfer_pool, sizeof(struct scsi_xfer), 0, IPL_BIO, 0, "scxspl", NULL); + pool_setlowat(&scsi_xfer_pool, 8); + pool_prime(&scsi_xfer_pool, 8); pool_init(&scsi_plug_pool, sizeof(struct scsi_plug), 0, IPL_BIO, 0, "scsiplug", NULL); } -- cgit v1.2.3