phdeniel/nfs-ganesha — pull request #37 by lieb (2012-01-24 00:06:32+00:00)
Title: Panasas, refactor of cache_entry_t

The first three commits refactor cache_entry_t followed by two further cleanups based on the refactor.

The first commiit moves 'handle' and 'attributes' out of the 'object' union. These were duplicated in each
union element making its use awkward. This change simplifies the handle and attribute dereference expressions and eliminates error prone switch statements in multiple places. Some redundant error checking was also dropped after verifying that the pentry type was already consistent prior to the test(s).

The second two simply remove two helper functions that became trivial with the removal of the switch statements and redundant error checks.

One missing V_w on an error path was found and fixed once some complex switch code was removed.

The reason for this refactor is that the new api work was getting messy with the current cache_entry_t
structure. I will be rebasing that work on this refactoring. I will unify 'handle' and 'attributes' further in
later work which will simplify a number of APIs and cut down on the number of struct copies.

These commits should not conflict with other people's work although I have not verified this.

This pull request is actually for the following 8 commits. Five appeared to be still dangling after
my rebase on stable_13_jan_2012. The key commits for this change are the top three.

commit 8dfdaae43243a7b2be05acce763b8fbaeb34950c
Author: Jim Lieb

Remove cache_inode_init_attributes in cache_inode_misc.c

commit 2500b748bd444111123703167780474f165cfa5a
Author: Jim Lieb

Remove cachde_inode_get_attributes

commit eba6cdb8a949ff0ce495196924d2189bd14864c7
Author: Jim Lieb

Refactor cache_entry_t

commit 3d706895190937f61552aeaf39777708c17f6e49
Author: Jim Lieb

Fix usage of fsal_dev_t

commit c10ad94e35f173eb5107d6f0f497186e769d7e66
Author: Jim Lieb

Consolidate configuration setting methods into COMMON

commit 87b1d7c1251865fc31d35af3f29126e892d649ba
Author: Jim Lieb

Consolidate filesystem static info display

commit a3f5e1b84a0d2045bfe4dc47ba8c8e2b055a6ce5
Author: Jim Lieb

Fix merge regressions

commit 73b36baeb20e9b6c4a406d4812c4f7aabce76506
Author: Jim Lieb

Consolidate access checking for XFS

panasas branch is rebased on stable_13_jan_2012