From: Jeremy Fitzhardinge <jeremy@goop.org>
To: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Jiri Kosina <jikos@jikos.cz>,
linux-next@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: linux-next: build failure after merge of the hid tree
Date: Mon, 28 Nov 2011 17:30:59 -0800 [thread overview]
Message-ID: <4ED435D3.70300@goop.org> (raw)
In-Reply-To: <20111129120059.a1818d7eaf663546edc6dc34@canb.auug.org.au>
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
On 11/28/2011 05:00 PM, Stephen Rothwell wrote:
> Hi Jiri,
>
> After merging the hid tree, today's linux-next build (powerpc
> ppc64_defconfig) failed like this:
>
> drivers/hid/hid-input.c: In function 'hidinput_hid_event':
> drivers/hid/hid-input.c:865:6: error: 'struct hid_device' has no member
named 'battery_val'
> drivers/hid/hid-input.c:866:3: error: 'struct hid_device' has no member
named 'battery_min'
> drivers/hid/hid-input.c:866:3: error: 'struct hid_device' has no member
named 'battery_max'
>
> Caused by commit 4f5ca836bef3 ("HID: hid-input: add support for HID
> devices reporting Battery Strength"). Those members are only defined when
> CONFIG_HID_BATTERY_STRENGTH is set.
>
> I have used the hid tree from next-20111128 for today.
Oh, sorry about that. Is this sufficient?
Subject: [PATCH] hid-input: fix compile for !HID_BATTERY_STRENGTH
As reported by Stephen Rothwell:
drivers/hid/hid-input.c: In function 'hidinput_hid_event':
drivers/hid/hid-input.c:865:6: error: 'struct hid_device' has no member
named 'battery_val'
drivers/hid/hid-input.c:866:3: error: 'struct hid_device' has no member
named 'battery_min'
drivers/hid/hid-input.c:866:3: error: 'struct hid_device' has no member
named 'battery_max'
Signed-off-by: Jeremy Fitzhardinge <jeremy@goop.org>
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c
index 83afb86..d9cadb3 100644
- --- a/drivers/hid/hid-input.c
+++ b/drivers/hid/hid-input.c
@@ -861,12 +861,14 @@ void hidinput_hid_event(struct hid_device *hid,
struct hid_field *field, struct
input = field->hidinput->input;
+#ifdef CONFIG_HID_BATTERY_STRENGTH
if (usage->hid == HID_DC_BATTERYSTRENGTH) {
hid->battery_val = value;
hid_dbg(hid, "battery value is %d (range %d-%d)\n",
value, hid->battery_min, hid->battery_max);
return;
}
+#endif
if (!usage->type)
return;
J
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
iQEkBAEBCgAGBQJO1DXKAAoJEAUkni6MUg7H2/wIPAk0oHGVawNScWJdJXMhMVca
ApxAr1h2v5kgIzRlihkpOiK3opft/GzBYh54HHd4nPdC5D4KAmuOXeX2+fwVgIEG
SlrwsGU4J9n9uH/e3qgJf2aANcWH+bQwqL58ZyLE0Yo+N3dBzDNaNGd8Gygw8jk+
mGtsMAfjIwe5vDLmsIED1+hqGNUL8/vt+TnCcpNVWUdrUtCT7dpDifcoeblO/qrs
5hWbpf+AOek7UEoHQ0qAbRLi8A1FcoMs20mHiSpkfVn2d2gUYUYZRjeW66xwuKB7
Q9iYEoOEszj+07nkHvS8VZZFMIXKsBOvkDVrktQtgDTZzI71axbgKPK8UESjjH4U
uMPpWmv8yA==
=2NZE
-----END PGP SIGNATURE-----
next prev parent reply other threads:[~2011-11-29 1:31 UTC|newest]
Thread overview: 41+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-29 1:00 linux-next: build failure after merge of the hid tree Stephen Rothwell
2011-11-29 1:30 ` Jeremy Fitzhardinge [this message]
-- strict thread matches above, loose matches on Subject: below --
2026-03-02 13:56 Mark Brown
2026-03-02 15:58 ` Benjamin Tissoires
2026-03-02 17:52 ` Denis Benato
2025-02-09 23:43 Stephen Rothwell
2025-02-10 22:07 ` Jiri Kosina
2025-02-11 3:15 ` Kate Hsuan
2025-01-10 6:52 Stephen Rothwell
2024-07-01 8:51 Stephen Rothwell
2024-07-01 12:43 ` Benjamin Tissoires
2024-06-20 13:55 Mark Brown
2024-05-07 1:06 Stephen Rothwell
2024-05-07 7:22 ` Kenny Levinsen
2024-04-11 0:51 Stephen Rothwell
2024-04-11 7:17 ` Benjamin Tissoires
2024-02-28 3:56 Stephen Rothwell
2022-07-25 0:40 Stephen Rothwell
2022-07-25 9:42 ` Jiri Kosina
2022-07-27 1:11 ` Stephen Rothwell
2021-12-03 7:01 Stephen Rothwell
2021-12-03 8:09 ` Greg Kroah-Hartman
2021-05-27 5:26 Stephen Rothwell
2021-05-27 8:14 ` Jiri Kosina
2021-05-27 8:25 ` Hans de Goede
2021-05-27 13:22 ` Naresh Kamboju
2021-05-27 13:42 ` Jiri Kosina
2019-10-04 0:28 Stephen Rothwell
2019-10-04 6:55 ` Hans de Goede
2016-12-11 23:59 Stephen Rothwell
2016-12-12 8:50 ` Jiri Kosina
2012-06-29 2:47 Stephen Rothwell
2012-06-29 13:03 ` Jiri Kosina
2011-12-19 1:34 Stephen Rothwell
2011-12-19 8:21 ` Jiri Kosina
2011-06-08 3:03 Stephen Rothwell
2011-06-08 7:26 ` Stefan Kriwanek
2011-06-08 7:50 ` Jiri Kosina
2011-04-07 1:06 Stephen Rothwell
2011-04-07 13:00 ` Alan Ott
2011-04-08 23:54 ` Jiri Kosina
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=4ED435D3.70300@goop.org \
--to=jeremy@goop.org \
--cc=jikos@jikos.cz \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--cc=sfr@canb.auug.org.au \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.