remove deprecated 'NATIVE' AIO mode (#10269)

Co-authored-by: Chris McFarlen <cmcfarlen@apple.com>
diff --git a/CMakeLists.txt b/CMakeLists.txt
index a7ca255..9e3724f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -248,9 +248,6 @@
 set(CMAKE_REQUIRED_LIBRARIES uring)
 check_symbol_exists(io_uring_queue_init "liburing.h" HAVE_IOURING)
 unset(CMAKE_REQUIRED_LIBRARIES)
-set(CMAKE_REQUIRED_LIBRARIES aio)
-check_symbol_exists(io_submit "libaio.h" HAVE_LIBAIO)
-unset(CMAKE_REQUIRED_LIBRARIES)
 check_symbol_exists(getresuid unistd.h HAVE_GETRESUID)
 check_symbol_exists(getresgid unistd.h HAVE_GETRESGID)
 check_symbol_exists(accept4 sys/socket.h HAVE_ACCEPT4)
@@ -262,12 +259,6 @@
     set(TS_USE_LINUX_IO_URING 1)
 endif(HAVE_IOURING AND USE_IOURING)
 
-option(USE_LIBAIO "Use experimental libaio (linux only)" 0)
-if (HAVE_LIBAIO AND USE_LIBAIO)
-    message(Using libaio)
-    set(TS_USE_LINUX_NATIVE_AIO 1)
-endif(HAVE_LIBAIO AND USE_LIBAIO)
-
 # Check ssl functionality
 list(APPEND CMAKE_REQUIRED_INCLUDES ${OPENSSL_INCLUDE_DIR})
 list(APPEND CMAKE_REQUIRED_LIBRARIES
diff --git a/configure.ac b/configure.ac
index 397bc61..e2b5ad7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1645,35 +1645,6 @@
 )
 AC_SUBST(use_posix_cap)
 
-#
-# If the OS is linux, we can use the '--enable-experimental-linux-native-aio' option to
-# replace the aio thread mode. Effective only on the linux system.
-#
-
-AC_MSG_CHECKING([whether to enable Linux native AIO])
-AC_ARG_ENABLE([experimental-linux-native-aio],
-  [AS_HELP_STRING([--enable-experimental-linux-native-aio], [WARNING this is experimental and has known issues enable native Linux AIO support @<:@default=no@:>@])],
-  [enable_linux_native_aio="${enableval}"],
-  [enable_linux_native_aio=no]
-)
-
-AS_IF([test "x$enable_linux_native_aio" = "xyes"], [
-  if test $host_os_def  != "linux"; then
-    AC_MSG_ERROR([Linux native AIO can only be enabled on Linux systems])
-  fi
-
-  AC_CHECK_HEADERS([libaio.h], [],
-    [AC_MSG_ERROR([Linux native AIO requires libaio.h])]
-  )
-
-  AC_SEARCH_LIBS([io_submit], [aio], [],
-    [AC_MSG_ERROR([Linux native AIO requires libaio])]
-  )
-])
-
-AC_MSG_RESULT([$enable_linux_native_aio])
-TS_ARG_ENABLE_VAR([use], [linux_native_aio])
-
 # Check for enabling io_uring on linux
 
 AC_MSG_CHECKING([whether to enable Linux io_uring])
diff --git a/doc/developer-guide/testing/blackbox-testing.en.rst b/doc/developer-guide/testing/blackbox-testing.en.rst
index 5bd7ef7..9d54f47 100644
--- a/doc/developer-guide/testing/blackbox-testing.en.rst
+++ b/doc/developer-guide/testing/blackbox-testing.en.rst
@@ -254,7 +254,6 @@
         - TS_USE_TLS13
         - TS_USE_QUIC
         - TS_HAS_QUICHE
-        - TS_USE_LINUX_NATIVE_AIO
         - TS_HAS_SO_PEERCRED
         - TS_USE_REMOTE_UNWINDING
         - TS_HAS_128BIT_CAS
@@ -267,10 +266,6 @@
 .. code-block:: python
 
   Test.SkipUnless(
-    Condition.HasATSFeature('TS_USE_LINUX_NATIVE_AIO'),
-  )
-
-  Test.SkipUnless(
     Condition.HasCurlFeature('http2'),
   )
 
diff --git a/include/tscore/ink_config.h.cmake.in b/include/tscore/ink_config.h.cmake.in
index 25b74ef..da9f929 100644
--- a/include/tscore/ink_config.h.cmake.in
+++ b/include/tscore/ink_config.h.cmake.in
@@ -136,7 +136,6 @@
 #cmakedefine01 TS_USE_HWLOC
 #cmakedefine01 TS_USE_KQUEUE
 #cmakedefine01 TS_USE_LINUX_IO_URING
-#cmakedefine01 TS_USE_LINUX_NATIVE_AIO
 #cmakedefine01 TS_USE_POSIX_CAP
 #cmakedefine01 TS_USE_QUIC
 #cmakedefine01 TS_USE_REMOTE_UNWINDING
diff --git a/include/tscore/ink_config.h.in b/include/tscore/ink_config.h.in
index 69574cc..f2b74b5 100644
--- a/include/tscore/ink_config.h.in
+++ b/include/tscore/ink_config.h.in
@@ -78,7 +78,6 @@
 #define TS_HAS_QUICHE @has_quiche@
 #define TS_USE_TLS_SET_CIPHERSUITES @use_tls_set_ciphersuites@
 #define TS_HAS_TLS_KEYLOGGING @has_tls_keylogging@
-#define TS_USE_LINUX_NATIVE_AIO @use_linux_native_aio@
 #define TS_USE_LINUX_IO_URING @use_linux_io_uring@
 #define TS_USE_REMOTE_UNWINDING @use_remote_unwinding@
 #define TS_HAS_TLS_EARLY_DATA @has_tls_early_data@
diff --git a/iocore/aio/AIO.cc b/iocore/aio/AIO.cc
index 91a9df7..52d45fe 100644
--- a/iocore/aio/AIO.cc
+++ b/iocore/aio/AIO.cc
@@ -32,15 +32,6 @@
 
 #include "P_AIO.h"
 
-#if AIO_MODE == AIO_MODE_NATIVE
-
-#ifdef HAVE_EVENTFD
-#include <sys/eventfd.h>
-#endif
-
-#define AIO_PERIOD -HRTIME_MSECONDS(10)
-#else
-
 #define MAX_DISKS_POSSIBLE 100
 
 // globals
@@ -51,7 +42,6 @@
 {
 void setup_prep_ops(IOUringContext *);
 }
-
 #endif
 
 /* structure to hold information about each file descriptor */
@@ -64,7 +54,6 @@
 static ink_mutex insert_mutex;
 
 int thread_is_created = 0;
-#endif // AIO_MODE == AIO_MODE_NATIVE
 
 RecInt cache_config_threads_per_disk = 12;
 RecInt api_config_threads_per_disk   = 12;
@@ -189,17 +178,12 @@
   RecRegisterRawStat(aio_rsb, RECT_PROCESS, "proxy.process.io_uring.completed", RECD_FLOAT, RECP_PERSISTENT,
                      (int)AIO_STAT_IO_URING_COMPLETED, aio_stats_cb);
 #endif
-#if AIO_MODE == AIO_MODE_DEFAULT
+
   memset(&aio_reqs, 0, MAX_DISKS_POSSIBLE * sizeof(AIO_Reqs *));
   ink_mutex_init(&insert_mutex);
-#endif
-  REC_ReadConfigInteger(cache_config_threads_per_disk, "proxy.config.cache.threads_per_disk");
-#if TS_USE_LINUX_NATIVE_AIO
-  Warning(
-    "Running with Linux libaio is deprecated. There are known issues with this feature and it is being replaced with io_uring");
-#endif
 
-#if AIO_MODE == AIO_MODE_DEFAULT
+  REC_ReadConfigInteger(cache_config_threads_per_disk, "proxy.config.cache.threads_per_disk");
+
 #if TS_USE_LINUX_IO_URING
   // If the caller specified auto backend, check for config to force a backend
   if (backend == AIOBackend::AIO_BACKEND_AUTO) {
@@ -250,11 +234,8 @@
     Note("Using thread for AIO");
   }
 #endif
-#endif
 }
 
-#if AIO_MODE == AIO_MODE_DEFAULT
-
 struct AIOThreadInfo : public Continuation {
   AIO_Reqs *req;
   int sleep_wait;
@@ -706,162 +687,3 @@
 
   return 1;
 }
-#endif
-
-#if AIO_MODE == AIO_MODE_NATIVE
-int
-DiskHandler::startAIOEvent(int /* event ATS_UNUSED */, Event *e)
-{
-  SET_HANDLER(&DiskHandler::mainAIOEvent);
-  e->schedule_every(AIO_PERIOD);
-  trigger_event = e;
-  return EVENT_CONT;
-}
-
-int
-DiskHandler::mainAIOEvent(int event, Event *e)
-{
-  AIOCallback *op = nullptr;
-Lagain:
-  int ret = io_getevents(ctx, 0, MAX_AIO_EVENTS, events, nullptr);
-  for (int i = 0; i < ret; i++) {
-    op             = (AIOCallback *)events[i].data;
-    op->aio_result = events[i].res;
-    ink_assert(op->action.continuation);
-    complete_list.enqueue(op);
-  }
-
-  if (ret == MAX_AIO_EVENTS) {
-    goto Lagain;
-  }
-
-  if (ret < 0) {
-    if (errno == EINTR)
-      goto Lagain;
-    if (errno == EFAULT || errno == ENOSYS)
-      Dbg(_dbg_ctl_aio, "io_getevents failed: %s (%d)", strerror(-ret), -ret);
-  }
-
-  ink_aiocb *cbs[MAX_AIO_EVENTS];
-  int num = 0;
-
-  for (; num < MAX_AIO_EVENTS && ((op = ready_list.dequeue()) != nullptr); ++num) {
-    cbs[num] = &op->aiocb;
-    ink_assert(op->action.continuation);
-  }
-
-  if (num > 0) {
-    int ret;
-    do {
-      ret = io_submit(ctx, num, cbs);
-    } while (ret < 0 && ret == -EAGAIN);
-
-    if (ret != num) {
-      if (ret < 0) {
-        Dbg(_dbg_ctl_aio, "io_submit failed: %s (%d)", strerror(-ret), -ret);
-      } else {
-        Fatal("could not submit IOs, io_submit(%p, %d, %p) returned %d", ctx, num, cbs, ret);
-      }
-    }
-  }
-
-  while ((op = complete_list.dequeue()) != nullptr) {
-    op->mutex = op->action.mutex;
-    MUTEX_TRY_LOCK(lock, op->mutex, trigger_event->ethread);
-    if (!lock.is_locked()) {
-      trigger_event->ethread->schedule_imm(op);
-    } else {
-      op->handleEvent(EVENT_NONE, nullptr);
-    }
-  }
-  return EVENT_CONT;
-}
-
-int
-ink_aio_read(AIOCallback *op, int /* fromAPI ATS_UNUSED */)
-{
-  op->aiocb.aio_lio_opcode = IO_CMD_PREAD;
-  op->aiocb.data           = op;
-  EThread *t               = this_ethread();
-#ifdef HAVE_EVENTFD
-  io_set_eventfd(&op->aiocb, t->evfd);
-#endif
-  t->diskHandler->ready_list.enqueue(op);
-
-  return 1;
-}
-
-int
-ink_aio_write(AIOCallback *op, int /* fromAPI ATS_UNUSED */)
-{
-  op->aiocb.aio_lio_opcode = IO_CMD_PWRITE;
-  op->aiocb.data           = op;
-  EThread *t               = this_ethread();
-#ifdef HAVE_EVENTFD
-  io_set_eventfd(&op->aiocb, t->evfd);
-#endif
-  t->diskHandler->ready_list.enqueue(op);
-
-  return 1;
-}
-
-int
-ink_aio_readv(AIOCallback *op, int /* fromAPI ATS_UNUSED */)
-{
-  EThread *t      = this_ethread();
-  DiskHandler *dh = t->diskHandler;
-  AIOCallback *io = op;
-  int sz          = 0;
-
-  while (io) {
-    io->aiocb.aio_lio_opcode = IO_CMD_PREAD;
-    io->aiocb.data           = io;
-#ifdef HAVE_EVENTFD
-    io_set_eventfd(&op->aiocb, t->evfd);
-#endif
-    dh->ready_list.enqueue(io);
-    ++sz;
-    io = io->then;
-  }
-
-  if (sz > 1) {
-    ink_assert(op->action.continuation);
-    AIOVec *vec = new AIOVec(sz, op);
-    while (--sz >= 0) {
-      op->action = vec;
-      op         = op->then;
-    }
-  }
-  return 1;
-}
-
-int
-ink_aio_writev(AIOCallback *op, int /* fromAPI ATS_UNUSED */)
-{
-  EThread *t      = this_ethread();
-  DiskHandler *dh = t->diskHandler;
-  AIOCallback *io = op;
-  int sz          = 0;
-
-  while (io) {
-    io->aiocb.aio_lio_opcode = IO_CMD_PWRITE;
-    io->aiocb.data           = io;
-#ifdef HAVE_EVENTFD
-    io_set_eventfd(&op->aiocb, t->evfd);
-#endif
-    dh->ready_list.enqueue(io);
-    ++sz;
-    io = io->then;
-  }
-
-  if (sz > 1) {
-    ink_assert(op->action.continuation);
-    AIOVec *vec = new AIOVec(sz, op);
-    while (--sz >= 0) {
-      op->action = vec;
-      op         = op->then;
-    }
-  }
-  return 1;
-}
-#endif // AIO_MODE != AIO_MODE_NATIVE
diff --git a/iocore/aio/I_AIO.h b/iocore/aio/I_AIO.h
index 917909d..47dc35c 100644
--- a/iocore/aio/I_AIO.h
+++ b/iocore/aio/I_AIO.h
@@ -38,15 +38,6 @@
 
 #define AIO_EVENT_DONE (AIO_EVENT_EVENTS_START + 0)
 
-#define AIO_MODE_DEFAULT 0
-#define AIO_MODE_NATIVE  1
-
-#if TS_USE_LINUX_NATIVE_AIO
-#define AIO_MODE AIO_MODE_NATIVE
-#else
-#define AIO_MODE AIO_MODE_DEFAULT
-#endif
-
 #define LIO_READ  0x1
 #define LIO_WRITE 0x2
 
@@ -56,22 +47,6 @@
   AIO_BACKEND_IO_URING = 2,
 };
 
-#if AIO_MODE == AIO_MODE_NATIVE
-
-#include <libaio.h>
-
-#define MAX_AIO_EVENTS 1024
-
-using ink_aiocb      = struct iocb;
-using ink_io_event_t = struct io_event;
-
-// XXX hokey old-school compatibility with ink_aiocb.h ...
-#define aio_nbytes u.c.nbytes
-#define aio_offset u.c.offset
-#define aio_buf    u.c.buf
-
-#else
-
 struct ink_aiocb {
   int aio_fildes    = -1;      /* file descriptor or status: AIO_NOT_IN_PROGRESS */
   void *aio_buf     = nullptr; /* buffer location */
@@ -83,7 +58,6 @@
 };
 
 bool ink_aio_thread_num_set(int thread_num);
-#endif
 
 // AIOCallback::thread special values
 #define AIO_CALLBACK_THREAD_ANY ((EThread *)0) // any regular event thread
@@ -102,49 +76,6 @@
   AIOCallback() {}
 };
 
-#if AIO_MODE == AIO_MODE_NATIVE
-
-struct AIOVec : public Continuation {
-  Action action;
-  int size;
-  int completed;
-  AIOCallback *first;
-
-  AIOVec(int sz, AIOCallback *c) : Continuation(new_ProxyMutex()), size(sz), completed(0), first(c)
-  {
-    action = c->action;
-    SET_HANDLER(&AIOVec::mainEvent);
-  }
-
-  int mainEvent(int event, Event *e);
-};
-
-struct DiskHandler : public Continuation {
-  Event *trigger_event;
-  io_context_t ctx;
-  ink_io_event_t events[MAX_AIO_EVENTS];
-  Que(AIOCallback, link) ready_list;
-  Que(AIOCallback, link) complete_list;
-  int startAIOEvent(int event, Event *e);
-  int mainAIOEvent(int event, Event *e);
-  DiskHandler()
-  {
-    SET_HANDLER(&DiskHandler::startAIOEvent);
-    memset(&ctx, 0, sizeof(ctx));
-    int ret = io_setup(MAX_AIO_EVENTS, &ctx);
-    if (ret < 0) {
-      Dbg(_dbg_ctl_aio, "io_setup error: %s (%d)", strerror(-ret), -ret);
-    }
-  }
-
-private:
-  inline static DbgCtl _dbg_ctl_aio{"aio"};
-};
-int ink_aio_readv(AIOCallback *op,
-                  int fromAPI = 0); // fromAPI is a boolean to indicate if this is from an API call such as upload proxy feature
-int ink_aio_writev(AIOCallback *op, int fromAPI = 0);
-#endif
-
 void ink_aio_init(ts::ModuleVersion version, AIOBackend backend = AIO_BACKEND_AUTO);
 void ink_aio_set_callback(Continuation *error_callback);
 
diff --git a/iocore/aio/P_AIO.h b/iocore/aio/P_AIO.h
index 41e2eb1..a6ff603 100644
--- a/iocore/aio/P_AIO.h
+++ b/iocore/aio/P_AIO.h
@@ -50,37 +50,6 @@
 
 extern Continuation *aio_err_callbck;
 
-#if AIO_MODE == AIO_MODE_NATIVE
-
-struct AIOCallbackInternal : public AIOCallback {
-  int io_complete(int event, void *data);
-  AIOCallbackInternal()
-  {
-    memset((void *)&(this->aiocb), 0, sizeof(this->aiocb));
-    this->aiocb.aio_fildes = -1;
-    SET_HANDLER(&AIOCallbackInternal::io_complete);
-  }
-};
-
-TS_INLINE int
-AIOVec::mainEvent(int /* event */, Event *)
-{
-  ++completed;
-  if (completed < size)
-    return EVENT_CONT;
-  else if (completed == size) {
-    SCOPED_MUTEX_LOCK(lock, action.mutex, this_ethread());
-    if (!action.cancelled)
-      action.continuation->handleEvent(AIO_EVENT_DONE, first);
-    delete this;
-    return EVENT_DONE;
-  }
-  ink_assert(!"AIOVec mainEvent err");
-  return EVENT_ERROR;
-}
-
-#else /* AIO_MODE != AIO_MODE_NATIVE */
-
 struct AIO_Reqs;
 
 #if TS_USE_LINUX_IO_URING
@@ -118,8 +87,6 @@
   int requests_queued = 0;
 };
 
-#endif // AIO_MODE == AIO_MODE_NATIVE
-
 TS_INLINE int
 AIOCallbackInternal::io_complete(int event, void *data)
 {
diff --git a/iocore/aio/test_AIO.cc b/iocore/aio/test_AIO.cc
index 9d7ba00..8742b58 100644
--- a/iocore/aio/test_AIO.cc
+++ b/iocore/aio/test_AIO.cc
@@ -496,12 +496,6 @@
   Thread *main_thread = new EThread;
   main_thread->set_specific();
 
-#if AIO_MODE == AIO_MODE_NATIVE
-  for (EThread *et : eventProcessor.active_group_threads(ET_NET)) {
-    et->diskHandler = new DiskHandler();
-    et->schedule_imm(et->diskHandler);
-  }
-#endif
 #if TS_USE_LINUX_IO_URING
   if (!io_uring_force_thread) {
     for (EThread *et : eventProcessor.active_group_threads(ET_NET)) {
diff --git a/iocore/cache/Cache.cc b/iocore/cache/Cache.cc
index 6607147..18911d9 100644
--- a/iocore/cache/Cache.cc
+++ b/iocore/cache/Cache.cc
@@ -153,55 +153,6 @@
   }
 };
 
-#if AIO_MODE == AIO_MODE_NATIVE
-struct VolInit : public Continuation {
-  Vol *vol;
-  char *path;
-  off_t blocks;
-  int64_t offset;
-  bool vol_clear;
-
-  int
-  mainEvent(int /* event ATS_UNUSED */, Event * /* e ATS_UNUSED */)
-  {
-    vol->init(path, blocks, offset, vol_clear);
-    mutex.clear();
-    delete this;
-    return EVENT_DONE;
-  }
-
-  VolInit(Vol *v, char *p, off_t b, int64_t o, bool c) : Continuation(v->mutex), vol(v), path(p), blocks(b), offset(o), vol_clear(c)
-  {
-    SET_HANDLER(&VolInit::mainEvent);
-  }
-};
-
-struct DiskInit : public Continuation {
-  CacheDisk *disk;
-  char *s;
-  off_t blocks;
-  off_t askip;
-  int ahw_sector_size;
-  int fildes;
-  bool clear;
-
-  int
-  mainEvent(int /* event ATS_UNUSED */, Event * /* e ATS_UNUSED */)
-  {
-    disk->open(s, blocks, askip, ahw_sector_size, fildes, clear);
-    ats_free(s);
-    mutex.clear();
-    delete this;
-    return EVENT_DONE;
-  }
-
-  DiskInit(CacheDisk *d, char *str, off_t b, off_t skip, int sector, int f, bool c)
-    : Continuation(d->mutex), disk(d), s(ats_strdup(str)), blocks(b), askip(skip), ahw_sector_size(sector), fildes(f), clear(c)
-  {
-    SET_HANDLER(&DiskInit::mainEvent);
-  }
-};
-#endif
 void cplist_init();
 static void cplist_update();
 int cplist_reconfigure();
@@ -596,12 +547,6 @@
   ink_assert((int)TS_EVENT_CACHE_SCAN_OPERATION_BLOCKED == (int)CACHE_EVENT_SCAN_OPERATION_BLOCKED);
   ink_assert((int)TS_EVENT_CACHE_SCAN_OPERATION_FAILED == (int)CACHE_EVENT_SCAN_OPERATION_FAILED);
   ink_assert((int)TS_EVENT_CACHE_SCAN_DONE == (int)CACHE_EVENT_SCAN_DONE);
-#if AIO_MODE == AIO_MODE_NATIVE
-  for (EThread *et : eventProcessor.active_group_threads(ET_NET)) {
-    et->diskHandler = new DiskHandler();
-    et->schedule_imm(et->diskHandler);
-  }
-#endif
   start_internal_flags = flags;
   clear                = !!(flags & PROCESSOR_RECONFIGURE) || auto_clear_flag;
   fix                  = !!(flags & PROCESSOR_FIX);
@@ -757,11 +702,7 @@
     ink_release_assert(sds[j] != nullptr); // Defeat clang-analyzer
     off_t skip     = ROUND_TO_STORE_BLOCK((sd->offset < START_POS ? START_POS + sd->alignment : sd->offset));
     int64_t blocks = sd->blocks - (skip >> STORE_BLOCK_SHIFT);
-#if AIO_MODE == AIO_MODE_NATIVE
-    eventProcessor.schedule_imm(new DiskInit(gdisks[j], paths[j], blocks, skip, sector_sizes[j], fds[j], clear));
-#else
     gdisks[j]->open(paths[j], blocks, skip, sector_sizes[j], fds[j], clear);
-#endif
 
     Dbg(dbg_ctl_cache_hosting, "Disk: %d:%s, blocks: %" PRId64 "", gndisks, paths[j], blocks);
   }
@@ -1310,11 +1251,7 @@
     aio->thread           = AIO_CALLBACK_THREAD_ANY;
     aio->then             = (i < 3) ? &(init_info->vol_aio[i + 1]) : nullptr;
   }
-#if AIO_MODE == AIO_MODE_NATIVE
-  ink_assert(ink_aio_readv(init_info->vol_aio));
-#else
   ink_assert(ink_aio_read(init_info->vol_aio));
-#endif
   return 0;
 }
 
@@ -1672,11 +1609,7 @@
   init_info->vol_aio[2].aiocb.aio_offset = ss + dirlen - footerlen;
 
   SET_HANDLER(&Vol::handle_recover_write_dir);
-#if AIO_MODE == AIO_MODE_NATIVE
-  ink_assert(ink_aio_writev(init_info->vol_aio));
-#else
   ink_assert(ink_aio_write(init_info->vol_aio));
-#endif
   return EVENT_CONT;
 }
 
@@ -2098,11 +2031,7 @@
             blocks                      = q->b->len;
 
             bool vol_clear = clear || d->cleared || q->new_block;
-#if AIO_MODE == AIO_MODE_NATIVE
-            eventProcessor.schedule_imm(new VolInit(cp->vols[vol_no], d->path, blocks, q->b->offset, vol_clear));
-#else
             cp->vols[vol_no]->init(d->path, blocks, q->b->offset, vol_clear);
-#endif
             vol_no++;
             cache_size += blocks;
           }
diff --git a/src/traffic_layout/info.cc b/src/traffic_layout/info.cc
index 687291a..54db8c4 100644
--- a/src/traffic_layout/info.cc
+++ b/src/traffic_layout/info.cc
@@ -109,7 +109,6 @@
   print_feature("TS_USE_TLS13", TS_USE_TLS13, json);
   print_feature("TS_USE_QUIC", TS_USE_QUIC, json);
   print_feature("TS_HAS_QUICHE", TS_HAS_QUICHE, json);
-  print_feature("TS_USE_LINUX_NATIVE_AIO", TS_USE_LINUX_NATIVE_AIO, json);
   print_feature("TS_HAS_SO_PEERCRED", TS_HAS_SO_PEERCRED, json);
   print_feature("TS_USE_REMOTE_UNWINDING", TS_USE_REMOTE_UNWINDING, json);
   print_feature("SIZEOF_VOIDP", SIZEOF_VOIDP, json);
diff --git a/src/traffic_server/CMakeLists.txt b/src/traffic_server/CMakeLists.txt
index 7dc6100..c053d72 100644
--- a/src/traffic_server/CMakeLists.txt
+++ b/src/traffic_server/CMakeLists.txt
@@ -84,9 +84,6 @@
 if (TS_USE_LINUX_IO_URING)
     target_link_libraries(traffic_server PRIVATE inkuring uring)
 endif (TS_USE_LINUX_IO_URING)
-if (TS_USE_LINUX_NATIVE_AIO)
-    target_link_libraries(traffic_server PRIVATE aio)
-endif (TS_USE_LINUX_NATIVE_AIO)
 
 set_target_properties(traffic_server PROPERTIES ENABLE_EXPORTS ON)
 
diff --git a/src/traffic_server/InkAPI.cc b/src/traffic_server/InkAPI.cc
index a8830cc..af9345a 100644
--- a/src/traffic_server/InkAPI.cc
+++ b/src/traffic_server/InkAPI.cc
@@ -8147,16 +8147,11 @@
 TSReturnCode
 tsapi::c::TSAIOThreadNumSet(int thread_num)
 {
-#if AIO_MODE == AIO_MODE_NATIVE || AIO_MODE == AIO_MODE_IO_URING
-  (void)thread_num;
-  return TS_SUCCESS;
-#else
   if (ink_aio_thread_num_set(thread_num)) {
     return TS_SUCCESS;
   }
 
   return TS_ERROR;
-#endif
 }
 
 void
@@ -10054,9 +10049,9 @@
   sdk_assert(sdk_sanity_check_null_ptr(yaml_version) == TS_SUCCESS);
   sdk_assert(sdk_sanity_check_null_ptr(provider_name) == TS_SUCCESS);
 
-  // We want to make sure that plugins are using the same yaml library version as we use internally. Plugins have to cast the TSYaml
-  // to the YAML::Node, in order for them to make sure the version compatibility they need to register here and make sure the
-  // version is the same.
+  // We want to make sure that plugins are using the same yaml library version as we use internally. Plugins have to cast the
+  // TSYaml to the YAML::Node, in order for them to make sure the version compatibility they need to register here and make sure
+  // the version is the same.
   if (std::string_view{yaml_version, yamlcpp_lib_len} != YAMLCPP_LIB_VERSION) {
     return nullptr;
   }
diff --git a/tests/README.md b/tests/README.md
index 3f732b8..90b8532 100644
--- a/tests/README.md
+++ b/tests/README.md
@@ -349,21 +349,12 @@
  * TS_USE_TLS13
  * TS_USE_QUIC
  * TS_HAS_QUICHE
- * TS_USE_LINUX_NATIVE_AIO
  * TS_HAS_SO_PEERCRED
  * TS_USE_REMOTE_UNWINDING
  * TS_HAS_128BIT_CAS
  * TS_HAS_TESTS
  * TS_HAS_WCCP
 
-### Example
-```python
-#create the origin server process
-Test.SkipUnless(
-    Condition.HasATSFeature('TS_USE_LINUX_NATIVE_AIO'),
-)
-```
-
 ### Condition.HasCurlFeature(feature)
  * feature - The feature to test for