mirror of
https://github.com/86Box/86Box.git
synced 2026-02-22 09:35:32 -07:00
Merge branch '86Box:master' into machine_23
This commit is contained in:
4
.github/workflows/cmake.yml
vendored
4
.github/workflows/cmake.yml
vendored
@@ -263,7 +263,7 @@ jobs:
|
||||
build-wrapper-win-x86-64 --out-dir ${{ env.BUILD_WRAPPER_OUT_DIR }} cmake --build build
|
||||
|
||||
- name: Run sonar-scanner
|
||||
# if: 0
|
||||
if: 0
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||
@@ -445,7 +445,7 @@ jobs:
|
||||
build-wrapper-macosx-x86 --out-dir ${{ env.BUILD_WRAPPER_OUT_DIR }} cmake --build build
|
||||
|
||||
- name: Run sonar-scanner
|
||||
# if: 0
|
||||
if: 0
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||
|
||||
@@ -652,7 +652,7 @@ cdi_cue_get_buffer(char *str, char **line, int up)
|
||||
done = 1;
|
||||
break;
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -324,7 +324,7 @@ mitsumi_cdrom_out(uint16_t port, uint8_t val, void *priv)
|
||||
break;
|
||||
case 5:
|
||||
dev->readmsf = 0;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 4:
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
#include <86box/io.h>
|
||||
#include <86box/mem.h>
|
||||
#include <86box/pci.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
#include <86box/smram.h>
|
||||
#include <86box/spd.h>
|
||||
@@ -108,7 +109,7 @@ ali1621_smram_recalc(uint8_t val, ali1621_t *dev)
|
||||
switch (val & 0x30) {
|
||||
case 0x10: /* Open. */
|
||||
access_normal = ACCESS_SMRAM_RX;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x30: /* Protect. */
|
||||
@@ -123,7 +124,7 @@ ali1621_smram_recalc(uint8_t val, ali1621_t *dev)
|
||||
switch (val & 0x30) {
|
||||
case 0x10: /* Open. */
|
||||
access_normal |= ACCESS_SMRAM_W;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x30: /* Protect. */
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
#include <86box/hdc.h>
|
||||
#include <86box/hdc_ide.h>
|
||||
#include <86box/chipset.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
|
||||
typedef struct ali6117_t {
|
||||
uint32_t local;
|
||||
@@ -233,7 +234,7 @@ ali6117_reg_write(uint16_t addr, uint8_t val, void *priv)
|
||||
|
||||
case 0x12:
|
||||
val &= 0xf7;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
#include <86box/io.h>
|
||||
#include <86box/device.h>
|
||||
#include <86box/mem.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
#include <86box/chipset.h>
|
||||
|
||||
@@ -228,7 +229,7 @@ opti283_write(uint16_t addr, uint8_t val, void *priv)
|
||||
|
||||
case 0x14:
|
||||
reset_on_hlt = !!(val & 0x40);
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x11:
|
||||
|
||||
@@ -41,6 +41,7 @@
|
||||
#include <86box/ddma.h>
|
||||
#include <86box/pci.h>
|
||||
#include <86box/pic.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
#include <86box/port_92.h>
|
||||
#include <86box/hdc.h>
|
||||
@@ -1474,7 +1475,7 @@ pipc_write(int func, int addr, uint8_t val, void *priv)
|
||||
case 0xd2:
|
||||
if (dev->local == VIA_PIPC_686B)
|
||||
smbus_piix4_setclock(dev->smbus, (val & 0x04) ? 65536 : 16384);
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -481,6 +481,8 @@ typedef union {
|
||||
# define FP_TAG_VALID_N cpu_state.tag[(cpu_state.TOP + 1) & 7] &= ~TAG_UINT64
|
||||
#endif
|
||||
|
||||
#include "softfloat/softfloat-specialize.h"
|
||||
|
||||
#include "x87_ops_sf_arith.h"
|
||||
#include "x87_ops_sf_compare.h"
|
||||
#include "x87_ops_sf_const.h"
|
||||
|
||||
@@ -29,6 +29,7 @@
|
||||
#include <86box/io.h>
|
||||
#include <86box/pic.h>
|
||||
#include <86box/pit.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
#include <86box/ppi.h>
|
||||
#include <86box/mem.h>
|
||||
@@ -463,7 +464,7 @@ kbc_at_poll_at(atkbc_t *dev)
|
||||
case STATE_KBC_AMI_OUT:
|
||||
if (dev->status & STAT_OFULL)
|
||||
break;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case STATE_MAIN_IBF:
|
||||
@@ -588,7 +589,7 @@ kbc_at_poll_ps2(atkbc_t *dev)
|
||||
case STATE_KBC_AMI_OUT:
|
||||
if (dev->status & STAT_OFULL)
|
||||
break;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case STATE_MAIN_IBF:
|
||||
|
||||
@@ -38,6 +38,7 @@
|
||||
#include <86box/snd_speaker.h>
|
||||
#include <86box/video.h>
|
||||
#include <86box/keyboard.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
|
||||
#ifdef ENABLE_KBC_AT_DEV_LOG
|
||||
int kbc_at_dev_do_log = ENABLE_KBC_AT_DEV_LOG;
|
||||
@@ -135,7 +136,7 @@ kbc_at_dev_poll(void *priv)
|
||||
dev->port->wantcmd = 0;
|
||||
break;
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case DEV_STATE_MAIN_WANT_IN:
|
||||
|
||||
@@ -26,6 +26,7 @@
|
||||
#include <86box/timer.h>
|
||||
#include <86box/serial.h>
|
||||
#include <86box/mouse.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
#define SERMOUSE_PORT 0 /* attach to Serial0 */
|
||||
@@ -507,7 +508,7 @@ sermouse_command_timer(void *priv)
|
||||
break;
|
||||
case PHASE_ACK:
|
||||
serial_write_fifo(dev->serial, 0x06);
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case PHASE_BAUD_RATE:
|
||||
@@ -647,7 +648,7 @@ ltsermouse_write(UNUSED(struct serial_s *serial), void *priv, uint8_t data)
|
||||
switch (data) {
|
||||
default:
|
||||
mouse_serial_log("Serial mouse: Invalid period %02X, using 1200 bps\n", data);
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x6E:
|
||||
|
||||
@@ -28,6 +28,7 @@
|
||||
#include <86box/timer.h>
|
||||
#include <86box/i2c.h>
|
||||
#include <86box/smbus.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
|
||||
#ifdef ENABLE_SMBUS_ALI7101_LOG
|
||||
int smbus_ali7101_do_log = ENABLE_SMBUS_ALI7101_LOG;
|
||||
@@ -193,7 +194,7 @@ smbus_ali7101_write(uint16_t addr, uint8_t val, void *priv)
|
||||
case 0x4: /* block R/W */
|
||||
timer_bytes++; /* count the SMBus length byte now */
|
||||
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -27,6 +27,7 @@
|
||||
#include <86box/timer.h>
|
||||
#include <86box/i2c.h>
|
||||
#include <86box/smbus.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
|
||||
#ifdef ENABLE_SMBUS_PIIX4_LOG
|
||||
int smbus_piix4_do_log = ENABLE_SMBUS_PIIX4_LOG;
|
||||
@@ -195,7 +196,7 @@ smbus_piix4_write(uint16_t addr, uint8_t val, void *priv)
|
||||
timer_bytes++;
|
||||
}
|
||||
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -216,7 +217,7 @@ smbus_piix4_write(uint16_t addr, uint8_t val, void *priv)
|
||||
case 0x5: /* block R/W */
|
||||
timer_bytes++; /* count the SMBus length byte now */
|
||||
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -251,7 +252,7 @@ smbus_piix4_write(uint16_t addr, uint8_t val, void *priv)
|
||||
i2c_write(i2c_smbus, smbus_addr, dev->cmd);
|
||||
timer_bytes++;
|
||||
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -338,7 +338,7 @@ esdi_write(uint16_t port, uint8_t val, void *priv)
|
||||
esdi->command &= ~0x03;
|
||||
if (val & 0x02)
|
||||
fatal("Read with ECC\n");
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -399,7 +399,7 @@ esdi_write(uint16_t port, uint8_t val, void *priv)
|
||||
|
||||
default:
|
||||
esdi_at_log("WD1007: bad command %02X\n", val);
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0xe8: /*???*/
|
||||
|
||||
@@ -1655,7 +1655,7 @@ ide_writeb(uint16_t addr, uint8_t val, void *priv)
|
||||
disabled, the Read Multiple operation is rejected with an Aborted Com-
|
||||
mand error. */
|
||||
ide->blockcount = 0;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -1706,7 +1706,7 @@ ide_writeb(uint16_t addr, uint8_t val, void *priv)
|
||||
/* Turn on the activity indicator *here* so that it gets turned on
|
||||
less times. */
|
||||
ui_sb_update_icon(SB_HDD | hdd[ide->hdd_num].bus, 1);
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -623,7 +623,7 @@ st506_callback(void *priv)
|
||||
st506_complete(dev);
|
||||
break;
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -1608,7 +1608,7 @@ st506_init(const device_t *info)
|
||||
|
||||
case ST506_XT_TYPE_ST11R: /* Seagate ST-11R (RLL) */
|
||||
dev->spt = RLL_SECTORS;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -509,7 +509,7 @@ hdc_callback(void *priv)
|
||||
|
||||
case CMD_READ_VERIFY:
|
||||
no_data = 1;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -536,7 +536,7 @@ hdc_callback(void *priv)
|
||||
dev->buf_len = 512;
|
||||
|
||||
dev->state = STATE_SEND;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -646,7 +646,7 @@ do_send:
|
||||
dev->buf_len = 512;
|
||||
|
||||
dev->state = STATE_RECV;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -655,7 +655,7 @@ mo_update_request_length(mo_t *dev, int len, int block_len)
|
||||
break;
|
||||
}
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
default:
|
||||
@@ -1344,7 +1344,7 @@ mo_command(scsi_common_t *sc, uint8_t *cdb)
|
||||
mo_invalid_field(dev);
|
||||
return;
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case GPCMD_SCSI_RESERVE:
|
||||
|
||||
@@ -821,7 +821,7 @@ zip_update_request_length(zip_t *dev, int len, int block_len)
|
||||
break;
|
||||
}
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -1411,7 +1411,7 @@ zip_command(scsi_common_t *sc, uint8_t *cdb)
|
||||
zip_invalid_field(dev);
|
||||
return;
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case GPCMD_SCSI_RESERVE:
|
||||
@@ -1576,7 +1576,7 @@ zip_command(scsi_common_t *sc, uint8_t *cdb)
|
||||
zip_command_complete(dev);
|
||||
break;
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case GPCMD_WRITE_6:
|
||||
|
||||
@@ -36,6 +36,7 @@
|
||||
#include <86box/fdd.h>
|
||||
#include <86box/fdc.h>
|
||||
#include <86box/fdc_ext.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
extern uint64_t motoron[FDD_NUM];
|
||||
@@ -916,7 +917,7 @@ fdc_write(uint16_t addr, uint8_t val, void *priv)
|
||||
fdc_bad_command(fdc);
|
||||
break;
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x07: /*Recalibrate*/
|
||||
@@ -961,7 +962,7 @@ fdc_write(uint16_t addr, uint8_t val, void *priv)
|
||||
fdc_bad_command(fdc);
|
||||
break;
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x10: /*Get version*/
|
||||
@@ -1085,7 +1086,7 @@ fdc_write(uint16_t addr, uint8_t val, void *priv)
|
||||
case 0x16: /* Verify */
|
||||
if (fdc->params[0] & 0x80)
|
||||
fdc->sc = fdc->params[7];
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x06: /* Read data */
|
||||
|
||||
@@ -1951,7 +1951,7 @@ d86f_format_track(int drive, int side, int do_write)
|
||||
if (dev->datac == 3)
|
||||
fdc_stop_id_request(d86f_fdc);
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -2296,7 +2296,7 @@ d86f_turbo_poll(int drive, int side)
|
||||
case STATE_0D_SPIN_TO_INDEX:
|
||||
dev->sector_count = 0;
|
||||
dev->datac = 5;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -2343,7 +2343,7 @@ d86f_turbo_poll(int drive, int side)
|
||||
dev->last_sector.id.r = dev->req_sector.id.r;
|
||||
dev->last_sector.id.n = dev->req_sector.id.n;
|
||||
d86f_handler[drive].set_sector(drive, side, dev->last_sector.id.c, dev->last_sector.id.h, dev->last_sector.id.r, dev->last_sector.id.n);
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -55,6 +55,10 @@ extern int strnicmp(const char *s1, const char *s2, size_t n);
|
||||
# define off64_t off_t
|
||||
#endif
|
||||
|
||||
#if !defined (__APPLE__) && !defined(__clang__)
|
||||
# define FALLTHROUGH_ANNOTATION
|
||||
#endif
|
||||
|
||||
#ifdef _MSC_VER
|
||||
# define UNUSED(arg) arg
|
||||
#else
|
||||
|
||||
25
src/include/86box/plat_fallthrough.h
Normal file
25
src/include/86box/plat_fallthrough.h
Normal file
@@ -0,0 +1,25 @@
|
||||
/*
|
||||
* 86Box A hypervisor and IBM PC system emulator that specializes in
|
||||
* running old operating systems and software designed for IBM
|
||||
* PC systems and compatibles from 1981 through fairly recent
|
||||
* system designs based on the PCI bus.
|
||||
*
|
||||
* This file is part of the 86Box distribution.
|
||||
*
|
||||
* Define the various platform support functions.
|
||||
*
|
||||
*
|
||||
*
|
||||
* Authors: Jasmine Iwanek, <jasmine@iwanek.co.uk>
|
||||
*
|
||||
* Copyright 2023 Jasmine Iwanek
|
||||
*/
|
||||
|
||||
#ifndef EMU_PLAT_FALLTHROUGH_H
|
||||
#define EMU_PLAT_FALLTHROUGH_H
|
||||
|
||||
#if !defined (__APPLE__) && !defined(__clang__)
|
||||
# define FALLTHROUGH_ANNOTATION
|
||||
#endif
|
||||
|
||||
#endif /*EMU_PLAT_FALLTHROUGH_H*/
|
||||
@@ -20,7 +20,7 @@
|
||||
|
||||
#include <86box/rom.h>
|
||||
|
||||
typedef struct xga_hwcursor_t {
|
||||
typedef struct {
|
||||
int ena;
|
||||
int x;
|
||||
int y;
|
||||
@@ -37,14 +37,11 @@ typedef struct xga_t {
|
||||
mem_mapping_t video_mapping;
|
||||
rom_t bios_rom;
|
||||
rom_t vga_bios_rom;
|
||||
xga_hwcursor_t hwcursor;
|
||||
xga_hwcursor_t hwcursor_latch;
|
||||
xga_hwcursor_t hwcursor, hwcursor_latch;
|
||||
PALETTE extpal;
|
||||
|
||||
uint8_t test;
|
||||
uint8_t atest[2];
|
||||
uint8_t testpixel;
|
||||
|
||||
uint8_t test, atest[2], testpixel;
|
||||
;
|
||||
uint8_t pos_regs[8];
|
||||
uint8_t disp_addr;
|
||||
uint8_t cfg_reg;
|
||||
@@ -57,43 +54,34 @@ typedef struct xga_t {
|
||||
uint8_t regs_idx;
|
||||
uint8_t hwc_hotspot_x;
|
||||
uint8_t hwc_hotspot_y;
|
||||
uint8_t disp_cntl_1;
|
||||
uint8_t disp_cntl_2;
|
||||
uint8_t clk_sel_1;
|
||||
uint8_t clk_sel_2;
|
||||
uint8_t disp_cntl_1, disp_cntl_2;
|
||||
uint8_t clk_sel_1, clk_sel_2;
|
||||
uint8_t hwc_control;
|
||||
uint8_t bus_arb;
|
||||
uint8_t isa_pos_enable;
|
||||
uint8_t hwcursor_oddeven;
|
||||
uint8_t cfg_reg_instance;
|
||||
uint8_t rowcount;
|
||||
uint8_t pal_idx;
|
||||
uint8_t pal_idx_prefetch;
|
||||
uint8_t pal_idx, pal_idx_prefetch;
|
||||
uint8_t pal_seq;
|
||||
uint8_t pal_mask;
|
||||
uint8_t pal_r;
|
||||
uint8_t pal_r_prefetch;
|
||||
uint8_t pal_g;
|
||||
uint8_t pal_g_prefetch;
|
||||
uint8_t pal_b;
|
||||
uint8_t pal_b_prefetch;
|
||||
uint8_t pal_r, pal_r_prefetch;
|
||||
uint8_t pal_g, pal_g_prefetch;
|
||||
uint8_t pal_b, pal_b_prefetch;
|
||||
uint8_t sprite_data[1024];
|
||||
uint8_t scrollcache;
|
||||
uint8_t border_color;
|
||||
uint8_t direct_color;
|
||||
uint8_t dma_channel;
|
||||
uint8_t instance_isa;
|
||||
uint8_t instance_num;
|
||||
uint8_t ext_mem_addr;
|
||||
uint8_t *vram;
|
||||
uint8_t *changedvram;
|
||||
uint8_t instance_isa, instance_num, ext_mem_addr;
|
||||
uint8_t *vram, *changedvram;
|
||||
|
||||
int16_t hwc_pos_x;
|
||||
int16_t hwc_pos_y;
|
||||
|
||||
uint16_t pos_idx;
|
||||
uint16_t htotal;
|
||||
uint16_t sprite_idx;
|
||||
uint16_t sprite_idx_prefetch;
|
||||
uint16_t sprite_idx, sprite_idx_prefetch;
|
||||
uint16_t hdisp;
|
||||
uint16_t vtotal;
|
||||
uint16_t vdispend;
|
||||
@@ -101,74 +89,41 @@ typedef struct xga_t {
|
||||
uint16_t vsyncstart;
|
||||
uint16_t linecmp;
|
||||
uint16_t pix_map_width;
|
||||
uint16_t sprite_pal_addr_idx;
|
||||
uint16_t old_pal_addr_idx;
|
||||
uint16_t sprite_pal_addr_idx, old_pal_addr_idx;
|
||||
uint16_t sprite_pal_addr_idx_prefetch;
|
||||
|
||||
int v_total;
|
||||
int dispend;
|
||||
int v_syncstart;
|
||||
int split;
|
||||
int v_blankstart;
|
||||
int h_disp;
|
||||
int h_disp_old;
|
||||
int h_total;
|
||||
int h_disp_time;
|
||||
int rowoffset;
|
||||
int dispon;
|
||||
int h_disp_on;
|
||||
int vc;
|
||||
int sc;
|
||||
int linepos;
|
||||
int oddeven;
|
||||
int firstline;
|
||||
int lastline;
|
||||
int firstline_draw;
|
||||
int lastline_draw;
|
||||
int displine;
|
||||
int fullchange;
|
||||
int interlace;
|
||||
int char_width;
|
||||
int hwcursor_on;
|
||||
int pal_pos;
|
||||
int pal_pos_prefetch;
|
||||
int v_total, dispend, v_syncstart, split, v_blankstart,
|
||||
h_disp, h_disp_old, h_total, h_disp_time, rowoffset,
|
||||
dispon, h_disp_on, vc, sc, linepos, oddeven, firstline, lastline,
|
||||
firstline_draw, lastline_draw, displine, fullchange, interlace,
|
||||
char_width, hwcursor_on;
|
||||
int pal_pos, pal_pos_prefetch;
|
||||
int on;
|
||||
int op_mode_reset;
|
||||
int linear_endian_reverse;
|
||||
int sprite_pos;
|
||||
int sprite_pos_prefetch;
|
||||
int cursor_data_on;
|
||||
int pal_test;
|
||||
int a5_test;
|
||||
int type;
|
||||
int bus;
|
||||
int op_mode_reset, linear_endian_reverse;
|
||||
int sprite_pos, sprite_pos_prefetch, cursor_data_on;
|
||||
int pal_test, a5_test;
|
||||
int type, bus;
|
||||
|
||||
uint32_t linear_base;
|
||||
uint32_t linear_size;
|
||||
uint32_t banked_mask;
|
||||
uint32_t linear_base, linear_size, banked_mask;
|
||||
uint32_t base_addr_1mb;
|
||||
uint32_t hwc_color0;
|
||||
uint32_t hwc_color1;
|
||||
uint32_t hwc_color0, hwc_color1;
|
||||
uint32_t disp_start_addr;
|
||||
uint32_t ma_latch;
|
||||
uint32_t vram_size;
|
||||
uint32_t vram_mask;
|
||||
uint32_t rom_addr;
|
||||
uint32_t ma;
|
||||
uint32_t maback;
|
||||
uint32_t ma, maback;
|
||||
uint32_t extpallook[256];
|
||||
uint32_t read_bank;
|
||||
uint32_t write_bank;
|
||||
uint32_t read_bank, write_bank;
|
||||
uint32_t px_map_base;
|
||||
|
||||
uint64_t dispontime;
|
||||
uint64_t dispofftime;
|
||||
uint64_t dispontime, dispofftime;
|
||||
|
||||
struct {
|
||||
struct
|
||||
{
|
||||
uint8_t control;
|
||||
uint8_t px_map_idx;
|
||||
uint8_t frgd_mix;
|
||||
uint8_t bkgd_mix;
|
||||
uint8_t frgd_mix, bkgd_mix;
|
||||
uint8_t cc_cond;
|
||||
uint8_t octant;
|
||||
uint8_t draw_mode;
|
||||
@@ -179,19 +134,15 @@ typedef struct xga_t {
|
||||
uint8_t short_stroke_vector4;
|
||||
|
||||
int16_t bres_err_term;
|
||||
int16_t bres_k1;
|
||||
int16_t bres_k2;
|
||||
int16_t bres_k1, bres_k2;
|
||||
|
||||
uint16_t blt_width;
|
||||
uint16_t blt_height;
|
||||
uint16_t mask_map_origin_x_off;
|
||||
uint16_t mask_map_origin_y_off;
|
||||
uint16_t src_map_x;
|
||||
uint16_t src_map_y;
|
||||
uint16_t dst_map_x;
|
||||
uint16_t dst_map_y;
|
||||
uint16_t pat_map_x;
|
||||
uint16_t pat_map_y;
|
||||
uint16_t src_map_x, src_map_y;
|
||||
uint16_t dst_map_x, dst_map_y;
|
||||
uint16_t pat_map_x, pat_map_y;
|
||||
|
||||
int ssv_state;
|
||||
int pat_src;
|
||||
@@ -199,14 +150,7 @@ typedef struct xga_t {
|
||||
int dst_map;
|
||||
int bkgd_src;
|
||||
int fore_src;
|
||||
int x;
|
||||
int y;
|
||||
int sx;
|
||||
int sy;
|
||||
int dx;
|
||||
int dy;
|
||||
int px;
|
||||
int py;
|
||||
int x, y, sx, sy, dx, dy, px, py;
|
||||
int pattern;
|
||||
int command_len;
|
||||
|
||||
@@ -214,8 +158,7 @@ typedef struct xga_t {
|
||||
uint32_t color_cmp;
|
||||
uint32_t carry_chain;
|
||||
uint32_t plane_mask;
|
||||
uint32_t frgd_color;
|
||||
uint32_t bkgd_color;
|
||||
uint32_t frgd_color, bkgd_color;
|
||||
uint32_t command;
|
||||
uint32_t dir_cmd;
|
||||
|
||||
@@ -225,6 +168,6 @@ typedef struct xga_t {
|
||||
uint32_t px_map_base[4];
|
||||
} accel;
|
||||
|
||||
volatile int force_busy;
|
||||
int big_endian_linear;
|
||||
} xga_t;
|
||||
#endif /*VIDEO_XGA_H*/
|
||||
|
||||
@@ -50,6 +50,7 @@
|
||||
#include <86box/rom.h>
|
||||
#include <86box/video.h>
|
||||
#include <86box/vid_cga.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
static void
|
||||
@@ -123,7 +124,7 @@ elt_vid_out(uint16_t addr, uint8_t val, void *priv)
|
||||
case 0x3d1:
|
||||
if (cga->crtcreg >= 32)
|
||||
return;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -699,7 +699,7 @@ do_fmt:
|
||||
|
||||
/* Done with this track. */
|
||||
dev->state = STATE_FDONE;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case STATE_FDONE:
|
||||
|
||||
@@ -68,6 +68,7 @@
|
||||
#include <86box/net_ne2000.h>
|
||||
#include <86box/bswap.h>
|
||||
#include <86box/isapnp.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
/* ROM BIOS file paths. */
|
||||
@@ -749,7 +750,7 @@ nic_pci_write(UNUSED(int func), int addr, uint8_t val, void *priv)
|
||||
case 0x10: /* PCI_BAR */
|
||||
val &= 0xe0; /* 0xe0 acc to RTL DS */
|
||||
val |= 0x01; /* re-enable IOIN bit */
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -64,6 +64,7 @@
|
||||
#include <86box/net_dp8390.h>
|
||||
#include <86box/net_wd8003.h>
|
||||
#include <86box/bswap.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
#include "cpu.h"
|
||||
@@ -734,7 +735,7 @@ wd_init(const device_t *info)
|
||||
/* Ethernet, MCA, 5x3 interface chip, RAM 16k */
|
||||
case WD8003EA:
|
||||
dev->board_chip = WE_ID_SOFT_CONFIG;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
/* Ethernet, MCA, no interface chip, RAM 16k */
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
#include <86box/io.h>
|
||||
#include <86box/pci.h>
|
||||
#include <86box/pci_dummy.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
typedef struct pci_dummy_t {
|
||||
@@ -210,7 +211,7 @@ pci_dummy_pci_write(int func, int addr, uint8_t val, void *priv)
|
||||
|
||||
case 0x10: /* PCI_BAR */
|
||||
val &= 0xe0; /* 0xe0 acc to RTL DS */
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -1462,7 +1462,7 @@ process_char(escp_t *dev, uint8_t ch)
|
||||
dev->curr_x = dev->left_margin;
|
||||
if (!dev->autofeed)
|
||||
return 1;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -283,7 +283,7 @@ process_char(prnt_t *dev, uint8_t ch)
|
||||
dev->curr_x = 0;
|
||||
if (!dev->autofeed)
|
||||
return 1;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -1709,18 +1709,20 @@ void
|
||||
MainWindow::on_actionRemember_size_and_position_triggered()
|
||||
{
|
||||
window_remember ^= 1;
|
||||
window_w = ui->stackedWidget->width();
|
||||
window_h = ui->stackedWidget->height();
|
||||
if (!QApplication::platformName().contains("wayland")) {
|
||||
window_x = geometry().x();
|
||||
window_y = geometry().y();
|
||||
}
|
||||
for (int i = 1; i < MONITORS_NUM; i++) {
|
||||
if (window_remember && renderers[i]) {
|
||||
monitor_settings[i].mon_window_w = renderers[i]->geometry().width();
|
||||
monitor_settings[i].mon_window_h = renderers[i]->geometry().height();
|
||||
monitor_settings[i].mon_window_x = renderers[i]->geometry().x();
|
||||
monitor_settings[i].mon_window_y = renderers[i]->geometry().y();
|
||||
if (!video_fullscreen) {
|
||||
window_w = ui->stackedWidget->width();
|
||||
window_h = ui->stackedWidget->height();
|
||||
if (!QApplication::platformName().contains("wayland")) {
|
||||
window_x = geometry().x();
|
||||
window_y = geometry().y();
|
||||
}
|
||||
for (int i = 1; i < MONITORS_NUM; i++) {
|
||||
if (window_remember && renderers[i]) {
|
||||
monitor_settings[i].mon_window_w = renderers[i]->geometry().width();
|
||||
monitor_settings[i].mon_window_h = renderers[i]->geometry().height();
|
||||
monitor_settings[i].mon_window_x = renderers[i]->geometry().x();
|
||||
monitor_settings[i].mon_window_y = renderers[i]->geometry().y();
|
||||
}
|
||||
}
|
||||
}
|
||||
ui->actionRemember_size_and_position->setChecked(window_remember);
|
||||
|
||||
@@ -1232,7 +1232,7 @@ BuslogicPCIWrite(UNUSED(int func), int addr, uint8_t val, void *priv)
|
||||
case 0x10:
|
||||
val &= 0xe0;
|
||||
val |= 1;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -1258,7 +1258,7 @@ BuslogicPCIWrite(UNUSED(int func), int addr, uint8_t val, void *priv)
|
||||
|
||||
case 0x14:
|
||||
val &= 0xe0;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -883,7 +883,7 @@ scsi_cdrom_update_request_length(scsi_cdrom_t *dev, int len, int block_len)
|
||||
break;
|
||||
}
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
@@ -961,7 +961,7 @@ scsi_cdrom_command_common(scsi_cdrom_t *dev)
|
||||
scsi_cdrom_log("CD-ROM %i: Seek period: %" PRIu64 " us\n",
|
||||
dev->id, (uint64_t) period);
|
||||
dev->callback += period;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x25:
|
||||
@@ -1940,7 +1940,7 @@ begin:
|
||||
/* IMPORTANT: Convert the command to new read CD
|
||||
for pass through purposes. */
|
||||
dev->current_cdb[0] = GPCMD_READ_CD;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -597,7 +597,7 @@ scsi_disk_command(scsi_common_t *sc, uint8_t *cdb)
|
||||
scsi_disk_invalid_field(dev);
|
||||
return;
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case GPCMD_SCSI_RESERVE:
|
||||
|
||||
@@ -1029,7 +1029,7 @@ esp_reg_write(esp_t *dev, uint32_t saddr, uint32_t val)
|
||||
switch (saddr) {
|
||||
case ESP_TCHI:
|
||||
dev->tchi_written = 1;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case ESP_TCLO:
|
||||
|
||||
@@ -486,7 +486,7 @@ x54x_bios_command(x54x_t *x54x, uint8_t max_id, BIOSCMD *cmd, int8_t islba)
|
||||
|
||||
default:
|
||||
x54x_log("BIOS: Unimplemented command: %02X\n", cmd->command);
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x05: /* Format Track, invalid since SCSI has no tracks */
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
#include <86box/device.h>
|
||||
#include <86box/io.h>
|
||||
#include <86box/snd_ac97.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
|
||||
static const struct {
|
||||
const device_t *device;
|
||||
@@ -417,7 +418,7 @@ rate: /* Writable only if VRA/VRM is set. */
|
||||
/* Get actual previous value. */
|
||||
prev = dev->vendor_reg_pages[(i << 3) | ((reg & 0x0e) >> 1)];
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -30,6 +30,7 @@
|
||||
#include <86box/timer.h>
|
||||
#include <86box/sound.h>
|
||||
#include <86box/snd_ad1848.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
|
||||
#define CS4231 0x80
|
||||
#define CS4236 0x03
|
||||
@@ -241,7 +242,7 @@ ad1848_write(uint16_t addr, uint8_t val, void *priv)
|
||||
case 10:
|
||||
if (ad1848->type < AD1848_TYPE_CS4235)
|
||||
break;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -34,6 +34,7 @@
|
||||
#include <86box/gameport.h>
|
||||
#include <86box/nmi.h>
|
||||
#include <86box/ui.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
enum {
|
||||
@@ -467,7 +468,7 @@ cmi8x38_sb_mixer_write(uint16_t addr, uint8_t val, void *priv)
|
||||
case 0xf8 ... 0xff:
|
||||
if (dev->type == CMEDIA_CMI8338)
|
||||
mixer->regs[mixer->index] = val;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -36,6 +36,7 @@
|
||||
#include <86box/snd_ad1848.h>
|
||||
#include <86box/snd_opl.h>
|
||||
#include <86box/snd_sb.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
#define CRYSTAL_NOEEPROM 0x100
|
||||
@@ -299,7 +300,7 @@ cs423x_write(uint16_t addr, uint8_t val, void *priv)
|
||||
switch (val) {
|
||||
case 0x55: /* Disable PnP Key */
|
||||
dev->pnp_enable = 0;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
#include <86box/sound.h>
|
||||
#include <86box/timer.h>
|
||||
#include <86box/snd_ad1848.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
enum {
|
||||
@@ -626,7 +627,7 @@ writegus(uint16_t addr, uint8_t val, void *priv)
|
||||
else if (gus->irq != -1)
|
||||
picint(1 << gus->irq);
|
||||
}
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x20d:
|
||||
|
||||
@@ -25,6 +25,7 @@
|
||||
#include <86box/sound.h>
|
||||
#include <86box/timer.h>
|
||||
#include <86box/snd_sb.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
#define ADPCM_4 1
|
||||
@@ -600,7 +601,7 @@ sb_exec_command(sb_dsp_t *dsp)
|
||||
case 0x75: /* 4-bit ADPCM output with reference */
|
||||
dsp->sbref = dsp->dma_readb(dsp->dma_priv);
|
||||
dsp->sbstep = 0;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x74: /* 4-bit ADPCM output */
|
||||
|
||||
@@ -536,7 +536,7 @@ ibm8514_accel_out_fifo(svga_t *svga, uint16_t port, uint32_t val, int len)
|
||||
case 0x92e8:
|
||||
if (len != 1)
|
||||
dev->test = val;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0xd2e8:
|
||||
|
||||
@@ -26,6 +26,7 @@
|
||||
#include <86box/timer.h>
|
||||
#include <86box/nvr.h>
|
||||
#include <86box/vid_ati_eeprom.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
|
||||
void
|
||||
ati_eeprom_load(ati_eeprom_t *eeprom, char *fn, int type)
|
||||
@@ -93,7 +94,7 @@ ati_eeprom_write(ati_eeprom_t *eeprom, int ena, int clk, int dat)
|
||||
if (!dat)
|
||||
break;
|
||||
eeprom->state = EEPROM_OPCODE;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case EEPROM_OPCODE:
|
||||
|
||||
@@ -748,7 +748,7 @@ mach64_accel_write_fifo(mach64_t *mach64, uint32_t addr, uint8_t val)
|
||||
case 0x11e:
|
||||
case 0x11f:
|
||||
WRITE8(addr, mach64->dst_height_width, val);
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x113:
|
||||
@@ -973,7 +973,7 @@ mach64_accel_write_fifo(mach64_t *mach64, uint32_t addr, uint8_t val)
|
||||
case 0x2a4:
|
||||
case 0x2a5:
|
||||
addr += 2;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x2aa:
|
||||
@@ -990,7 +990,7 @@ mach64_accel_write_fifo(mach64_t *mach64, uint32_t addr, uint8_t val)
|
||||
case 0x2b0:
|
||||
case 0x2b1:
|
||||
addr += 2;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x2b6:
|
||||
|
||||
@@ -2838,7 +2838,7 @@ mach_accel_out_fifo(mach_t *mach, svga_t *svga, ibm8514_t *dev, uint16_t port, u
|
||||
case 0x92e8:
|
||||
if (len != 1)
|
||||
dev->test = val;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0xd2e8:
|
||||
|
||||
@@ -52,6 +52,7 @@
|
||||
#include <86box/video.h>
|
||||
#include <86box/vid_svga.h>
|
||||
#include <86box/vid_svga_render.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
#define ET4000_TYPE_ISA 1 /* ISA ET4000AX */
|
||||
@@ -432,7 +433,7 @@ et4000_kasan_out(uint16_t addr, uint8_t val, void *priv)
|
||||
case 5:
|
||||
et4000->kasan_cfg_regs[5] = val;
|
||||
et4000->svga.ksc5601_english_font_type = 0x100 | val;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 6:
|
||||
|
||||
@@ -35,6 +35,7 @@
|
||||
#include <86box/video.h>
|
||||
#include <86box/vid_svga.h>
|
||||
#include <86box/vid_svga_render.h>
|
||||
#include <86box/plat_fallthrough.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
typedef struct ht216_t {
|
||||
@@ -320,7 +321,7 @@ ht216_out(uint16_t addr, uint8_t val, void *priv)
|
||||
svga->adv_flags &= ~FLAG_RAMDAC_SHIFT;
|
||||
if (val & 0x04)
|
||||
svga->adv_flags |= FLAG_RAMDAC_SHIFT;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
/*Bank registers*/
|
||||
|
||||
@@ -664,7 +664,7 @@ mystique_out(uint16_t addr, uint8_t val, void *priv)
|
||||
switch (addr) {
|
||||
case 0x3c8:
|
||||
mystique->xreg_idx = val;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
case 0x3c6:
|
||||
|
||||
@@ -39,7 +39,6 @@
|
||||
#include <86box/vid_ddc.h>
|
||||
#include <86box/vid_svga.h>
|
||||
#include <86box/vid_svga_render.h>
|
||||
#include <86box/plat_unused.h>
|
||||
|
||||
static int dither[4][4] = {
|
||||
{0, 4, 1, 5},
|
||||
@@ -4305,7 +4304,7 @@ s3_virge_init(const device_t *info)
|
||||
|
||||
case S3_VIRGE_GX:
|
||||
virge->virge_rev = 0x01;
|
||||
#ifndef __APPLE__
|
||||
#ifdef FALLTHROUGH_ANNOTATION
|
||||
[[fallthrough]];
|
||||
#endif
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -269,8 +269,8 @@ else
|
||||
endif
|
||||
|
||||
ifeq ($(CLANG), y)
|
||||
CPP := ${TOOL_PREFIX}clang++
|
||||
CC := ${TOOL_PREFIX}clang
|
||||
CPP := clang++
|
||||
CC := clang
|
||||
else
|
||||
CPP := ${TOOL_PREFIX}g++
|
||||
CC := ${TOOL_PREFIX}gcc
|
||||
@@ -304,17 +304,38 @@ ifeq ($(DEBUG), y)
|
||||
ifndef COPTIM
|
||||
COPTIM := -Og
|
||||
endif
|
||||
ifndef CXXOPTIM
|
||||
ifeq ($(CLANG), y)
|
||||
CXXOPTIM := -Os
|
||||
else
|
||||
CXXOPTIM := -Og
|
||||
endif
|
||||
endif
|
||||
else
|
||||
DFLAGS += -g0
|
||||
ifeq ($(OPTIM), y)
|
||||
AOPTIM := -mtune=native
|
||||
ifndef COPTIM
|
||||
COPTIM := -O3 -ffp-contract=fast -flto
|
||||
CXXOPTIM := -O3 -ffp-contract=fast -flto
|
||||
endif
|
||||
ifndef CXXOPTIM
|
||||
ifeq ($(CLANG), y)
|
||||
CXXOPTIM := -Os -ffp-contract=fast -flto
|
||||
else
|
||||
CXXOPTIM := -O3 -ffp-contract=fast -flto
|
||||
endif
|
||||
endif
|
||||
else
|
||||
ifndef COPTIM
|
||||
COPTIM := -O3
|
||||
endif
|
||||
ifndef CXXOPTIM
|
||||
ifeq ($(CLANG), y)
|
||||
CXXOPTIM := -Os
|
||||
else
|
||||
CXXOPTIM := -O3
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
ifeq ($(AVX), y)
|
||||
@@ -531,7 +552,9 @@ CFLAGS := $(OPTS) $(DFLAGS) $(COPTIM) $(AOPTIM) \
|
||||
# Add freetyp2 references through pkgconfig
|
||||
CFLAGS := $(CFLAGS) `pkg-config --cflags freetype2`
|
||||
|
||||
CXXFLAGS := $(CFLAGS)
|
||||
CXXFLAGS := $(OPTS) $(DFLAGS) $(CXXOPTIM) $(AOPTIM) \
|
||||
$(AFLAGS) -fomit-frame-pointer -mstackrealign -Wall \
|
||||
-fno-strict-aliasing
|
||||
|
||||
CFLAGS += -Werror=implicit-int -Werror=implicit-function-declaration \
|
||||
-Werror=int-conversion -Werror=strict-prototypes -Werror=old-style-definition
|
||||
@@ -811,13 +834,21 @@ else
|
||||
endif
|
||||
|
||||
ifeq ($(RTMIDI), y)
|
||||
LIBS += -lrtmidi -lwinmm
|
||||
ifeq ($(CLANG), y)
|
||||
LIBS += -lrtmidi.dll -lwinmm
|
||||
else
|
||||
LIBS += -lrtmidi -lwinmm
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(VNC), y)
|
||||
LIBS += $(VNCLIB) -lws2_32
|
||||
endif
|
||||
LIBS += -lpng -lz -lwsock32 -liphlpapi -lpsapi -lhid -lsetupapi -luxtheme -static -lstdc++
|
||||
ifeq ($(CLANG), y)
|
||||
LIBS += -lpng -lz -lwsock32 -liphlpapi -lpsapi -lhid -lsetupapi -luxtheme -static -lstdc++.dll
|
||||
else
|
||||
LIBS += -lpng -lz -lwsock32 -liphlpapi -lpsapi -lhid -lsetupapi -luxtheme -static -lstdc++
|
||||
endif
|
||||
ifneq ($(X64), y)
|
||||
ifneq ($(ARM64), y)
|
||||
LIBS += -Wl,--large-address-aware
|
||||
|
||||
@@ -544,6 +544,10 @@ media_menu_proc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
|
||||
int ret = 0;
|
||||
int wp = 0;
|
||||
|
||||
#ifdef __clang__
|
||||
BROWSEINFO bi;
|
||||
#endif
|
||||
|
||||
id = LOWORD(wParam) & 0x00ff;
|
||||
|
||||
switch (LOWORD(wParam) & 0xff00) {
|
||||
@@ -651,10 +655,15 @@ media_menu_proc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
|
||||
break;
|
||||
|
||||
case IDM_CDROM_DIR:
|
||||
#ifndef __clang__
|
||||
BROWSEINFO bi = {
|
||||
.hwndOwner = hwnd,
|
||||
.ulFlags = BIF_EDITBOX
|
||||
};
|
||||
#else
|
||||
bi.hwndOwner = hwnd;
|
||||
bi.ulFlags = BIF_EDITBOX;
|
||||
#endif
|
||||
OleInitialize(NULL);
|
||||
int old_dopause = dopause;
|
||||
plat_pause(1);
|
||||
|
||||
Reference in New Issue
Block a user