Ignore:
Timestamp:
Jul 6, 2011, 10:02:47 AM (14 years ago)
Author:
Markus Thielen
Message:
  • removed RAS calls (tracing to OS/2 kernel trace buffer was unreliable)
  • added private trace ring buffer implementation
  • support read from OS2AHCI$ character device
  • contents of trace ring buffer are accesible via OS2AHCI$ character device
  • updated WATCOM makefile; WATCOM build still produces a non-working driver
  • code cleanup (unused variables etc.)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/os2ahci/wmakefile

    r43 r112  
    33#
    44# Copyright (c) 2010 Christian Mueller, Markus Thielen.
    5 # Parts copied from/inspired by the Linux AHCI driver; 
     5# Parts copied from/inspired by the Linux AHCI driver;
    66# those parts are (c) Linux AHCI/ATA maintainers
    77#
     
    1919#  along with this program; if not, write to the Free Software
    2020#  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
     21
     22###############################################################################
     23# Calling Syntax
     24#
     25# wmake -ms -f wmakefile
     26#
     27# NOTE: we use MS compatibility mode (-ms) so we can use a syntax similar
     28#       to the well known nmake syntax.
     29#
     30
     31#
     32# THE WATCOM BUILD IS BROKEN!
     33#
     34# It might run through but produces a non-working driver
     35#
     36
     37###############################################################################
     38# wmake directives
     39.HOLD # do not prompt for deletion of created files on error; leave them alone
     40
    2141
    2242
     
    3858               -I$(DDK)\base\ibmh \
    3959               -I$(DDK)\base\src\dev\dasd\diskh \
    40                -I$(WATCOM)\h
     60               -I$(DDK)\base\src\dev\thinkpad\dockii\apmcalls \
     61               -I$(CC16)\include
    4162
    4263AS_INCLUDE   = -I:$(DDK)\base\inc \
     
    4566LIB_DIRS     = $(DDK)\base\lib\ \
    4667               $(DDK)\base\src\dev\dasd\devhlp\ \
    47 
     68               $(DDK)\base\src\dev\thinkpad\dockii\apmcalls\ \
    4869
    4970###############################################################################
    5071# Tool Chain
    5172#
    52 # This makefile uses the Watcom 16bit compiler. 
     73# This makefile uses the Watcom 16bit compiler.
    5374# Linker and assembler are link.exe and alp.exe that ship with the OS/2 DDK
    5475#
     
    6283
    6384AFLAGS        = -Mb
    64 CFLAGS        = -d3 -hc -bt=os2 -ms -zu -5 -w2 -wcd=138 -zp1 -q -s -zgp -zfp -oi
     85CFLAGS        = -d3 -hc -bt=os2 -ms -zu -5 -w3 -wcd=138 -wcd=300 -ecc -zp1 -q -s -zgp -zfp -oi
    6586CFLAGS_DEBUG  = -d3 -hc
    66 LFLAGS        = /noe /nod /packd /a:16 /batch /map /line 
     87LFLAGS        = /noe /nod /packd /a:16 /batch /map /line
    6788
    6889###############################################################################
     
    7192TARGET   = os2ahci.add
    7293
    73 LIBS     = addcalls doscalls rmcalls # dhcalls not needed, see local devhelp.h
     94LIBS     = addcalls doscalls rmcalls apmcalls # dhcalls not needed, see local devhelp.h
    7495
    7596SRCS     = init.asm math.asm libc.c os2ahci.c pci.c ahci.c ata.c atapi.c \
    76            ctxhook.c
     97           ctxhook.c trace.c ioctl.c apm.c
    7798
    7899OBJS     = init.obj libc.obj os2ahci.obj pci.obj ahci.obj ata.obj atapi.obj \
    79            ctxhook.obj
     100           ctxhook.obj trace.obj ioctl.obj apm.obj
    80101
    81102INCS     = os2ahci.h ahci.h version.h
     
    85106
    86107clean:
    87         rm -f $(OBJS) $(TARGET)
     108        rm -f $(OBJS) $(TARGET) *.lst *.cod
    88109
    89110###############################################################################
    90111# Object/source dependencies
    91112
    92 init.obj:     init.asm   wmakefile
     113init.obj:     init.asm   Makefile
    93114
    94 libc.obj:     libc.c     wmakefile $(INCS)
     115libc.obj:     libc.c     Makefile $(INCS)
    95116
    96 os2ahci.obj:  os2ahci.c  wmakefile $(INCS) bldday.h
     117os2ahci.obj:  os2ahci.c  Makefile $(INCS) bldday.h ioctl.h
    97118
    98 pci.obj:      pci.c      wmakefile $(INCS)
     119pci.obj:      pci.c      Makefile $(INCS)
    99120
    100 ahci.obj:     ahci.c     wmakefile $(INCS) ata.h atapi.h
     121ahci.obj:     ahci.c     Makefile $(INCS) ata.h atapi.h
    101122
    102 ata.obj:      ata.c      wmakefile $(INCS) ata.h
     123ata.obj:      ata.c      Makefile $(INCS) ata.h
    103124
    104 atapi.obj:    atapi.c    wmakefile $(INCS) ata.h atapi.h
     125atapi.obj:    atapi.c    Makefile $(INCS) ata.h atapi.h
    105126
    106 ctxhook.obj:  ctxhook.c  wmakefile $(INCS) ata.h atapi.h
     127ctxhook.obj:  ctxhook.c  Makefile $(INCS) ata.h atapi.h
     128
     129apm.obj:      apm.c      Makefile $(INCS)
     130
     131ioctl.obj:    ioctl.c    Makefile $(INCS) atapi.h ioctl.h
     132
     133trace.obj:    trace.c    Makefile $(INCS)
     134
     135os2ahci.def:  version.h  os2ahci.def.template
    107136
    108137###############################################################################
     
    124153        wdis -l $*.obj
    125154
     155os2ahci.def:
     156        $(BLDLEVEL) os2ahci.def.template os2ahci.def version.h
     157
    126158$(TARGET): $(OBJS) os2ahci.def wmakefile
    127         $(BLDLEVEL) os2ahci.def version.h
    128159        $(LD) $(LFLAGS) $(OBJS),$(TARGET),$*.map,$(LIB_DIRS) $(LIBS),$*.def
    129160        mapsym os2ahci
Note: See TracChangeset for help on using the changeset viewer.