--- /dev/null
+/*
+ * Copyright (c) 2020 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+
+#ifndef __TIZEN_SYSTEM_PMQOS_H__
+#define __TIZEN_SYSTEM_PMQOS_H__
+
+
+#include <stdbool.h>
+#include "device-error.h"
+
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+/**
+ * @addtogroup CAPI_SYSTEM_DEVICE_PMQOS_MODULE
+ * @{
+ */
+
+/**
+ * @brief pmqos cpu request for AppLaunchHome.
+ * @since_tizen 6.0
+ * @param[in] timeout Timeout to change state
+ * @return @c 0 on success,
+ * otherwise a negative error value
+ * @retval #DEVICE_ERROR_NONE Successful
+ * @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed
+ * @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device
+ */
+int device_pmqos_app_launch_home(int timeout);
+
+/**
+ * @brief pmqos cpu request for HomeScreen.
+ * @since_tizen 6.0
+ * @param[in] timeout Timeout to change state
+ * @return @c 0 on success,
+ * otherwise a negative error value
+ * @retval #DEVICE_ERROR_NONE Successful
+ * @retval #DEVICE_ERROR_INVALID_PARAMETER Invalid parameter
+ * @retval #DEVICE_ERROR_OPERATION_FAILED Operation failed
+ * @retval #DEVICE_ERROR_NOT_SUPPORTED Not supported device
+ */
+int device_pmqos_homescreen(int timeout);
+
+/**
+ * @}
+ */
+
+
+#ifdef __cplusplus
+}
+#endif
+
+
+#endif // __TIZEN_SYSTEM_PMQOS_H__
#define DEVICED_OBJECT_PATH "/Org/Tizen/System/DeviceD"
#define DEVICED_INTERFACE_NAME DEVICED_BUS_NAME
+/* PmQos service: operations about pmqos */
+#define DEVICED_PATH_PMQOS DEVICED_OBJECT_PATH"/PmQos"
+#define DEVICED_INTERFACE_PMQOS DEVICED_INTERFACE_NAME".PmQos"
+
/* Display service: start/stop display(pm), get/set brightness operations about display */
#define DEVICED_PATH_DISPLAY DEVICED_OBJECT_PATH"/Display"
#define DEVICED_INTERFACE_DISPLAY DEVICED_INTERFACE_NAME".display"
--- /dev/null
+/*
+ * Copyright (c) 2020 Samsung Electronics Co., Ltd All Rights Reserved
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+
+#include "pmqos-internal.h"
+#include "common.h"
+#include "dbus.h"
+
+#define METHOD_APP_LAUNCH_HOME "AppLaunchHome"
+#define METHOD_HOMESCREEN "HomeScreen"
+
+int device_pmqos_app_launch_home(int timeout)
+{
+ int ret;
+
+ if (timeout < 0)
+ return DEVICE_ERROR_INVALID_PARAMETER;
+
+ ret = dbus_method_sync_var(DEVICED_BUS_NAME,
+ DEVICED_PATH_PMQOS,
+ DEVICED_INTERFACE_PMQOS,
+ METHOD_APP_LAUNCH_HOME,
+ g_variant_new("(i)", timeout));;
+ if (ret < 0)
+ return errno_to_device_error(ret);
+
+ return DEVICE_ERROR_NONE;
+}
+
+int device_pmqos_homescreen(int timeout)
+{
+ int ret;
+
+ if (timeout < 0)
+ return DEVICE_ERROR_INVALID_PARAMETER;
+
+ ret = dbus_method_sync_var(DEVICED_BUS_NAME,
+ DEVICED_PATH_PMQOS,
+ DEVICED_INTERFACE_PMQOS,
+ METHOD_HOMESCREEN,
+ g_variant_new("(i)", timeout));;
+ if (ret < 0)
+ return errno_to_device_error(ret);
+
+ return DEVICE_ERROR_NONE;
+}
+