[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202501171826.NGZwFrgW-lkp@intel.com>
Date: Fri, 17 Jan 2025 19:03:53 +0800
From: kernel test robot <lkp@...el.com>
To: Pengyu Luo <mitltlatltl@...il.com>, Rob Herring <robh@...nel.org>,
Krzysztof Kozlowski <krzk@...nel.org>,
Conor Dooley <conor+dt@...nel.org>,
Bjorn Andersson <andersson@...nel.org>,
Konrad Dybcio <konradybcio@...nel.org>,
Hans de Goede <hdegoede@...hat.com>,
Ilpo Järvinen <ilpo.jarvinen@...ux.intel.com>,
Bryan O'Donoghue <bryan.odonoghue@...aro.org>,
Jean Delvare <jdelvare@...e.com>,
Guenter Roeck <linux@...ck-us.net>
Cc: oe-kbuild-all@...ts.linux.dev, devicetree@...r.kernel.org,
linux-kernel@...r.kernel.org, linux-arm-msm@...r.kernel.org,
platform-driver-x86@...r.kernel.org, linux-hwmon@...r.kernel.org,
Pengyu Luo <mitltlatltl@...il.com>
Subject: Re: [PATCH v4 2/3] platform: arm64: add Huawei Matebook E Go EC
driver
Hi Pengyu,
kernel test robot noticed the following build warnings:
[auto build test WARNING on b323d8e7bc03d27dec646bfdccb7d1a92411f189]
url: https://github.com/intel-lab-lkp/linux/commits/Pengyu-Luo/dt-bindings-platform-Add-Huawei-Matebook-E-Go-EC/20250116-192206
base: b323d8e7bc03d27dec646bfdccb7d1a92411f189
patch link: https://lore.kernel.org/r/20250116111559.83641-3-mitltlatltl%40gmail.com
patch subject: [PATCH v4 2/3] platform: arm64: add Huawei Matebook E Go EC driver
config: sh-allmodconfig (https://download.01.org/0day-ci/archive/20250117/202501171826.NGZwFrgW-lkp@intel.com/config)
compiler: sh4-linux-gcc (GCC) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250117/202501171826.NGZwFrgW-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202501171826.NGZwFrgW-lkp@intel.com/
All warnings (new ones prefixed by >>):
drivers/platform/arm64/huawei-gaokun-ec.c: In function 'extr_resp_shallow':
>> drivers/platform/arm64/huawei-gaokun-ec.c:91:20: warning: return discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
91 | return src + RESP_HDR_SIZE;
| ^
drivers/platform/arm64/huawei-gaokun-ec.c: In function 'gaokun_ec_request':
>> drivers/platform/arm64/huawei-gaokun-ec.c:112:32: warning: initialization discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
112 | .buf = req,
| ^~~
vim +/const +91 drivers/platform/arm64/huawei-gaokun-ec.c
88
89 static inline void *extr_resp_shallow(const u8 *src)
90 {
> 91 return src + RESP_HDR_SIZE;
92 }
93
94 struct gaokun_ec {
95 struct i2c_client *client;
96 struct mutex lock; /* EC transaction lock */
97 struct blocking_notifier_head notifier_list;
98 struct device *hwmon_dev;
99 struct input_dev *idev;
100 bool suspended;
101 };
102
103 static int gaokun_ec_request(struct gaokun_ec *ec, const u8 *req,
104 size_t resp_len, u8 *resp)
105 {
106 struct i2c_client *client = ec->client;
107 struct i2c_msg msgs[2] = {
108 {
109 .addr = client->addr,
110 .flags = client->flags,
111 .len = REQ_LEN(req),
> 112 .buf = req,
113 }, {
114 .addr = client->addr,
115 .flags = client->flags | I2C_M_RD,
116 .len = resp_len,
117 .buf = resp,
118 },
119 };
120
121 guard(mutex)(&ec->lock);
122 i2c_transfer(client->adapter, msgs, ARRAY_SIZE(msgs));
123 usleep_range(2000, 2500); /* have a break, ACPI did this */
124
125 return *resp ? -EIO : 0;
126 }
127
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists