X-Git-Url: https://git.camperquake.de/gitweb.cgi?a=blobdiff_plain;f=module%2Fzfs%2Fzfs_fm.c;h=7801837f104b8166d09888c5c15e69eff147d192;hb=ee5fd0bb80d68ef095f831784cbb17181b2ba898;hp=c93057e8e8d1654f2f75b9e1110c07f75f9f5095;hpb=266852767f42781821c1d62544c9b9e985828304;p=zfs.git diff --git a/module/zfs/zfs_fm.c b/module/zfs/zfs_fm.c index c93057e..7801837 100644 --- a/module/zfs/zfs_fm.c +++ b/module/zfs/zfs_fm.c @@ -23,6 +23,10 @@ * Use is subject to license terms. */ +/* + * Copyright (c) 2012 by Delphix. All rights reserved. + */ + #include #include #include @@ -144,22 +148,6 @@ zfs_ereport_start(nvlist_t **ereport_out, nvlist_t **detector_out, zio->io_type != ZIO_TYPE_WRITE) return; - /* - * Ignore any errors from speculative I/Os, as failure is an - * expected result. - */ - if (zio->io_flags & ZIO_FLAG_SPECULATIVE) - return; - - /* - * If this I/O is not a retry I/O, don't post an ereport. - * Otherwise, we risk making bad diagnoses based on B_FAILFAST - * I/Os. - */ - if (zio->io_error == EIO && - !(zio->io_flags & ZIO_FLAG_IO_RETRY)) - return; - if (vd != NULL) { /* * If the vdev has already been marked as failing due @@ -304,6 +292,10 @@ zfs_ereport_start(nvlist_t **ereport_out, nvlist_t **detector_out, */ fm_payload_set(ereport, FM_EREPORT_PAYLOAD_ZFS_ZIO_ERR, DATA_TYPE_INT32, zio->io_error, NULL); + fm_payload_set(ereport, FM_EREPORT_PAYLOAD_ZFS_ZIO_FLAGS, + DATA_TYPE_INT32, zio->io_flags, NULL); + fm_payload_set(ereport, FM_EREPORT_PAYLOAD_ZFS_ZIO_DELAY, + DATA_TYPE_UINT64, zio->io_delay, NULL); /* * If the 'size' parameter is non-zero, it indicates this is a @@ -718,6 +710,10 @@ zfs_ereport_start_checksum(spa_t *spa, vdev_t *vd, if (report->zcr_ereport == NULL) { report->zcr_free(report->zcr_cbdata, report->zcr_cbinfo); + if (report->zcr_ckinfo != NULL) { + kmem_free(report->zcr_ckinfo, + sizeof (*report->zcr_ckinfo)); + } kmem_free(report, sizeof (*report)); return; }