Linux From Scratch This Forum is for the discussion of LFS.
LFS is a project that provides you with the steps necessary to build your own custom Linux system. |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
 |
05-12-2007, 10:02 PM
|
#1
|
LQ Newbie
Registered: Jun 2004
Location: Colorado, USA
Distribution: LFS 6.2
Posts: 25
Rep:
|
NIC Driver Installation Problems
Hi all,
I have a relatively clean build of LFS for which I'm working on installing some BLFS packages (I've done Emacs and Lynx so far...) I am trying to install drivers for my network card (a Realtek RTL8168/8111). When I attempt to do a "make modules" as described in the driver documentation, I get the following error and standard output:
Quote:
make -C src/ modules
make[1]: Entering directory `/usr/src/r1000_v1.05/src'
make -C /lib/modules/2.6.16.27/build SUBDIRS=/usr/src/r1000_v1.05/src modules
make[2]: Entering directory `/sources/linux-2.6.16.27'
WARNING: Symbol version dump /sources/linux-2.6.16.27/Module.symvers
is missing; modules will have no dependencies and modversions.
CC [M] /usr/src/r1000_v1.05/src/r1000_n.o
In file included from include/linux/module.h:10,
from /usr/src/r1000_v1.05/src/r1000.h:1,
from /usr/src/r1000_v1.05/src/r1000_n.c:5:
include/linux/sched.h:4:36: error: asm/param.h: No such file or directory
In file included from include/linux/types.h:15,
from include/linux/capability.h:16,
from include/linux/sched.h:7,
from include/linux/module.h:10,
from /usr/src/r1000_v1.05/src/r1000.h:1,
from /usr/src/r1000_v1.05/src/r1000_n.c:5:
include/linux/posix_types.h:47:29: error: asm/posix_types.h: No such file or directory
In file included from include/linux/capability.h:16,
from include/linux/sched.h:7,
from include/linux/module.h:10,
from /usr/src/r1000_v1.05/src/r1000.h:1,
from /usr/src/r1000_v1.05/src/r1000_n.c:5:
include/linux/types.h:16:23: error: asm/types.h: No such file or directory
In file included from include/linux/capability.h:16,
from include/linux/sched.h:7,
from include/linux/module.h:10,
from /usr/src/r1000_v1.05/src/r1000.h:1,
from /usr/src/r1000_v1.05/src/r1000_n.c:5:
include/linux/types.h:20: error: syntax error before '__kernel_dev_t'
include/linux/types.h:20: warning: type defaults to 'int' in declaration of '__kernel_dev_t'
include/linux/types.h:20: warning: data definition has no type or storage class
include/linux/types.h:23: error: syntax error before 'dev_t'
include/linux/types.h:23: warning: type defaults to 'int' in declaration of 'dev_t'
include/linux/types.h:23: warning: data definition has no type or storage class
include/linux/types.h:24: error: syntax error before 'ino_t'
include/linux/types.h:24: warning: type defaults to 'int' in declaration of 'ino_t'
include/linux/types.h:24: warning: data definition has no type or storage class
include/linux/types.h:25: error: syntax error before 'mode_t'
include/linux/types.h:25: warning: type defaults to 'int' in declaration of 'mode_t'
include/linux/types.h:25: warning: data definition has no type or storage class
include/linux/types.h:26: error: syntax error before 'nlink_t'
include/linux/types.h:26: warning: type defaults to 'int' in declaration of 'nlink_t'
include/linux/types.h:26: warning: data definition has no type or storage class
include/linux/types.h:27: error: syntax error before 'off_t'
include/linux/types.h:27: warning: type defaults to 'int' in declaration of 'off_t'
/usr/src/r1000_v1.05/src/r1000_n.c:1698: error: invalid type argument of '->'
/usr/src/r1000_v1.05/src/r1000_n.c:1698: error: 'TIF_NEED_RESCHED' undeclared (first use in this function)
/usr/src/r1000_v1.05/src/r1000_n.c:1698: warning: passing argument 1 of 'test_ti_thread_flag' makes pointer from integer without a cast
/usr/src/r1000_v1.05/src/r1000_n.c:1698: error: dereferencing pointer to incomplete type
/usr/src/r1000_v1.05/src/r1000_n.c: In function 'r1000_get_stats':
/usr/src/r1000_v1.05/src/r1000_n.c:1705: error: dereferencing pointer to incomplete type
/usr/src/r1000_v1.05/src/r1000_n.c:1707: error: dereferencing pointer to incomplete type
... (lots more stuff like that) ...
make[3]: *** [/usr/src/r1000_v1.05/src/r1000_n.o] Error 1
make[2]: *** [_module_/usr/src/r1000_v1.05/src] Error 2
make[2]: Leaving directory `/sources/linux-2.6.16.27'
make[1]: *** [modules] Error 2
make[1]: Leaving directory `/usr/src/r1000_v1.05/src'
make: *** [modules] Error 2
|
Looking around at other mentions of files like param.h, it looks like my kernel headers might not be installed correctly. Does this sound right, and if so, how can I go about repairing this? Thanks in advance.
|
|
|
05-12-2007, 11:10 PM
|
#2
|
LQ Newbie
Registered: Jun 2004
Location: Colorado, USA
Distribution: LFS 6.2
Posts: 25
Original Poster
Rep:
|
As a follow-up to this, I tried patching and re-copying the kernel headers package according to the directions in the book, but I still get the same errors... Any ideas? :-/
|
|
|
05-12-2007, 11:19 PM
|
#3
|
Member
Registered: Aug 2003
Location: Minnesota, U.S.A.
Distribution: Debian, openSUSE
Posts: 400
Rep:
|
There's an in-kernel driver for that card, why not just compile your kernel with that either built as a module or built in? Does the externally provided Realtek driver offer some additional functionality?
|
|
|
05-12-2007, 11:29 PM
|
#4
|
LQ Newbie
Registered: Jun 2004
Location: Colorado, USA
Distribution: LFS 6.2
Posts: 25
Original Poster
Rep:
|
Hmmm, well the answer to your "why not" question is ... I'm a Linux noob, lol. O.o I didn't realize it was supported by the kernel. So, I can just re-enable it in the kernel config and recompile the kernel? If that's the case, why would Realtek offer this driver at all? Thanks in advance...
PS: Even tho it may not be necessary, I'd be curious as to why this is failing; I would imagine other third-party software will encounter these problems if my kernel headers aren't accessible, unless the driver makefile is just poorly written...
|
|
|
05-13-2007, 12:48 AM
|
#5
|
LQ Newbie
Registered: Jun 2004
Location: Colorado, USA
Distribution: LFS 6.2
Posts: 25
Original Poster
Rep:
|
I tried re-compiling the kernel with the appropriate driver, and unless I did something wrong there, it still seems to not recognize the card (it's compiled in directly, not as a module). I put in PCI Utils and did an lspci, and I see the card on that list, so at least that's a good sign...any other ideas? I saw somewhere that the kernel support might only work for this card after 2.6.19 kernels or so (and I'm running 2.6.17); I assume in that case I'd have to install the drivers straight from Realtek, which would bring us back to the previous problem. Any ideas? Thanks in advance.
|
|
|
05-13-2007, 12:51 AM
|
#6
|
LQ Newbie
Registered: Jun 2004
Location: Colorado, USA
Distribution: LFS 6.2
Posts: 25
Original Poster
Rep:
|
If I'm reading it properly, this seems to suggest support wasn't in until at least 2.6.19...
https://bugs.launchpad.net/ubuntu/+s....17/+bug/63314
|
|
|
05-14-2007, 11:09 AM
|
#7
|
LQ Newbie
Registered: Jun 2004
Location: Colorado, USA
Distribution: LFS 6.2
Posts: 25
Original Poster
Rep:
|
So I've messed around with this quite a bit; did a *lot* of kernel upgrades (and downgrades) and worked through some issues where my hard drive wasn't getting recognized during boot (apparently because of the new "libsata" package or whatnot). Anyway...I'm currently at 2.6.22-rc1 and 2.6.21.1, and in both these cases my network card *is* recognized, but it always says "r8169: eth0: link down", and it looks like others have had similar problems with this NIC. I haven't seen mention of anyone fixing this problem while using the in-kernel drivers, but it looks like the ones from Realtek should work, so I'd be especially thankful if anyone could explain to me why the installation described above fails. If I can install the Realtek drivers then I can probably even just go back to the old kernel if I like, but in either case it sounds like the built-in driver is not reliable (at least for the RTL8168). Thanks very much in advance!
*edit* Here's the page where I saw mention of the Realtek driver fixing the problem...
http://linux-on-laptops.com/forum/showthread.php?t=265
Last edited by MailleMan; 05-14-2007 at 11:13 AM.
|
|
|
05-16-2007, 07:49 AM
|
#8
|
LQ Newbie
Registered: Jun 2004
Location: Colorado, USA
Distribution: LFS 6.2
Posts: 25
Original Poster
Rep:
|
So thanks to the LFS support list, I was informed that I'm simply missing my kernel source tree. After making it available and fixing a problem with the driver source code, I got it compiled and the kernel recognizes my card. However, it seems that I can't receive packets or that the connection isn't recognized (DHCP times out). Here is my output from "ifconfig eth0":
eth0 Link encap:Ethernet HWaddr XX:XX:XX:XX:XX:XX
BROADCAST MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:2 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 b) TX bytes:1180 (1.1 Kb)
Interrupt:18 Base address:0x3000
Anyone have any ideas as to what could be wrong? Thanks in advance.
|
|
|
All times are GMT -5. The time now is 12:10 PM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|