Re: [PATCH] xfs_db: allow recalculating CRCs on invalid metadata

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On 5/12/16 6:28 PM, Dave Chinner wrote:
>>> +
>>> > > +	if (corrupt) {
>>> > >  		nowrite_ops.verify_write = xfs_dummy_verify;
>>> > > -		iocur_top->bp->b_ops = &nowrite_ops;
>>> > > -		dbprintf(_("Allowing write of corrupted data\n"));
>>> > > +		dbprintf(_("Allowing write of corrupted data and bad CRC\n"));
>>> > > +	} else {
>> > 
>> > Maybe a helpful/redundant comment about /* invalid_data */ alongside } else { ?
> I though the dbprintf() documented it well enough? maybe move that
> to the top of each branch?

Oh, I suppose it does.  By the time we returned early on !corrupt & ! invalid_data,
then tested explicitly for (corrupt), it requires a decent brain-stack to 
remember what the } else { clause is for, IMHO.

But like I said, just a thought.

-Eric

_______________________________________________
xfs mailing list
xfs@xxxxxxxxxxx
http://oss.sgi.com/mailman/listinfo/xfs



[Index of Archives]     [Linux XFS Devel]     [Linux Filesystem Development]     [Filesystem Testing]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux