[BACK]Return to bpb.h CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / fs / msdosfs

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/fs/msdosfs/bpb.h between version 1.1 and 1.1.4.3

version 1.1, 2002/12/26 12:31:33 version 1.1.4.3, 2004/09/21 13:35:01
Line 77  struct bpb710 {
Line 77  struct bpb710 {
         u_int32_t       bpbRootClust;   /* start cluster for root directory */          u_int32_t       bpbRootClust;   /* start cluster for root directory */
         u_int16_t       bpbFSInfo;      /* filesystem info structure sector */          u_int16_t       bpbFSInfo;      /* filesystem info structure sector */
         u_int16_t       bpbBackup;      /* backup boot sector */          u_int16_t       bpbBackup;      /* backup boot sector */
         /* There is a 12 byte filler here, but we ignore it */          u_int8_t        bpbReserved[12]; /* Reserved for future expansion */
 };  };
   
 #ifdef  atari  #ifdef  atari
Line 113  struct bpb_a {
Line 113  struct bpb_a {
  * use the macros for the big-endian case.   * use the macros for the big-endian case.
  */   */
 #include <machine/endian.h>  #include <machine/endian.h>
   #ifdef __STDC__
   #define __ICAST(q,a,x)  ((q u_int ## a ## _t *)(q void *)(x))
   #else
   #define __ICAST(q,a,x)  ((q u_int/**/a/**/_t *)(q void *)(x))
   #endif
 #if (BYTE_ORDER == LITTLE_ENDIAN) && defined(UNALIGNED_ACCESS)  #if (BYTE_ORDER == LITTLE_ENDIAN) && defined(UNALIGNED_ACCESS)
 #define getushort(x)    *((u_int16_t *)(x))  #define getushort(x)    *__ICAST(const,16,x)
 #define getulong(x)     *((u_int32_t *)(x))  #define getulong(x)     *__ICAST(const,32,x)
 #define putushort(p, v) (*((u_int16_t *)(p)) = (v))  #define putushort(p, v) (void)(*__ICAST(,16,p) = (v))
 #define putulong(p, v)  (*((u_int32_t *)(p)) = (v))  #define putulong(p, v)  (void)(*__ICAST(,32,p) = (v))
 #else  #else
 #define getushort(x)    (((u_int8_t *)(x))[0] + (((u_int8_t *)(x))[1] << 8))  #define getushort(x)    (__ICAST(const,8,x)[0] + (__ICAST(const,8,x)[1] << 8))
 #define getulong(x)     (((u_int8_t *)(x))[0] + (((u_int8_t *)(x))[1] << 8) \  #define getulong(x)     (__ICAST(const,8,x)[0] + (__ICAST(const,8,x)[1] << 8) \
                          + (((u_int8_t *)(x))[2] << 16) \                           + (__ICAST(const,8,x)[2] << 16)        \
                          + (((u_int8_t *)(x))[3] << 24))                           + (__ICAST(const,8,x)[3] << 24))
 #define putushort(p, v) (((u_int8_t *)(p))[0] = (v),    \  #define putushort(p, v) (__ICAST(,8,p)[0] = (v),        \
                          ((u_int8_t *)(p))[1] = (v) >> 8)                           __ICAST(,8,p)[1] = (v) >> 8)
 #define putulong(p, v)  (((u_int8_t *)(p))[0] = (v),    \  #define putulong(p, v)  (__ICAST(,8,p)[0] = (v),        \
                          ((u_int8_t *)(p))[1] = (v) >> 8, \                           __ICAST(,8,p)[1] = (v) >> 8, \
                          ((u_int8_t *)(p))[2] = (v) >> 16,\                           __ICAST(,8,p)[2] = (v) >> 16,\
                          ((u_int8_t *)(p))[3] = (v) >> 24)                           __ICAST(,8,p)[3] = (v) >> 24)
 #endif  #endif
   
 /*  /*
Line 189  struct byte_bpb710 {
Line 194  struct byte_bpb710 {
         u_int8_t bpbRootClust[4];       /* start cluster for root directory */          u_int8_t bpbRootClust[4];       /* start cluster for root directory */
         u_int8_t bpbFSInfo[2];          /* filesystem info structure sector */          u_int8_t bpbFSInfo[2];          /* filesystem info structure sector */
         u_int8_t bpbBackup[2];          /* backup boot sector */          u_int8_t bpbBackup[2];          /* backup boot sector */
         /* There is a 12 byte filler here, but we ignore it */          u_int8_t bpbReserved[12];       /* Reserved for future expansion */
 };  };
   
 /*  /*

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.1.4.3

CVSweb <webmaster@jp.NetBSD.org>