sys/vfs/hammer: Add lo_to_pfs()/pfs_to_lo() macros
commit20cf2291b7b758fecda6e4e8f0a11effbc91c226
authorTomohiro Kusumi <kusumi.tomohiro@gmail.com>
Sun, 6 Dec 2015 10:36:05 +0000 (6 19:36 +0900)
committerTomohiro Kusumi <kusumi.tomohiro@gmail.com>
Sun, 6 Dec 2015 16:41:51 +0000 (7 01:41 +0900)
treecbe103d4d1f8bbf1d45a869dd3699a672eaa61dc
parent2e462bd630f91e68cfe220859c168b81c2e8230e
sys/vfs/hammer: Add lo_to_pfs()/pfs_to_lo() macros

These macros hide 16 bits shift and cast to int/uint32_t
that are necessary on localization to/from PFS id conversion.

Some code are better without details being hidden by macros,
but this seems to be more readable with x_to_y macros that
hide bunch of >>16, <<16, and casts.

(No diff in binary on x86_64/gcc5)
sbin/hammer/cmd_recover.c
sys/vfs/hammer/hammer_btree.h
sys/vfs/hammer/hammer_mirror.c
sys/vfs/hammer/hammer_pfs.c
sys/vfs/hammer/hammer_rebalance.c
sys/vfs/hammer/hammer_reblock.c
sys/vfs/hammer/hammer_subs.c
sys/vfs/hammer/hammer_vfsops.c
sys/vfs/hammer/hammer_vnops.c