Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
lspci displays my wifi card, but ifconfig does not
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
m_p_w
n00b
n00b


Joined: 12 Sep 2016
Posts: 31

PostPosted: Sat Aug 18, 2018 6:12 pm    Post subject: lspci displays my wifi card, but ifconfig does not Reply with quote

basically I am trying to set up the wpa_supplicant, but it cannot find a wireless interface.
Furthermore, the ifconfig does not find my wifi card, but lspci does. What am I doing wrong?
Additionally the kernel is configured as it is mentioned in the gentoo handbook/wiki when it comes to wifi
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54237
Location: 56N 3W

PostPosted: Sat Aug 18, 2018 6:39 pm    Post subject: Reply with quote

m_p_w,

Code:
ifconfig
only shows interfaces that are up.
Code:
ifconfig -a
shows all interfaces known to the kernel.

Which invocation are you using?

If the interface is not known to the kernel, its driver and possibly its firmware are not loaded.

Maybe you did make the kernel correctly and then messed up the install?
Look at the date/time in
Code:
uname -a
Thats the build date and time of the running kernel.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
m_p_w
n00b
n00b


Joined: 12 Sep 2016
Posts: 31

PostPosted: Sat Aug 18, 2018 7:20 pm    Post subject: Reply with quote

I did
Code:
ifconfig -a
and it appears that the kernel does not recognize the wifi's driver.
The kernel's menu shows that driver for my wifi's card is set up to <M> and the setting which are mentioned in gentoo.wiki/wifi are also set up in my kernel.
Additionally I did install the latest firmware with the command
Code:
emerge --ask sys-kernel/linux-firmware

and uname-a shows the date when I installed the system.


Do you have idea what I am doing wrong?
Back to top
View user's profile Send private message
Anon-E-moose
Watchman
Watchman


Joined: 23 May 2008
Posts: 6098
Location: Dallas area

PostPosted: Sat Aug 18, 2018 7:26 pm    Post subject: Reply with quote

what card? What does lspci say it is?
_________________
PRIME x570-pro, 3700x, 6.1 zen kernel
gcc 13, profile 17.0 (custom bare multilib), openrc, wayland
Back to top
View user's profile Send private message
m_p_w
n00b
n00b


Joined: 12 Sep 2016
Posts: 31

PostPosted: Sat Aug 18, 2018 7:29 pm    Post subject: Reply with quote

it is Qualcomm Atheros QCA9565 / AR9565, From my experience this card works very well on debian-distro family.
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54237
Location: 56N 3W

PostPosted: Sat Aug 18, 2018 7:33 pm    Post subject: Reply with quote

m_p_w,

When you install a new kernel, you need to mount /boot.
Look in /boot with it both unmounted and mounted.
If you don't have a separate boot, you can't have this problem.

When your kernel changes version, you need to tell the boot loader about it, or it will always load the old kernel.

What is the output of
Code:
uname -a

What is the output of
Code:
ls -l /usr/src/linux/x86/boot/bzImage


The first tells about the running kernel, the latter about the most recently built kernel, as long as your /usr/src/linux/ symlink is up to date.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
m_p_w
n00b
n00b


Joined: 12 Sep 2016
Posts: 31

PostPosted: Sat Aug 18, 2018 7:49 pm    Post subject: Reply with quote

I am not sure if it makes any difference on gentoo, but normally when I install debian or other distro based on debian, I do not create seperate /boot partition, and the same I did when I was installing gentoo.
The output of
Code:
uname -a
is 4.14.61-gentoo

when I type
Code:
ls -l /usr/src/linux/x86/boot/bzImag
I get that this directory does not exist, also I looked into it and I do not have directory x86 at all in /usr/src/linux/
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54237
Location: 56N 3W

PostPosted: Sat Aug 18, 2018 8:03 pm    Post subject: Reply with quote

m_p_w,

I wanted all of
Code:
uname -a
In particular, the time and date.

I messed up the kernel binary build location. I missed the /arch/ part.
Code:
ls -l /usr/src/linux/arch/x86/boot/bzImage

The idea is to compare the time stamps.

A separate /boot is not required. It narrows the problem space if you don't have one.

Can you put your /boot/grub/grub.cfg onto a pastebin site please?
Post
Code:
ls -l /boot
too.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
m_p_w
n00b
n00b


Joined: 12 Sep 2016
Posts: 31

PostPosted: Sat Aug 18, 2018 8:21 pm    Post subject: Reply with quote

Code:
uname -a

https://pastebin.com/FtRzFwbN

Code:
ls -l /boot

https://pastebin.com/STfbxZFA

/boot/grub/grub.cfg
https://pastebin.com/EJ3vLqE0

Code:
ls -l /usr/src/linux/arch/x86/boot/bzImage


I do not have bzImage in /usr/src/linux/arch/x86/boot/
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54237
Location: 56N 3W

PostPosted: Sat Aug 18, 2018 8:36 pm    Post subject: Reply with quote

m_p_w,

The good news is that your system is self consistent.
You only have a single kernel in /boot and in grub.cfg.

That you don't have a /usr/src/linux/arch/x86/boot/bzImage file suggests that the kernel build failed.
The file /boot/initramfs-genkernel-x86_64-4.14.61-gentoo tells that you use genkernel.
genkernel runs
Code:
make clean
at the start, which will remove all the binaries in the kernel tree, including bzImage, which is created at the end of the kernel build.
In /boot, its vmlinuz-4.14.61-gentoo.

Have you updated the kernel since
Code:
Wed Aug 15 07:03:22 CEST 2018

If so, the kernel failed to build.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
m_p_w
n00b
n00b


Joined: 12 Sep 2016
Posts: 31

PostPosted: Sat Aug 18, 2018 8:50 pm    Post subject: Reply with quote

is it possible to rebuild the kernel?
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54237
Location: 56N 3W

PostPosted: Sat Aug 18, 2018 9:36 pm    Post subject: Reply with quote

m_p_w,

Yes and you should do it once every x release in 4.x.y to keep up with security updates and if you have new hardware, performance improvements.

The process is the same as building the kernel the first time.
As you are a genkernel user, run
Code:
genkernel --menuconfig all

When you are dropped into the kernel menu system, make the changes to support your wifi.
Exit when you are finished and genkernel will build and install your new kernel.

If the build fails put the log onto a pastebin site.

If you are rebuilding 4.14.61 you are done. The new kernel will overwrite the old kernel.

If you build a different version you must update grub.cfg, so grub knows about it.
When this happens, you will get another kernel in the boot menu. Take care to choose the new one at boot time.

Its a good idea to have at least two kernels. Everyone builds a kernel that won't boot from time to time.
Its convenient to use the grub menu to have another go.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
m_p_w
n00b
n00b


Joined: 12 Sep 2016
Posts: 31

PostPosted: Sun Aug 19, 2018 11:58 am    Post subject: Reply with quote

ok I compiled kernel, but still config -a does not display my wifi :(
However, now lspci displays kernel module for the wifi card, but then by my understanding all drivers are modules, but not all modules are drivers :/


Do you know why the kernel driver is not being used?
Back to top
View user's profile Send private message
Anon-E-moose
Watchman
Watchman


Joined: 23 May 2008
Posts: 6098
Location: Dallas area

PostPosted: Sun Aug 19, 2018 12:25 pm    Post subject: Reply with quote

is the kernel module loaded, ie does "lsmod" show the module?

what does "dmesg|grep <module name>" show (use whatever the module is called for the grep part)
_________________
PRIME x570-pro, 3700x, 6.1 zen kernel
gcc 13, profile 17.0 (custom bare multilib), openrc, wayland
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54237
Location: 56N 3W

PostPosted: Sun Aug 19, 2018 12:28 pm    Post subject: Reply with quote

m_p_w,

Please put all of dmesg from booting your own kernel onto a pastebin site,
It sounds like your wifi may need firmware which is not being found.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
m_p_w
n00b
n00b


Joined: 12 Sep 2016
Posts: 31

PostPosted: Sun Aug 19, 2018 12:48 pm    Post subject: Reply with quote

the output of dmesg

https://pastebin.com/GM6yVW2U

when I run dmesg|grep ath9k then nothing is shown
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54237
Location: 56N 3W

PostPosted: Sun Aug 19, 2018 1:11 pm    Post subject: Reply with quote

m_p_w,

All those
Code:
version magic '4.14.61-gentoo SMP mod_unload modversions ' should be '4.14.61-gentoo SMP mod_unload
mean that something went wrong with your kernel build and install.
Some parts are compiled with modversions and some are not. The mix makes the parts incompatible.

This can happen if your clock takes a step back because make is lazy.
make looks at the timestamp of an output file, if its newer that all the input files, make does nothing. That usually saves time.

Have you seen any warnings about clock skew?
Are you using NTP to set your system time at boot?

Save your .config file out of the way. Its at /usr/src/linux/.config
Code:
cd /usr/src/linux/
make mrproper

That last step restores the kernel to its state as it was when it came out of the tarball.
Put the .config file back.

Now rebuild and reinstall your kernel.
The make mrproper step will force make to rebuild everything so its self consistent.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
m_p_w
n00b
n00b


Joined: 12 Sep 2016
Posts: 31

PostPosted: Sun Aug 19, 2018 2:13 pm    Post subject: Reply with quote

I am not using ntp, and I have not seen any warnings about clock skew
Back to top
View user's profile Send private message
Anon-E-moose
Watchman
Watchman


Joined: 23 May 2008
Posts: 6098
Location: Dallas area

PostPosted: Sun Aug 19, 2018 2:20 pm    Post subject: Reply with quote

m_p_w wrote:
I am not using ntp, and I have not seen any warnings about clock skew


Still worthwhile to clean it proper and rebuild it all.
If I make minor changes, I just do a make and let it rebuild the few things needed,
but if I make major changes, I like to clean it and rebuild it all.
Judging by the messages, something is out of whack.
_________________
PRIME x570-pro, 3700x, 6.1 zen kernel
gcc 13, profile 17.0 (custom bare multilib), openrc, wayland
Back to top
View user's profile Send private message
Jaglover
Watchman
Watchman


Joined: 29 May 2005
Posts: 8291
Location: Saint Amant, Acadiana

PostPosted: Sun Aug 19, 2018 2:24 pm    Post subject: Reply with quote

'clean' and 'proper' are make targets alright, 'make clean' removes all compiled parts and lets you start clean, 'make proper' restores your sources into pristine state, also removing your precious .config file.
_________________
My Gentoo installation notes.
Please learn how to denote units correctly!
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54237
Location: 56N 3W

PostPosted: Sun Aug 19, 2018 4:28 pm    Post subject: Reply with quote

Jaglover,

The .config is not that precious to genkernel users.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
m_p_w
n00b
n00b


Joined: 12 Sep 2016
Posts: 31

PostPosted: Sun Aug 19, 2018 6:14 pm    Post subject: Reply with quote

w8 a sec when I am building the kernel I get a message
>> Not installing firmware as requested by configuration FIRMWARE_INSTALL=no...

https://pastebin.com/Ygc6Jp2j

I think this is the reason why the driver is not used, what do you think?
Back to top
View user's profile Send private message
Anon-E-moose
Watchman
Watchman


Joined: 23 May 2008
Posts: 6098
Location: Dallas area

PostPosted: Sun Aug 19, 2018 6:24 pm    Post subject: Reply with quote

I don't install firmware when I compile my kernel, especially on those things that I compile as modules, they install when loaded.
_________________
PRIME x570-pro, 3700x, 6.1 zen kernel
gcc 13, profile 17.0 (custom bare multilib), openrc, wayland
Back to top
View user's profile Send private message
m_p_w
n00b
n00b


Joined: 12 Sep 2016
Posts: 31

PostPosted: Sun Aug 19, 2018 6:27 pm    Post subject: Reply with quote

Then I really don't know what I am doing wrong :(
Back to top
View user's profile Send private message
NeddySeagoon
Administrator
Administrator


Joined: 05 Jul 2003
Posts: 54237
Location: 56N 3W

PostPosted: Sun Aug 19, 2018 6:29 pm    Post subject: Reply with quote

m_p_w,

That looks good so far. Now rewrite grub.cfg.
It should not be needed but you don't want an old initrd being used with your new kernel.

Code:
Not installing firmware as requested by configuration FIRMWARE_INSTALL=no...
is probably harmless.
Firmware is provided in two ways. Embedded in the kernel source and external to kernel firmware, in sys-kernel/linux-firmware and friends.

I think that FIRMWARE_INSTALL=no refers to firmware embedded in the kernel source and that's not where WiFi firmware is usually found.

Reboot into your new kernel and initrd using your new grub.cfg then pasetbin dmesg.
That will show us what's going on.
_________________
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum