0a6e34e950
The cylinder group header structure ended with `u_int8_t cg_space[1]' representing the beginning of the inode bitmap array. Some architectures like the i386 rounded this up to a 4-byte boundry while other architectures like the amd64 rounded it up to an 8-byte boundry. Thus sizeof(struct cg) was four bytes bigger on an amd64 machine than on an i386 machine. If a filesystem created on an i386 machine was moved to an amd64 machine, the size of the cylinder group calculated by the CGSIZE macro would appear to grow by four bytes. Filesystems whose cylinder groups were exactly equal to the block size on an i386 machine would appear to have a cylinder group that was four bytes too big when moved to an amd64 machine. Note that although the structure appears to be too big, it in fact is fine. It is just the calaculation of its size that is in error. The fix is to remove the cg_space element from the cylinder-group structure so that the calculated size of the structure is the same size on all architectures. Reported by: Tijl Coosemans Tested by: Tijl Coosemans and Peter Holm MFC after: 1 week Sponsored by: The FreeBSD Foundation |
||
---|---|---|
.. | ||
tests | ||
debug.c | ||
debug.h | ||
growfs.8 | ||
growfs.c | ||
Makefile | ||
Makefile.depend |