From: hm@seneca.muc.de (Harald Milz)
To: netboot@baghira.han.de
Subject: (fwd) NFSROOT broken in 2.1.32
Newsgroups: linux.dev.kernel
Organization: Linux.DE
X-PGP-Fingerprint: 44 5B 4E 65 50 F5 99 2B 20 55 C1 B0 56 FC C4 00
X-Nospam: Unsolicited ads are unwanted and will be proofread for $199/hr.
You might be interested in this one. Sorry if you got it twice now.
Newsgroups: linux.dev.kernel
From: bofh@snoopy.virtual.net.au
Subject: NFSROOT broken in 2.1.32
Date: 06 Apr 1997 17:24:50 GMT
NFS root is badly broken in 2.1.32 (basically the core NFS code has been massively changed without any changes being made to nfsroot.c). Here is a patch I've developed which fixes the easy problems in nfsroot.c for anyone who wants to investigate it further:
*** nfsroot.c.orig Mon Apr 7 01:51:16 1997
--- nfsroot.c Mon Apr 7 02:13:51 1997
***************
*** 59,64 ****
--- 59,65 ----
#undef NFSROOT_DEBUG
#undef NFSROOT_BOOTP_DEBUG
+ #include <linux/sunrpc/clnt.h>
#include <linux/config.h>
#include <linux/types.h>
***************
*** 1576,1583 ****
int *p;
/* Prepare header for portmap request */
! server.sin_port = htons(NFS_PMAP_PORT);
! p = root_nfs_header(NFS_PMAP_PROC, NFS_PMAP_PROGRAM, NFS_PMAP_VERSION);
if (!p)
return -1;
--- 1577,1584 ----
int *p;
/* Prepare header for portmap request */
! server.sin_port = htons(RPC_PMAP_PORT);
! p = root_nfs_header(NFSPROC_ROOT, NFS_PROGRAM, NFS_VERSION);
if (!p)
return -1;
***************
*** 1603,1611 ****
int port;
if (nfs_port < 0) {
! if ((port = root_nfs_get_port(NFS_NFS_PROGRAM, NFS_NFS_VERSION)) < 0) {
printk(KERN_ERR "Root-NFS: Unable to get nfsd port number from server, using default\n");
! port = NFS_NFS_PORT;
}
nfs_port = port;
#ifdef NFSROOT_DEBUG
--- 1604,1612 ----
int port;
if (nfs_port < 0) {
! if ((port = root_nfs_get_port(NFS_PROGRAM, NFS_VERSION)) < 0) {
printk(KERN_ERR "Root-NFS: Unable to get nfsd port number from server, using default\n");
! port = NFS_PORT;
}
nfs_port = port;
#ifdef NFSROOT_DEBUG
--
Harald Milz ----------- PGP Public Key: finger hm[AT]muc.de (Key ID 7ADC4839)
Yinkel, n.:
A person who combs his hair over his bald spot, hoping no one
will notice.
-- Rich Hall, "Sniglets"
For requests or suggestions regarding this mailing list archive please write to netboot@gkminix.han.de.