<feed xmlns='http://www.w3.org/2005/Atom'>
<title>starfive-tech/linux.git/include/linux/hid.h, branch visionfive_v1_5.13</title>
<subtitle>StarFive Tech Linux Kernel for VisionFive (JH7110) boards (mirror)</subtitle>
<id>https://git.radix-linux.su/starfive-tech/linux.git/atom?h=visionfive_v1_5.13</id>
<link rel='self' href='https://git.radix-linux.su/starfive-tech/linux.git/atom?h=visionfive_v1_5.13'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/starfive-tech/linux.git/'/>
<updated>2021-05-05T13:52:34+00:00</updated>
<entry>
<title>HID: usbhid: fix info leak in hid_submit_ctrl</title>
<updated>2021-05-05T13:52:34+00:00</updated>
<author>
<name>Anirudh Rayabharam</name>
<email>mail@anirudhrb.com</email>
</author>
<published>2021-04-25T17:33:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/starfive-tech/linux.git/commit/?id=6be388f4a35d2ce5ef7dbf635a8964a5da7f799f'/>
<id>urn:sha1:6be388f4a35d2ce5ef7dbf635a8964a5da7f799f</id>
<content type='text'>
In hid_submit_ctrl(), the way of calculating the report length doesn't
take into account that report-&gt;size can be zero. When running the
syzkaller reproducer, a report of size 0 causes hid_submit_ctrl) to
calculate transfer_buffer_length as 16384. When this urb is passed to
the usb core layer, KMSAN reports an info leak of 16384 bytes.

To fix this, first modify hid_report_len() to account for the zero
report size case by using DIV_ROUND_UP for the division. Then, call it
from hid_submit_ctrl().

Reported-by: syzbot+7c2bb71996f95a82524c@syzkaller.appspotmail.com
Signed-off-by: Anirudh Rayabharam &lt;mail@anirudhrb.com&gt;
Acked-by: Benjamin Tissoires &lt;benjamin.tissoires@redhat.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>Merge branch 'for-5.13/plantronics' into for-linus</title>
<updated>2021-04-29T19:44:07+00:00</updated>
<author>
<name>Jiri Kosina</name>
<email>jkosina@suse.cz</email>
</author>
<published>2021-04-29T19:44:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/starfive-tech/linux.git/commit/?id=cfc9bdfb6ba76de84a9ed8ee75dc56903b505a78'/>
<id>urn:sha1:cfc9bdfb6ba76de84a9ed8ee75dc56903b505a78</id>
<content type='text'>
- Workaround for broken behavior of Plantronics Blackwire from Maxim
  Mikityanskiy
</content>
</entry>
<entry>
<title>HID: input: map battery capacity (00850065)</title>
<updated>2021-04-07T11:15:17+00:00</updated>
<author>
<name>John Chen</name>
<email>johnchen902@gmail.com</email>
</author>
<published>2021-03-30T11:33:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/starfive-tech/linux.git/commit/?id=9de07a4e8d4cb269f9876b2ffa282b5ffd09e05b'/>
<id>urn:sha1:9de07a4e8d4cb269f9876b2ffa282b5ffd09e05b</id>
<content type='text'>
This is the capacity in percentage, relative to design capacity.
Specifically, it is present in Apple Magic Mouse 2.

In contrast, usage 00850064 is also the capacity in percentage, but is
relative to full capacity. It is not mapped here because I don't have
such device.

Signed-off-by: John Chen &lt;johnchen902@gmail.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: plantronics: Workaround for double volume key presses</title>
<updated>2021-03-08T10:08:58+00:00</updated>
<author>
<name>Maxim Mikityanskiy</name>
<email>maxtram95@gmail.com</email>
</author>
<published>2021-02-07T14:47:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/starfive-tech/linux.git/commit/?id=f567d6ef8606fb427636e824c867229ecb5aefab'/>
<id>urn:sha1:f567d6ef8606fb427636e824c867229ecb5aefab</id>
<content type='text'>
Plantronics Blackwire 3220 Series (047f:c056) sends HID reports twice
for each volume key press. This patch adds a quirk to hid-plantronics
for this product ID, which will ignore the second volume key press if
it happens within 5 ms from the last one that was handled.

The patch was tested on the mentioned model only, it shouldn't affect
other models, however, this quirk might be needed for them too.
Auto-repeat (when a key is held pressed) is not affected, because the
rate is about 3 times per second, which is far less frequent than once
in 5 ms.

Fixes: 81bb773faed7 ("HID: plantronics: Update to map volume up/down controls")
Signed-off-by: Maxim Mikityanskiy &lt;maxtram95@gmail.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: correct kernel-doc notation in &lt;linux/hid*.h&gt;</title>
<updated>2021-01-26T13:24:26+00:00</updated>
<author>
<name>Randy Dunlap</name>
<email>rdunlap@infradead.org</email>
</author>
<published>2021-01-19T20:07:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/starfive-tech/linux.git/commit/?id=ceecd1bff6f9a741adc173f062f1f9312c3a66c8'/>
<id>urn:sha1:ceecd1bff6f9a741adc173f062f1f9312c3a66c8</id>
<content type='text'>
Correct kernel-doc notation in HID header files (include/linux/hid*.h).
Add notation (comments) where it is missing.
Use the documented "Return:" notation for function return values.
Fix a few typos/spellos.

Signed-off-by: Randy Dunlap &lt;rdunlap@infradead.org&gt;
Cc: Jiri Kosina &lt;jikos@kernel.org&gt;
Cc: Benjamin Tissoires &lt;benjamin.tissoires@redhat.com&gt;
Cc: linux-input@vger.kernel.org
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: Increase HID maximum report size to 16KB</title>
<updated>2020-11-27T14:44:21+00:00</updated>
<author>
<name>Dean Camera</name>
<email>dean@fourwalledcubicle.com</email>
</author>
<published>2020-11-25T22:39:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/starfive-tech/linux.git/commit/?id=6a0eaf5123e0e1223252b88cd5775f74105e27bd'/>
<id>urn:sha1:6a0eaf5123e0e1223252b88cd5775f74105e27bd</id>
<content type='text'>
Currently the maximum HID report size which can be buffered by the kernel is
8KB. This is sufficient for the vast majority of HID devices on the market, as
most HID reports are fairly small.

However, some unusual devices such as the Elgate Stream Deck exist which use a
report size slightly over 8KB for the image data that is sent to the device.
Reports these large cannot be buffered by the regular HID subsystem currently,
thus the only way to use such device is to bypass the HID subsystem entirely.

This increases the maximum HID report size to 16KB, which should cover all
sanely designed HID devices.

Signed-off-by: Dean Camera &lt;dean@fourwalledcubicle.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: hid-input: occasionally report stylus battery even if not changed</title>
<updated>2020-10-29T15:14:36+00:00</updated>
<author>
<name>dmitry.torokhov@gmail.com</name>
<email>dmitry.torokhov@gmail.com</email>
</author>
<published>2020-09-30T22:47:13+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/starfive-tech/linux.git/commit/?id=c6838eeef2fbc7e3e1f83759aa016ae6b70c643e'/>
<id>urn:sha1:c6838eeef2fbc7e3e1f83759aa016ae6b70c643e</id>
<content type='text'>
There are styluses that only report their battery status when they are
touching the touchscreen; additionally we currently suppress battery
reports if capacity has not changed. To help userspace recognize how long
ago the device reported battery status, let's send the change event through
if either capacity has changed, or at least 30 seconds have passed since
last report we've let through.

Signed-off-by: Dmitry Torokhov &lt;dmitry.torokhov@gmail.com&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: add vivaldi HID driver</title>
<updated>2020-09-30T20:44:26+00:00</updated>
<author>
<name>Sean O'Brien</name>
<email>seobrien@chromium.org</email>
</author>
<published>2020-09-09T22:03:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/starfive-tech/linux.git/commit/?id=14c9c014babedc6098bf4cd83c622997867bc0df'/>
<id>urn:sha1:14c9c014babedc6098bf4cd83c622997867bc0df</id>
<content type='text'>
Add vivaldi HID driver. This driver allows us to read and report the top
row layout of keyboards which provide a vendor-defined (Google) HID
usage.

Signed-off-by: Sean O'Brien &lt;seobrien@chromium.org&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
<entry>
<title>HID: core: Sanitize event code and type when mapping input</title>
<updated>2020-09-01T10:06:41+00:00</updated>
<author>
<name>Marc Zyngier</name>
<email>maz@kernel.org</email>
</author>
<published>2020-09-01T09:52:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/starfive-tech/linux.git/commit/?id=35556bed836f8dc07ac55f69c8d17dce3e7f0e25'/>
<id>urn:sha1:35556bed836f8dc07ac55f69c8d17dce3e7f0e25</id>
<content type='text'>
When calling into hid_map_usage(), the passed event code is
blindly stored as is, even if it doesn't fit in the associated bitmap.

This event code can come from a variety of sources, including devices
masquerading as input devices, only a bit more "programmable".

Instead of taking the event code at face value, check that it actually
fits the corresponding bitmap, and if it doesn't:
- spit out a warning so that we know which device is acting up
- NULLify the bitmap pointer so that we catch unexpected uses

Code paths that can make use of untrusted inputs can now check
that the mapping was indeed correct and bail out if not.

Cc: stable@vger.kernel.org
Signed-off-by: Marc Zyngier &lt;maz@kernel.org&gt;
Signed-off-by: Benjamin Tissoires &lt;benjamin.tissoires@gmail.com&gt;
</content>
</entry>
<entry>
<title>HID: core: increase HID report buffer size to 8KiB</title>
<updated>2020-02-12T13:18:33+00:00</updated>
<author>
<name>Johan Korsnes</name>
<email>jkorsnes@cisco.com</email>
</author>
<published>2020-01-17T12:08:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/starfive-tech/linux.git/commit/?id=84a4062632462c4320704fcdf8e99e89e94c0aba'/>
<id>urn:sha1:84a4062632462c4320704fcdf8e99e89e94c0aba</id>
<content type='text'>
We have a HID touch device that reports its opens and shorts test
results in HID buffers of size 8184 bytes. The maximum size of the HID
buffer is currently set to 4096 bytes, causing probe of this device to
fail. With this patch we increase the maximum size of the HID buffer to
8192 bytes, making device probe and acquisition of said buffers succeed.

Signed-off-by: Johan Korsnes &lt;jkorsnes@cisco.com&gt;
Cc: Alan Stern &lt;stern@rowland.harvard.edu&gt;
Cc: Armando Visconti &lt;armando.visconti@st.com&gt;
Cc: Jiri Kosina &lt;jkosina@suse.cz&gt;
Signed-off-by: Jiri Kosina &lt;jkosina@suse.cz&gt;
</content>
</entry>
</feed>
