• David Howells's avatar
    afs: Fix over zealous "vnode modified" warnings · 3647e42b
    David Howells authored
    Occasionally, warnings like this:
    
    	vnode modified 2af7 on {10000b:1} [exp 2af2] YFS.FetchStatus(vnode)
    
    are emitted into the kernel log.  This indicates that when we were applying
    the updated vnode (file) status retrieved from the server to an inode we
    saw that the data version number wasn't what we were expecting (in this
    case it's 0x2af7 rather than 0x2af2).
    
    We've usually received a callback from the server prior to this point - or
    the callback promise has lapsed - so the warning is merely informative and
    the state is to be expected.
    
    Fix this by only emitting the warning if the we still think that we have a
    valid callback promise and haven't received a callback.
    
    Also change the format slightly so so that the new data version doesn't
    look like part of the text, the like is prefixed with "kAFS: " and the
    message is ranked as a warning.
    
    Fixes: 31143d5d ("AFS: implement basic file write support")
    Reported-by: default avatarIan Wienand <iwienand@redhat.com>
    Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
    3647e42b
inode.c 21.9 KB