summaryrefslogtreecommitdiff
tag namescrub-nlinks_2022-11-09 (1b05f6a024f0efac893181d62e40e0b8eb91c338)
tag date2022-11-09 19:10:05 -0800
tagged byDarrick J. Wong <djwong@kernel.org>
tagged objectcommit 9540456134...
xfs: online repair of file link counts
Now that we've created the infrastructure to perform live scans of every file in the filesystem and the necessary hook infrastructure to observe live updates, use it to scan directories to compute the correct link counts for files in the filesystem, and reset those link counts. This patchset creates a tailored readdir implementation for scrub because the regular version has to cycle ILOCKs to copy information to userspace. We can't cycle the ILOCK during the nlink scan and we don't need all the other VFS support code (maintaining a readdir cursor and translating XFS structures to VFS structures and back) so it was easier to duplicate the code. Signed-off-by: Darrick J. Wong <djwong@kernel.org> -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEUzaAxoMeQq6m2jMV+H93GTRKtOsFAmNsa40ACgkQ+H93GTRK tOupNA/+PvKi5rb45EuFeNWc5cyXhI+Ty/SsaBMhxyXTwj3XNflGXisvasielZJY BScGkZKJJ2Duc84X34zd/qy3DSIIS0G8kg59MLP7LkS7yf/o8y8QTE4cPbyvX0pr ut5QQViZ61iTka7qn5xm6zpUGNdGLHotKshDIpriPGGQqqwNDAF2GY/5c8qECkoU dD2M2qt/2kd0gCSeplhVgAK8C2CxPoAA+5h7fXM7acWMKqRQzEVeuOcM3NqtzAtg Qwp3DDDL72U32/OMzUThe6yN5yDnPmYgNW1ATigEtfUpsyNAPIGY5GVxgO+1l5yl L6kDQTubrGyxLmAUiNXykblwLN3aazmdW5JhSSYvlGsjZTPzp9WggydBO/GZbx9j ewSijemCkwUZ1JIui4qU3D+CB76QB3uNwEFVZOQ3xg9nZPkuoChwuek5Z18wHzZZ GUz8tTdTxRLQ5gRTSbudStknYGoDuavxNBGrPSU2xPIu4P68iu3F6hAy2v8CsuJl +WjV4lYQEBTaNgRrjlHmMQ3PbX55oIrcdRoS4YsZMPhlB4MoU9i7n9U87J6b4Tsz nxkFSV9FAM5dU2U6S5dASa2dCnZJ8pzahnqfAmQe+Q2YDMYgJ9Ub7FmpMeaN7Cbh nvxRBJsJ2bfK/hhUXJYeq/QxNejR1+wLo1lsPmf5ontWjMu7sdc= =EKmk -----END PGP SIGNATURE-----