Skip to content

Commit 7a28743

Browse files
krzkwsakernel
authored andcommitted
i2c: cros-ec-tunnel: Mark ACPI and OF related data as maybe unused
The driver can be compile tested with !CONFIG_OF or !CONFIG_ACPI making certain data unused: drivers/i2c/busses/i2c-cros-ec-tunnel.c:295:34: error: ‘cros_ec_i2c_of_match’ defined but not used [-Werror=unused-const-variable=] Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Guenter Roeck <groeck@chromium.org> Signed-off-by: Wolfram Sang <wsa@kernel.org>
1 parent 8759500 commit 7a28743

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

drivers/i2c/busses/i2c-cros-ec-tunnel.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -292,13 +292,13 @@ static int ec_i2c_remove(struct platform_device *dev)
292292
return 0;
293293
}
294294

295-
static const struct of_device_id cros_ec_i2c_of_match[] = {
295+
static const struct of_device_id cros_ec_i2c_of_match[] __maybe_unused = {
296296
{ .compatible = "google,cros-ec-i2c-tunnel" },
297297
{},
298298
};
299299
MODULE_DEVICE_TABLE(of, cros_ec_i2c_of_match);
300300

301-
static const struct acpi_device_id cros_ec_i2c_tunnel_acpi_id[] = {
301+
static const struct acpi_device_id cros_ec_i2c_tunnel_acpi_id[] __maybe_unused = {
302302
{ "GOOG0012", 0 },
303303
{ }
304304
};

0 commit comments

Comments
 (0)