salvager: Create link table with volume group id

The link table needs to be created with the VG id or RW vol id, not
the non-RW vol id. Unlike other special inodes, this goes for both the
'parent' and 'volume' volume ids, not just the 'parent' id, since
there is only one link table per VG.

Without this, the salvager can generate invalid linktable special
inodes if it encounters a VG with no inodes for the RW vol.

Change-Id: I10725c514ef1b8a5b09a506e42596b51b74af5a2
Reviewed-on: http://gerrit.openafs.org/6179
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Derrick Brashear <shadow@dementix.org>
This commit is contained in:
Andrew Deason 2011-12-02 14:36:59 -06:00 committed by Derrick Brashear
parent 53230846a2
commit ae227049fc

View File

@ -1808,7 +1808,7 @@ CreateLinkTable(struct SalvInfo *salvinfo, struct InodeSummary *isp, Inode ino)
if (!VALID_INO(ino)) if (!VALID_INO(ino))
ino = ino =
IH_CREATE(NULL, salvinfo->fileSysDevice, salvinfo->fileSysPath, 0, isp->volumeId, IH_CREATE(NULL, salvinfo->fileSysDevice, salvinfo->fileSysPath, 0, isp->RWvolumeId,
INODESPECIAL, VI_LINKTABLE, isp->RWvolumeId); INODESPECIAL, VI_LINKTABLE, isp->RWvolumeId);
if (!VALID_INO(ino)) if (!VALID_INO(ino))
Abort Abort