Remove function attributes (used/saveds)

lide doesn't use fbaserel and the used attribute is not needed
This commit is contained in:
Matt Harlum 2025-07-05 03:28:11 +00:00
parent 7a3fbbd49f
commit 83f74a8cb1
4 changed files with 13 additions and 13 deletions

View File

@ -11,7 +11,7 @@ export BUILD_DATE
export GIT_REF
CC=m68k-amigaos-gcc
CFLAGS+=-nostartfiles -nostdlib -mcpu=68000 -Wall -Wno-multichar -Wno-pointer-sign -Wno-attributes -Wno-unused-value -s -Os -fomit-frame-pointer -DCDBOOT=1 -DNO_RDBLAST=1
CFLAGS+=-nostartfiles -nostdlib -mcpu=68000 -Wall -Wno-multichar -Wno-pointer-sign -Wno-unused-value -s -Os -fomit-frame-pointer -DCDBOOT=1 -DNO_RDBLAST=1
CFLAGS+=-DGIT_REF=$(GIT_REF) -DBUILD_DATE=$(BUILD_DATE)
LDFLAGS=-lgcc -lc
AS=m68k-amigaos-as
@ -71,7 +71,7 @@ OBJ = device.o \
scsi.o \
idetask.o \
lide_alib.o \
mounter.o \
mounter/mounter.o \
debug.o
ASMOBJ = endskip.o

4
ata.c
View File

@ -34,7 +34,7 @@ static BYTE write_taskfile_chs(struct IDEUnit *unit, UBYTE command, ULONG lba, U
*
* @param unit Pointer to an IDEUnit struct
*/
static void __attribute__((always_inline)) ata_status_reg_delay(struct IDEUnit *unit) {
static void ata_status_reg_delay(struct IDEUnit *unit) {
asm volatile (
".rep 4 \n\t"
"tst.l (%0) \n\t" // Use tst.l so we don't need to save/restore some other register
@ -68,7 +68,7 @@ static void ata_save_error(struct IDEUnit *unit) {
* @param unit Pointer to an IDEUnit struct
* @returns True if error is indicated
*/
static bool __attribute__((always_inline)) ata_check_error(struct IDEUnit *unit) {
static bool ata_check_error(struct IDEUnit *unit) {
return (*unit->drive.status_command & (ata_flag_error | ata_flag_df));
}

View File

@ -31,7 +31,7 @@
*
* @param unit Pointer to an IDEUnit struct
*/
static void __attribute__((always_inline)) atapi_status_reg_delay() {
static void atapi_status_reg_delay() {
asm volatile (
"tst.b 0xBFE001"
);
@ -158,7 +158,7 @@ static bool atapi_check_ir(struct IDEUnit *unit, UBYTE mask, UBYTE value, UWORD
* @param unit Pointer to an IDEUnit struct
* @returns True if error is indicated
*/
static bool __attribute__((always_inline)) atapi_check_error(struct IDEUnit *unit) {
static bool atapi_check_error(struct IDEUnit *unit) {
atapi_status_reg_delay();
return (*unit->drive.status_command & (ata_flag_error | ata_flag_df));
}

View File

@ -339,7 +339,7 @@ static BYTE detectChannels(struct ConfigDev *cd) {
*
* Scan for drives and initialize the driver if any are found
*/
struct Library __attribute__((used, saveds)) * init_device(struct ExecBase *SysBase asm("a6"), BPTR seg_list asm("a0"), struct DeviceBase *dev asm("d0"))
struct Library * init_device(struct ExecBase *SysBase asm("a6"), BPTR seg_list asm("a0"), struct DeviceBase *dev asm("d0"))
{
dev->SysBase = SysBase;
Trace("Init dev, base: %08lx\n",dev);
@ -495,7 +495,7 @@ struct Library __attribute__((used, saveds)) * init_device(struct ExecBase *SysB
* IMPORTANT: because Expunge is called from the memory allocator,
* it may NEVER Wait() or otherwise take long time to complete.
*/
static BPTR __attribute__((used, saveds)) expunge(struct DeviceBase *dev asm("a6"))
static BPTR expunge(struct DeviceBase *dev asm("a6"))
{
Trace((CONST_STRPTR) "running expunge()\n");
@ -516,7 +516,7 @@ static BPTR __attribute__((used, saveds)) expunge(struct DeviceBase *dev asm("a6
* This call is guaranteed to be single-threaded; only one task
* will execute your Open at a time.
*/
static void __attribute__((used, saveds)) open(struct DeviceBase *dev asm("a6"), struct IORequest *ioreq asm("a1"), ULONG unitnum asm("d0"), ULONG flags asm("d1"))
static void open(struct DeviceBase *dev asm("a6"), struct IORequest *ioreq asm("a1"), ULONG unitnum asm("d0"), ULONG flags asm("d1"))
{
struct ExecBase *SysBase = dev->SysBase;
struct IDEUnit *unit = NULL;
@ -635,7 +635,7 @@ static void td_get_geometry(struct IOStdReq *ioreq) {
* This call is guaranteed to be single-threaded; only one task
* will execute your Close at a time.
*/
static BPTR __attribute__((used, saveds)) close(struct DeviceBase *dev asm("a6"), struct IORequest *ioreq asm("a1"))
static BPTR close(struct DeviceBase *dev asm("a6"), struct IORequest *ioreq asm("a1"))
{
if (ioreq_is_valid(dev,ioreq)) {
struct IDEUnit *unit = (struct IDEUnit *)ioreq->io_Unit;
@ -696,7 +696,7 @@ const UWORD supported_commands[] =
*
* Handle immediate requests and send any others to ide_task
*/
static void __attribute__((used, saveds)) begin_io(struct DeviceBase *dev asm("a6"), struct IOStdReq *ioreq asm("a1"))
static void begin_io(struct DeviceBase *dev asm("a6"), struct IOStdReq *ioreq asm("a1"))
{
struct ExecBase *SysBase = dev->SysBase;
@ -879,7 +879,7 @@ sendToTask:
*
* Abort io request
*/
static ULONG __attribute__((used, saveds)) abort_io(struct DeviceBase *dev asm("a6"), struct IOStdReq *ioreq asm("a1"))
static ULONG abort_io(struct DeviceBase *dev asm("a6"), struct IOStdReq *ioreq asm("a1"))
{
struct ExecBase *SysBase = dev->SysBase;
@ -1002,7 +1002,7 @@ void TweakBootList(struct ExecBase *SysBase) {
*
* Create the device and add it to the system if init_device succeeds
*/
static struct Library __attribute__((used)) * init(BPTR seg_list asm("a0"))
static struct Library * init(BPTR seg_list asm("a0"))
{
struct ExecBase *SysBase = *(struct ExecBase **)4UL;
Info("Init driver.\n");