include and whitespace clean-up in dos source files

master
Ozkan Sezer 3 years ago
parent 653d0afaf3
commit b597ad2eeb
  1. 5
      src/dos/dosdma.c
  2. 28
      src/dos/dosirq.c
  3. 2
      src/dos/dossb.c
  4. 1
      src/dos/dossb.h

@ -9,9 +9,6 @@
* file for more information. * file for more information.
*/ */
#include "dosdma.h"
#include "dosutil.h"
#include <dos.h> #include <dos.h>
#include <malloc.h> #include <malloc.h>
@ -19,6 +16,8 @@
#include <sys/nearptr.h> #include <sys/nearptr.h>
#endif #endif
#include "dosdma.h"
__dma_regs dma[8] = { __dma_regs dma[8] = {
/* *INDENT-OFF* */ /* *INDENT-OFF* */
{DMA_ADDR_0, DMA_PAGE_0, DMA_SIZE_0, {DMA_ADDR_0, DMA_PAGE_0, DMA_SIZE_0,

@ -9,17 +9,18 @@
* file for more information. * file for more information.
*/ */
#include "dosirq.h"
#include "dosutil.h"
#include <dos.h> #include <dos.h>
#include <malloc.h> #include <malloc.h>
#include <string.h> #include <string.h>
#ifdef __DJGPP__ #ifdef __DJGPP__
#include <dpmi.h> #include <dpmi.h>
#include <go32.h> #include <go32.h>
#include <sys/nearptr.h> #include <sys/nearptr.h>
#endif
#include "dosirq.h"
#if defined(__DJGPP__)
unsigned int __irq_stack_size = 0x4000; unsigned int __irq_stack_size = 0x4000;
unsigned int __irq_stack_count = 1; unsigned int __irq_stack_count = 1;
@ -65,8 +66,6 @@ static void __int_stub_template (void)
/* *INDENT-ON* */ /* *INDENT-ON* */
} }
#include <stdio.h>
static int _allocate_iret_wrapper(_go32_dpmi_seginfo * info) static int _allocate_iret_wrapper(_go32_dpmi_seginfo * info)
{ {
unsigned char *irqtpl = (unsigned char *)__int_stub_template; unsigned char *irqtpl = (unsigned char *)__int_stub_template;
@ -281,15 +280,14 @@ static int (*__irq_confirm) (int irqno);
static volatile unsigned int __irq_mask; static volatile unsigned int __irq_mask;
static volatile unsigned int __irq_count[16]; static volatile unsigned int __irq_count[16];
#define DECLARE_IRQ_HANDLER(irqno) \ #define DECLARE_IRQ_HANDLER(irqno) \
static void INTERRUPT_ATTRIBUTES NO_REORDER __irq##irqno##_handler () \ static void INTERRUPT_ATTRIBUTES NO_REORDER __irq##irqno##_handler () \
{ \ { \
if (irq_check (__irqs [irqno]) && __irq_confirm (irqno)) \ if (irq_check (__irqs [irqno]) && __irq_confirm (irqno)) { \
{ \ __irq_count [irqno]++; \
__irq_count [irqno]++; \ __irq_mask |= (1 << irqno); \
__irq_mask |= (1 << irqno); \ } \
} \ irq_ack (__irqs [irqno]); \
irq_ack (__irqs [irqno]); \
} }
/* *INDENT-OFF* */ /* *INDENT-OFF* */

@ -20,7 +20,7 @@
#include <sys/farptr.h> #include <sys/farptr.h>
#else #else
#define _farsetsel(seg) #define _farsetsel(seg)
#define _farnspeekl(addr) (*((unsigned long *)(addr))) #define _farnspeekl(addr) (*((unsigned long *)(addr)))
#endif #endif
#include "dossb.h" #include "dossb.h"

@ -15,7 +15,6 @@
#include "dosdma.h" #include "dosdma.h"
#include "dosirq.h" #include "dosirq.h"
#include "dosutil.h"
#define SB_FM_LEFT_STATUS (sb.port + 0x00) /* (r) Left FM status */ #define SB_FM_LEFT_STATUS (sb.port + 0x00) /* (r) Left FM status */
#define SB_FM_LEFT_REGSEL (sb.port + 0x00) /* (w) Left FM register select */ #define SB_FM_LEFT_REGSEL (sb.port + 0x00) /* (w) Left FM register select */

Loading…
Cancel
Save