]> err.no Git - linux-2.6/blobdiff - fs/udf/inode.c
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
[linux-2.6] / fs / udf / inode.c
index c150b6df6261f023e6b26a945f405adc08a76806..6e74b117aaf0e58d078e59d88817562de8379a1d 100644 (file)
@@ -37,6 +37,7 @@
 #include <linux/buffer_head.h>
 #include <linux/writeback.h>
 #include <linux/slab.h>
+#include <linux/crc-itu-t.h>
 
 #include "udf_i.h"
 #include "udf_sb.h"
@@ -1301,6 +1302,15 @@ static void udf_fill_inode(struct inode *inode, struct buffer_head *bh)
                inode->i_op = &page_symlink_inode_operations;
                inode->i_mode = S_IFLNK | S_IRWXUGO;
                break;
+       case ICBTAG_FILE_TYPE_MAIN:
+               udf_debug("METADATA FILE-----\n");
+               break;
+       case ICBTAG_FILE_TYPE_MIRROR:
+               udf_debug("METADATA MIRROR FILE-----\n");
+               break;
+       case ICBTAG_FILE_TYPE_BITMAP:
+               udf_debug("METADATA BITMAP FILE-----\n");
+               break;
        default:
                printk(KERN_ERR "udf: udf_fill_inode(ino %ld) failed unknown "
                                "file type=%d\n", inode->i_ino,
@@ -1410,9 +1420,9 @@ static int udf_update_inode(struct inode *inode, int do_sync)
                                                iinfo->i_location.
                                                        logicalBlockNum);
                use->descTag.descCRCLength = cpu_to_le16(crclen);
-               use->descTag.descCRC = cpu_to_le16(udf_crc((char *)use +
-                                                          sizeof(tag), crclen,
-                                                          0));
+               use->descTag.descCRC = cpu_to_le16(crc_itu_t(0, (char *)use +
+                                                          sizeof(tag),
+                                                          crclen));
                use->descTag.tagChecksum = udf_tag_checksum(&use->descTag);
 
                mark_buffer_dirty(bh);
@@ -1575,8 +1585,8 @@ static int udf_update_inode(struct inode *inode, int do_sync)
        crclen += iinfo->i_lenEAttr + iinfo->i_lenAlloc -
                                                                sizeof(tag);
        fe->descTag.descCRCLength = cpu_to_le16(crclen);
-       fe->descTag.descCRC = cpu_to_le16(udf_crc((char *)fe + sizeof(tag),
-                                                 crclen, 0));
+       fe->descTag.descCRC = cpu_to_le16(crc_itu_t(0, (char *)fe + sizeof(tag),
+                                                 crclen));
        fe->descTag.tagChecksum = udf_tag_checksum(&fe->descTag);
 
        /* write the data blocks */