Changeset 333 for GPL


Ignore:
Timestamp:
Apr 1, 2008, 10:54:17 AM (17 years ago)
Author:
Paul Smedley
Message:

Add ACPI support, make OSS compatability stuff build

Location:
GPL/branches/uniaud32-2.0
Files:
2 added
28 edited

Legend:

Unmodified
Added
Removed
  • GPL/branches/uniaud32-2.0/Configure.cmd

    r313 r333  
    4444        call lineout sIncFile, 'ALSA_LIB_      =' sAlsaBase'\lib';
    4545        call lineout sIncFile, 'ALSA_BIN_      =' sAlsaBase'\bin';
    46         call lineout sIncFile, '!ifdef 32BIT'
    4746        call lineout sIncFile, 'ALSA_INCLUDE   =' sAlsaBase'\include';
    4847        call lineout sIncFile, 'ALSA_TOOLS     =' sAlsaBase'\tools';
    49         call lineout sIncFile, '!else'
    50         call lineout sIncFile, 'ALSA_INCLUDE   =' sAlsaBase'\OCO\include';
    51         call lineout sIncFile, 'ALSA_TOOLS     =' sAlsaBase'\OCO\tools';
    52         call lineout sIncFile, '!endif'
    5348        call lineout sIncFile, ''
    5449        say 'Enter DDK base directory (e.g. c:\ddk\base)';
     
    6055        call lineout sIncFile, 'WATCOM         =' sWatcomPath;
    6156
     57        say 'Enter directory location for AcpiDrv.lib (e.g. C:\ACPI)';
     58        say 'Or leave blank if not present.'
     59        sAcpiLibPath = linein();
     60        call lineout sIncFile, 'ACPI_LIB       =' sAcpiLibPath;
     61
    6262        call lineout sIncFile, '################################################################################'
    6363        call lineout sIncFile, '# Include the right watcom makefile'
    6464        call lineout sIncFile, '################################################################################'
    65         call lineout sIncFile, '!ifdef 32BIT'
    6665        call lineout sIncFile, '!include 'sAlsaBase'\include\watcom32.mk'
    6766        call lineout sIncFile, '!include 'sAlsaBase'\include\watcom32.mak'
    68         call lineout sIncFile, '!else'
    69         call lineout sIncFile, '!include 'sAlsaBase'\OCO\include\watcom16.mk'
    70         call lineout sIncFile, '!include 'sAlsaBase'\OCO\include\watcom16.mak'
    71         call lineout sIncFile, '!endif'
    7267        call lineout sIncFile, ''
    7368
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/info_oss.c

    r305 r333  
    9393{
    9494        snd_iprintf(buffer, "Sound Driver:3.8.1a-980706 (ALSA v" CONFIG_SND_VERSION " emulation code)\n");
     95#ifndef TARGET_OS2
    9596        snd_iprintf(buffer, "Kernel: %s %s %s %s %s\n",
    9697                    init_utsname()->sysname,
     
    99100                    init_utsname()->version,
    100101                    init_utsname()->machine);
     102#endif
    101103        snd_iprintf(buffer, "Config options: 0\n");
    102104        snd_iprintf(buffer, "\nInstalled drivers: \n");
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/makefile.os2

    r313 r333  
    77!include ..\..\makefile.inc
    88
    9 NMAKEOPTS=-f makefile.os2 $(LOGO)
    10 
    11 !if "$(DEBUG)" == "1"
    12 NMAKEOPTS += DEBUG=1
    13 !endif
    14 
    15 !if "$(KEE)" == "0"
    16 NMAKEOPTS += KEE=0
    17 KEE=0
    18 !else
    19 NMAKEOPTS += KEE=1
    20 KEE=1
    21 !endif
    22 
    23 !if "$(DEBUG)" == "1"
    24 !Message BUILDING DEBUG VERSION
    25 !else
    26 !Message BUILDING RELEASE VERSION
    27 !endif
     9NMAKEOPTS=-f makefile.os2 $(LOGO) ACPI=$(ACPI) KEE=$(KEE) DEBUG=$(DEBUG)
    2810
    2911#===================================================================
     
    3416FILE1    = sound.obj init.obj memory.obj memalloc.obj sgbuf.obj
    3517FILE2    = control.obj device.obj misc.obj wrappers.obj
    36 #FILE3    = sound_oss.obj info_oss.obj isadma.obj
     18FILE3    = sound_oss.obj info_oss.obj
    3719FILE4    = pcm.obj pcm_native.obj pcm_lib.obj pcm_misc.obj pcm_timer.obj pcm_memory.obj
    3820FILE5    = rawmidi.obj
     
    7052    @wmake $(NMAKEOPTS)
    7153    @cd ..
     54    @echo BUILDING oss
     55    @cd oss
     56    @wmake $(NMAKEOPTS)
     57    @cd ..
    7258
    7359clean: .SYMBOLIC
     
    7662    @wmake $(NMAKEOPTS) clean
    7763    @cd ..
     64    @echo CLEARING oss
     65    @cd oss
     66    @wmake $(NMAKEOPTS) clean
     67    @cd ..
    7868    -@rm *.err
    7969    @cd $(OBJDIR)
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/oss/mixer_oss.c

    r305 r333  
    3636MODULE_DESCRIPTION("Mixer OSS emulation for ALSA.");
    3737MODULE_LICENSE("GPL");
     38#ifndef TARGET_OS2
    3839MODULE_ALIAS_SNDRV_MINOR(SNDRV_MINOR_OSS_MIXER);
     40#endif
    3941
    4042static int snd_mixer_oss_open(struct inode *inode, struct file *file)
     
    4446        int err;
    4547
     48#ifndef TARGET_OS2
    4649        card = snd_lookup_oss_minor_data(iminor(inode),
     50#else
     51        card = snd_lookup_oss_minor_data(MINOR(inode->i_rdev),
     52#endif
    4753                                         SNDRV_OSS_DEVICE_TYPE_MIXER);
    4854        if (card == NULL)
     
    385391#endif
    386392
     393#ifndef CONFIG_SND_HAVE_NEW_IOCTL
     394/* need to unlock BKL to allow preemption */
     395static int snd_mixer_oss_ioctl_old(struct inode *inode, struct file * file,
     396                                   unsigned int cmd, unsigned long arg)
     397{
     398        int err;
     399        err = snd_mixer_oss_ioctl(file, cmd, arg);
     400        return err;
     401}
     402#endif
     403
    387404/*
    388405 *  REGISTRATION PART
     
    391408static const struct file_operations snd_mixer_oss_f_ops =
    392409{
     410#ifndef TARGET_OS2
    393411        .owner =        THIS_MODULE,
     412#endif
    394413        .open =         snd_mixer_oss_open,
    395414        .release =      snd_mixer_oss_release,
     415#ifdef CONFIG_SND_HAVE_NEW_IOCTL
    396416        .unlocked_ioctl =       snd_mixer_oss_ioctl,
    397417        .compat_ioctl = snd_mixer_oss_ioctl_compat,
     418#else
     419        .ioctl =        snd_mixer_oss_ioctl_old,
     420#endif 
    398421};
    399422
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/oss/pcm_oss.c

    r305 r333  
    4545
    4646static int dsp_map[SNDRV_CARDS];
     47#ifndef TARGET_OS2
    4748static int adsp_map[SNDRV_CARDS] = {[0 ... (SNDRV_CARDS-1)] = 1};
     49#else
     50static int adsp_map[SNDRV_CARDS] = {1,1,1,1,1,1,1,1};
     51#endif
    4852static int nonblock_open = 1;
    4953
     
    5761module_param(nonblock_open, bool, 0644);
    5862MODULE_PARM_DESC(nonblock_open, "Don't block opening busy PCM devices.");
     63#ifndef TARGET_OS2
    5964MODULE_ALIAS_SNDRV_MINOR(SNDRV_MINOR_OSS_PCM);
    6065MODULE_ALIAS_SNDRV_MINOR(SNDRV_MINOR_OSS_PCM1);
     66#endif
    6167
    6268extern int snd_mixer_oss_ioctl_card(struct snd_card *card, unsigned int cmd, unsigned long arg);
     
    466472}
    467473
     474#ifndef TARGET_OS2
    468475static int _snd_pcm_hw_param_set(struct snd_pcm_hw_params *params,
     476#else
     477int _snd_pcm_hw_param_set(struct snd_pcm_hw_params *params,
     478#endif
    469479                                 snd_pcm_hw_param_t var, unsigned int val,
    470480                                 int dir)
     
    16281638                                }
    16291639                        } else if (runtime->access == SNDRV_PCM_ACCESS_RW_NONINTERLEAVED) {
     1640#ifndef TARGET_OS2
    16301641                                void __user *buffers[runtime->channels];
     1642#else
     1643                                void __user *buffers[32];
     1644#endif
    16311645                                memset(buffers, 0, runtime->channels * sizeof(void *));
    16321646                                snd_pcm_lib_writev(substream, buffers, size);
     
    23392353        wait_queue_t wait;
    23402354
     2355#ifndef TARGET_OS2
    23412356        pcm = snd_lookup_oss_minor_data(iminor(inode),
     2357#else
     2358        pcm = snd_lookup_oss_minor_data(MINOR(inode->i_rdev),
     2359#endif
    23422360                                        SNDRV_OSS_DEVICE_TYPE_PCM);
    23432361        if (pcm == NULL) {
     
    23732391        while (1) {
    23742392                err = snd_pcm_oss_open_file(file, pcm, &pcm_oss_file,
     2393#ifndef TARGET_OS2
    23752394                                            iminor(inode), setup);
     2395#else
     2396                                            MINOR(inode->i_rdev), setup);
     2397#endif
    23762398                if (err >= 0)
    23772399                        break;
     
    25952617#endif
    25962618
     2619#ifndef CONFIG_SND_HAVE_NEW_IOCTL
     2620/* need to unlock BKL to allow preemption */
     2621static int snd_pcm_oss_ioctl_old(struct inode *inode, struct file * file,
     2622                                 unsigned int cmd, unsigned long arg)
     2623{
     2624        int err;
     2625        err = snd_pcm_oss_ioctl(file, cmd, arg);
     2626        return err;
     2627}
     2628#endif
     2629
    25972630static ssize_t snd_pcm_oss_read(struct file *file, char __user *buf, size_t count, loff_t *offset)
    25982631{
     
    29222955static const struct file_operations snd_pcm_oss_f_reg =
    29232956{
     2957#ifndef TARGET_OS2
    29242958        .owner =        THIS_MODULE,
     2959#endif
    29252960        .read =         snd_pcm_oss_read,
    29262961        .write =        snd_pcm_oss_write,
     
    29282963        .release =      snd_pcm_oss_release,
    29292964        .poll =         snd_pcm_oss_poll,
     2965#ifdef CONFIG_SND_HAVE_NEW_IOCTL
    29302966        .unlocked_ioctl =       snd_pcm_oss_ioctl,
    29312967        .compat_ioctl = snd_pcm_oss_ioctl_compat,
     2968#else
     2969        .ioctl =        snd_pcm_oss_ioctl_old,
     2970#endif
     2971#ifndef TARGET_OS2
    29322972        .mmap =         snd_pcm_oss_mmap,
     2973#endif
    29332974};
    29342975
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/oss/pcm_plugin.h

    r305 r333  
    179179#define pdprintf( fmt, args... ) printk( "plugin: " fmt, ##args)
    180180#else
     181#ifndef TARGET_OS2
    181182#define pdprintf( fmt, args... )
     183#else
     184#define pdprintf printk
     185#endif
    182186#endif
    183187
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/pcm_lib.c

    r320 r333  
    13381338EXPORT_SYMBOL(snd_pcm_hw_param_last);
    13391339
    1340 #ifdef TARGET_OS2
    1341 int snd_interval_refine_set(struct snd_interval *i, unsigned int val)
    1342 {
    1343         struct snd_interval t;
    1344         t.empty = 0;
    1345         t.min = t.max = val;
    1346         t.openmin = t.openmax = 0;
    1347         t.integer = 1;
    1348         return snd_interval_refine(i, &t);
    1349 }
    1350 
    1351 int _snd_pcm_hw_param_set(struct snd_pcm_hw_params *params,
    1352                                  snd_pcm_hw_param_t var, unsigned int val,
    1353                                  int dir)
    1354 {
    1355         int changed;
    1356         if (hw_is_mask(var)) {
    1357                 struct snd_mask *m = hw_param_mask(params, var);
    1358                 if (val == 0 && dir < 0) {
    1359                         changed = -EINVAL;
    1360                         snd_mask_none(m);
    1361                 } else {
    1362                         if (dir > 0)
    1363                                 val++;
    1364                         else if (dir < 0)
    1365                                 val--;
    1366                         changed = snd_mask_refine_set(hw_param_mask(params, var), val);
    1367                 }
    1368         } else if (hw_is_interval(var)) {
    1369                 struct snd_interval *i = hw_param_interval(params, var);
    1370                 if (val == 0 && dir < 0) {
    1371                         changed = -EINVAL;
    1372                         snd_interval_none(i);
    1373                 } else if (dir == 0)
    1374                         changed = snd_interval_refine_set(i, val);
    1375                 else {
    1376                         struct snd_interval t;
    1377                         t.openmin = 1;
    1378                         t.openmax = 1;
    1379                         t.empty = 0;
    1380                         t.integer = 0;
    1381                         if (dir < 0) {
    1382                                 t.min = val - 1;
    1383                                 t.max = val;
    1384                         } else {
    1385                                 t.min = val;
    1386                                 t.max = val+1;
    1387                         }
    1388                         changed = snd_interval_refine(i, &t);
    1389                 }
    1390         } else
    1391                 return -EINVAL;
    1392         if (changed) {
    1393                 params->cmask |= 1 << var;
    1394                 params->rmask |= 1 << var;
    1395         }
    1396         return changed;
    1397 }
    1398 
    1399 #endif
    14001340/**
    14011341 * snd_pcm_hw_param_choose
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/pcm_misc.c

    r305 r333  
    445445                        break;
    446446                }
     447
    447448        }
    448449        return 0;
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/rawmidi.c

    r318 r333  
    4242#ifdef CONFIG_SND_OSSEMUL
    4343static int midi_map[SNDRV_CARDS];
     44#ifndef TARGET_OS2
    4445static int amidi_map[SNDRV_CARDS] = {[0 ... (SNDRV_CARDS-1)] = 1};
     46#else
     47static int amidi_map[SNDRV_CARDS] = {1,1,1,1,1,1,1,1};
     48#endif
    4549module_param_array(midi_map, int, NULL, 0444);
    4650MODULE_PARM_DESC(midi_map, "Raw MIDI device number assigned to 1st OSS device.");
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/seq/makefile.os2

    r313 r333  
    77!include ..\..\..\makefile.inc
    88
    9 NMAKEOPTS=-f makefile.os2 $(LOGO)
    10 
    11 !if "$(DEBUG)" == "1"
    12 NMAKEOPTS += DEBUG=1
    13 !endif
    14 
    15 !if "$(KEE)" == "0"
    16 NMAKEOPTS += KEE=0
    17 KEE=0
    18 !else
    19 NMAKEOPTS += KEE=1
    20 KEE=1
    21 !endif
    22 
    23 !if "$(DEBUG)" == "1"
    24 !Message BUILDING DEBUG VERSION
    25 !else
    26 !Message BUILDING RELEASE VERSION
    27 !endif
     9NMAKEOPTS=-f makefile.os2 $(LOGO) ACPI=$(ACPI) KEE=$(KEE) DEBUG=$(DEBUG)
    2810
    2911#===================================================================
     
    6244
    6345subdirs: .SYMBOLIC
    64 #    @echo BUILDING instr
    65 #    @cd instr
    66 #    @wmake $(NMAKEOPTS)
    67 #    @cd ..
     46    @echo BUILDING oss
     47    @cd oss
     48    @wmake $(NMAKEOPTS)
     49    @cd ..
    6850
    6951clean: .SYMBOLIC
    70 #    @echo BUILDING instr
    71 #    @cd instr
    72 #    @wmake $(NMAKEOPTS) clean
    73 #    @cd ..
     52    @echo BUILDING oss
     53    @cd oss
     54    @wmake $(NMAKEOPTS) clean
     55    @cd ..
    7456    -@rm *.err 2>nul
    7557    @cd $(OBJDIR)
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/seq/oss/seq_oss.c

    r305 r333  
    3737MODULE_LICENSE("GPL");
    3838/* Takashi says this is really only for sound-service-0-, but this is OK. */
     39#ifndef TARGET_OS2
    3940MODULE_ALIAS_SNDRV_MINOR(SNDRV_MINOR_OSS_SEQUENCER);
    4041MODULE_ALIAS_SNDRV_MINOR(SNDRV_MINOR_OSS_MUSIC);
     42#endif
    4143
    4244#ifdef SNDRV_SEQ_OSS_DEBUG
     
    194196#endif
    195197
     198#ifndef CONFIG_SND_HAVE_NEW_IOCTL
     199/* need to unlock BKL to allow preemption */
     200static int odev_ioctl_old(struct inode *inode, struct file * file,
     201                          unsigned int cmd, unsigned long arg)
     202{
     203        int err;
     204        err = odev_ioctl(file, cmd, arg);
     205        return err;
     206}
     207#endif
     208
    196209static unsigned int
    197210odev_poll(struct file *file, poll_table * wait)
     
    209222static const struct file_operations seq_oss_f_ops =
    210223{
     224#ifndef TARGET_OS2
    211225        .owner =        THIS_MODULE,
     226#endif
    212227        .read =         odev_read,
    213228        .write =        odev_write,
     
    215230        .release =      odev_release,
    216231        .poll =         odev_poll,
     232#ifdef CONFIG_SND_HAVE_NEW_IOCTL
    217233        .unlocked_ioctl =       odev_ioctl,
    218234        .compat_ioctl = odev_ioctl_compat,
     235#else
     236        .ioctl =        odev_ioctl_old,
     237#endif
    219238};
    220239
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/seq/oss/seq_oss_init.c

    r305 r333  
    2121 */
    2222
     23#ifdef TARGET_OS2
     24#include <sound/initval.h>
     25#endif
    2326#include "seq_oss_device.h"
    2427#include "seq_oss_synth.h"
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/seq/oss/seq_oss_midi.c

    r305 r333  
    5757static struct seq_oss_midi *midi_devs[SNDRV_SEQ_OSS_MAX_MIDI_DEVS];
    5858
     59#ifndef TARGET_OS2
    5960static DEFINE_SPINLOCK(register_lock);
     61#else
     62spinlock_t register_lock = SPIN_LOCK_UNLOCKED;
     63#endif
     64
    6065
    6166/*
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/seq/oss/seq_oss_synth.c

    r305 r333  
    7676};
    7777
     78#ifndef TARGET_OS2
    7879static DEFINE_SPINLOCK(register_lock);
     80#else
     81spinlock_t register_lock = SPIN_LOCK_UNLOCKED;
     82#endif
    7983
    8084/*
  • GPL/branches/uniaud32-2.0/alsa-kernel/core/sound_oss.c

    r305 r333  
    1919 *
    2020 */
     21#ifdef TARGET_OS2
     22#include <sound/config.h>
     23#endif
    2124
    2225#ifdef CONFIG_SND_OSSEMUL
    23 
    2426#if !defined(CONFIG_SOUND) && !(defined(MODULE) && defined(CONFIG_SOUND_MODULE))
    2527#error "Enable the OSS soundcore multiplexer (CONFIG_SOUND) in the kernel."
     
    133135                break;
    134136        }
     137#ifndef TARGET_OS2
    135138        register1 = register_sound_special_device(f_ops, minor, carddev);
    136139        if (register1 != minor)
     
    143146                snd_oss_minors[track2] = preg;
    144147        }
     148#endif
    145149        mutex_unlock(&sound_oss_mutex);
    146150        return 0;
  • GPL/branches/uniaud32-2.0/alsa-kernel/drivers/makefile.os2

    r313 r333  
    77!include ..\..\makefile.inc
    88
    9 NMAKEOPTS=-f makefile.os2 $(LOGO)
    10 
    11 !if "$(DEBUG)" == "1"
    12 NMAKEOPTS += DEBUG=1
    13 !endif
    14 
    15 !if "$(KEE)" == "0"
    16 NMAKEOPTS += KEE=0
    17 KEE=0
    18 !else
    19 NMAKEOPTS += KEE=1
    20 KEE=1
    21 !endif
    22 
    23 !if "$(DEBUG)" == "1"
    24 !Message BUILDING DEBUG VERSION
    25 !else
    26 !Message BUILDING RELEASE VERSION
    27 !endif
     9NMAKEOPTS=-f makefile.os2 $(LOGO) ACPI=$(ACPI) KEE=$(KEE) DEBUG=$(DEBUG)
    2810
    2911#===================================================================
  • GPL/branches/uniaud32-2.0/alsa-kernel/include/sound/config.h

    r315 r333  
    280280#define CONFIG_HAS_DMA
    281281#define CONFIG_SND_SEQUENCER
    282 //#define CONFIG_SND_OSSEMUL
     282#define CONFIG_SND_OSSEMUL
     283#define CONFIG_SND_PCM_OSS
     284#define CONFIG_SND_MIXER_OSS
    283285#define SNDRV_LITTLE_ENDIAN
    284286#define EXPORT_SYMBOL(a)
  • GPL/branches/uniaud32-2.0/alsa-kernel/include/sound/pcm.h

    r319 r333  
    658658{
    659659        snd_pcm_sframes_t avail = runtime->status->hw_ptr + runtime->buffer_size - runtime->control->appl_ptr;
     660#if defined TARGET_OS2
     661       if ( runtime->buffer_size > runtime->control->appl_ptr)
     662          avail = runtime->status->hw_ptr + runtime->buffer_size - runtime->control->appl_ptr;
     663       else
     664       {
     665 
     666          avail = runtime->control->appl_ptr - runtime->status->hw_ptr;
     667          if ( avail > runtime->buffer_size )
     668             avail = 0;
     669          else
     670             avail = runtime->buffer_size - avail;
     671       }
     672#endif /* TARGET_OS2  */
    660673        if (avail < 0)
    661674                avail += runtime->boundary;
  • GPL/branches/uniaud32-2.0/alsa-kernel/isa/makefile.os2

    r313 r333  
    77!include ..\..\makefile.inc
    88
    9 NMAKEOPTS=-f makefile.os2 $(LOGO)
    10 
    11 !if "$(DEBUG)" == "1"
    12 NMAKEOPTS += DEBUG=1
    13 !endif
    14 
    15 !if "$(KEE)" == "0"
    16 NMAKEOPTS += KEE=0
    17 KEE=0
    18 !else
    19 NMAKEOPTS += KEE=1
    20 KEE=1
    21 !endif
    22 
    23 !if "$(DEBUG)" == "1"
    24 !Message BUILDING DEBUG VERSION
    25 !else
    26 !Message BUILDING RELEASE VERSION
    27 !endif
     9NMAKEOPTS=-f makefile.os2 $(LOGO) ACPI=$(ACPI) KEE=$(KEE) DEBUG=$(DEBUG)
    2810
    2911#===================================================================
  • GPL/branches/uniaud32-2.0/alsa-kernel/makefile.os2

    r312 r333  
    11LOGO=-h
    22
    3 NMAKEOPTS=-f makefile.os2 $(LOGO)
    4 
    5 !if "$(DEBUG)" == "1"
    6 NMAKEOPTS += DEBUG=1
    7 !endif
    8 
    9 !if "$(KEE)" == "0"
    10 NMAKEOPTS += KEE=0
    11 KEE=0
    12 !else
    13 NMAKEOPTS += KEE=1
    14 KEE=1
    15 !endif
    16 
    17 
    18 !if "$(DEBUG)" == "1"
    19 !Message BUILDING DEBUG VERSION
    20 !else
    21 !Message BUILDING RELEASE VERSION
    22 !endif
    23 
     3NMAKEOPTS=-f makefile.os2 $(LOGO) ACPI=$(ACPI) KEE=$(KEE) DEBUG=$(DEBUG)
    244
    255#===================================================================
  • GPL/branches/uniaud32-2.0/alsa-kernel/pci/makefile.os2

    r319 r333  
    77!include ..\..\makefile.inc
    88
    9 NMAKEOPTS=-f makefile.os2 $(LOGO)
    10 
    11 !if "$(DEBUG)" == "1"
    12 NMAKEOPTS += DEBUG=1
    13 !endif
    14 
    15 !if "$(KEE)" == "0"
    16 NMAKEOPTS += KEE=0
    17 KEE=0
    18 !else
    19 NMAKEOPTS += KEE=1
    20 KEE=1
    21 !endif
    22 
    23 !if "$(DEBUG)" == "1"
    24 !Message BUILDING DEBUG VERSION
    25 !else
    26 !Message BUILDING RELEASE VERSION
    27 !endif
     9NMAKEOPTS=-f makefile.os2 $(LOGO) ACPI=$(ACPI) KEE=$(KEE) DEBUG=$(DEBUG)
    2810
    2911#===================================================================
     
    9072    @wmake $(NMAKEOPTS)
    9173    @cd ..
    92 ##    @echo BUILDING korg1212
    93 ##    @cd korg1212
    94 ##    @wmake $(NMAKEOPTS)
    95 ##    @cd ..
    9674    @echo BUILDING nm256
    9775    @cd nm256
  • GPL/branches/uniaud32-2.0/alsa-kernel/synth/makefile.os2

    r313 r333  
    77!include ..\..\makefile.inc
    88
    9 NMAKEOPTS=-f makefile.os2 $(LOGO)
    10 
    11 !if "$(DEBUG)" == "1"
    12 NMAKEOPTS += DEBUG=1
    13 !endif
    14 
    15 !if "$(KEE)" == "0"
    16 NMAKEOPTS += KEE=0
    17 KEE=0
    18 !else
    19 NMAKEOPTS += KEE=1
    20 KEE=1
    21 !endif
    22 
    23 !if "$(DEBUG)" == "1"
    24 !Message BUILDING DEBUG VERSION
    25 !else
    26 !Message BUILDING RELEASE VERSION
    27 !endif
    28 
     9NMAKEOPTS=-f makefile.os2 $(LOGO) ACPI=$(ACPI) KEE=$(KEE) DEBUG=$(DEBUG)
    2910
    3011#===================================================================
  • GPL/branches/uniaud32-2.0/drv32/makefile.os2

    r313 r333  
    1 # $Id: makefile.os2,v 1.3 2003/07/21 18:35:39 vladest Exp $
    21#
    32# Makefile for the 32bit UNIAUD driver
     
    6261FILE5    = idc.obj dispatch.obj
    6362FILE6    = rmhelp.obj irq.obj util.obj
    64 FILE7    = impdos.lib
     63FILE7    = impdos.lib 
    6564!if "$(KEE)" == "1"
    6665FILE8    = impkee.lib
     
    7069FILES    = $(FILEFIRST) $(FILE0) $(FILE1) $(FILE2) $(FILE3) $(FILE4) $(FILE5) $(FILE6) $(FILE7) $(FILE8) $(FILE9) $(FILE10)
    7170
    72 #LIBS     = $(ALSA_LIB)\linuxlib.lib $(ALSA_LIB)\core.lib $(ALSA_LIB)\drivers.lib $(ALSA_LIB)\ac97.lib $(ALSA_LIB)\pci.lib $(ALSA_LIB)\emu10k1.lib $(ALSA_LIB)\ca0106.lib $(ALSA_LIB)\hda.lib $(ALSA_LIB)\sequencer.lib $(ALSA_LIB)\opl3.lib $(ALSA_LIB)\mpu401.lib $(ALSA_LIB)\instr.lib $(ALSA_LIB)\synth.lib $(ALSA_LIB)\cs46xx.lib $(ALSA_LIB)\ymfpci.lib $(ALSA_LIB)\ali5451.lib $(ALSA_LIB)\trident.lib $(ALSA_LIB)\nm256.lib $(ALSA_LIB)\sb.lib
    73 LIBS     = $(ALSA_LIB)\linuxlib.lib $(ALSA_LIB)\core.lib $(ALSA_LIB)\drivers.lib $(ALSA_LIB)\ac97.lib $(ALSA_LIB)\pci.lib  $(ALSA_LIB)\ca0106.lib $(ALSA_LIB)\hda.lib $(ALSA_LIB)\sequencer.lib $(ALSA_LIB)\opl3.lib $(ALSA_LIB)\mpu401.lib $(ALSA_LIB)\synth.lib $(ALSA_LIB)\cs46xx.lib $(ALSA_LIB)\ymfpci.lib $(ALSA_LIB)\ali5451.lib $(ALSA_LIB)\trident.lib $(ALSA_LIB)\nm256.lib $(ALSA_LIB)\sb.lib
     71LIBS     = $(ALSA_LIB)\linuxlib.lib $(ALSA_LIB)\core.lib $(ALSA_LIB)\drivers.lib $(ALSA_LIB)\ac97.lib $(ALSA_LIB)\pci.lib  $(ALSA_LIB)\ca0106.lib $(ALSA_LIB)\hda.lib $(ALSA_LIB)\sequencer.lib $(ALSA_LIB)\opl3.lib $(ALSA_LIB)\mpu401.lib $(ALSA_LIB)\synth.lib $(ALSA_LIB)\cs46xx.lib $(ALSA_LIB)\ymfpci.lib $(ALSA_LIB)\ali5451.lib $(ALSA_LIB)\trident.lib $(ALSA_LIB)\nm256.lib $(ALSA_LIB)\sb.lib $(ALSA_LIB)\core_oss.lib $(ALSA_LIB)\seq-oss.lib
    7472WMAPNAME = $(OBJDIR)\$(TARGET).wmap
    7573# $(ALSA_LIB)\au88xx.lib
     
    8987    @%write $^@ option alignment=16
    9088    @%write $^@ option map=$(WMAPNAME)
    91 !if "$(KEE)" == "1"
     89!if "$(ACPI)" == "1"
     90    @%write $^@ option description '$(%BUILDLEVEL) (ACPI)'
     91!else if "$(KEE)" == "1" !else if "$(KEE)" == "1"
    9292    @%write $^@ option description '$(%BUILDLEVEL) (KEE)'
    9393!else
     
    9797    @for %f in ($(FILES)) do @%append $^@ file $(OBJDIR)\%f
    9898    @for %f in ($(LIBS)) do @%append $^@ library %f
     99!if "$(ACPI)" == "1"
     100    @%write $^@ $(ACPI_LIB)\acpidrv.lib
     101!endif
    99102    @%write $^@ library $(%WATCOM)\lib386\os2\clib3r.lib
    100103    @%write $^@ library $(%WATCOM)\lib386\os2\os2386.lib
     
    105108    @for %f in ($(FILES)) do @%append $^@ $(OBJDIR)\%f
    106109    @for %f in ($(LIBS)) do @%append $^@ %f
     110!if "$(ACPI)" == "1"
     111    @%write $^@ $(ACPI_LIB)\acpidrv.lib
     112!endif
    107113    @%write $^@ $(%WATCOM)\lib386\os2\clib3r.lib
    108114    @%write $^@ $(%WATCOM)\lib386\os2\os2386.lib
     
    111117
    112118$(OBJDIR)\$(TARGET).sys: $(LNKFILE) $(FILES) $(LIBS)
    113 !if "$(KEE)" == "1"
     119!if "$(ACPI)" == "1"
     120     @%write $(DEFFILE) description '$(%BUILDLEVEL) (ACPI)'
     121!else if "$(KEE)" == "1"
    114122     @%write $(DEFFILE) description '$(%BUILDLEVEL) (KEE)'
    115123!else
     
    120128
    121129     copy $(OBJDIR)\$(TARGET).sys $(ALSA_BIN)
    122 !if "$(KEE)" == "1"
    123 #     copy $(OBJDIR)\$(TARGET).sys $(ALSA_BIN)\$(TARGET)kee.sys
    124130         
     131!if "$(ACPI)" == "1"
     132      copy $(OBJDIR)\$(TARGET).sys $(ALSA_BIN_)\$(TARGET)acpi.sys
     133!else if "$(KEE)" == "1"
    125134      copy $(OBJDIR)\$(TARGET).sys $(ALSA_BIN_)\$(TARGET)kee.sys
    126135!else
    127 #     copy $(OBJDIR)\$(TARGET).sys $(ALSA_BIN)\$(TARGET)w4.sys
    128136     copy $(OBJDIR)\$(TARGET).sys $(ALSA_BIN_)\$(TARGET)w4.sys
    129137!endif
  • GPL/branches/uniaud32-2.0/include/version.h

    r324 r333  
    1313#define PRODUCT_NAME            "Universal Audio Driver for OS/2 and eComStation"
    1414#define VENDOR_NAME             "Netlabs"
    15 #define PRODUCT_TIMESTAMP       20080325L       // YYYYMMDD
     15#define PRODUCT_TIMESTAMP       20080401L       // YYYYMMDD
    1616#define UNIAUD_VERSION          "1.9.1"
    1717#define ALSA_VERSION            "1.0.16"
  • GPL/branches/uniaud32-2.0/include/watcom32.mak

    r272 r333  
    3636CFLAGS  +=  -mf -DFLATSTACK
    3737ASFLAGS += -D:FLATSTACK
     38!endif
     39
     40!if "$(ACPI)" == "1"
     41CFLAGS += -DACPI
    3842!endif
    3943
  • GPL/branches/uniaud32-2.0/include/watcom32.mk

    r32 r333  
    66DIREXT = W4
    77KEE    = 0
     8!else if "$(ACPI)" == "1"
     9DIREXT = ACP
     10ACPI   = 1
     11KEE    = 1
    812!else
    913DIREXT = KEE
  • GPL/branches/uniaud32-2.0/lib32/pci.c

    r306 r333  
    5555#define PCI_CONFIG_DATA         0xCFC
    5656
     57#ifdef ACPI
     58APIRET APIENTRY ACPIFindPCIDevice(ULONG Bus, ULONG Dev, ULONG Fun, ULONG *PicIRQ, ULONG *ApicIRQ, ULONG *Hdl, char *Component);
     59#endif
    5760
    5861//******************************************************************************
     
    135138                            struct pci_dev near *pcidev, int idx)
    136139{
     140#ifdef ACPI
     141    APIRET           rc;
     142#endif
    137143    int         resNo, addr, found = 0;
    138144    u32         devNr, busNr, funcNr, detectedId, pciId, cfgaddrreg, temp, temp2;
     145#ifdef ACPI
     146    ULONG            temp1,temp3; //PS++
     147#endif
    139148    u8          headerType;
    140149
     
    221230                        // IRQ and PIN
    222231                        pci_read_config_dword(pcidev, PCI_INTERRUPT_LINE, &temp);
     232#ifdef ACPI
     233                        temp2 = temp3 = 0;
     234                        rc = ACPIFindPCIDevice( (ULONG)busNr,                        // Bus
     235                                                (ULONG)devNr,                        // Dev
     236                                                (ULONG)(pcidev->devfn >> 8) & 7,     // Function
     237                                                &temp1,                              // PIC IRQ
     238                                                &temp3,                              // APIC IRQ
     239                                                NULL,                                // ACPI handle to finding device
     240                                                "Uniaud32");                         // Name for acpi log
     241                        if (!rc)
     242                        {
     243                        // Check APIC IRQ, if we have /SMP /APIC, must be set
     244                        if (temp3)
     245                           temp = (temp & (~0xff)) | (temp3 & 0xff);
     246                        // Check PIC IRQ
     247                        else if (temp1)
     248                                 temp = (temp & (~0xff)) | (temp1 & 0xff);
     249                        dprintf(("pci_query_device: IRQs ACPI PIC%d APIC%d", temp1, temp3));
     250                        }
     251#endif /* ACPI */
    223252                        if( (u8)temp && (u8)temp != 0xff )
    224253                        {
  • GPL/branches/uniaud32-2.0/makefile.os2

    r32 r333  
    55!if "$(DEBUG)" == "1"
    66NMAKEOPTS += DEBUG=1
     7!else
     8NMAKEOPTS += DEBUG=0
    79!endif
    810
     
    1012NMAKEOPTS += KEE=0
    1113KEE=0
     14!Message KEE=0 so ACPI=0
     15NMAKEOPTS += ACPI=0
    1216!else
    1317NMAKEOPTS += KEE=1
    1418KEE=1
     19!endif
     20
     21!include Makefile.inc
     22!if "$(ACPI_LIB)" == "" || "$(ACPI)" == "0"
     23NMAKEOPTS += ACPI=0
     24ACPI=0
     25!else
     26NMAKEOPTS += ACPI=1
     27ACPI=1
    1528!endif
    1629
Note: See TracChangeset for help on using the changeset viewer.