Bug 204837

Summary: hid-sensor-hub bug filling up logs
Product: Drivers Reporter: dovla091
Component: OtherAssignee: drivers_other
Status: NEW ---    
Severity: high CC: dovla091, linuxkernel
Priority: P1 Keywords: trivial
Hardware: x86-64   
OS: Linux   
Kernel Version: 5.2.13 Subsystem:
Regression: No Bisected commit-id:
Attachments: dmesg log

Description dovla091 2019-09-13 15:00:18 UTC
Created attachment 284947 [details]
dmesg log

Hi

This affects all users having HP Spectre x360 model, with kernel version from 4.19 to 5.3 RC

Recently I have installed Fedora 30 on my HP Spectre x360 Laptop and found out that our logs are flooded with message:

hid-sensor-hub 001F:8087:0AC2.0003: hid_field_extract() called with n (192) > 32!

I also install for a test Fedora 31, as it is running newest kernel version, to see if this was fixed, but still I got the same output... Since I am not a developer but mere mortal, I need to ask, is it possible to fix this bug as it present since kernel version 4.19 and is making lot of issues to all of us that have Spectre laptop (not only Fedora but other distributions using kernel version higher the 4.19). As the result of that bug, system is generating insane amount of data into /var/log/message, and when I meant insane, its probably around tens of messages within a single second, so the logs grow to couple of GB within a day.

By doing a research I have found that another developer had the same issue as me, and he provided some sort of a bypass by patching hid-core.c in the drivers/hid folder and hid.h in the library/linux

Please refer to the link below:

https://patchwork.kernel.org/patch/11052949

and

https://patchwork.kernel.org/patch/11052951


If it is not a problem, can you please patch this bug and put it into a newer kernel version 5.3 kernel which will be released soon? At this point, our PC is quite unusable, as the logs are being filled up quickly, and not being able to have larger disk space we are forced to write a script to delete logs every day...
Comment 1 AO 2019-11-26 19:39:01 UTC
Yesterday (2019-11-25) I installed the recommended BIOS updates from HP on a HP x360 Zbook.

Now I am getting this exact same problem with KUbuntu 19.10 running "Linux ao-x360 5.3.0-23-generic #25-Ubuntu SMP Tue Nov 12 09:22:33 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux"

I just did a quick "ls -l" comparison over time and the system is writing about 308kB/min (5kB/sec) to syslog and kern.log. Or, in an hour, the two files increase in size about 20 MB each. 

The message is

kernel: [ 1627.620171] hid-sensor-hub 001F:8087:0AC2.0003: hid_field_extract() called with n (192) > 32! (kworker/3:2)


I'm concerned that this is going to rapidly degrade the hard drives in the system.
Comment 2 AO 2019-11-26 22:34:43 UTC
(In reply to dovla091 from comment #0)

> 
> At this point,
> our PC is quite unusable, as the logs are being filled up quickly, and not
> being able to have larger disk space we are forced to write a script to
> delete logs every day...

dovla091, 

You can stop these messages by modifying your system to not log these messages.  For example, if you have rsyslog and the directory /etc/rsyslog.d/

Then you can create the file:  

/etc/rsyslog.d/10-hidsensor.conf

with content: 

#Disable runaway messages: 
:msg, contains, "hid-sensor-hub 001F:8087:0AC2.0003: hid_field_extract() called with n (192) > 32!" stop


And once that file exists, when you restart rsyslog (e.g. sudo system rsyslog restart) the messages will no longer hit your logs.