Commit 466f70fb authored by Tzung-Bi Shih's avatar Tzung-Bi Shih

platform/chrome: kunit: make EC protocol tests independent

Remove CONFIG_CROS_KUNIT and common code concept for ChromeOS Kunit but
make it bundle to ChromeOS EC protocol tests.
Reviewed-by: default avatarGuenter Roeck <groeck@chromium.org>
Link: https://lore.kernel.org/r/20231003080515.4011374-1-tzungbi@kernel.orgSigned-off-by: default avatarTzung-Bi Shih <tzungbi@kernel.org>
parent e410b4ad
...@@ -299,12 +299,12 @@ config CROS_TYPEC_SWITCH ...@@ -299,12 +299,12 @@ config CROS_TYPEC_SWITCH
source "drivers/platform/chrome/wilco_ec/Kconfig" source "drivers/platform/chrome/wilco_ec/Kconfig"
# Kunit test cases # Kunit test cases
config CROS_KUNIT config CROS_KUNIT_EC_PROTO_TEST
tristate "Kunit tests for ChromeOS" if !KUNIT_ALL_TESTS tristate "Kunit tests for ChromeOS EC protocol" if !KUNIT_ALL_TESTS
depends on KUNIT && CROS_EC depends on KUNIT && CROS_EC
default KUNIT_ALL_TESTS default KUNIT_ALL_TESTS
select CROS_EC_PROTO select CROS_EC_PROTO
help help
ChromeOS Kunit tests. Kunit tests for ChromeOS EC protocol.
endif # CHROMEOS_PLATFORMS endif # CHROMEOS_PLATFORMS
...@@ -36,6 +36,5 @@ obj-$(CONFIG_CROS_USBPD_NOTIFY) += cros_usbpd_notify.o ...@@ -36,6 +36,5 @@ obj-$(CONFIG_CROS_USBPD_NOTIFY) += cros_usbpd_notify.o
obj-$(CONFIG_WILCO_EC) += wilco_ec/ obj-$(CONFIG_WILCO_EC) += wilco_ec/
# Kunit test cases # Kunit test cases
obj-$(CONFIG_CROS_KUNIT) += cros_kunit.o obj-$(CONFIG_CROS_KUNIT_EC_PROTO_TEST) += cros_kunit_proto_test.o
cros_kunit-objs := cros_kunit_util.o cros_kunit_proto_test-objs := cros_ec_proto_test_util.o cros_ec_proto_test.o
cros_kunit-objs += cros_ec_proto_test.o
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
#include <linux/platform_data/cros_ec_proto.h> #include <linux/platform_data/cros_ec_proto.h>
#include "cros_ec.h" #include "cros_ec.h"
#include "cros_kunit_util.h" #include "cros_ec_proto_test_util.h"
#define BUFSIZE 512 #define BUFSIZE 512
......
...@@ -11,7 +11,7 @@ ...@@ -11,7 +11,7 @@
#include <linux/platform_data/cros_ec_proto.h> #include <linux/platform_data/cros_ec_proto.h>
#include "cros_ec.h" #include "cros_ec.h"
#include "cros_kunit_util.h" #include "cros_ec_proto_test_util.h"
int cros_kunit_ec_xfer_mock_default_result; int cros_kunit_ec_xfer_mock_default_result;
int cros_kunit_ec_xfer_mock_default_ret; int cros_kunit_ec_xfer_mock_default_ret;
...@@ -126,5 +126,3 @@ void cros_kunit_mock_reset(void) ...@@ -126,5 +126,3 @@ void cros_kunit_mock_reset(void)
cros_kunit_readmem_mock_data = NULL; cros_kunit_readmem_mock_data = NULL;
cros_kunit_readmem_mock_ret = 0; cros_kunit_readmem_mock_ret = 0;
} }
MODULE_LICENSE("GPL");
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment