diff options
author | jv227347 <Jordan.Vaughan@Sun.com> | 2009-01-30 12:25:48 -0800 |
---|---|---|
committer | jv227347 <Jordan.Vaughan@Sun.com> | 2009-01-30 12:25:48 -0800 |
commit | 5679c89fcd2facbb4334df8870d3d7a4d2b11673 (patch) | |
tree | bd866343c67036778a29b550abaecd793de008cd /usr/src/uts/common/conf | |
parent | 7b26d9ff58e6ee1f319b41c922c7ac8d3cb4804c (diff) | |
download | illumos-joyent-5679c89fcd2facbb4334df8870d3d7a4d2b11673.tar.gz |
PSARC/2008/647 Configurable Hostids for Non-Global Zones
6580939 RFE: provide unique hostid for each non-global zone
Diffstat (limited to 'usr/src/uts/common/conf')
-rw-r--r-- | usr/src/uts/common/conf/param.c | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/usr/src/uts/common/conf/param.c b/usr/src/uts/common/conf/param.c index 3d43511623..5831545a33 100644 --- a/usr/src/uts/common/conf/param.c +++ b/usr/src/uts/common/conf/param.c @@ -19,7 +19,7 @@ * CDDL HEADER END */ /* - * Copyright 2008 Sun Microsystems, Inc. All rights reserved. + * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ @@ -63,6 +63,7 @@ #include <sys/cyclic_impl.h> #include <sys/disp.h> #include <sys/tuneable.h> +#include <sys/systeminfo.h> #include <sys/vmem.h> #include <sys/clock.h> @@ -494,6 +495,14 @@ struct var v; /* System Configuration Information */ * System Configuration Information */ +/* + * The physical system's host identifier, expressed as a decimal string. + * Code should only directly access this value when writing to it (setting the + * physical system's host identifier). Code that reads the physical system's + * host identifier should use zone_get_hostid(NULL) instead. + */ +char hw_serial[HW_HOSTID_LEN] = "0"; + #if defined(__sparc) /* @@ -502,7 +511,6 @@ struct var v; /* System Configuration Information */ */ char architecture[] = "sparcv9"; char architecture_32[] = "sparc"; -char hw_serial[11]; char hw_provider[] = "Sun_Microsystems"; #elif defined(__i386) @@ -513,7 +521,6 @@ char hw_provider[] = "Sun_Microsystems"; */ char architecture[] = "i386"; char architecture_32[] = "i386"; -char hw_serial[11] = "0"; char hw_provider[SYS_NMLN] = ""; #elif defined(__amd64) @@ -524,7 +531,6 @@ char hw_provider[SYS_NMLN] = ""; */ char architecture[] = "amd64"; char architecture_32[] = "i386"; -char hw_serial[11] = "0"; char hw_provider[SYS_NMLN] = ""; #else |