drop remove_from_dbus_on_fail option

Signed-off-by: Patrick Venture <venture@google.com>
Change-Id: I8af40d0db98c2d995542cbc46821b0f6cf602de0
diff --git a/configure.ac b/configure.ac
index bd63629..c189114 100644
--- a/configure.ac
+++ b/configure.ac
@@ -160,28 +160,7 @@
     AC_SUBST([OESDK_TESTCASE_FLAGS], [$testcase_flags])
 )
 
-# When a sensor access fails, just remove the sensor from dbus instead of exiting the daemon.
-AC_ARG_ENABLE([remove-from-dbus-on-fail],
-    AS_HELP_STRING(
-        [--enable-remove-from-dbus-on-fail],
-        [Remove properties from D-Bus on access failures]
-    )
-)
-
-AC_ARG_VAR(REMOVE_ON_FAIL, [Remove properties from D-Bus on access failures])
-
-AS_IF(
-    [test "x$enable_remove_from_dbus_on_fail" == "xyes"],
-    [REMOVE_ON_FAIL="yes"]
-    AC_DEFINE_UNQUOTED(
-        [REMOVE_ON_FAIL],
-        ["$REMOVE_ON_FAIL"],
-        [Remove properties from D-Bus on access failures]
-    )
-)
-
 # When a sensor read fails, set the Value on dbus with -errno.
-# Incompatible with remove-from-dbus-on-fail.
 AC_ARG_ENABLE([negative-errno-on-fail],
     AS_HELP_STRING([--enable-negative-errno-on-fail], [Set sensor value to -errno on read failures])
 )
diff --git a/mainloop.cpp b/mainloop.cpp
index a35c40e..5fa66cd 100644
--- a/mainloop.cpp
+++ b/mainloop.cpp
@@ -208,7 +208,7 @@
         auto file =
             sysfs::make_sysfs_path(_ioAccess->path(), sensor.first.first,
                                    sensor.first.second, hwmon::entry::cinput);
-#ifndef REMOVE_ON_FAIL
+
         // Check sensorAdjusts for sensor removal RCs
         auto& sAdjusts = sensorObj->getAdjusts();
         if (sAdjusts.rmRCs.count(e.code().value()) > 0)
@@ -224,7 +224,7 @@
             }
             return {};
         }
-#endif
+
         using namespace sdbusplus::xyz::openbmc_project::Sensor::Device::Error;
         report<ReadFailure>(
             xyz::openbmc_project::Sensor::Device::ReadFailure::CALLOUT_ERRNO(
@@ -234,11 +234,7 @@
 
         log<level::INFO>("Logging failing sysfs file",
                          entry("FILE=%s", file.c_str()));
-#ifdef REMOVE_ON_FAIL
-        return {}; /* skip adding this sensor for now. */
-#else
         exit(EXIT_FAILURE);
-#endif
     }
     auto sensorValue = valueInterface->value();
     int64_t scale = 0;
@@ -445,7 +441,7 @@
                 auto file = sysfs::make_sysfs_path(
                     _ioAccess->path(), i.first.first, i.first.second,
                     hwmon::entry::cinput);
-#ifndef REMOVE_ON_FAIL
+
                 // Check sensorAdjusts for sensor removal RCs
                 auto& sAdjusts = _sensorObjects[i.first]->getAdjusts();
                 if (sAdjusts.rmRCs.count(e.code().value()) > 0)
@@ -463,7 +459,7 @@
                     }
                     continue;
                 }
-#endif
+
                 using namespace sdbusplus::xyz::openbmc_project::Sensor::
                     Device::Error;
                 report<ReadFailure>(
@@ -475,20 +471,14 @@
                 log<level::INFO>("Logging failing sysfs file",
                                  entry("FILE=%s", file.c_str()));
 
-#ifdef REMOVE_ON_FAIL
-                _rmSensors[i.first] = std::get<0>(i.second);
-#else
                 exit(EXIT_FAILURE);
-#endif
             }
         }
     }
 
     removeSensors();
 
-#ifndef REMOVE_ON_FAIL
     addDroppedSensors();
-#endif
 }
 
 void MainLoop::removeSensors()