nfs4_fs.h (9938b04472d5c59f8bd8152a548533a8599596a2) | nfs4_fs.h (93b717fd81bf6b9a73c3702e9b079b4de8148b34) |
---|---|
1/* 2 * linux/fs/nfs/nfs4_fs.h 3 * 4 * Copyright (C) 2005 Trond Myklebust 5 * 6 * NFSv4-specific filesystem definitions and declarations 7 */ 8 --- 482 unchanged lines hidden (view full) --- 491struct nfs4_mount_data; 492 493/* callback_xdr.c */ 494extern struct svc_version nfs4_callback_version1; 495extern struct svc_version nfs4_callback_version4; 496 497static inline void nfs4_stateid_copy(nfs4_stateid *dst, const nfs4_stateid *src) 498{ | 1/* 2 * linux/fs/nfs/nfs4_fs.h 3 * 4 * Copyright (C) 2005 Trond Myklebust 5 * 6 * NFSv4-specific filesystem definitions and declarations 7 */ 8 --- 482 unchanged lines hidden (view full) --- 491struct nfs4_mount_data; 492 493/* callback_xdr.c */ 494extern struct svc_version nfs4_callback_version1; 495extern struct svc_version nfs4_callback_version4; 496 497static inline void nfs4_stateid_copy(nfs4_stateid *dst, const nfs4_stateid *src) 498{ |
499 memcpy(dst, src, sizeof(*dst)); | 499 memcpy(dst->data, src->data, sizeof(dst->data)); 500 dst->type = src->type; |
500} 501 502static inline bool nfs4_stateid_match(const nfs4_stateid *dst, const nfs4_stateid *src) 503{ | 501} 502 503static inline bool nfs4_stateid_match(const nfs4_stateid *dst, const nfs4_stateid *src) 504{ |
504 return memcmp(dst, src, sizeof(*dst)) == 0; | 505 if (dst->type != src->type) 506 return false; 507 return memcmp(dst->data, src->data, sizeof(dst->data)) == 0; |
505} 506 507static inline bool nfs4_stateid_match_other(const nfs4_stateid *dst, const nfs4_stateid *src) 508{ 509 return memcmp(dst->other, src->other, NFS4_STATEID_OTHER_SIZE) == 0; 510} 511 512static inline bool nfs4_stateid_is_newer(const nfs4_stateid *s1, const nfs4_stateid *s2) --- 18 unchanged lines hidden --- | 508} 509 510static inline bool nfs4_stateid_match_other(const nfs4_stateid *dst, const nfs4_stateid *src) 511{ 512 return memcmp(dst->other, src->other, NFS4_STATEID_OTHER_SIZE) == 0; 513} 514 515static inline bool nfs4_stateid_is_newer(const nfs4_stateid *s1, const nfs4_stateid *s2) --- 18 unchanged lines hidden --- |