Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gentoo Kernel 4.4.6 - modprobe fails to load mt7630e module (missing CRC-CCITT routine) #27

Open
AndyMender opened this issue May 17, 2016 · 4 comments

Comments

@AndyMender
Copy link

AndyMender commented May 17, 2016

I was trying to install the Mediatek mt7630e driver from this GItHub repository, though it seems to be impossible on my Asus S301A with the most recent Gentoo kernel 4.4.6.

The kernel modules 7630e and 76xx build fine, though modprobe fails while loading the mt7630e module with a crc_ccitt error printed several times by dmesg. I haven't encountered this problem some months ago on Manjaro Linux. Point in case, I used the manual install, since Gentoo doesn't utilize dkms.

EDIT: The kernel was missing the CRC-CCITT Library routine, needed for the mt7630e module to load completely. When either compiled into the kernel or as an additional module called crc_ccitt, mt7630e was loaded properly. I assume CRC-CCITT is enabled in most common kernels, though as this is a rather old routine, one might add it to the list of required kernel parameters or external modules :).

@AndyMender AndyMender changed the title Gentoo Kernel 4.4.6 - modprobe fails to load mt7630e module Gentoo Kernel 4.4.6 - modprobe fails to load mt7630e module (missing CRC-CCITT routine) May 17, 2016
@neurobin
Copy link
Owner

Seems like you solved it. It would be great if you posted your solutions here (both). That would help others having the same problem...

Regards,
Jahid

@AndyMender
Copy link
Author

AndyMender commented May 28, 2016

Unfortunately, this only solves loading of the module. Creating a connection is still impossible as another error pops up: crc RXD_W3_CIPHER_ERROR. Once this is solved and I can actually connect, I will submit a proper patch :).

Per 'crc RXD_W3_CIPHER_ERROR' I tried enabling every possible Cryptographic algorithm in the Linux kernel with no success. The source code is not very specific what this error means.

EDIT:
I finally managed to pinpoint the missing kernel features!
The Mediatek mt7630e wireless NIC driver you are currently maintaining provides the following kernel modules:

mt7630e
mt76xx
In order for mt7630e to properly attach to the NIC, 2 kernel features are mandatory:
crc_ccitt (for the module to attach at all)
eeprom_93xc6 (for the module to gover authorization without errors)
The above features can be found in the kernel tree via the following branches:
Device Drivers> Misc devices>EEPROM support>EEPROM 93CX6 support
Library routines>CRC-CCITT functions (though all 'crc' related library routines may be required)
After having those 2 features and compiling the mt7630e driver properly, 'lsmod' should report the following (or something similar):
Module Size Used by
mt7630e 156040 0
mt76xx 9536 0
crc_ccitt 1531 1 mt7630e
eeprom_93cx6 2715 1 mt7630e
x86_pkg_temp_thermal 5061 0
crc32_pclmul 2803 0
crc32c_intel 13062 0
shpchp 23762 0

I strongly recommend adding this to the documentation for this repository. Also, the issue can be closed at this point.

@dakk
Copy link
Contributor

dakk commented Feb 17, 2017

Same problem here; I was using the driver on gentoo with a debian-sources kernel and was working fine. Then I switched to a manually configured kernel and the module works fine with compiling the kernel EEPROM and CRC-CCITT.
I tested the solution from Andy in 4.8.15-1 and 4.9.10

@dakk
Copy link
Contributor

dakk commented Jan 8, 2018

Update: in gentoo (and funtoo) the default genkernel configuration build all needed modules

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants