From: kbuild test robot <lkp@intel.com>
To: Enric Balletbo i Serra <enric.balletbo@collabora.com>
Cc: kbuild-all@01.org, Lee Jones <lee.jones@linaro.org>,
Benson Leung <bleung@chromium.org>,
linux-kernel@vger.kernel.org, kernel@collabora.com,
groeck@chromium.org, gwendal@chromium.org,
Andy Shevchenko <andy.shevchenko@gmail.com>,
Shawn Nematbakhsh <shawnn@chromium.org>
Subject: Re: [PATCH v2 5/6] platform/chrome: cros_ec_debugfs: Add PD port info to debugfs
Date: Thu, 1 Mar 2018 08:26:03 +0800 [thread overview]
Message-ID: <201803010857.Fk9inaoE%fengguang.wu@intel.com> (raw)
In-Reply-To: <20180221170748.27505-6-enric.balletbo@collabora.com>
[-- Attachment #1: Type: text/plain, Size: 3582 bytes --]
Hi Shawn,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on ljones-mfd/for-mfd-next]
[also build test ERROR on v4.16-rc3 next-20180228]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]
url: https://github.com/0day-ci/linux/commits/Enric-Balletbo-i-Serra/platform-chrome-cros_ec_sysfs-Modify-error-handling/20180223-053556
base: https://git.kernel.org/pub/scm/linux/kernel/git/lee/mfd.git for-mfd-next
config: x86_64-allmodconfig (attached as .config)
compiler: gcc-7 (Debian 7.3.0-1) 7.3.0
reproduce:
# save the attached .config to linux build tree
make ARCH=x86_64
All errors (new ones prefixed by >>):
drivers/platform/chrome/cros_ec_debugfs.c: In function 'cros_ec_pdinfo_read':
>> drivers/platform/chrome/cros_ec_debugfs.c:219:16: error: 'EC_USB_PD_MAX_PORTS' undeclared (first use in this function); did you mean 'EC_CMD_USB_PD_PORTS'?
char read_buf[EC_USB_PD_MAX_PORTS * 40], *p = read_buf;
^~~~~~~~~~~~~~~~~~~
EC_CMD_USB_PD_PORTS
drivers/platform/chrome/cros_ec_debugfs.c:219:16: note: each undeclared identifier is reported only once for each function it appears in
drivers/platform/chrome/cros_ec_debugfs.c:219:7: warning: unused variable 'read_buf' [-Wunused-variable]
char read_buf[EC_USB_PD_MAX_PORTS * 40], *p = read_buf;
^~~~~~~~
drivers/platform/chrome/cros_ec_debugfs.c:264:1: warning: control reaches end of non-void function [-Wreturn-type]
}
^
vim +219 drivers/platform/chrome/cros_ec_debugfs.c
213
214 static ssize_t cros_ec_pdinfo_read(struct file *file,
215 char __user *user_buf,
216 size_t count,
217 loff_t *ppos)
218 {
> 219 char read_buf[EC_USB_PD_MAX_PORTS * 40], *p = read_buf;
220 struct cros_ec_debugfs *debug_info = file->private_data;
221 struct cros_ec_device *ec_dev = debug_info->ec->ec_dev;
222 struct {
223 struct cros_ec_command msg;
224 union {
225 struct ec_response_usb_pd_control_v1 resp;
226 struct ec_params_usb_pd_control params;
227 };
228 } __packed ec_buf;
229 struct cros_ec_command *msg;
230 struct ec_response_usb_pd_control_v1 *resp;
231 struct ec_params_usb_pd_control *params;
232 int i;
233
234 msg = &ec_buf.msg;
235 params = (struct ec_params_usb_pd_control *)msg->data;
236 resp = (struct ec_response_usb_pd_control_v1 *)msg->data;
237
238 msg->command = EC_CMD_USB_PD_CONTROL;
239 msg->version = 1;
240 msg->insize = sizeof(*resp);
241 msg->outsize = sizeof(*params);
242
243 /*
244 * Read status from all PD ports until failure, typically caused
245 * by attempting to read status on a port that doesn't exist.
246 */
247 for (i = 0; i < EC_USB_PD_MAX_PORTS; ++i) {
248 params->port = i;
249 params->role = 0;
250 params->mux = 0;
251 params->swap = 0;
252
253 if (cros_ec_cmd_xfer_status(ec_dev, msg) < 0)
254 break;
255
256 p += scnprintf(p, sizeof(read_buf) + read_buf - p,
257 "p%d: %s en:%.2x role:%.2x pol:%.2x\n", i,
258 resp->state, resp->enabled, resp->role,
259 resp->polarity);
260 }
261
262 return simple_read_from_buffer(user_buf, count, ppos,
263 read_buf, p - read_buf);
264 }
265
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 62548 bytes --]
next prev parent reply other threads:[~2018-03-01 0:26 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-02-21 17:07 [PATCH v2 0/6] platform/chrome: cros_ec debugfs and sysfs updates Enric Balletbo i Serra
2018-02-21 17:07 ` [PATCH v2 1/6] platform/chrome: cros_ec_sysfs: Modify error handling Enric Balletbo i Serra
2018-02-21 23:59 ` Gwendal Grignou
2018-02-21 17:07 ` [PATCH v2 2/6] platform/chrome: cros_ec_sysfs: introduce to_cros_ec_dev define Enric Balletbo i Serra
2018-02-21 19:04 ` Andy Shevchenko
2018-02-21 17:07 ` [PATCH v2 3/6] platform/chrome: cros_ec_sysfs: use permission-specific DEVICE_ATTR variants Enric Balletbo i Serra
2018-02-21 19:06 ` Andy Shevchenko
2018-02-21 17:07 ` [PATCH v2 4/6] platform/chrome: cros_ec_debugfs: Use octal permissions '0444' Enric Balletbo i Serra
2018-02-21 17:07 ` [PATCH v2 5/6] platform/chrome: cros_ec_debugfs: Add PD port info to debugfs Enric Balletbo i Serra
2018-03-01 0:26 ` kbuild test robot [this message]
2018-03-01 1:02 ` kbuild test robot
2018-02-21 17:07 ` [PATCH v2 6/6] platform/chrome: mfd/cros_ec_dev: Add sysfs entry to set keyboard wake lid angle Enric Balletbo i Serra
2018-03-07 16:28 ` Lee Jones
2018-03-17 5:31 ` Gwendal Grignou
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201803010857.Fk9inaoE%fengguang.wu@intel.com \
--to=lkp@intel.com \
--cc=andy.shevchenko@gmail.com \
--cc=bleung@chromium.org \
--cc=enric.balletbo@collabora.com \
--cc=groeck@chromium.org \
--cc=gwendal@chromium.org \
--cc=kbuild-all@01.org \
--cc=kernel@collabora.com \
--cc=lee.jones@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=shawnn@chromium.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®