add a kernel configuration option to set the string passed in bp_file

in diskless BOOTP/DHCP configuration - good for booting different
userland versions depending on the kernel version
This commit is contained in:
drochner 2000-12-05 17:59:43 +00:00
parent 2d8bb6f643
commit 8f6e088214
2 changed files with 6 additions and 2 deletions

View File

@ -1,4 +1,4 @@
# $NetBSD: files,v 1.407 2000/12/02 20:43:08 scw Exp $
# $NetBSD: files,v 1.408 2000/12/05 17:59:43 drochner Exp $
# @(#)files.newconf 7.5 (Berkeley) 5/10/93
@ -20,6 +20,7 @@ defopt opt_sysvparam.h SHMMAXPGS SEMMNI SEMMNS SEMUME SEMMNU
defopt opt_ntp.h PPS_SYNC NTP
defopt opt_nfs_boot.h NFS_BOOT_BOOTP NFS_BOOT_BOOTPARAM NFS_BOOT_DHCP
NFS_BOOT_BOOTP_REQFILE
NFS_BOOT_GATEWAY
NFS_BOOT_TCP NFS_BOOT_OPTIONS NFS_BOOT_RWSIZE
defopt opt_nfs.h NFS_V2_ONLY

View File

@ -1,4 +1,4 @@
/* $NetBSD: nfs_bootdhcp.c,v 1.15 2000/05/28 07:01:09 gmcgarry Exp $ */
/* $NetBSD: nfs_bootdhcp.c,v 1.16 2000/12/05 17:59:43 drochner Exp $ */
/*-
* Copyright (c) 1995, 1997 The NetBSD Foundation, Inc.
@ -547,6 +547,9 @@ bootpc_call(nd, procp)
bootp->bp_hlen = halen; /* Hardware address length */
bootp->bp_xid = ++xid;
memcpy(bootp->bp_chaddr, haddr, halen);
#ifdef NFS_BOOT_BOOTP_REQFILE
strncpy(bootp->bp_file, NFS_BOOT_BOOTP_REQFILE, sizeof(bootp->bp_file));
#endif
/* Fill-in the vendor data. */
memcpy(bootp->bp_vend, vm_rfc1048, 4);
#ifdef NFS_BOOT_DHCP