nfs_vfsops.c (180780) | nfs_vfsops.c (181803) |
---|---|
1/*- 2 * Copyright (c) 1989, 1993, 1995 3 * The Regents of the University of California. All rights reserved. 4 * 5 * This code is derived from software contributed to Berkeley by 6 * Rick Macklem at The University of Guelph. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 19 unchanged lines hidden (view full) --- 28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30 * SUCH DAMAGE. 31 * 32 * @(#)nfs_vfsops.c 8.12 (Berkeley) 5/20/95 33 */ 34 35#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 1989, 1993, 1995 3 * The Regents of the University of California. All rights reserved. 4 * 5 * This code is derived from software contributed to Berkeley by 6 * Rick Macklem at The University of Guelph. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 19 unchanged lines hidden (view full) --- 28 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 29 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 30 * SUCH DAMAGE. 31 * 32 * @(#)nfs_vfsops.c 8.12 (Berkeley) 5/20/95 33 */ 34 35#include <sys/cdefs.h> |
36__FBSDID("$FreeBSD: head/sys/nfsclient/nfs_vfsops.c 180780 2008-07-24 14:02:03Z dfr $"); | 36__FBSDID("$FreeBSD: head/sys/nfsclient/nfs_vfsops.c 181803 2008-08-17 23:27:27Z bz $"); |
37 38 39#include "opt_bootp.h" 40#include "opt_nfsroot.h" 41 42#include <sys/param.h> 43#include <sys/systm.h> 44#include <sys/kernel.h> --- 6 unchanged lines hidden (view full) --- 51#include <sys/mount.h> 52#include <sys/proc.h> 53#include <sys/socket.h> 54#include <sys/socketvar.h> 55#include <sys/sockio.h> 56#include <sys/sysctl.h> 57#include <sys/vnode.h> 58#include <sys/signalvar.h> | 37 38 39#include "opt_bootp.h" 40#include "opt_nfsroot.h" 41 42#include <sys/param.h> 43#include <sys/systm.h> 44#include <sys/kernel.h> --- 6 unchanged lines hidden (view full) --- 51#include <sys/mount.h> 52#include <sys/proc.h> 53#include <sys/socket.h> 54#include <sys/socketvar.h> 55#include <sys/sockio.h> 56#include <sys/sysctl.h> 57#include <sys/vnode.h> 58#include <sys/signalvar.h> |
59#include <sys/vimage.h> |
|
59 60#include <vm/vm.h> 61#include <vm/vm_extern.h> 62#include <vm/uma.h> 63 64#include <net/if.h> 65#include <net/route.h> 66#include <netinet/in.h> --- 437 unchanged lines hidden (view full) --- 504 } 505 506 /* 507 * This is not really an nfs issue, but it is much easier to 508 * set hostname here and then let the "/etc/rc.xxx" files 509 * mount the right /var based upon its preset value. 510 */ 511 mtx_lock(&hostname_mtx); | 60 61#include <vm/vm.h> 62#include <vm/vm_extern.h> 63#include <vm/uma.h> 64 65#include <net/if.h> 66#include <net/route.h> 67#include <netinet/in.h> --- 437 unchanged lines hidden (view full) --- 505 } 506 507 /* 508 * This is not really an nfs issue, but it is much easier to 509 * set hostname here and then let the "/etc/rc.xxx" files 510 * mount the right /var based upon its preset value. 511 */ 512 mtx_lock(&hostname_mtx); |
512 bcopy(nd->my_hostnam, hostname, MAXHOSTNAMELEN); 513 hostname[MAXHOSTNAMELEN - 1] = '\0'; | 513 bcopy(nd->my_hostnam, V_hostname, MAXHOSTNAMELEN); 514 V_hostname[MAXHOSTNAMELEN - 1] = '\0'; |
514 for (i = 0; i < MAXHOSTNAMELEN; i++) | 515 for (i = 0; i < MAXHOSTNAMELEN; i++) |
515 if (hostname[i] == '\0') | 516 if (V_hostname[i] == '\0') |
516 break; 517 mtx_unlock(&hostname_mtx); 518 inittodr(ntohl(nd->root_time)); 519 return (0); 520} 521 522/* 523 * Internal version of mount system call for diskless setup. --- 656 unchanged lines hidden --- | 517 break; 518 mtx_unlock(&hostname_mtx); 519 inittodr(ntohl(nd->root_time)); 520 return (0); 521} 522 523/* 524 * Internal version of mount system call for diskless setup. --- 656 unchanged lines hidden --- |