Date: Mon, 25 Jul 2011 21:37:52 +0000 (UTC) From: Marius Strobl <marius@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org Subject: svn commit: r224403 - stable/7/sys/boot/common Message-ID: <201107252137.p6PLbqd3077907@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: marius Date: Mon Jul 25 21:37:52 2011 New Revision: 224403 URL: http://svn.freebsd.org/changeset/base/224403 Log: MFC: r192972 (partial) Some of the boot loader code only works on a ufs file system, but it uses the generic struct dirent, which happens to look identical to UFS's struct direct. If BSD ever changes dirent then this will be a problem. Submitted by: matthew dot fleming at isilon dot com Modified: stable/7/sys/boot/common/ufsread.c Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/boot/common/ufsread.c ============================================================================== --- stable/7/sys/boot/common/ufsread.c Mon Jul 25 20:13:35 2011 (r224402) +++ stable/7/sys/boot/common/ufsread.c Mon Jul 25 21:37:52 2011 (r224403) @@ -47,6 +47,7 @@ __FBSDID("$FreeBSD$"); #include <ufs/ufs/dinode.h> +#include <ufs/ufs/dir.h> #include <ufs/ffs/fs.h> #ifdef UFS_SMALL_CGBASE /* XXX: Revert to old (broken for over 1.5Tb filesystems) version of cgbase @@ -93,7 +94,7 @@ static __inline int fsfind(const char *name, ino_t * ino) { char buf[DEV_BSIZE]; - struct dirent *d; + struct direct *d; char *s; ssize_t n; @@ -104,7 +105,7 @@ fsfind(const char *name, ino_t * ino) if (ls) printf("%s ", d->d_name); else if (!strcmp(name, d->d_name)) { - *ino = d->d_fileno; + *ino = d->d_ino; return d->d_type; } s += d->d_reclen;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201107252137.p6PLbqd3077907>