Next round of sonarlint cleanups

This commit is contained in:
Jasmine Iwanek
2023-06-26 12:47:04 -04:00
parent 2fe3bcd5d2
commit 21adfd4d50
176 changed files with 2791 additions and 1377 deletions

View File

@@ -25,6 +25,7 @@
#include <86box/device.h>
#include <86box/io.h>
#include <86box/hwm.h>
#include <86box/plat_unused.h>
#define CLAMP(a, min, max) (((a) < (min)) ? (min) : (((a) > (max)) ? (max) : (a)))
/* Formulas and factors derived from Linux's via686a.c driver. */
@@ -113,6 +114,8 @@ vt82c686_write(uint16_t port, uint8_t val, void *priv)
case 0x48:
val &= 0x7f;
break;
default:
break;
}
dev->regs[reg] = val;
@@ -143,6 +146,9 @@ vt82c686_hwm_write(uint8_t addr, uint8_t val, void *priv)
case 0x74:
dev->enable = val & 0x01;
break;
default:
break;
}
if (dev->enable && dev->io_base)
@@ -174,7 +180,7 @@ vt82c686_close(void *priv)
}
static void *
vt82c686_init(const device_t *info)
vt82c686_init(UNUSED(const device_t *info))
{
vt82c686_t *dev = (vt82c686_t *) malloc(sizeof(vt82c686_t));
memset(dev, 0, sizeof(vt82c686_t));