diff options
author | Achim Maurer <Achim.Maurer@Sun.COM> | 2009-01-09 13:42:37 -0800 |
---|---|---|
committer | Achim Maurer <Achim.Maurer@Sun.COM> | 2009-01-09 13:42:37 -0800 |
commit | 8d3e758bff27e5f861c26b99da9fb94cf5a41b23 (patch) | |
tree | 69b551f5a35d93c8699ec8899ec612ebfd7ad66f /usr/src/lib/lvm | |
parent | f13a3029268921bbc7dd12be1c5ab90599b37d79 (diff) | |
download | illumos-joyent-8d3e758bff27e5f861c26b99da9fb94cf5a41b23.tar.gz |
6754142 slow metainit commands may occur in a SunCluster environment due to devfsadm not being bound to it
Diffstat (limited to 'usr/src/lib/lvm')
-rw-r--r-- | usr/src/lib/lvm/libmeta/common/sdssc_bind.c | 19 |
1 files changed, 8 insertions, 11 deletions
diff --git a/usr/src/lib/lvm/libmeta/common/sdssc_bind.c b/usr/src/lib/lvm/libmeta/common/sdssc_bind.c index c8e1f8c3ee..5abbb841aa 100644 --- a/usr/src/lib/lvm/libmeta/common/sdssc_bind.c +++ b/usr/src/lib/lvm/libmeta/common/sdssc_bind.c @@ -2,9 +2,8 @@ * CDDL HEADER START * * The contents of this file are subject to the terms of the - * Common Development and Distribution License, Version 1.0 only - * (the "License"). You may not use this file except in compliance - * with the License. + * Common Development and Distribution License (the "License"). + * You may not use this file except in compliance with the License. * * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE * or http://www.opensolaris.org/os/licensing. @@ -20,12 +19,10 @@ * CDDL HEADER END */ /* - * Copyright 2004 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ -#pragma ident "%Z%%M% %I% %E% SMI" - /* * Block comment which describes the contents of this file. */ @@ -140,19 +137,19 @@ sdssc_bind_library(void) void *dp; int (*lb)(); func_table_p ftp; + static int initialised = 0; /* * If already bound then just return okay so this routine * becomes idempotent. If this check isn't made then we'll * fail when calling the "_bind_library" function because * dcs_initialize() can only be called once. + * If not bound first time we try it again. */ - if (sdssc_version != 0) { - if ((void *)sdssc_version == (void *)not_bound) - return (SDSSC_NOT_BOUND); - else - return (SDSSC_OKAY); + if (initialised && (void *)sdssc_version != (void *)not_bound) { + return (SDSSC_OKAY); } + initialised = 1; if ((dp = dlopen(SDSSC_PATH, RTLD_LAZY)) == NULL) { set_common_routine(); |