171 |
|
char *value; |
172 |
|
int instance; |
173 |
|
if ((root_node = di_init("/", DINFOCPYALL)) == DI_NODE_NIL) { |
174 |
< |
return 1; |
174 |
> |
return -1; |
175 |
|
} |
176 |
|
node = di_drv_first_node(alias, root_node); |
177 |
|
while (node != DI_NODE_NIL) { |
213 |
|
int found; |
214 |
|
|
215 |
|
if ((kc = kstat_open()) == NULL) { |
216 |
< |
return 1; |
216 |
> |
return -1; |
217 |
|
} |
218 |
|
|
219 |
|
for (ksp = kc->kc_chain; ksp; ksp = ksp->ks_next) { |
235 |
|
if (x>=BIG_ENOUGH){ |
236 |
|
/* We've got bigger than we thought was massive */ |
237 |
|
/* If we hit this.. Make big enough bigger */ |
238 |
< |
return 1; |
238 |
> |
return -1; |
239 |
|
} |
240 |
|
if( !strncmp(driver_list[x], device_name, BIG_ENOUGH)){ |
241 |
|
found = 1; |
245 |
|
|
246 |
|
if(!found){ |
247 |
|
if((get_alias(device_name)) != 0){ |
248 |
< |
return 1; |
248 |
> |
return -1; |
249 |
|
} |
250 |
|
strncpy(driver_list[x], device_name, BIG_ENOUGH); |
251 |
|
list_entries++; |
479 |
|
int sg_init(){ |
480 |
|
#if (defined(FREEBSD) && !defined(FREEBSD5)) || defined(DFBSD) |
481 |
|
if (sg_get_kvm() == NULL) { |
482 |
< |
return 1; |
482 |
> |
return -1; |
483 |
|
} |
484 |
|
if (sg_get_kvm2() == NULL) { |
485 |
< |
return 1; |
485 |
> |
return -1; |
486 |
|
} |
487 |
|
#endif |
488 |
|
#ifdef SOLARIS |