Source-Changes-HG archive

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

[src/trunk]: src/external/cddl/osnet/dist/uts/common/fs/zfs Set up more of a ...



details:   https://anonhg.NetBSD.org/src/rev/5245057dbbad
branches:  trunk
changeset: 971595:5245057dbbad
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Wed Apr 29 04:30:40 2020 +0000

description:
Set up more of a fake struct buf, for ldminphys.

Fixes:

arm64# zpool create rpool ld4
[ 198.4376097] panic: Trap: Data Abort (EL1): Translation Fault L1 with read access for 0000000000000178: pc ffffc0000017acf4: opcode f940bc00: ldr x0, [x0,#376]
[ 198.4694793] fp ffffc00073026660 ldminphys() at ffffc0000017acf4 netbsd:ldminphys+0x34
[ 198.4792624] fp ffffc00073026680 vdev_disk_open.part.4() at ffffc000013d4c4c zfs:vdev_disk_open.part.4+0x37c
[ 198.4792624] fp ffffc000730268d0 vdev_open() at ffffc000013d2530 zfs:vdev_open+0x68
[ 198.4792624] fp ffffc00073026920 vdev_open_children() at ffffc000013d2958 zfs:vdev_open_children+0x40
[ 198.4792624] fp ffffc00073026950 vdev_root_open() at ffffc000013dad48 zfs:vdev_root_open+0x30

XXX pullup-9

diffstat:

 external/cddl/osnet/dist/uts/common/fs/zfs/vdev_disk.c |  5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diffs (15 lines):

diff -r 5b41cbb6fceb -r 5245057dbbad external/cddl/osnet/dist/uts/common/fs/zfs/vdev_disk.c
--- a/external/cddl/osnet/dist/uts/common/fs/zfs/vdev_disk.c    Wed Apr 29 03:58:27 2020 +0000
+++ b/external/cddl/osnet/dist/uts/common/fs/zfs/vdev_disk.c    Wed Apr 29 04:30:40 2020 +0000
@@ -228,7 +228,10 @@
                dvd->vd_maxphys = (pdk ? disk_maxphys(pdk) : MACHINE_MAXPHYS);
        */
        {
-               struct buf buf = { .b_bcount = MAXPHYS };
+               struct buf buf = {
+                       .b_dev = vp->v_rdev,
+                       .b_bcount = MAXPHYS,
+               };
                if (pdk && pdk->dk_driver && pdk->dk_driver->d_minphys)
                        (*pdk->dk_driver->d_minphys)(&buf);
                dvd->vd_maxphys = buf.b_bcount;



Home | Main Index | Thread Index | Old Index