patch-2.4.26 linux-2.4.26/fs/hfsplus/wrapper.c
Next file: linux-2.4.26/fs/inode.c
Previous file: linux-2.4.26/fs/fat/inode.c
Back to the patch index
Back to the overall index
- Lines: 17
- Date:
2004-04-14 06:05:40.000000000 -0700
- Orig file:
linux-2.4.25/fs/hfsplus/wrapper.c
- Orig date:
2003-08-25 04:44:43.000000000 -0700
diff -urN linux-2.4.25/fs/hfsplus/wrapper.c linux-2.4.26/fs/hfsplus/wrapper.c
@@ -14,6 +14,7 @@
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,5,0)
#include <linux/buffer_head.h>
#endif
+#include <asm/unaligned.h>
#include "hfsplus_fs.h"
#include "hfsplus_raw.h"
@@ -45,7 +46,7 @@
return 0;
wd->ablk_start = be16_to_cpu(*(u16 *)(bufptr + HFSP_WRAPOFF_ABLKSTART));
- extent = be32_to_cpu(*(u32 *)(bufptr + HFSP_WRAPOFF_EMBEDEXT));
+ extent = be32_to_cpu(get_unaligned((u32 *)(bufptr + HFSP_WRAPOFF_EMBEDEXT)));
wd->embed_start = (extent >> 16) & 0xFFFF;
wd->embed_count = extent & 0xFFFF;
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)