Changeset 667


Ignore:
Timestamp:
Jan 27, 2021, 9:35:47 AM (5 years ago)
Author:
Paul Smedley
Message:

Remove remaining support for non-KEE builds

Location:
GPL/branches/uniaud32-next
Files:
2 deleted
24 edited

Legend:

Unmodified
Added
Removed
  • GPL/branches/uniaud32-next/Makefile

    r591 r667  
    77!include $(ROOT)\tools\header.mif
    88
    9 WMAKEOPTS=-h $(__MAKEOPTS__) KEE=1
     9WMAKEOPTS=-h $(__MAKEOPTS__)
    1010
    1111!if "$(IBM_BUILD)" == "1"
  • GPL/branches/uniaud32-next/alsa-kernel/Makefile

    r615 r667  
    1 WMAKEOPTS=-h $(__MAKEOPTS__) KEE=$(KEE) DEBUG=$(DEBUG)
     1WMAKEOPTS=-h $(__MAKEOPTS__) DEBUG=$(DEBUG)
    22
    33#===================================================================
  • GPL/branches/uniaud32-next/alsa-kernel/core/Makefile

    r615 r667  
    66!include $(ROOT)\tools\header.mif
    77
    8 WMAKEOPTS=-h $(__MAKEOPTS__) KEE=$(KEE) DEBUG=$(DEBUG)
     8WMAKEOPTS=-h $(__MAKEOPTS__) DEBUG=$(DEBUG)
    99
    1010#===================================================================
  • GPL/branches/uniaud32-next/alsa-kernel/core/oss/Makefile

    r587 r667  
    1010!if "$(DEBUG)" == "1"
    1111WMAKEOPTS += DEBUG=1
    12 !endif
    13 
    14 !if "$(KEE)" == "0"
    15 WMAKEOPTS += KEE=0
    16 KEE=0
    17 !else
    18 WMAKEOPTS += KEE=1
    19 KEE=1
    2012!endif
    2113
  • GPL/branches/uniaud32-next/alsa-kernel/core/seq/Makefile

    r587 r667  
    66!include $(ROOT)\tools\header.mif
    77
    8 WMAKEOPTS=-h $(__MAKEOPTS__) KEE=$(KEE) DEBUG=$(DEBUG)
     8WMAKEOPTS=-h $(__MAKEOPTS__) DEBUG=$(DEBUG)
    99
    1010#===================================================================
  • GPL/branches/uniaud32-next/alsa-kernel/core/seq/oss/Makefile

    r587 r667  
    1010!if "$(DEBUG)" == "1"
    1111WMAKEOPTS += DEBUG=1
    12 !endif
    13 
    14 !if "$(KEE)" == "0"
    15 WMAKEOPTS += KEE=0
    16 KEE=0
    17 !else
    18 WMAKEOPTS += KEE=1
    19 KEE=1
    2012!endif
    2113
  • GPL/branches/uniaud32-next/alsa-kernel/drivers/Makefile

    r587 r667  
    77!include $(ROOT)\tools\header.mif
    88
    9 WMAKEOPTS=-h $(__MAKEOPTS__) KEE=$(KEE) DEBUG=$(DEBUG)
     9WMAKEOPTS=-h $(__MAKEOPTS__) DEBUG=$(DEBUG)
    1010
    1111all: subdirs
  • GPL/branches/uniaud32-next/alsa-kernel/hda/Makefile

    r615 r667  
    66!include $(ROOT)\tools\header.mif
    77
    8 WMAKEOPTS=-h $(__MAKEOPTS__) KEE=$(KEE) DEBUG=$(DEBUG)
     8WMAKEOPTS=-h $(__MAKEOPTS__) DEBUG=$(DEBUG)
    99
    1010#===================================================================
  • GPL/branches/uniaud32-next/alsa-kernel/isa/Makefile

    r587 r667  
    77!include $(ROOT)\tools\header.mif
    88
    9 WMAKEOPTS=-h $(__MAKEOPTS__) KEE=$(KEE) DEBUG=$(DEBUG)
     9WMAKEOPTS=-h $(__MAKEOPTS__) DEBUG=$(DEBUG)
    1010
    1111
  • GPL/branches/uniaud32-next/alsa-kernel/pci/Makefile

    r598 r667  
    66!include $(ROOT)\tools\header.mif
    77
    8 WMAKEOPTS=-h $(__MAKEOPTS__) KEE=$(KEE) DEBUG=$(DEBUG)
     8WMAKEOPTS=-h $(__MAKEOPTS__) DEBUG=$(DEBUG)
    99
    1010#===================================================================
  • GPL/branches/uniaud32-next/alsa-kernel/synth/Makefile

    r587 r667  
    66!include $(ROOT)\tools\header.mif
    77
    8 WMAKEOPTS=-h $(__MAKEOPTS__) KEE=$(KEE) DEBUG=$(DEBUG)
     8WMAKEOPTS=-h $(__MAKEOPTS__) DEBUG=$(DEBUG)
    99
    1010#===================================================================
  • GPL/branches/uniaud32-next/drv32/Makefile

    r615 r667  
    5454#===================================================================
    5555
    56 FILES = begin.obj startup.obj &
    57   strategy.obj read.obj &
    58   init.obj parse.obj &
    59   devhlp.obj &
    60   idc.obj dispatch.obj &
    61   rmhelp.obj irq.obj util.obj &
    62   impdos.lib
    63 !if "$(KEE)" == "1"
    64 FILES += impkee.lib
    65 !endif
    66 FILES += end.obj
     56FILES = begin.obj startup.obj strategy.obj read.obj init.obj parse.obj idc.obj &
     57        dispatch.obj rmhelp.obj irq.obj util.obj impdos.lib impkee.lib end.obj
    6758
    6859LIBS = $(ALSA_LIB)\linuxlib.lib $(ALSA_LIB)\core.lib $(ALSA_LIB)\ac97.lib $(ALSA_LIB)\pci.lib &
  • GPL/branches/uniaud32-next/drv32/init.c

    r655 r667  
    3939#include <irqos2.h>
    4040#include <osspci.h>
    41 //#include <bsedos16.h>
    42 #ifdef KEE
    4341#include <kee.h>
    44 #endif
    4542#include "parse.h"
    4643#include "malloc.h"
     
    103100int LockSegments(void)
    104101{
    105 #ifdef KEE
    106102    KEEVMLock lock;
    107 #else
    108     char   lock[12];
    109     ULONG  PgCount;
    110 #endif
    111103    ULONG  segsize;
    112104
     
    122114    }
    123115    segsize &= ~0xFFF;
    124 #ifdef KEE
     116
    125117    if(KernVMLock(VMDHL_LONG,
    126118                  (PVOID)((OffsetBeginDS32) & ~0xFFF),
     
    129121                  (KEEVMPageList*)-1,
    130122                  0)) {
    131 #else
    132     if(DevVMLock(VMDHL_LONG,
    133                    ((OffsetBeginDS32) & ~0xFFF),
    134                    segsize,
    135                    (LINEAR)-1,
    136                    (LINEAR)lock,
    137                    (LINEAR)&PgCount)) {
    138 #endif
    139123      return(1);
    140124    }
     
    147131    }
    148132    segsize &= ~0xFFF;
    149 #ifdef KEE
     133
    150134    if(KernVMLock(VMDHL_LONG,
    151135                  (PVOID)((OffsetBeginCS32) & ~0xFFF),
     
    154138                  (KEEVMPageList*)-1,
    155139                  0)) {
    156 #else
    157     if(DevVMLock(VMDHL_LONG,
    158                  ((OffsetBeginCS32) & ~0xFFF),
    159                  segsize,
    160                  (LINEAR)-1,
    161                  (LINEAR)lock,
    162                  (LINEAR)&PgCount)) {
    163 #endif
    164140      return(1);
    165141    }
     
    202178  char debugmsg[64];
    203179  char FAR48 *args;
    204 
    205 #ifndef KEE
    206   GetTKSSBase();
    207 #endif
    208180
    209181  DebugLevel = 1;
  • GPL/branches/uniaud32-next/drv32/segments.inc

    r32 r667  
    6868CONST2  ENDS
    6969
    70 IFDEF KEE
    7170LASTDATA32 SEGMENT DWORD PUBLIC USE32 'DATA'
    7271LASTDATA32 ENDS
    73 ELSE
    74 LASTDATA32 SEGMENT DWORD PUBLIC USE32 'BSS'
    75 LASTDATA32 ENDS
    76 ENDIF
    7772
    7873;order is important!
    79 IFDEF KEE
    8074DGROUP  group BSS32, DATA32, _DATA, CONST32, C_COMMON, c_common, CONST2, CONST, _BSS, LASTDATA32
    81 ELSE
    82 DGROUP  group DATA32, CONST32, C_COMMON, c_common, CONST2, CONST, _BSS, BSS32, _DATA, LASTDATA32
    83 ENDIF
    8475
    8576CGROUP  group FIRSTCODE32, CODE32, _TEXT, LASTCODE32
  • GPL/branches/uniaud32-next/drv32/startup.asm

    r655 r667  
    10401040        extrn  ALSA_Interrupt : near
    10411041        extrn  _rdOffset: dword
    1042 
    1043 IFDEF KEE
    10441042        extrn  KernThunkStackTo16 : near
    10451043        extrn  KernThunkStackTo32 : near
    1046 ELSE
    1047         extrn  GetTKSSBase : near
    1048         extrn  StackAlloc : near
    1049         extrn  StackFree  : near
    1050 ENDIF
    10511044
    10521045;Called by Watcom to set the DS
     
    10871080        ret
    10881081DevHlp_ModifiedDS endp
    1089 
    1090 
    1091 IFNDEF KEE
    1092 ;;******************************************************************************
    1093 ;FixSelDPL:
    1094 ;
    1095 ; Set DPL of DOS32FLATDS selector to 0 or else we'll get a trap D when loading
    1096 ; it into the SS register (DPL must equal CPL when loading a selector into SS)
    1097 ;;******************************************************************************
    1098         PUBLIC FixSelDPL
    1099         ALIGN  4
    1100 FixSelDPL proc near
    1101         cmp     fWrongDPL, 1
    1102         jne     short @@fixdpl_end
    1103         cmp     SelRef, 0
    1104         jne     short @@fixdpl_endfix
    1105         push    eax
    1106         push    ebx
    1107         push    edx
    1108         sgdt    fword ptr [gdtsave]             ; access the GDT ptr
    1109         mov     ebx, dword ptr [gdtsave+2]      ; get lin addr of GDT
    1110         mov     eax, ds                         ; build offset into table
    1111         and     eax, 0fffffff8h                 ; mask away DPL
    1112         add     ebx, eax                        ; build address
    1113 
    1114         mov     eax, dword ptr [ebx+4]
    1115         mov     edx, eax
    1116         shr     edx, 13
    1117         and     edx, 3
    1118 
    1119         ;has the OS/2 kernel finally changed the DPL to 0?
    1120         cmp     edx, 0
    1121         jne     @@changedpl
    1122         mov     fWrongDPL, 0            ;don't bother anymore
    1123         mov     SelRef, 0
    1124         jmp     short @@endchange
    1125 
    1126 @@changedpl:
    1127         mov     oldDPL, eax
    1128         and     eax, NOT 6000h          ;clear bits 5 & 6 in the high word (DPL)
    1129         mov     dword ptr [ebx+4], eax
    1130 @@endchange:
    1131         pop     edx
    1132         pop     ebx
    1133         pop     eax
    1134 @@fixdpl_endfix:
    1135         inc     SelRef
    1136 @@fixdpl_end:
    1137         ret
    1138 FixSelDPL endp
    1139 ;;******************************************************************************
    1140 ; RestoreSelDPL:
    1141 ;
    1142 ;  Restore DPL of DOS32FLATDS selector or else OS/2 kernel code running in ring 3
    1143 ;  will trap (during booting only; this sel has a DPL of 0 when PM starts up)
    1144 ;;******************************************************************************
    1145         PUBLIC RestoreSelDPL
    1146         ALIGN  4
    1147 RestoreSelDPL proc near
    1148         cmp     fWrongDPL, 1
    1149         jne     short @@restdpl_end
    1150 
    1151         cmp     SelRef, 1
    1152         jne     short @@restdpl_endrest
    1153         push    eax
    1154         push    ebx
    1155         sgdt    fword ptr [gdtsave]             ; access the GDT ptr
    1156         mov     ebx, dword ptr [gdtsave+2]      ; get lin addr of GDT
    1157         mov     eax, ds                         ; build offset into table
    1158         and     eax, 0fffffff8h                 ; mask away DPL
    1159         add     ebx, eax                        ; build address
    1160 
    1161         mov     eax, oldDPL
    1162         mov     dword ptr [ebx+4], eax
    1163         pop     ebx
    1164         pop     eax
    1165 @@restdpl_endrest:
    1166         dec     SelRef
    1167 @@restdpl_end:
    1168         ret
    1169 RestoreSelDPL endp
    1170 ENDIF
    11711082
    11721083;*******************************************************************************
     
    11841095        mov  ebp, esp
    11851096        push ebx
    1186 
    11871097        lea  ebx, [ebp+8]
    11881098        DevThunkStackTo16_Int
    1189 
    11901099        push dword ptr [ebx+16]    ;param2
    11911100        push dword ptr [ebx+12]    ;param1
     
    11931102        call fword ptr [ebx]
    11941103        add  sp, 12
    1195 
    11961104        DevThunkStackTo32_Int
    1197 
    11981105        pop  ebx
    11991106        pop  ebp
     
    12151122        mov     ds, eax
    12161123        mov     es, eax
    1217 IFNDEF KEE
    1218         ;done in init.cpp for the KEE version
    1219         cmp     dword ptr [intSwitchStack], 0
    1220         jne     stratcontinue
    1221         ;get TKSSBase & intSwitchStack pointers
    1222         call    GetTKSSBase
    1223 stratcontinue:
    1224 ENDIF
    12251124        DevThunkStackTo32
    1226         cmp     eax, 0
    1227         jne     @@stackswitchfail_strat
    12281125        call    ALSA_STRATEGY
    12291126        DevThunkStackTo16
    1230 @@stackswitchfail_strat:
    12311127        pop     gs
    12321128        pop     fs
     
    12531149        mov     es, eax
    12541150        DevThunkStackTo32
    1255         cmp     eax, 0
    1256         jne     @@stackswitchfail_idc
    12571151        call    ALSA_IDC
    12581152        DevThunkStackTo16
    1259 @@stackswitchfail_idc:
    12601153        pop     gs
    12611154        pop     fs
     
    12811174ENDIF
    12821175        DevThunkStackTo32
    1283         cmp     eax, 0
    1284         jne     @@stackswitchfail_timer
    12851176        call    ALSA_TIMER_
    12861177        DevThunkStackTo16
    1287 @@stackswitchfail_timer:
    12881178IFDEF DEBUG
    12891179        add     DbgU32TimerCnt, -1
     
    13221212        ;cli
    13231213        DevThunkStackTo32
    1324         cmp     eax, 0
    1325         jne     @@stackswitchfail_irq
    13261214        ;returns irq status in eax (1=handled; 0=unhandled)
    13271215        call    ALSA_Interrupt
    13281216        DevThunkStackTo16
    1329 @@stackswitchfail_irq:
    13301217IFDEF DEBUG
    13311218                add         DbgU32IntCnt, -1
     
    15021389_RMHandleToResourceHandleList endp
    15031390
     1391; shifted from devhlp.asm
     1392        extrn  DOSIODELAYCNT : ABS
     1393        ALIGN 4
     1394        public iodelay32_
     1395iodelay32_ proc near
     1396        mov   eax, DOSIODELAYCNT
     1397        align 4
     1398@@:     dec   eax
     1399        jnz   @b
     1400        loop  iodelay32_
     1401        ret
     1402iodelay32_ endp
    15041403
    15051404CODE32 ends
     
    15301429    public  _ISR07
    15311430
    1532 IFDEF KEE
    15331431    public  stackbase
    15341432    public  stacksel
     
    15361434    stackbase dd 0
    15371435    stacksel  dd 0
    1538 ELSE
    1539     extrn   intSwitchStack : dword
    1540 
    1541     public  gdtsave
    1542     public  fWrongDPL
    1543     public  oldDPL
    1544     public  SelRef
    1545 
    1546     tempeax          dd 0
    1547     tempedx          dd 0
    1548     tempesi          dd 0
    1549     cpuflags         dd 0
    1550 
    1551     gdtsave          dq 0
    1552     fWrongDPL        dd 1       ;DOS32FLATDS has the wrong DPL for SS
    1553     SelRef           dd 0
    1554     oldDPL           dd 0
    1555 
    1556     fInitStack       dd 0
    1557 ENDIF
    15581436
    15591437    __OffsetFinalCS16 dw OFFSET CODE16:__OffFinalCS16
  • GPL/branches/uniaud32-next/drv32/startup.inc

    r655 r667  
    5353                ENDM
    5454
    55 
    56 IFDEF KEE
    5755;pushfd/popfd trashed by fucking BUGY KernThunkStackTo32
    5856;fix idea by zuko
     
    6462        push    stacksel
    6563        push    stackbase
    66 
    6764        push    edx
    6865        mov     edx, ss
    6966        mov     stacksel, edx
    7067        pushfd
    71 
    7268        call    KernThunkStackTo32
    7369        popfd
    7470        mov     stackbase, edx
    75         pop     edx     ;trashed by KernThunkStackTo32
    76         xor     eax, eax ; mark success
     71        pop     edx      ;trashed by KernThunkStackTo32
    7772        ENDM
     73
    7874;;******************************************************************************
    7975;;******************************************************************************
     
    8783        pop     eax     ;trashed by KernThunkStackTo32
    8884        ENDM
     85
    8986;;******************************************************************************
    9087;;******************************************************************************
     
    9794        pop     eax     ;trashed by KernThunkStackTo16
    9895        pop     edx     ;trashed by KernThunkStackTo16 when called in interrupt context
    99 
    10096        pop     stackbase
    10197        pop     stacksel
     
    113109        pop     edx     ;trashed by KernThunkStackTo16 when called in interrupt context
    114110        ENDM
    115 ;;******************************************************************************
    116 ;;******************************************************************************
    117 
    118 ELSE
    119 
    120 ;;******************************************************************************
    121 ;;Need to preserve fs:ebx!! (all other registers must be saved by the caller)
    122 ;;******************************************************************************
    123 DevThunkStackTo32 MACRO
    124         LOCAL @@stackok, @@stackchangeend
    125 
    126 ;;;;        int     3
    127        
    128         pushfd
    129         cli
    130         pop     dword ptr [cpuflags]
    131 
    132         ;check if kernel DS selector DPL == 3; if so, change to 0       
    133         call    FixSelDPL
    134 
    135         ;allocate private stack
    136         push    fs
    137         call    StackAlloc
    138         pop     fs                             ;trashed by StackAlloc
    139         mov     dword ptr [fInitStack], 1
    140 
    141         cmp     eax, 0
    142         jne     @@stackok
    143        
    144 IFDEF DEBUG
    145         int     3   ;this is very fatal
    146 ENDIF
    147         call    RestoreSelDPL
    148         mov     eax, -1                         ;mark failure
    149 
    150         push    dword ptr [cpuflags]
    151         popfd
    152         jmp     short @@stackchangeend
    153        
    154 @@stackok:
    155         ;stack ptr in eax
    156         call    dword ptr [intSwitchStack]
    157 
    158         push    dword ptr [cpuflags]
    159         popfd
    160 
    161         mov     eax, 0                          ;mark success
    162 @@stackchangeend:
    163         ENDM
    164        
    165 ;;******************************************************************************
    166 ;;******************************************************************************
    167 DevThunkStackTo32_Int MACRO
    168         LOCAL @@cont32
    169 
    170         cmp     dword ptr [fInitStack], 0
    171         je      @@cont32
    172 
    173 ;;;;        int     3
    174         pushfd
    175         cli
    176         pop     dword ptr [cpuflags]
    177 
    178         mov     dword ptr [tempeax], eax        ;save eax
    179 
    180         pop     eax             ;pop saved flat stack pointer
    181 
    182         ;and switch back to our flat stack again
    183         call    dword ptr [intSwitchStack]
    184 
    185         mov     eax, dword ptr [tempeax]        ;restore eax
    186         push    dword ptr [cpuflags]
    187         popfd
    188 
    189 @@cont32:
    190         ENDM
    191        
    192 ;;******************************************************************************
    193 ;;******************************************************************************
    194 DevThunkStackTo16 MACRO
    195 ;;;;        int     3
    196 
    197         pushfd
    198         cli
    199         pop     dword ptr [cpuflags]
    200 
    201         mov     dword ptr [tempeax], eax        ;save eax
    202         mov     dword ptr [tempesi], esi        ;save esi
    203 
    204         mov     esi, esp
    205         xor     eax, eax        ;switch to 16 bits stack
    206         call    dword ptr [intSwitchStack]
    207 
    208         mov     eax, esi       
    209         call    StackFree
    210 
    211         call    RestoreSelDPL
    212 
    213         mov     eax, dword ptr [tempeax]
    214         mov     esi, dword ptr [tempesi]
    215                
    216         push    dword ptr [cpuflags]
    217         popfd
    218        
    219         ENDM
    220        
    221 ;;******************************************************************************
    222 ;;******************************************************************************
    223 DevThunkStackTo16_Int MACRO
    224         LOCAL @@cont16
    225 
    226         cmp     dword ptr [fInitStack], 0
    227         je      @@cont16
    228 
    229 ;;;;        int     3
    230         pushfd
    231         cli
    232         pop     dword ptr [cpuflags]
    233 
    234         mov     dword ptr [tempeax], eax        ;save eax
    235         mov     dword ptr [tempesi], esi        ;save esi
    236         mov     esi, esp
    237         xor     eax, eax        ;switch to 16 bits stack
    238         call    dword ptr [intSwitchStack]
    239         push    esi             ;flat stack ptr (popped before switching back to flat)
    240 
    241         mov     eax, dword ptr [tempeax]
    242         mov     esi, dword ptr [tempesi]
    243         push    dword ptr [cpuflags]
    244         popfd
    245 
    246 @@cont16:
    247         ENDM
    248 
    249 ENDIF ;KEE
    250111
    251112;*******************************************************************************
     
    262123                push    esi
    263124                push    edi
    264 
    265125                ;to access the parameters on the 32 bits stack, once we've switched
    266126                mov     edi, ebp
    267 
    268127                DevThunkStackTo16_Int
    269128                ENDM
     129
    270130;*******************************************************************************
    271131;switch stack from 16 bits to 32 bits and return
     
    289149
    290150;Constants and structure definitions
    291 
    292 DevHlp_VirtToLin        EQU     5Bh
    293 DevHlp_VMLock           EQU     55h
    294151
    295152; Status word masks
  • GPL/branches/uniaud32-next/drv32/util.c

    r587 r667  
    111111
    112112//*****************************************************************************
    113 #if !defined(KEE)
    114 static  GINFO FAR48 *pGIS = 0;
    115 #endif
    116 
    117 //*****************************************************************************
    118113//PS++ Begin
    119114#pragma pack(1)
     
    124119ULONG os2gettimesec()
    125120{
    126 #if !defined(KEE)
    127     APIRET rc;
    128     FARPTR16 p;
    129 
    130     if(pGIS == NULL) {
    131         // Build a pointer to the Global Information Segment.
    132         rc = DevGetDOSVar( DHGETDOSV_SYSINFOSEG, 0, (VOID NEAR *)&p );
    133         if (rc) {
    134             return 0;
    135         }
    136         SEL FAR48 *pSel = (SEL FAR48 *)MAKE_FARPTR32(p);
    137         pGIS = (GINFO FAR48 *)MAKE_FARPTR32((ULONG)(*pSel << 16));
    138     }
    139     return pGIS->Time;
    140 #else
    141121    return KernSISData->SIS_BigTime;
    142 #endif
    143122}
    144123
     
    146125ULONG os2gettimemsec()
    147126{
    148 #if !defined(KEE)
    149     APIRET rc;
    150     FARPTR16 p;
    151 
    152     if(pGIS == NULL) {
    153         // Build a pointer to the Global Information Segment.
    154         rc = DevGetDOSVar( DHGETDOSV_SYSINFOSEG, 0, (VOID NEAR *)&p );
    155         if (rc) {
    156             return 0;
    157         }
    158         SEL FAR48 *pSel = (SEL FAR48 *)MAKE_FARPTR32(p);
    159         pGIS = (GINFO FAR48 *)MAKE_FARPTR32((ULONG)(*pSel << 16));
    160     }
    161     return pGIS->MilliSeconds;
    162 #else
    163127    return KernSISData->SIS_MsCount;
    164 #endif
    165128}
    166129//PS++ End
  • GPL/branches/uniaud32-next/include/stacktoflat.h

    r655 r667  
    2626#define __STACKTOFLAT_H__
    2727
    28 #ifdef KEE
    2928extern ULONG stacksel;          //16 bits stack selector
    3029#pragma aux stacksel "stacksel"
     
    3332#pragma aux stackbase "stackbase"
    3433
    35 #else
    36 
    37 extern ULONG TKSSBase;
    38 #pragma aux TKSSBase "_TKSSBase"
    39 
    40 extern ULONG GetTKSSBase();
    41 #pragma aux GetTKSSBase "GetTKSSBase" \
    42   value [eax];
    43 
    44 #endif
    45 
    46 #ifdef KEE
    4734//Convert 16:16 stack based address to 0:32 flat addresss
    4835#define __Stack16ToFlat(addr)   (LINEAR)((ULONG)(addr&0xffff) + stackbase)
    49 #else
    50 //Convert 16:16 stack based address to 0:32 flat addresss
    51 #define __Stack16ToFlat(addr)   (LINEAR)((((ULONG)addr)&0xffff) + *(ULONG *)TKSSBase)
    52 #endif
    5336
    5437// Convert 16:16 pointer to 16:32
     
    10588#define FLATPTR(a)      GETFLATPTR((char FAR48 *)a)
    10689
    107 #ifdef KEE
    10890#define FlatToSel(addr32)       ((stacksel << 16) | (((ULONG)addr32 - stackbase) & 0xffff))
    109 #else
    110 //Only valid for stack based pointer!!
    111 ULONG FlatToSel(ULONG addr32);
    112 #endif
    11391
    11492#endif
  • GPL/branches/uniaud32-next/lib32/Makefile

    r615 r667  
    2929  regmap.obj regcache.obj regcache-flat.obj regcache-rbtree.obj
    3030
    31  
    32 !if $(KEE) == 0
    33 FILES += stack.obj
    34 !endif
    35 
    3631TARGET = linuxlib
    3732
  • GPL/branches/uniaud32-next/lib32/malloc.c

    r587 r667  
    2929
    3030#include <devhelp.h>
    31 #ifdef KEE
    3231#include <kee.h>
    33 #endif
    3432#include "malloc.h"
    3533
  • GPL/branches/uniaud32-next/lib32/memory.c

    r662 r667  
    3232#include <stacktoflat.h>
    3333#include <limits.h>
    34 #ifdef KEE
    3534#include <kee.h>
    36 #endif
    3735#include "malloc.h"
    3836#define _I386_PAGE_H
     
    178176unsigned long virt_to_phys(void * address)
    179177{
    180 #ifdef KEE
    181178    KEEVMPageList pagelist;
    182179    ULONG         nrpages;
     
    187184        }
    188185        return pagelist.addr;
    189 #else
    190     LINEAR addr = (LINEAR)address;
    191     PAGELIST pagelist;
    192 
    193         if(DevLinToPageList(addr, PAGE_SIZE, (PAGELIST NEAR *)&pagelist)) {
    194                 DebugInt3();
    195                 return 0;
    196         }
    197         return pagelist.physaddr;
    198 #endif
    199186}
    200187//******************************************************************************
     
    205192    ULONG addr = 0;
    206193
    207 #ifdef KEE
    208194    SHORT sel;
    209195    rc = KernVMAlloc(PAGE_SIZE, VMDHA_PHYS, (PVOID*)&addr, (PVOID*)&address, &sel);
    210 #else
    211     rc = DevVMAlloc(VMDHA_PHYS, PAGE_SIZE, (LINEAR)&address, (ULONG)&addr);
    212 #endif
    213196    if (rc != 0) {
    214197        DebugInt3();
     
    232215__again:
    233216
    234 #ifdef KEE
    235 
    236217    rc = KernVMAlloc(size, flags, (PVOID*)&addr, (PVOID*)-1, &sel);
    237 #else
    238     rc = DevVMAlloc(flags, size, (LINEAR)-1, (ULONG)&addr);
    239 #endif
    240218    if (rc == 0) {
    241219        *pAddr = (LINEAR)addr;
     
    257235{
    258236    APIRET rc;
    259 
    260 #ifdef KEE
    261         rc = KernVMFree((PVOID)addr);
    262 #else
    263         rc = DevVMFree((LINEAR)addr);
    264 #endif
     237    rc = KernVMFree((PVOID)addr);
    265238    if(rc) {
    266239        DebugInt3();
     
    531504        //size &= 0xFFFFF000;
    532505
    533 #ifdef KEE
    534506    SHORT sel;
    535 
    536         //rc = KernVMAlloc(size, VMDHA_PHYS, (PVOID*)&addr, (PVOID*)&physaddr, &sel);
     507    //rc = KernVMAlloc(size, VMDHA_PHYS, (PVOID*)&addr, (PVOID*)&physaddr, &sel);
    537508    rc = KernVMAlloc(Length, VMDHA_PHYS, (PVOID*)&addr, (PVOID*)&PhysicalAddress, &sel);
    538 #else
    539     //rc = DevVMAlloc(VMDHA_PHYS, size, (LINEAR)&physaddr, (ULONG)&addr);
    540     rc = DevVMAlloc(VMDHA_PHYS, Length, (LINEAR)&PhysicalAddress, (ULONG)&addr);
    541 #endif
    542509    if (rc != 0) {
    543510        dprintf(("ioremap error: %x", rc));
  • GPL/branches/uniaud32-next/lib32/ossidc.c

    r657 r667  
    3232#include <unicard.h>
    3333#include <version.h>
    34 #ifdef KEE
    35 #include <kee.h>
    36 #endif
    3734#include "initcall.h"
    3835
  • GPL/branches/uniaud32-next/tools/header.mif

    r655 r667  
    1717!endif
    1818WATCOM=$(%WATCOM)
    19 
    20 #Always build KEE version
    21 KEE = 1
    2219
    2320!if "$(DEBUG)" == "1"
     
    5956!else
    6057CFLAGS += -zp4
    61 !endif
    62 
    63 !if $(KEE) == 1
    64 CFLAGS  += -DKEE
    65 ASFLAGS += -D:KEE
    6658!endif
    6759
  • GPL/branches/uniaud32-next/tools/mkversion.cmd

    r656 r667  
    1010projVendor    = EnvVar_Get_If('VENDOR', 'Netlabs <www.netlabs.org>');
    1111projProduct   = "OS/2 Universal Audio 32 Driver";
    12 projAdapter   = "OS/2 Universal Audio";
    1312
    1413/* uniaud.inc is located in the base gpl directory and
Note: See TracChangeset for help on using the changeset viewer.