Skip to content
Commit 6514bac4 authored by Tzung-Bi Shih's avatar Tzung-Bi Shih
Browse files

platform/chrome: cros_ec_proto: remove big stub objects from stack



sizeof(struct device) = 680
sizeof(struct cros_ec_dev) = 720

They tend to exceed the stack frame size limit in some specific
environment which results in the following compilation error:

>> drivers/platform/chrome/cros_ec_proto_test.c:2530:13: error: stack
frame size (2128) exceeds limit (2048) in
'cros_ec_proto_test_get_sensor_count_legacy'

Remove the big stub objects from stack.

This is:
$ sed -i 's/struct cros_ec_dev /static struct cros_ec_dev /' \
    drivers/platform/chrome/cros_ec_proto_test.c

Reported-by: default avatarkernel test robot <lkp@intel.com>
Signed-off-by: default avatarTzung-Bi Shih <tzungbi@kernel.org>
Reviewed-by: default avatarGuenter Roeck <linux@roeck-us.net>
Link: https://lore.kernel.org/r/20230117080254.2725536-1-tzungbi@kernel.org
parent 8bb233b2
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