smbus: Move smbus_utils.h from includes to driver area

Move smbus_utils.h header from generic includes to the driver's area
in order to have in include/zephyr/drivers only smbus.h header.

Signed-off-by: Andrei Emeltchenko <andrei.emeltchenko@intel.com>
This commit is contained in:
Andrei Emeltchenko 2023-03-24 15:24:25 +02:00 committed by Fabio Baltieri
commit 1679faaa0e
4 changed files with 4 additions and 2 deletions

View file

@ -21,7 +21,7 @@
#include <zephyr/logging/log.h> #include <zephyr/logging/log.h>
LOG_MODULE_REGISTER(intel_pch, CONFIG_SMBUS_LOG_LEVEL); LOG_MODULE_REGISTER(intel_pch, CONFIG_SMBUS_LOG_LEVEL);
#include <zephyr/drivers/smbus_utils.h> #include "smbus_utils.h"
#include "intel_pch_smbus.h" #include "intel_pch_smbus.h"
/** /**

View file

@ -6,6 +6,7 @@ if(BOARD STREQUAL qemu_x86_64)
LIST(APPEND QEMU_EXTRA_FLAGS -machine q35) LIST(APPEND QEMU_EXTRA_FLAGS -machine q35)
endif() endif()
target_include_directories(app PRIVATE ${ZEPHYR_BASE}/drivers/smbus)
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE}) find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
project(smbus_api) project(smbus_api)

View file

@ -11,7 +11,8 @@
#include <zephyr/kernel.h> #include <zephyr/kernel.h>
#include <zephyr/ztest.h> #include <zephyr/ztest.h>
#include <zephyr/drivers/smbus.h> #include <zephyr/drivers/smbus.h>
#include <zephyr/drivers/smbus_utils.h>
#include <smbus_utils.h>
BUILD_ASSERT(DT_NODE_HAS_STATUS(DT_NODELABEL(smbus0), okay), BUILD_ASSERT(DT_NODE_HAS_STATUS(DT_NODELABEL(smbus0), okay),
"SMBus node is disabled!"); "SMBus node is disabled!");