fs-root revision 6927f468b0af7710df000f6b16f6ee413e1e3007
# The contents of this file are subject to the terms of the # Common Development and Distribution License (the "License"). # You may not use this file except in compliance with the License. # See the License for the specific language governing permissions # and limitations under the License. # When distributing Covered Code, include this CDDL HEADER in each # If applicable, add the following below this CDDL HEADER, with the # fields enclosed by brackets "[]" replaced with your own identifying # information: Portions Copyright [yyyy] [name of copyright owner] # Copyright 2006 Sun Microsystems, Inc. All rights reserved. # Use is subject to license terms. # ident "%Z%%M% %I% %E% SMI" # Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T. # Make sure that the libraries essential to this stage of booting can be found. # If there is an optimized libc available in /usr that fits this # processor, mount it on top of the base libc. # This mount function is sun4v only. It may be melded with the sun4u-us3 # This is specific to sun4u[-us3]. # try to intelligently handle the various ways that a hwcap library can # be present for libc_psr for sun4u. # first look for $PLAT specific # the string $HWCAP is not an env var but part of the argument to moe # try the 'generic' one under $ARCH # Most of the operations in this script are only necessary in the global # zone but due to the way initialization scripts like this are packaged, # it needs to currently exist for all zones. # Root is already mounted (by the kernel), but still needs to be # checked, possibly remounted and entered into mnttab. First # mount /usr read only if it is a separate file system. This must # be done first to allow utilities such as fsck and setmnt to # reside on /usr minimizing the space required by the root file # Mount without the cache initially. We'll enable it # later at remount time. This lets us avoid # teaching the statically linked mount program about # cachefs. Here we determine the backfstype. # This is not pretty, but we have no tools for parsing # the option string until we get /usr mounted... msg=
'invalid vfstab entry for /usr' # Must use -o largefiles here to ensure the # read-only mount does not fail as a result of # having a large file present on /usr. This gives # fsck a chance to fix up the largefiles flag # before we remount /usr read-write. # Requesting logging on a read-only mount # causes errors to be displayed, so remove # "logging" from the list of options for now. # The read-write mount performed later will # specify the logging option if appropriate. # Also mount /boot now so that things like keymap.sh can access # boot properties through eeprom. Readonly isn't required because # /boot (and other pcfs filesystems) aren't fsck'ed at boot yet. # Also, we don't account for caching /boot as it must be on a local # disk. So what's in vfstab is fine as it stands; just look to see # if it's there and avoid the mount if not. # files found on /usr, and device permissions from /etc/minor_perm. # Discover architecture and find and mount optimal libc_psr if [
"$ARCH" =
"sun4v" ];
then elif [
"$ARCH" =
"sun4u" ];
then