mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 11:11:45 -04:00
fs: cleanup slight list_entry abuse
list_entry is just a wrapper for container_of, but it is arguably wrong (and slightly confusing) to use it when the pointed-to struct member is not a struct list_head. Use container_of directly instead. Signed-off-by: Rasmus Villemoes <[email protected]> Signed-off-by: Al Viro <[email protected]>
This commit is contained in:
parent
8ea3a7c0df
commit
db6172c411
13 changed files with 13 additions and 13 deletions
|
|
@ -252,7 +252,7 @@ extern void hfs_mark_mdb_dirty(struct super_block *sb);
|
|||
#define __hfs_u_to_mtime(sec) cpu_to_be32(sec + 2082844800U - sys_tz.tz_minuteswest * 60)
|
||||
#define __hfs_m_to_utime(sec) (be32_to_cpu(sec) - 2082844800U + sys_tz.tz_minuteswest * 60)
|
||||
|
||||
#define HFS_I(inode) (list_entry(inode, struct hfs_inode_info, vfs_inode))
|
||||
#define HFS_I(inode) (container_of(inode, struct hfs_inode_info, vfs_inode))
|
||||
#define HFS_SB(sb) ((struct hfs_sb_info *)(sb)->s_fs_info)
|
||||
|
||||
#define hfs_m_to_utime(time) (struct timespec){ .tv_sec = __hfs_m_to_utime(time) }
|
||||
|
|
|
|||
Loading…
Reference in a new issue