Loading fs/adfs/adfs.h +0 −13 Original line number Diff line number Diff line Loading @@ -113,19 +113,6 @@ struct object_info { __u16 filetype; }; /* RISC OS 12-bit filetype converts to ,xyz hex filename suffix */ static inline int append_filetype_suffix(char *buf, __u16 filetype) { if (filetype == 0xffff) /* no explicit 12-bit file type was set */ return 0; *buf++ = ','; *buf++ = hex_asc_lo(filetype >> 8); *buf++ = hex_asc_lo(filetype >> 4); *buf++ = hex_asc_lo(filetype >> 0); return 4; } struct adfs_dir_ops { int (*read)(struct super_block *sb, unsigned int id, unsigned int sz, struct adfs_dir *dir); int (*setpos)(struct adfs_dir *dir, unsigned int fpos); Loading fs/adfs/dir.c +8 −5 Original line number Diff line number Diff line Loading @@ -42,11 +42,14 @@ void adfs_object_fixup(struct adfs_dir *dir, struct object_info *obj) obj->filetype = (__u16) ((0x000fff00 & obj->loadaddr) >> 8); /* optionally append the ,xyz hex filetype suffix */ if (ADFS_SB(dir->sb)->s_ftsuffix) obj->name_len += append_filetype_suffix( &obj->name[obj->name_len], obj->filetype); if (ADFS_SB(dir->sb)->s_ftsuffix) { __u16 filetype = obj->filetype; obj->name[obj->name_len++] = ','; obj->name[obj->name_len++] = hex_asc_lo(filetype >> 8); obj->name[obj->name_len++] = hex_asc_lo(filetype >> 4); obj->name[obj->name_len++] = hex_asc_lo(filetype >> 0); } } } Loading Loading
fs/adfs/adfs.h +0 −13 Original line number Diff line number Diff line Loading @@ -113,19 +113,6 @@ struct object_info { __u16 filetype; }; /* RISC OS 12-bit filetype converts to ,xyz hex filename suffix */ static inline int append_filetype_suffix(char *buf, __u16 filetype) { if (filetype == 0xffff) /* no explicit 12-bit file type was set */ return 0; *buf++ = ','; *buf++ = hex_asc_lo(filetype >> 8); *buf++ = hex_asc_lo(filetype >> 4); *buf++ = hex_asc_lo(filetype >> 0); return 4; } struct adfs_dir_ops { int (*read)(struct super_block *sb, unsigned int id, unsigned int sz, struct adfs_dir *dir); int (*setpos)(struct adfs_dir *dir, unsigned int fpos); Loading
fs/adfs/dir.c +8 −5 Original line number Diff line number Diff line Loading @@ -42,11 +42,14 @@ void adfs_object_fixup(struct adfs_dir *dir, struct object_info *obj) obj->filetype = (__u16) ((0x000fff00 & obj->loadaddr) >> 8); /* optionally append the ,xyz hex filetype suffix */ if (ADFS_SB(dir->sb)->s_ftsuffix) obj->name_len += append_filetype_suffix( &obj->name[obj->name_len], obj->filetype); if (ADFS_SB(dir->sb)->s_ftsuffix) { __u16 filetype = obj->filetype; obj->name[obj->name_len++] = ','; obj->name[obj->name_len++] = hex_asc_lo(filetype >> 8); obj->name[obj->name_len++] = hex_asc_lo(filetype >> 4); obj->name[obj->name_len++] = hex_asc_lo(filetype >> 0); } } } Loading