|
@@ -185,7 +185,7 @@ static ssize_t show_ec_version(struct device *dev,
|
|
|
count += scnprintf(buf + count, PAGE_SIZE - count,
|
|
|
"Build info: EC error %d\n", msg->result);
|
|
|
else {
|
|
|
- msg->data[sizeof(msg->data) - 1] = '\0';
|
|
|
+ msg->data[EC_HOST_PARAM_SIZE - 1] = '\0';
|
|
|
count += scnprintf(buf + count, PAGE_SIZE - count,
|
|
|
"Build info: %s\n", msg->data);
|
|
|
}
|