mirror of
https://github.com/Zeal-Operating-System/ZealOS.git
synced 2025-06-07 08:14:48 +00:00
DiskATA.CC refactor
This commit is contained in:
parent
48f9e4c7d6
commit
948532f39e
Binary file not shown.
@ -20,5 +20,7 @@ StartOS.CC
|
||||
ZBlkDev/
|
||||
Mount.CC
|
||||
|
||||
|
||||
/Kernel/
|
||||
BlkDev/
|
||||
DiskATA.CC
|
||||
$FG,7$-Tom$FG,0$
|
File diff suppressed because it is too large
Load Diff
@ -6,44 +6,40 @@ $LK,"KernelB",A="FF:::/StartOS.CC,KernelB"$ StartOS.CC
|
||||
|
||||
#help_index "Bit"
|
||||
#help_file "::/Doc/Bit"
|
||||
public _intern IC_BSF I64 Bsf(I64 bit_field_val);//Scan forward from lowest for 1st set. -1 if not found.
|
||||
public _intern IC_BSR I64 Bsr(I64 bit_field_val);//Scan rev from highest for 1st set. -1 if not found.
|
||||
public _intern IC_BT Bool Bt(U8 *bit_field,I64 bit); //Bit test.
|
||||
public _intern IC_BTC Bool Btc(U8 *bit_field,I64 bit); //Bit test and complement (same as xor with 1).
|
||||
public _intern IC_BTR Bool Btr(U8 *bit_field,I64 bit); //Bit test and reset to zero.
|
||||
public _intern IC_BTS Bool Bts(U8 *bit_field,I64 bit); //Bit test and set to one.
|
||||
public _intern IC_LBTC Bool LBtc(U8 *bit_field,I64 bit); //Locked bit test and complement (xor with 1).
|
||||
public _intern IC_LBTR Bool LBtr(U8 *bit_field,I64 bit); //Locked bit test and reset to zero.
|
||||
public _intern IC_LBTS Bool LBts(U8 *bit_field,I64 bit); //Locked bit test and set to one.
|
||||
public _intern IC_POPCNT I64 PopCount(I64 bit_field_val); //Count number of set bits in number.
|
||||
public _extern _BEQUAL Bool BEqual(U8 *bit_field,I64 bit,Bool val);//Set bit equ to val.
|
||||
public _intern IC_BSF I64 Bsf(I64 bit_field_val);//Scan forward from lowest for 1st set. -1 if not found.
|
||||
public _intern IC_BSR I64 Bsr(I64 bit_field_val);//Scan rev from highest for 1st set. -1 if not found.
|
||||
public _intern IC_BT Bool Bt(U8 *bit_field,I64 bit); //Bit test.
|
||||
public _intern IC_BTC Bool Btc(U8 *bit_field,I64 bit); //Bit test and complement (same as xor with 1).
|
||||
public _intern IC_BTR Bool Btr(U8 *bit_field,I64 bit); //Bit test and reset to zero.
|
||||
public _intern IC_BTS Bool Bts(U8 *bit_field,I64 bit); //Bit test and set to one.
|
||||
public _intern IC_LBTC Bool LBtc(U8 *bit_field,I64 bit); //Locked bit test and complement (xor with 1).
|
||||
public _intern IC_LBTR Bool LBtr(U8 *bit_field,I64 bit); //Locked bit test and reset to zero.
|
||||
public _intern IC_LBTS Bool LBts(U8 *bit_field,I64 bit); //Locked bit test and set to one.
|
||||
public _intern IC_POPCNT I64 PopCount(I64 bit_field_val); //Count number of set bits in number.
|
||||
public _extern _BEQUAL Bool BEqual(U8 *bit_field,I64 bit,Bool val);//Set bit equ to val.
|
||||
public _extern _LBEQUAL Bool LBEqual(U8 *bit_field,I64 bit,Bool val); //Locked Set bit equ to val.
|
||||
public _extern _BIT_FIELD_EXT_U32 U32 BFieldExtU32(U8 *bit_field,I64 bit,I64 size); //Extract U32 from bit field.
|
||||
public _extern _BIT_FIELD_OR_U32 U0 BFieldOrU32(U8 *bit_field,I64 bit,U32 pattern); //Or U32 into bit field.
|
||||
public _extern _LBEQUAL Bool LBEqual(U8 *bit_field,I64 bit,Bool val); //Locked Set bit equ to val.
|
||||
|
||||
#help_index "Boot"
|
||||
_extern MEM_BOOT_BASE U32 mem_boot_base;
|
||||
_extern SYS_BOOT_BLK U32 sys_boot_blk;
|
||||
_extern MEM_BOOT_BASE U32 mem_boot_base;
|
||||
_extern SYS_BOOT_BLK U32 sys_boot_blk;
|
||||
_extern SYS_BOOT_PATCH_TABLE_BASE U32 sys_boot_patch_table_base;
|
||||
_extern SYS_BOOT_SRC U32 sys_boot_src;
|
||||
_extern SYS_RUN_LEVEL U32 sys_run_level;
|
||||
_extern SYS_BOOT_SRC U32 sys_boot_src;
|
||||
_extern SYS_RUN_LEVEL U32 sys_run_level;
|
||||
|
||||
#help_index "Call"
|
||||
public _extern _CALL I64 Call(U8 *machine_code); //Call addr with no args.
|
||||
public _extern _CALLEXTSTR I64 CallExtStr(
|
||||
/*argpop*/ U8 *name,...); //Search sym table for fun and pass it args.
|
||||
public _extern _CALL I64 Call(U8 *machine_code); //Call addr with no args.
|
||||
public _extern _CALLEXTSTR I64 CallExtStr(/*argpop*/ U8 *name,...); //Search sym table for fun and pass it args.
|
||||
//Can have any fixed number of arguments.
|
||||
public _extern _CALL_IND I64 CallInd(
|
||||
/*argpop*/I64 (*fp_addr)(...),...); //Call with fixed number of args.
|
||||
public _extern _CALL_IND I64 CallInd(/*argpop*/I64 (*fp_addr)(...),...); //Call with fixed number of args.
|
||||
|
||||
#help_index "Call/System Extern Num"
|
||||
public _extern SYS_EXTERN_TABLE /*argpop*/
|
||||
I64 (**ext)(...); //Array of fun ptrs. See $LK,"Extern Num Definitions",A="MN:EXT_EXTS_NUM"$
|
||||
public _extern _CALLEXTNUM
|
||||
I64 CallExtNum(I64 num,...); //Call ext num with fixed number of args.
|
||||
public _extern SYS_EXTERN_TABLE /*argpop*/I64 (**ext)(...); //Array of fun ptrs. See $LK,"Extern Num Definitions",A="MN:EXT_EXTS_NUM"$
|
||||
public _extern _CALLEXTNUM I64 CallExtNum(I64 num,...); //Call ext num with fixed number of args.
|
||||
|
||||
#help_index "Char/Conversion"
|
||||
public _intern IC_TOUPPER I64 ToUpper(U8 ch); //Convert char to upper case.
|
||||
public _intern IC_TOUPPER I64 ToUpper(U8 ch); //Convert char to upper case.
|
||||
|
||||
#help_index "Char/Operations"
|
||||
public _intern IC_STRLEN I64 StrLen(U8 *st); //String length.
|
||||
|
Loading…
x
Reference in New Issue
Block a user