Merge branch 'master' of ssh://github.com/86Box/86Box into cleanup30
# Conflicts: # .ci/build.sh # .ci/dependencies_msys.txt # src/sound/snd_audiopci.c
This commit is contained in:
@@ -73,20 +73,32 @@
|
||||
)
|
||||
#endif /*HAVE_BYTESWAP_H*/
|
||||
|
||||
#if defined __has_builtin && __has_builtin(__builtin_bswap16)
|
||||
#define bswap16(x) __builtin_bswap16(x)
|
||||
#else
|
||||
static __inline uint16_t bswap16(uint16_t x)
|
||||
{
|
||||
return bswap_16(x);
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined __has_builtin && __has_builtin(__builtin_bswap32)
|
||||
#define bswap32(x) __builtin_bswap32(x)
|
||||
#else
|
||||
static __inline uint32_t bswap32(uint32_t x)
|
||||
{
|
||||
return bswap_32(x);
|
||||
}
|
||||
#endif
|
||||
|
||||
#if defined __has_builtin && __has_builtin(__builtin_bswap64)
|
||||
#define bswap64(x) __builtin_bswap64(x)
|
||||
#else
|
||||
static __inline uint64_t bswap64(uint64_t x)
|
||||
{
|
||||
return bswap_64(x);
|
||||
}
|
||||
#endif
|
||||
|
||||
static __inline void bswap16s(uint16_t *s)
|
||||
{
|
||||
|
||||
@@ -108,12 +108,12 @@ typedef struct {
|
||||
char network_host[520]; /* PCap device */
|
||||
|
||||
/* Ports category */
|
||||
char parallel_devices[3][32]; /* LPT device names */
|
||||
char parallel_devices[PARALLEL_MAX][32]; /* LPT device names */
|
||||
#ifdef USE_SERIAL_DEVICES
|
||||
char serial_devices[4][32]; /* Serial device names */
|
||||
char serial_devices[SERIAL_MAX][32]; /* Serial device names */
|
||||
#endif
|
||||
int serial_enabled[4], /* Serial ports 1 and 2 enabled */
|
||||
parallel_enabled[3]; /* LPT1, LPT2, LPT3 enabled */
|
||||
int serial_enabled[SERIAL_MAX], /* Serial ports 1, 2, 3, 4 enabled */
|
||||
parallel_enabled[PARALLEL_MAX]; /* LPT1, LPT2, LPT3, LPT4 enabled */
|
||||
|
||||
/* Other peripherals category */
|
||||
int fdc_type, /* Floppy disk controller type */
|
||||
|
||||
@@ -109,8 +109,15 @@ extern "C" {
|
||||
#ifdef EMU_DEVICE_H
|
||||
extern const device_t gameport_device;
|
||||
extern const device_t gameport_201_device;
|
||||
extern const device_t gameport_203_device;
|
||||
extern const device_t gameport_205_device;
|
||||
extern const device_t gameport_207_device;
|
||||
extern const device_t gameport_208_device;
|
||||
extern const device_t gameport_209_device;
|
||||
extern const device_t gameport_20b_device;
|
||||
extern const device_t gameport_20d_device;
|
||||
extern const device_t gameport_20f_device;
|
||||
extern const device_t gameport_tm_acm_device;
|
||||
extern const device_t gameport_pnp_device;
|
||||
extern const device_t gameport_pnp_6io_device;
|
||||
extern const device_t gameport_sio_device;
|
||||
|
||||
@@ -39,6 +39,9 @@ extern const device_t st506_xt_st11_r_device; /* st506_xt_st11_m */
|
||||
extern const device_t st506_xt_wd1002a_wx1_device; /* st506_xt_wd1002a_wx1 */
|
||||
extern const device_t st506_xt_wd1002a_27x_device; /* st506_xt_wd1002a_27x */
|
||||
extern const device_t st506_at_wd1003_device; /* st506_at_wd1003 */
|
||||
extern const device_t st506_xt_wd1004a_wx1_device; /* st506_xt_wd1004a_wx1 */
|
||||
extern const device_t st506_xt_wd1004_27x_device; /* st506_xt_wd1004_27x */
|
||||
extern const device_t st506_xt_wd1004a_27x_device; /* st506_xt_wd1004a_27x */
|
||||
|
||||
extern const device_t esdi_at_wd1007vse1_device; /* esdi_at */
|
||||
extern const device_t esdi_ps2_device; /* esdi_mca */
|
||||
|
||||
@@ -19,6 +19,18 @@
|
||||
#ifndef EMU_IDE_H
|
||||
# define EMU_IDE_H
|
||||
|
||||
#define HDC_PRIMARY_BASE 0x01F0
|
||||
#define HDC_PRIMARY_SIDE 0x03F6
|
||||
#define HDC_PRIMARY_IRQ 14
|
||||
#define HDC_SECONDARY_BASE 0x0170
|
||||
#define HDC_SECONDARY_SIDE 0x0376
|
||||
#define HDC_SECONDARY_IRQ 15
|
||||
#define HDC_TERTIARY_BASE 0x0168
|
||||
#define HDC_TERTIARY_SIDE 0x036E
|
||||
#define HDC_TERTIARY_IRQ 10
|
||||
#define HDC_QUATERNARY_BASE 0x01E8
|
||||
#define HDC_QUATERNARY_SIDE 0x03EE
|
||||
#define HDC_QUATERNARY_IRQ 11
|
||||
|
||||
enum
|
||||
{
|
||||
|
||||
@@ -1,9 +1,26 @@
|
||||
#ifndef EMU_LPT_H
|
||||
# define EMU_LPT_H
|
||||
|
||||
#define LPT1_ADDR 0x0378
|
||||
#define LPT1_IRQ 7
|
||||
#define LPT2_ADDR 0x0278
|
||||
#define LPT2_IRQ 5
|
||||
// LPT 1 on machines when installed
|
||||
#define LPT_MDA_ADDR 0x03bc
|
||||
#define LPT_MDA_IRQ 7
|
||||
#define LPT4_ADDR 0x0268
|
||||
#define LPT4_IRQ 5
|
||||
/*
|
||||
#define LPT5_ADDR 0x027c
|
||||
#define LPT5_IRQ 7
|
||||
#define LPT6_ADDR 0x026c
|
||||
#define LPT6_IRQ 5
|
||||
*/
|
||||
|
||||
typedef struct
|
||||
{
|
||||
const char *name;
|
||||
const char *internal_name;
|
||||
|
||||
void * (*init)(void *lpt);
|
||||
void (*close)(void *p);
|
||||
|
||||
@@ -706,6 +706,7 @@ extern int machine_xt_mpc1600_init(const machine_t *);
|
||||
extern int machine_xt_pcspirit_init(const machine_t *);
|
||||
extern int machine_xt_pc700_init(const machine_t *);
|
||||
extern int machine_xt_pc500_init(const machine_t *);
|
||||
extern int machine_xt_vendex_init(const machine_t *);
|
||||
extern int machine_xt_znic_init(const machine_t *);
|
||||
|
||||
extern int machine_xt_iskra3104_init(const machine_t *);
|
||||
|
||||
@@ -6,26 +6,26 @@
|
||||
extern uint8_t MIDI_InSysexBuf[SYSEX_SIZE];
|
||||
extern uint8_t MIDI_evt_len[256];
|
||||
|
||||
extern int midi_device_current;
|
||||
extern int midi_output_device_current;
|
||||
extern int midi_input_device_current;
|
||||
|
||||
extern void (*input_msg)(void *p, uint8_t *msg, uint32_t len);
|
||||
extern int (*input_sysex)(void *p, uint8_t *buf, uint32_t len, int abort);
|
||||
extern void *midi_in_p;
|
||||
|
||||
extern int midi_device_available(int card);
|
||||
extern int midi_out_device_available(int card);
|
||||
extern int midi_in_device_available(int card);
|
||||
#ifdef EMU_DEVICE_H
|
||||
const device_t *midi_device_getdevice(int card);
|
||||
const device_t *midi_out_device_getdevice(int card);
|
||||
const device_t *midi_in_device_getdevice(int card);
|
||||
#endif
|
||||
extern int midi_device_has_config(int card);
|
||||
extern int midi_out_device_has_config(int card);
|
||||
extern int midi_in_device_has_config(int card);
|
||||
extern char *midi_device_get_internal_name(int card);
|
||||
extern char *midi_out_device_get_internal_name(int card);
|
||||
extern char *midi_in_device_get_internal_name(int card);
|
||||
extern int midi_device_get_from_internal_name(char *s);
|
||||
extern int midi_out_device_get_from_internal_name(char *s);
|
||||
extern int midi_in_device_get_from_internal_name(char *s);
|
||||
extern void midi_device_init();
|
||||
extern void midi_out_device_init();
|
||||
extern void midi_in_device_init();
|
||||
|
||||
typedef struct midi_device_t {
|
||||
@@ -56,11 +56,11 @@ typedef struct midi_t {
|
||||
midi_device_t *m_out_device, *m_in_device;
|
||||
} midi_t;
|
||||
|
||||
extern midi_t *midi, *midi_in;
|
||||
extern midi_t *midi_out, *midi_in;
|
||||
|
||||
extern void midi_init(midi_device_t *device);
|
||||
extern void midi_out_init(midi_device_t *device);
|
||||
extern void midi_in_init(midi_device_t *device, midi_t **mididev);
|
||||
extern void midi_close();
|
||||
extern void midi_out_close();
|
||||
extern void midi_in_close(void);
|
||||
extern void midi_raw_out_rt_byte(uint8_t val);
|
||||
extern void midi_raw_out_thru_rt_byte(uint8_t val);
|
||||
@@ -90,7 +90,7 @@ extern void midi_in_sysex(uint8_t *buffer, uint32_t len);
|
||||
#define MIDI_INPUT_INTERNAL_NAME "midi_in"
|
||||
|
||||
#ifdef EMU_DEVICE_H
|
||||
extern const device_t rtmidi_device;
|
||||
extern const device_t rtmidi_output_device;
|
||||
extern const device_t rtmidi_input_device;
|
||||
# ifdef USE_FLUIDSYNTH
|
||||
extern const device_t fluidsynth_device;
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
extern int rtmidi_get_num_devs(void);
|
||||
extern void rtmidi_get_dev_name(int num, char *s);
|
||||
extern int rtmidi_out_get_num_devs(void);
|
||||
extern void rtmidi_out_get_dev_name(int num, char *s);
|
||||
extern int rtmidi_in_get_num_devs(void);
|
||||
extern void rtmidi_in_get_dev_name(int num, char *s);
|
||||
|
||||
|
||||
@@ -40,7 +40,7 @@ extern int stricmp(const char* s1, const char* s2);
|
||||
extern int strnicmp(const char* s1, const char* s2, size_t n);
|
||||
#endif
|
||||
|
||||
#if (defined(__unix__) || defined(__APPLE__)) && !defined(__linux__)
|
||||
#if (defined(__HAIKU__) || defined(__unix__) || defined(__APPLE__)) && !defined(__linux__)
|
||||
/* FreeBSD has largefile by default. */
|
||||
# define fopen64 fopen
|
||||
# define fseeko64 fseeko
|
||||
|
||||
@@ -35,14 +35,14 @@
|
||||
#define SERIAL_FIFO_SIZE 16
|
||||
|
||||
/* Default settings for the standard ports. */
|
||||
#define SERIAL1_ADDR 0x03f8
|
||||
#define SERIAL1_IRQ 4
|
||||
#define SERIAL2_ADDR 0x02f8
|
||||
#define SERIAL2_IRQ 3
|
||||
#define SERIAL3_ADDR 0x03e8
|
||||
#define SERIAL3_IRQ 4
|
||||
#define SERIAL4_ADDR 0x02e8
|
||||
#define SERIAL4_IRQ 3
|
||||
#define COM1_ADDR 0x03f8
|
||||
#define COM1_IRQ 4
|
||||
#define COM2_ADDR 0x02f8
|
||||
#define COM2_IRQ 3
|
||||
#define COM3_ADDR 0x03e8
|
||||
#define COM3_IRQ 4
|
||||
#define COM4_ADDR 0x02e8
|
||||
#define COM4_IRQ 3
|
||||
|
||||
|
||||
struct serial_device_s;
|
||||
|
||||
Reference in New Issue
Block a user