diff options
| author | jdolecek <jdolecek@NetBSD.org> | 2020-06-19 19:29:39 +0000 |
|---|---|---|
| committer | jdolecek <jdolecek@NetBSD.org> | 2020-06-19 19:29:39 +0000 |
| commit | a17d07ef62d88312cc47a8c8a4377005e8d2de4c (patch) | |
| tree | 1e2df8e1b20f9ac94b11a646ce050fcffe0c409d /sys/dev/raidframe/rf_diskqueue.c | |
| parent | 9b92f961e9b186a31c7262a51e9dd1fd1e283039 (diff) | |
pass down b_flags B_PHYS|B_RAW|B_MEDIA_FLAGS from bio subsystem
to component I/O
fixes the xbd(4) KASSERT() triggered by raidframe, noted in PR kern/55397
by Frank Kardel
Diffstat (limited to 'sys/dev/raidframe/rf_diskqueue.c')
| -rw-r--r-- | sys/dev/raidframe/rf_diskqueue.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/sys/dev/raidframe/rf_diskqueue.c b/sys/dev/raidframe/rf_diskqueue.c index 356bda0da59..6312168d3ad 100644 --- a/sys/dev/raidframe/rf_diskqueue.c +++ b/sys/dev/raidframe/rf_diskqueue.c @@ -1,4 +1,4 @@ -/* $NetBSD: rf_diskqueue.c,v 1.56 2019/10/10 03:43:59 christos Exp $ */ +/* $NetBSD: rf_diskqueue.c,v 1.57 2020/06/19 19:29:39 jdolecek Exp $ */ /* * Copyright (c) 1995 Carnegie-Mellon University. * All rights reserved. @@ -66,7 +66,7 @@ ****************************************************************************/ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: rf_diskqueue.c,v 1.56 2019/10/10 03:43:59 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: rf_diskqueue.c,v 1.57 2020/06/19 19:29:39 jdolecek Exp $"); #include <dev/raidframe/raidframevar.h> @@ -362,7 +362,7 @@ rf_CreateDiskQueueData(RF_IoType_t typ, RF_SectorNum_t ssect, RF_ReconUnitNum_t which_ru, void (*wakeF) (void *, int), void *arg, RF_AccTraceEntry_t *tracerec, RF_Raid_t *raidPtr, - RF_DiskQueueDataFlags_t flags, void *kb_proc, + RF_DiskQueueDataFlags_t flags, const struct buf *mbp, int waitflag) { RF_DiskQueueData_t *p; @@ -381,6 +381,10 @@ rf_CreateDiskQueueData(RF_IoType_t typ, RF_SectorNum_t ssect, return (NULL); } SET(p->bp->b_cflags, BC_BUSY); /* mark buffer busy */ + if (mbp) { + SET(p->bp->b_flags, mbp->b_flags & rf_b_pass); + p->bp->b_proc = mbp->b_proc; + } p->sectorOffset = ssect + rf_protectedSectors; p->numSector = nsect; @@ -395,7 +399,6 @@ rf_CreateDiskQueueData(RF_IoType_t typ, RF_SectorNum_t ssect, p->priority = RF_IO_NORMAL_PRIORITY; p->raidPtr = raidPtr; p->flags = flags; - p->b_proc = kb_proc; return (p); } |
