libzfs_import.c (302408) | libzfs_import.c (307107) |
---|---|
1/* 2 * CDDL HEADER START 3 * 4 * The contents of this file are subject to the terms of the 5 * Common Development and Distribution License (the "License"). 6 * You may not use this file except in compliance with the License. 7 * 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE --- 7 unchanged lines hidden (view full) --- 16 * fields enclosed by brackets "[]" replaced with your own identifying 17 * information: Portions Copyright [yyyy] [name of copyright owner] 18 * 19 * CDDL HEADER END 20 */ 21 22/* 23 * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. | 1/* 2 * CDDL HEADER START 3 * 4 * The contents of this file are subject to the terms of the 5 * Common Development and Distribution License (the "License"). 6 * You may not use this file except in compliance with the License. 7 * 8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE --- 7 unchanged lines hidden (view full) --- 16 * fields enclosed by brackets "[]" replaced with your own identifying 17 * information: Portions Copyright [yyyy] [name of copyright owner] 18 * 19 * CDDL HEADER END 20 */ 21 22/* 23 * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. |
24 * Copyright (c) 2013 by Delphix. All rights reserved. | 24 * Copyright (c) 2012, 2015 by Delphix. All rights reserved. |
25 * Copyright 2015 RackTop Systems. 26 * Copyright 2016 Nexenta Systems, Inc. 27 */ 28 29/* 30 * Pool import support functions. 31 * 32 * To import a pool, we rely on reading the configuration information from the --- 402 unchanged lines hidden (view full) --- 435 * return to the user. 436 */ 437static nvlist_t * 438get_configs(libzfs_handle_t *hdl, pool_list_t *pl, boolean_t active_ok) 439{ 440 pool_entry_t *pe; 441 vdev_entry_t *ve; 442 config_entry_t *ce; | 25 * Copyright 2015 RackTop Systems. 26 * Copyright 2016 Nexenta Systems, Inc. 27 */ 28 29/* 30 * Pool import support functions. 31 * 32 * To import a pool, we rely on reading the configuration information from the --- 402 unchanged lines hidden (view full) --- 435 * return to the user. 436 */ 437static nvlist_t * 438get_configs(libzfs_handle_t *hdl, pool_list_t *pl, boolean_t active_ok) 439{ 440 pool_entry_t *pe; 441 vdev_entry_t *ve; 442 config_entry_t *ce; |
443 nvlist_t *ret = NULL, *config = NULL, *tmp, *nvtop, *nvroot; | 443 nvlist_t *ret = NULL, *config = NULL, *tmp = NULL, *nvtop, *nvroot; |
444 nvlist_t **spares, **l2cache; 445 uint_t i, nspares, nl2cache; 446 boolean_t config_seen; 447 uint64_t best_txg; | 444 nvlist_t **spares, **l2cache; 445 uint_t i, nspares, nl2cache; 446 boolean_t config_seen; 447 uint64_t best_txg; |
448 char *name, *hostname; | 448 char *name, *hostname = NULL; |
449 uint64_t guid; 450 uint_t children = 0; 451 nvlist_t **child = NULL; 452 uint_t holes; 453 uint64_t *hole_array, max_id; 454 uint_t c; 455 boolean_t isactive; 456 uint64_t hostid; --- 1292 unchanged lines hidden --- | 449 uint64_t guid; 450 uint_t children = 0; 451 nvlist_t **child = NULL; 452 uint_t holes; 453 uint64_t *hole_array, max_id; 454 uint_t c; 455 boolean_t isactive; 456 uint64_t hostid; --- 1292 unchanged lines hidden --- |