Моя клавиатура не имеет драйвера Linux, может кто-нибудь сказать мне, что означают эти сообщения об ошибках?

624
Jonathan

Этот вопрос лучше задать на unix.stackexchange.com, но я задаю его здесь, потому что уверен, что у кого-то будет ответ.

У моего keybaord нет драйвера для Linux, и я пытаюсь написать его как способ изучения C. У меня есть книга, но хороший проект также полезен. Я действительно не знаю, как это сделать, но это вопрос для другого места и времени. Вопрос, который у меня сейчас есть, что означают следующие сообщения об ошибках?

Я получаю 54 из них при загрузке, каждый с различным номером в скобках.

[ 1.543402] hid-generic 0003:05C7:2012.0004: unknown main item tag 0x0

и тогда я получаю 1 из них:

[ 1.546827] hid-generic 0003:05C7:2012.0004: unbalanced collection at end of report description

и 1 из них:

[ 1.547479] hid-generic: probe of 0003:05C7:2012.0004 failed with error -22

Может кто-нибудь сказать мне, что это значит? Я точно знаю, что это моя клавиатура. Сообщения исчезают, когда я отключаю его.

1
Вы можете найти полезную информацию относительно ошибки зонда здесь: http://stackoverflow.com/questions/7199827/linux-usb-device-driver-not-getting-probed. В зависимости от вашего опыта программирования изучение C с помощью драйвера для Linux будет трудным. Я рекомендую изучить основы C в userland, а затем перейти к разработке драйверов. user5071535 8 лет назад 1

1 ответ на вопрос

1
MariusMatutiae

I apologize for spoiling your fun, but it does not sound like a good project. For one thing, there is this Launchpad bug report which sounds very similar to yours indeed. Second, there is a possible solution on the ever helpful Arch Linux wiki: it is recommended that you enable EHCI Hand-off in your BIOS settings.

If it is indeed a bug, or a misconfiguration of the BIOS settings, it is hardly a matter to be solved by writing a good driver. My personal inclination is that it is a matter of BIOS setting (will you let me know?) because this German fellow reports using exactly your generic keyboard without a hitch in 2006. He displays the output of

cat /proc/bus/input/devices ....... I: Bus=0003 Vendor=05c7 Product=2012 Version=0001 N: Name="Generic USB K/B" 

which is exactly your keyboard as reported by

[ 1.543402] hid-generic 0003:05C7:2012.0004: unknown main item tag 0x0 

As for the meaning of the error messages, I can help you only partially: hid-generic is a driver for HID-compatible peripherals. HID (=Human Interface Device) is a protocol for the specification of input/output devices assuring compatibility of components across different computers. You can find a good intro to HID here.

You were searching for an (advanced!) C project: you may then hunt down the error messages you find in the code of the hid-generic driver I referenced above. I am too lazy to do it myself.

Спасибо за совет. Я посмотрел в моем BIOS и не нашел эту опцию. Я собираюсь заняться поиском, но мне интересно, нет ли в моей биографии ASROCK такой возможности. Если нет, я могу жить с ошибками. Jonathan 8 лет назад 0

Похожие вопросы