"Fossies" - the Fresh Open Source Software Archive

Member "ms-sys-2.7.0/inc/br.h" (7 Jan 2016, 5170 Bytes) of package /linux/privat/ms-sys-2.7.0.tar.gz:


As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style: standard) with prefixed line numbers and code folding option. Alternatively you can here view or download the uninterpreted source code file. For more information about "br.h" see the Fossies "Dox" file reference documentation and the last Fossies "Diffs" side-by-side code changes report: 2.4.1_vs_2.6.0.

    1 #ifndef BR_H
    2 #define BR_H
    3 
    4 #include <stdio.h>
    5 #include <stdint.h>
    6 
    7 /* Sets custom number of bytes per sector, default value is 512 */
    8 void set_bytes_per_sector(unsigned long ulValue);
    9 
   10 /* Gets Windows Disk Signature from MBR */
   11 uint32_t read_windows_disk_signature(FILE *fp);
   12 
   13 /* Sets a new Windows Disk Signature to MBR */
   14 int write_windows_disk_signature(FILE *fp, uint32_t tWDS);
   15 
   16 /* Reads copy protect bytes after Windows Disk Signature from MBR */
   17 uint16_t read_mbr_copy_protect_bytes(FILE *fp);
   18 const char *read_mbr_copy_protect_bytes_explained(FILE *fp);
   19 
   20 /* returns TRUE if the file has a boot record, otherwise FALSE.
   21    The file position will change when this function is called! */
   22 int is_br(FILE *fp);
   23 
   24 /* returns TRUE if the file has a LILO boot record, otherwise FALSE.
   25    The file position will change when this function is called! */
   26 int is_lilo_br(FILE *fp);
   27 
   28 /* returns TRUE if the file has a Microsoft dos master boot record, otherwise
   29    FALSE.The file position will change when this function is called! */
   30 int is_dos_mbr(FILE *fp);
   31 
   32 /* returns TRUE if the file has a Microsoft dos master boot record with the
   33    undocumented F2 instruction, otherwise FALSE. The file position will change
   34    when this function is called! */
   35 int is_dos_f2_mbr(FILE *fp);
   36 
   37 /* returns TRUE if the file has a Microsoft 95b master boot record, otherwise
   38    FALSE.The file position will change when this function is called! */
   39 int is_95b_mbr(FILE *fp);
   40 
   41 /* returns TRUE if the file has a Microsoft 2000 master boot record, otherwise
   42    FALSE.The file position will change when this function is called! */
   43 int is_2000_mbr(FILE *fp);
   44 
   45 /* returns TRUE if the file has a Microsoft Vista master boot record, otherwise
   46    FALSE.The file position will change when this function is called! */
   47 int is_vista_mbr(FILE *fp);
   48 
   49 /* returns TRUE if the file has a Microsoft 7 master boot record, otherwise
   50    FALSE.The file position will change when this function is called! */
   51 int is_win7_mbr(FILE *fp);
   52 
   53 /* returns TRUE if the file has a Rufus master boot record, otherwise
   54    FALSE.The file position will change when this function is called! */
   55 int is_rufus_mbr(FILE *fp);
   56 
   57 /* returns TRUE if the file has a ReactOS master boot record, otherwise
   58    FALSE.The file position will change when this function is called! */
   59 int is_reactos_mbr(FILE *fp);
   60 
   61 /* returns TRUE if the file has a Grub4DOS master boot record, otherwise
   62    FALSE.The file position will change when this function is called! */
   63 int is_grub4dos_mbr(FILE *fp);
   64 
   65 /* returns TRUE if the file has a Grub 2.0 master boot record, otherwise
   66    FALSE.The file position will change when this function is called! */
   67 int is_grub2_mbr(FILE *fp);
   68 
   69 /* returns TRUE if the file has a KolibriOS master boot record, otherwise
   70    FALSE.The file position will change when this function is called! */
   71 int is_kolibrios_mbr(FILE *fp);
   72 
   73 /* returns TRUE if the file has a syslinux master boot record, otherwise
   74    FALSE.The file position will change when this function is called! */
   75 int is_syslinux_mbr(FILE *fp);
   76 
   77 /* returns TRUE if the file has a syslinux GPT master boot record, otherwise
   78    FALSE.The file position will change when this function is called! */
   79 int is_syslinux_gpt_mbr(FILE *fp);
   80 
   81 /* returns TRUE if the file has a zeroed master boot record, otherwise
   82    FALSE.The file position will change when this function is called! */
   83 int is_zero_mbr(FILE *fp);
   84 int is_zero_mbr_not_including_disk_signature_or_copy_protect(FILE *fp);
   85 
   86 /* Writes a dos master boot record to a file, returns TRUE on success, otherwise
   87    FALSE */
   88 int write_dos_mbr(FILE *fp);
   89 
   90 /* Writes a 95b master boot record to a file, returns TRUE on success, otherwise
   91    FALSE */
   92 int write_95b_mbr(FILE *fp);
   93 
   94 /* Writes a 2000 master boot record to a file, returns TRUE on success, otherwise
   95    FALSE */
   96 int write_2000_mbr(FILE *fp);
   97 
   98 /* Writes a Vista master boot record to a file, returns TRUE on success, otherwise
   99    FALSE */
  100 int write_vista_mbr(FILE *fp);
  101 
  102 /* Writes a Windows 7 master boot record to a file, returns TRUE on success, otherwise
  103    FALSE */
  104 int write_win7_mbr(FILE *fp);
  105 
  106 /* Writes a Rufus master boot record to a file, returns TRUE on success, otherwise
  107    FALSE */
  108 int write_rufus_mbr(FILE *fp);
  109 
  110 /* Writes a ReactOS master boot record to a file, returns TRUE on success, otherwise
  111    FALSE */
  112 int write_reactos_mbr(FILE *fp);
  113 
  114 /* Writes a Grub4DOS master boot record to a file, returns TRUE on success, otherwise
  115    FALSE */
  116 int write_grub4dos_mbr(FILE *fp);
  117 
  118 /* Writes a Grub 2.0 master boot record to a file, returns TRUE on success, otherwise
  119    FALSE */
  120 int write_grub2_mbr(FILE *fp);
  121 
  122 /* Writes a KolibriOS master boot record to a file, returns TRUE on success, otherwise
  123    FALSE */
  124 int write_kolibrios_mbr(FILE *fp);
  125 
  126 /* Writes a syslinux master boot record to a file, returns TRUE on success, otherwise
  127    FALSE */
  128 int write_syslinux_mbr(FILE *fp);
  129 
  130 /* Writes a syslinux GPT master boot record to a file, returns TRUE on success, otherwise
  131    FALSE */
  132 int write_syslinux_gpt_mbr(FILE *fp);
  133 
  134 /* Writes an empty (zeroed) master boot record to a file, returns TRUE on success, otherwise
  135    FALSE */
  136 int write_zero_mbr(FILE *fp);
  137 
  138 #endif