NFSv4.1: use layout driver in global device cache
pnfs deviceids are unique per server, per layout type. struct nfs_client is currently used to distinguish deviceids from different nfs servers, yet these may clash between different layout types on the same server. Therefore, use the layout driver associated with each deviceid at insertion time to look it up, unhash, or delete it. Signed-off-by: Benny Halevy <bhalevy@panasas.com>
This commit is contained in:

committed by
Boaz Harrosh

parent
1be5683b03
commit
35c8bb543c
@@ -441,7 +441,8 @@ filelayout_check_layout(struct pnfs_layout_hdr *lo,
|
||||
}
|
||||
|
||||
/* find and reference the deviceid */
|
||||
d = nfs4_find_get_deviceid(NFS_SERVER(lo->plh_inode)->nfs_client, id);
|
||||
d = nfs4_find_get_deviceid(NFS_SERVER(lo->plh_inode)->pnfs_curr_ld,
|
||||
NFS_SERVER(lo->plh_inode)->nfs_client, id);
|
||||
if (d == NULL) {
|
||||
dsaddr = get_device_info(lo->plh_inode, id, gfp_flags);
|
||||
if (dsaddr == NULL)
|
||||
|
Reference in New Issue
Block a user