diff --git a/src/sdeventplus/internal/sdevent.cpp b/src/sdeventplus/internal/sdevent.cpp
index b5e4542..6d8cde9 100644
--- a/src/sdeventplus/internal/sdevent.cpp
+++ b/src/sdeventplus/internal/sdevent.cpp
@@ -191,17 +191,6 @@
     return ::sd_event_source_set_io_fd(source, fd);
 }
 
-int SdEventImpl::sd_event_source_get_io_fd_own(sd_event_source* source) const
-{
-    return ::sd_event_source_get_io_fd_own(source);
-}
-
-int SdEventImpl::sd_event_source_set_io_fd_own(sd_event_source* source,
-                                               int own) const
-{
-    return ::sd_event_source_set_io_fd_own(source, own);
-}
-
 int SdEventImpl::sd_event_source_get_io_events(sd_event_source* source,
                                                uint32_t* events) const
 {
diff --git a/src/sdeventplus/internal/sdevent.hpp b/src/sdeventplus/internal/sdevent.hpp
index 3151981..80a321c 100644
--- a/src/sdeventplus/internal/sdevent.hpp
+++ b/src/sdeventplus/internal/sdevent.hpp
@@ -85,10 +85,6 @@
     virtual int sd_event_source_get_io_fd(sd_event_source* source) const = 0;
     virtual int sd_event_source_set_io_fd(sd_event_source* source,
                                           int fd) const = 0;
-    virtual int
-        sd_event_source_get_io_fd_own(sd_event_source* source) const = 0;
-    virtual int sd_event_source_set_io_fd_own(sd_event_source* source,
-                                              int own) const = 0;
     virtual int sd_event_source_get_io_events(sd_event_source* source,
                                               uint32_t* events) const = 0;
     virtual int sd_event_source_set_io_events(sd_event_source* source,
@@ -189,9 +185,6 @@
     int sd_event_source_get_io_fd(sd_event_source* source) const override;
     int sd_event_source_set_io_fd(sd_event_source* source,
                                   int fd) const override;
-    int sd_event_source_get_io_fd_own(sd_event_source* source) const override;
-    int sd_event_source_set_io_fd_own(sd_event_source* source,
-                                      int own) const override;
     int sd_event_source_get_io_events(sd_event_source* source,
                                       uint32_t* events) const override;
     int sd_event_source_set_io_events(sd_event_source* source,
diff --git a/src/sdeventplus/source/io.cpp b/src/sdeventplus/source/io.cpp
index 2955a7d..a325f91 100644
--- a/src/sdeventplus/source/io.cpp
+++ b/src/sdeventplus/source/io.cpp
@@ -32,26 +32,6 @@
     }
 }
 
-bool IO::get_fd_own() const
-{
-    int r = event.getSdEvent()->sd_event_source_get_io_fd_own(source.get());
-    if (r < 0)
-    {
-        throw SdEventError(-r, "sd_event_source_get_io_fd_own");
-    }
-    return r;
-}
-
-void IO::set_fd_own(bool own) const
-{
-    int r =
-        event.getSdEvent()->sd_event_source_set_io_fd_own(source.get(), own);
-    if (r < 0)
-    {
-        throw SdEventError(-r, "sd_event_source_set_io_fd_own");
-    }
-}
-
 uint32_t IO::get_events() const
 {
     uint32_t events;
diff --git a/src/sdeventplus/source/io.hpp b/src/sdeventplus/source/io.hpp
index f8547ec..030f75e 100644
--- a/src/sdeventplus/source/io.hpp
+++ b/src/sdeventplus/source/io.hpp
@@ -19,8 +19,6 @@
 
     int get_fd() const;
     void set_fd(int fd) const;
-    bool get_fd_own() const;
-    void set_fd_own(bool own) const;
     uint32_t get_events() const;
     void set_events(uint32_t events) const;
     uint32_t get_revents() const;
diff --git a/src/sdeventplus/test/sdevent.hpp b/src/sdeventplus/test/sdevent.hpp
index 1d87174..5079a99 100644
--- a/src/sdeventplus/test/sdevent.hpp
+++ b/src/sdeventplus/test/sdevent.hpp
@@ -72,9 +72,6 @@
     MOCK_CONST_METHOD2(sd_event_source_set_enabled, int(sd_event_source*, int));
     MOCK_CONST_METHOD1(sd_event_source_get_io_fd, int(sd_event_source*));
     MOCK_CONST_METHOD2(sd_event_source_set_io_fd, int(sd_event_source*, int));
-    MOCK_CONST_METHOD1(sd_event_source_get_io_fd_own, int(sd_event_source*));
-    MOCK_CONST_METHOD2(sd_event_source_set_io_fd_own,
-                       int(sd_event_source*, int));
     MOCK_CONST_METHOD2(sd_event_source_get_io_events,
                        int(sd_event_source*, uint32_t*));
     MOCK_CONST_METHOD2(sd_event_source_set_io_events,
diff --git a/test/source/io.cpp b/test/source/io.cpp
index e3b5921..b680be7 100644
--- a/test/source/io.cpp
+++ b/test/source/io.cpp
@@ -172,37 +172,6 @@
     EXPECT_THROW(io->set_fd(fd), SdEventError);
 }
 
-TEST_F(IOMethodTest, GetFdOwnSuccess)
-{
-    EXPECT_CALL(mock, sd_event_source_get_io_fd_own(expected_source))
-        .WillOnce(Return(3));
-    EXPECT_TRUE(io->get_fd_own());
-    EXPECT_CALL(mock, sd_event_source_get_io_fd_own(expected_source))
-        .WillOnce(Return(0));
-    EXPECT_FALSE(io->get_fd_own());
-}
-
-TEST_F(IOMethodTest, GetFdOwnError)
-{
-    EXPECT_CALL(mock, sd_event_source_get_io_fd_own(expected_source))
-        .WillOnce(Return(-EINVAL));
-    EXPECT_THROW(io->get_fd_own(), SdEventError);
-}
-
-TEST_F(IOMethodTest, SetFdOwnSuccess)
-{
-    EXPECT_CALL(mock, sd_event_source_set_io_fd_own(expected_source, true))
-        .WillOnce(Return(0));
-    io->set_fd_own(true);
-}
-
-TEST_F(IOMethodTest, SetFdOwnError)
-{
-    EXPECT_CALL(mock, sd_event_source_set_io_fd_own(expected_source, false))
-        .WillOnce(Return(-EINVAL));
-    EXPECT_THROW(io->set_fd_own(false), SdEventError);
-}
-
 TEST_F(IOMethodTest, GetEventsSuccess)
 {
     const uint32_t events = EPOLLIN | EPOLLOUT;
