diff options
author | Hans Rosenfeld <hans.rosenfeld@joyent.com> | 2017-10-16 16:06:50 +0200 |
---|---|---|
committer | Hans Rosenfeld <hans.rosenfeld@joyent.com> | 2018-09-26 21:30:14 +0200 |
commit | d48defc5a82c2bc955d3c8c9a5a3c7ccea87d5d4 (patch) | |
tree | 1e44c9503f12229e65e6be2d1272a04b903da448 | |
parent | fbd54cb5fecaf7d64cca371aa5ff1b2a8a3d5a11 (diff) | |
download | illumos-joyent-d48defc5a82c2bc955d3c8c9a5a3c7ccea87d5d4.tar.gz |
9793 vioblk attach doesn't always fail when it should
Reviewed by: Robert Mustacchi <rm@joyent.com>
Reviewed by: Patrick Mooney <patrick.mooney@joyent.com>
Reviewed by: Toomas Soome <tsoome@me.com>
Reviewed by: Andy Fiddaman <omnios@citrus-it.net>
Approved by: Garrett D'Amore <garrett@damore.org>
-rw-r--r-- | usr/src/uts/common/io/vioblk/vioblk.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/usr/src/uts/common/io/vioblk/vioblk.c b/usr/src/uts/common/io/vioblk/vioblk.c index 141a3eddb6..aeabada516 100644 --- a/usr/src/uts/common/io/vioblk/vioblk.c +++ b/usr/src/uts/common/io/vioblk/vioblk.c @@ -22,6 +22,7 @@ /* * Copyright (c) 2015, Nexenta Systems, Inc. All rights reserved. * Copyright (c) 2012, Alexey Zaytsev <alexey.zaytsev@gmail.com> + * Copyright 2017, Joyent Inc. */ @@ -829,13 +830,11 @@ vioblk_attach(dev_info_t *devinfo, ddi_attach_cmd_t cmd) case DDI_RESUME: case DDI_PM_RESUME: dev_err(devinfo, CE_WARN, "resume not supported yet"); - ret = DDI_FAILURE; - goto exit; + return (DDI_FAILURE); default: dev_err(devinfo, CE_WARN, "cmd 0x%x not recognized", cmd); - ret = DDI_FAILURE; - goto exit; + return (DDI_FAILURE); } sc = kmem_zalloc(sizeof (struct vioblk_softc), KM_SLEEP); @@ -1029,8 +1028,7 @@ exit_intrstat: mutex_destroy(&sc->lock_devid); cv_destroy(&sc->cv_devid); kmem_free(sc, sizeof (struct vioblk_softc)); -exit: - return (ret); + return (DDI_FAILURE); } static int |