Change object manager path
Since there's not a "settings" root as such, and the settings objects
are spread across the object namespace, register "/" as the path for the
d-bus object manager.
Change-Id: Ic012129b333cba8831c331803124b3e89642b536
Signed-off-by: Deepak Kodihalli <dkodihal@in.ibm.com>
diff --git a/configure.ac b/configure.ac
index 6b3191d..3ee9c6b 100644
--- a/configure.ac
+++ b/configure.ac
@@ -28,12 +28,6 @@
AC_DEFINE_UNQUOTED([SETTINGS_BUSNAME], ["$SETTINGS_BUSNAME"],\
[The DBus busname to own])
-AC_ARG_VAR(SETTINGS_ROOT, [The settings Dbus root])
-AS_IF([test "x$SETTINGS_ROOT" == "x"],\
- [SETTINGS_ROOT="/xyz/openbmc_project/settings"])
-AC_DEFINE_UNQUOTED([SETTINGS_ROOT], ["$SETTINGS_ROOT"],\
- [The settings Dbus root])
-
AS_IF([test "x$SETTINGS_YAML" == "x"], [SETTINGS_YAML="settings_example.yaml"])
SETTINGSGEN="$PYTHON $srcdir/settings.py -i $SETTINGS_YAML"
AC_SUBST(SETTINGSGEN)
diff --git a/settings_main.cpp b/settings_main.cpp
index 22d6146..0d775e2 100644
--- a/settings_main.cpp
+++ b/settings_main.cpp
@@ -7,8 +7,10 @@
{
auto bus = sdbusplus::bus::new_default();
- // Add sdbusplus ObjectManager for the settings root.
- sdbusplus::server::manager::manager objManager(bus, SETTINGS_ROOT);
+ // Add sdbusplus ObjectManager. The settings objects are spread across
+ // the object namespace and are not under a (settings) root. Hence register
+ // "/" as the path.
+ sdbusplus::server::manager::manager objManager(bus, "/");
phosphor::settings::Manager mgr(bus);