From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932586AbbI3MHs (ORCPT ); Wed, 30 Sep 2015 08:07:48 -0400 Received: from mail-io0-f181.google.com ([209.85.223.181]:35736 "EHLO mail-io0-f181.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932292AbbI3MHn (ORCPT ); Wed, 30 Sep 2015 08:07:43 -0400 Subject: Re: Problems with printk logs and my driver To: Eric Curtin References: <56056C22.7050807@gmail.com> Cc: Jiri Kosina , Felipe Tonello , Alan Stern , USB list , Kernel development list From: Austin S Hemmelgarn Message-ID: <560BD068.1010104@gmail.com> Date: Wed, 30 Sep 2015 08:07:04 -0400 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.2.0 MIME-Version: 1.0 In-Reply-To: Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg=sha-512; boundary="------------ms080500020204070305010904" X-Antivirus: avast! (VPS 150929-1, 2015-09-29), Outbound message X-Antivirus-Status: Clean Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This is a cryptographically signed message in MIME format. --------------ms080500020204070305010904 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: quoted-printable On 2015-09-29 18:11, Eric Curtin wrote: > On 25 September 2015 at 16:45, Austin S Hemmelgarn wrote: >> On 2015-09-25 08:02, Jiri Kosina wrote: >>> >>> On Fri, 25 Sep 2015, Felipe Tonello wrote: >>> >>>> Maybe a better description on Kconfig and/or comments on source code= >>>> it's enough. >>> >>> >>> I personally find the current Kconfig description: >>> >>> =3D=3D=3D >>> config USB_KBD >>> tristate "USB HIDBP Keyboard (simple Boot) support" >>> depends on USB && INPUT >>> ---help--- >>> Say Y here only if you are absolutely sure that you don't= want >>> to use the generic HID driver for your USB keyboard and p= refer >>> to use the keyboard in its limited Boot Protocol mode ins= tead. >>> >>> This is almost certainly not what you want. This is most= ly >>> useful for embedded applications or simple keyboards. >>> >>> To compile this driver as a module, choose M here: the >>> module will be called usbkbd. >>> >>> If even remotely unsure, say N. >>> =3D=3D=3D >>> >>> shouldn't leave anyone dounting, but people are getting confused agai= n and >>> again nevertheless. >>> >> For some reason there seem to be a lot of people who go to configure t= here >> own kernel and don't read the help text (I understand if you've been >> building your own Linux kernel's for years and actually understand wha= t a >> Kconfig option is really asking, but most people who I've heard of doi= ng >> this have never built a kernel before in their life). >> >> On the other hand, can anyone think of any real reason to use this out= side >> of embedded systems? I know there are a lot of distros that build thi= s and >> the USB HIDBP mouse support as modules, but I have yet to hear/find an= y >> reports of hardware that _only_ works with this driver and not the gen= eric >> HID driver. If this is the case, it might make sense to make this dep= end on >> EXPERT or at least remove the bit about 'simple keyboards'. >> > > As regards renaming usbkbd.c, @Austin there are some reasons why you wo= uld > not read the Kconfig. As a beginner, I didn't even configure this part = or > read the help text as I used the configuration that comes with Fedora, = I > don't know if that's a valid excuse or not though. I'll leave you guys > decide, you're the experts! > > As regards the issue with my capslock led I'm still looking into it. > Personally, I would not ever advocate not reading the help text for an=20 option (although in some cases it's pretty un-helpful, especially for=20 some staging drivers). Your case is one of the common ones, and it's not a bad place to start,=20 but you have to keep in mind that most distro's turn on a huge amount of = stuff that more than 90% of people aren't ever going to need (for=20 example, I'm pretty sure Ubuntu still builds a module for SLIP, which=20 has been an essentially dead technology for more than a decade now).=20 For anyone starting from a distro's kconfig, I'd suggest at least: a. Turn off CONFIG_EXPERT unless you intend to actually try and=20 understand the options it enables (most distro's turn this on for some=20 of the fine tuning features it enables, most regular people don't=20 actually need it). b. Go through using menuconfig, and turn off stuff under the drivers=20 menu that you know you will never need (and take the time to use stuff=20 like lspci and lsusb to figure out what actually need). c. Read the help text before trying to change anything, and if you don't = understand it after that, look it up online, and even then be careful=20 changing it. d. If you intend on actually using it with a particular distro, don't=20 turn off too much outside of the drivers menu, other stuff can cause=20 things to fail in unusual ways, and you often won't get a great amount=20 of help from the distro maintainers when using a custom kernel. The real problem is when people just read the option name and think they = understand it when they don't really (or just don't think about the=20 implications), and then wonder why something stops working suddenly=20 (like one guy I know who was building a kernel for a server, and thought = he could just disable everything under the 'Graphics' menu, then=20 wondered why he didn't get console output on his monitor). --------------ms080500020204070305010904 Content-Type: application/pkcs7-signature; name="smime.p7s" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="smime.p7s" Content-Description: S/MIME Cryptographic Signature MIAGCSqGSIb3DQEHAqCAMIACAQExDzANBglghkgBZQMEAgMFADCABgkqhkiG9w0BBwEAAKCC Brgwgga0MIIEnKADAgECAgMRLfgwDQYJKoZIhvcNAQENBQAweTEQMA4GA1UEChMHUm9vdCBD QTEeMBwGA1UECxMVaHR0cDovL3d3dy5jYWNlcnQub3JnMSIwIAYDVQQDExlDQSBDZXJ0IFNp Z25pbmcgQXV0aG9yaXR5MSEwHwYJKoZIhvcNAQkBFhJzdXBwb3J0QGNhY2VydC5vcmcwHhcN MTUwOTIxMTEzNTEzWhcNMTYwMzE5MTEzNTEzWjBjMRgwFgYDVQQDEw9DQWNlcnQgV29UIFVz ZXIxIzAhBgkqhkiG9w0BCQEWFGFoZmVycm9pbjdAZ21haWwuY29tMSIwIAYJKoZIhvcNAQkB FhNhaGVtbWVsZ0BvaGlvZ3QuY29tMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEA nQ/81tq0QBQi5w316VsVNfjg6kVVIMx760TuwA1MUaNQgQ3NyUl+UyFtjhpkNwwChjgAqfGd LIMTHAdObcwGfzO5uI2o1a8MHVQna8FRsU3QGouysIOGQlX8jFYXMKPEdnlt0GoQcd+BtESr pivbGWUEkPs1CwM6WOrs+09bAJP3qzKIr0VxervFrzrC5Dg9Rf18r9WXHElBuWHg4GYHNJ2V Ab8iKc10h44FnqxZK8RDN8ts/xX93i9bIBmHnFfyNRfiOUtNVeynJbf6kVtdHP+CRBkXCNRZ qyQT7gbTGD24P92PS2UTmDfplSBcWcTn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