Re: [PATCH] nfsd: silence sparse warning about accessing credentials

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

 



On Tue, Jul 15, 2014 at 06:28:54AM -0400, Jeff Layton wrote:
> sparse says:
> 
>     fs/nfsd/auth.c:31:38: warning: incorrect type in argument 1 (different address spaces)
>     fs/nfsd/auth.c:31:38:    expected struct cred const *cred
>     fs/nfsd/auth.c:31:38:    got struct cred const [noderef] <asn:4>*real_cred
> 
> Add a new accessor for the ->real_cred and use that to fetch the
> pointer. Accessing current->real_cred directly is actually quite safe
> since we know that they can't go away so this is mostly a cosmetic fixup
> to silence sparse.

This looks reasonable, but I'd suggest Ccing linux-kernel for changes to
global headers.

Reviewed-by: Christoph Hellwig <hch@xxxxxx>
--
To unsubscribe from this list: send the line "unsubscribe linux-nfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Filesystem Development]     [Linux USB Development]     [Linux Media Development]     [Video for Linux]     [Linux NILFS]     [Linux Audio Users]     [Yosemite Info]     [Linux SCSI]

  Powered by Linux