diff --git a/src/sdeventplus/internal/utils.hpp b/src/sdeventplus/internal/utils.hpp
index c0b0e68..17e8cee 100644
--- a/src/sdeventplus/internal/utils.hpp
+++ b/src/sdeventplus/internal/utils.hpp
@@ -19,7 +19,7 @@
 
 // Helpers for sd_event callbacks to handle exceptions gracefully
 template <typename Func, typename... Args>
-static int performCallback(Func func, Args... args)
+static int performCallback(const char* name, Func func, Args... args)
 {
     try
     {
@@ -28,17 +28,17 @@
     }
     catch (const std::system_error& e)
     {
-        fprintf(stderr, "sdeventplus: callback: %s\n", e.what());
+        fprintf(stderr, "sdeventplus: %s: %s\n", name, e.what());
         return -e.code().value();
     }
     catch (const std::exception& e)
     {
-        fprintf(stderr, "sdeventplus: callback: %s\n", e.what());
+        fprintf(stderr, "sdeventplus: %s: %s\n", name, e.what());
         return -ENOSYS;
     }
     catch (...)
     {
-        fprintf(stderr, "sdeventplus: callback: Unknown error\n");
+        fprintf(stderr, "sdeventplus: %s: Unknown error\n", name);
         return -ENOSYS;
     }
 }
diff --git a/src/sdeventplus/source/base.cpp b/src/sdeventplus/source/base.cpp
index 5f202db..32e6edf 100644
--- a/src/sdeventplus/source/base.cpp
+++ b/src/sdeventplus/source/base.cpp
@@ -61,7 +61,8 @@
         return -EINVAL;
     }
     Base* base = reinterpret_cast<Base*>(userdata);
-    return internal::performCallback(base->get_prepare(), std::ref(*base));
+    return internal::performCallback("prepare_callback", base->get_prepare(),
+                                     std::ref(*base));
 }
 
 void Base::set_prepare(Callback&& callback)
diff --git a/test/internal/utils.cpp b/test/internal/utils.cpp
index 2a347ca..403964c 100644
--- a/test/internal/utils.cpp
+++ b/test/internal/utils.cpp
@@ -12,25 +12,27 @@
 
 TEST(UtilsTest, PerformCallbackSuccess)
 {
-    EXPECT_EQ(0, performCallback([]() {}));
+    EXPECT_EQ(0, performCallback(nullptr, []() {}));
 }
 
 TEST(UtilsTest, SetPrepareSystemError)
 {
-    EXPECT_EQ(-EBUSY, performCallback([]() {
+    EXPECT_EQ(-EBUSY, performCallback("system_error", []() {
         throw std::system_error(EBUSY, std::generic_category());
     }));
 }
 
 TEST(UtilsTest, SetPrepareException)
 {
-    EXPECT_EQ(-ENOSYS,
-              performCallback([]() { throw std::runtime_error("Exception"); }));
+    EXPECT_EQ(-ENOSYS, performCallback("runtime_error", []() {
+        throw std::runtime_error("Exception");
+    }));
 }
 
 TEST(UtilsTest, SetPrepareUnknownException)
 {
-    EXPECT_EQ(-ENOSYS, performCallback([]() { throw static_cast<int>(1); }));
+    EXPECT_EQ(-ENOSYS,
+              performCallback("unknown", []() { throw static_cast<int>(1); }));
 }
 
 } // namespace
