Re: [gentoo-user] binary packages: how to ...

2020-07-14 Thread Andreas Fink
On Wed, 15 Jul 2020 00:46:58 +0100
Ashley Dixon  wrote:

> On Tue, Jul 14, 2020 at 11:24:31PM +0200, n952162 wrote:
> > binary packages: how to:
> >
> > 1. find out if a package is binary before you install it (e.g. where on
> >app-arch/rar does it say it's a binary package)
>
> RAR is an unusual case, with both the "mirror" and "bindist" flags  set  in  
> the
> RESTRICT variable (i.e., Gentoo cannot legally mirror the  package,  and  
> you're
> not allowed to redistribute binaries either).  I couldn't find anything  in  
> the
> ebuild which suggests it is a binary package; perhaps  this  is  something  
> that
> should be reviewed by the Gentoo  developers,  as  most  packages  supporting 
>  a
> binary distribution provide a separate package with the `-bin` suffix, 
> although
> I suppose this doesn't make much sense when there is no source package.
>
> The entire RAR business model of free decompression  and  paid  compression  
> has
> caused confusion for many people over many decades.  I'd always stick to 7zip 
> or
> one of the classic UNIX compression utilities, if I had a choice.
>
> > 2. inhibit their installation
>
> Don't install them. ;-)
>
> More seriously: there's not that many of them, so it's probably  not  a  
> process
> worth automating, unless you're on a  multi-user  machine,  in  which  
> untrusted
> users can install packages -  although  I  think  you'd  have  more  
> significant
> problems at that point.  As you've unfortunately discovered, there isn't much 
> of
> a concrete framework in place to automatically  detect  binary  packages,  
> which
> also makes Point (3) difficult.
>
> > 3. get a list of the ones installed on a system
>
> `EIX_LIMIT=0 eix --only-names -I *-bin`, perhaps ?   Unfortunately,  this  
> won't
> catch the unusual cases, as seen with `app-arch/rar`.
>
> > Any ideas about that are appreciated.
>
> [1] might be worth a read; it's quite comprehensive, and  gives  you  a  
> glimpse
> into the inner-workings of Portage, allowing you to fix these  issues  
> yourself.
>
> Something to note: "bindist", as the USE-flag and RESTRICT option, does not 
> mean
> "use a binary distribution", but rather "compile the package in such a way  
> that
> I can redistribute my build without putting myself in a legal problem  with  
> the
> package authors" (this commonly is synonymous with disabling official 
> branding):
>
> $ ash-euses -sk bindist
>
> dev-libs/openssl:bindist - Disable/Restrict EC algorithms (as they seem to be 
> patented) -- note: changes the ABI
> dev-libs/openssl-compat:bindist - Disable/Restrict EC algorithms (as they 
> seem to be patented) -- note: changes the ABI
> dev-qt/qtnetwork:bindist - Disable EC support via dev-libs/openssl
> mail-client/thunderbird:bindist - Disable official Firefox/Thunderbird 
> branding (icons, name) which are not binary-redistributable according to 
> upstream.
> media-libs/freetype:bindist - Disable ClearType support (see 
> http://freetype.org/patents.html)
> net-libs/liboauth:bindist - Alias for the nss USE flag, since there are 
> license compliancy trouble when using OpenSSL.
> net-misc/openssh:bindist - Disable EC/RC5 algorithms in OpenSSL for patent 
> reasons.
> sys-apps/ucspi-ssl:bindist - Disable EC/RC5 algorithms in OpenSSL for patent 
> reasons.
> www-client/firefox:bindist - Disable official Firefox branding (icons, name) 
> which are not binary-redistributable according to upstream.
>
> Hope this helps,
> Ashley.
>
> [1] https://wiki.gentoo.org/wiki/Binary_package_guide
>
Searching for -bin does not help to find binary only packages. Two more
examples, which are binary only:
zoom, skypeforlinux

Searching for -bin mostly (if not always) implies that there would be a
possibility to compile it from source.

In my experience so far, every binary-only package does not have an open
source license. So mostly you'll hit a license issue and you have to
accept the license (/etc/portage/package.license) before you will be
able to merge the package. Any license issue should start make you
thinking what is going on, since it is a potential binary-only package.
Installation of these packages is inhibited by emerge, because you have
to accept the license first ;)
When I look into my /etc/portage/package.license file I get a good idea
of which packages are binary only. Not all of them are pure binary
packages, but it is a superset as far as I can tell.

To conclude: You cannot find out if a package is binary only with
emerge. You have to do the research yourself, but
/etc/portage/package.license is a good starting point to find potential
candidates.

Cheers
Andreas




Re: [gentoo-user] binary packages: how to ...

2020-07-14 Thread Ashley Dixon
On Tue, Jul 14, 2020 at 11:24:31PM +0200, n952162 wrote:
> binary packages: how to:
> 
> 1. find out if a package is binary before you install it (e.g. where on
>app-arch/rar does it say it's a binary package)

RAR is an unusual case, with both the "mirror" and "bindist" flags  set  in  the
RESTRICT variable (i.e., Gentoo cannot legally mirror the  package,  and  you're
not allowed to redistribute binaries either).  I couldn't find anything  in  the
ebuild which suggests it is a binary package; perhaps  this  is  something  that
should be reviewed by the Gentoo  developers,  as  most  packages  supporting  a
binary distribution provide a separate package with the `-bin` suffix, although
I suppose this doesn't make much sense when there is no source package.

The entire RAR business model of free decompression  and  paid  compression  has
caused confusion for many people over many decades.  I'd always stick to 7zip or
one of the classic UNIX compression utilities, if I had a choice.

> 2. inhibit their installation

Don't install them. ;-)

More seriously: there's not that many of them, so it's probably  not  a  process
worth automating, unless you're on a  multi-user  machine,  in  which  untrusted
users can install packages -  although  I  think  you'd  have  more  significant
problems at that point.  As you've unfortunately discovered, there isn't much of
a concrete framework in place to automatically  detect  binary  packages,  which
also makes Point (3) difficult.

> 3. get a list of the ones installed on a system

`EIX_LIMIT=0 eix --only-names -I *-bin`, perhaps ?   Unfortunately,  this  won't
catch the unusual cases, as seen with `app-arch/rar`.

> Any ideas about that are appreciated.

[1] might be worth a read; it's quite comprehensive, and  gives  you  a  glimpse
into the inner-workings of Portage, allowing you to fix these  issues  yourself.

Something to note: "bindist", as the USE-flag and RESTRICT option, does not mean
"use a binary distribution", but rather "compile the package in such a way  that
I can redistribute my build without putting myself in a legal problem  with  the
package authors" (this commonly is synonymous with disabling official branding):

$ ash-euses -sk bindist

dev-libs/openssl:bindist - Disable/Restrict EC algorithms (as they seem to be 
patented) -- note: changes the ABI
dev-libs/openssl-compat:bindist - Disable/Restrict EC algorithms (as they seem 
to be patented) -- note: changes the ABI
dev-qt/qtnetwork:bindist - Disable EC support via dev-libs/openssl
mail-client/thunderbird:bindist - Disable official Firefox/Thunderbird branding 
(icons, name) which are not binary-redistributable according to upstream.
media-libs/freetype:bindist - Disable ClearType support (see 
http://freetype.org/patents.html)
net-libs/liboauth:bindist - Alias for the nss USE flag, since there are license 
compliancy trouble when using OpenSSL.
net-misc/openssh:bindist - Disable EC/RC5 algorithms in OpenSSL for patent 
reasons.
sys-apps/ucspi-ssl:bindist - Disable EC/RC5 algorithms in OpenSSL for patent 
reasons.
www-client/firefox:bindist - Disable official Firefox branding (icons, name) 
which are not binary-redistributable according to upstream.

Hope this helps,
Ashley.

[1] https://wiki.gentoo.org/wiki/Binary_package_guide

-- 

Ashley Dixon
suugaku.co.uk

2A9A 4117
DA96 D18A
8A7B B0D2
A30E BF25
F290 A8AA



signature.asc
Description: PGP signature


[gentoo-user] binary packages: how to ...

2020-07-14 Thread n952162

binary packages: how to:

1. find out if a package is binary before you install it (e.g. where on
   app-arch/rar does it say it's a binary package)
2. inhibit their installation
3. get a list of the ones installed on a system

Any ideas about that are appreciated.


[gentoo-user] ebuild is trying to download a tarball instead of using git

2020-07-14 Thread Jack
I want to try some changes to an ebuild in the dotnet overlay.  So, I  
copied /var/lib/layman/dotnet/dev-lang/mono/mono-.ebuild into  
/usr/local/portage/dev-lang/mono.  I cd into that directory, and run  
"ebuild mono-.ebuild manifest" and it fails because it tries to  
download mono-.tar.bz2, which obviously doesn't exist anywhere.   
There is no SRC_URI in the ebuild, just  
"EGIT_REPO_URI="git://github.com/mono/${PN}.git".  Also, I notice there  
is no Manifest file (or no DIST line) for any  ebuild - and that  
seems true in the main tree and also overlays.  Trying "ebuild  
mono-.ebuild prepare" complains that the digest is missing.  So  
does "emerge mono-.ebuild" although it complains that a file (the  
ebuild itself) is not listed in the manifest.


So - if a manifest entry is not needed for a live/ ebuild, why is  
portage (ebuild or emerge) failing to work without one, and why is it  
trying to download a tarball, even without any SRC_URI in the ebuild?


Jack



[gentoo-user] [SOLVED] No wifi

2020-07-14 Thread Walter Dnes
On Tue, Jul 14, 2020 at 01:20:39PM -0400, Walter Dnes wrote
> 
>   Still no wireless, but one bit of progress.  It seems that the kernel
> does *NOT* like using subdirectories below /lib/firmware.  I copied the
> ucode file to /lib/firmware and changed the path appropriately before
> building the kernel.  Now dmesg at bootup shows...
> 
> [0.757370] Intel(R) Wireless WiFi driver for Linux
> [0.757372] Copyright(c) 2003- 2015 Intel Corporation
> [0.757478] iwlwifi :03:00.0: can't disable ASPM; OS doesn't have ASPM 
> control
> [0.757877] iwlwifi :03:00.0: loaded firmware version 8.83.5.1 build 
> 33692 op_mode iwldvm
> [0.757963] iwlwifi :03:00.0: CONFIG_IWLWIFI_DEBUG disabled
> [0.757967] iwlwifi :03:00.0: CONFIG_IWLWIFI_DEBUGFS disabled
> [0.757970] iwlwifi :03:00.0: CONFIG_IWLWIFI_DEVICE_TRACING disabled
> [0.757973] iwlwifi :03:00.0: Detected Intel(R) WiFi Link 5100 AGN, 
> REV=0x54
> [0.761128] [drm] HPD interrupt storm detected on connector DP-3: 
> switching from hotplug detection to polling
> [0.762028] fbcon: i915drmfb (fb0) is primary device
> [0.795312] ieee80211 phy0: Selected rate control algorithm 'iwl-agn-rs'

  Guess what I was missing... "ifconfig" versus "ifconfig -a".  One is
not like the other.  I feel stupid.  I may be back with more questions.
https://wiki.gentoo.org/wiki/Handbook:X86/Networking/Wireless looks
rather intimidating, but wpa_supplicant seems to be the only choice.

[thimk][root][~] ifconfig 
eth0: flags=4163  mtu 1500
inet 192.168.1.2  netmask 255.255.255.0  broadcast 192.168.1.255
ether 00:27:13:64:6a:0d  txqueuelen 1000  (Ethernet)
RX packets 51929  bytes 3348657 (3.1 MiB)
RX errors 0  dropped 0  overruns 0  frame 0
TX packets 426  bytes 79801 (77.9 KiB)
TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
device interrupt 20  memory 0xfc00-fc02  

lo: flags=73  mtu 65536
inet 127.0.0.1  netmask 255.0.0.0
loop  txqueuelen 1000  (Local Loopback)
RX packets 0  bytes 0 (0.0 B)
RX errors 0  dropped 0  overruns 0  frame 0
TX packets 0  bytes 0 (0.0 B)
TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

[thimk][root][~] ifconfig -a
eth0: flags=4163  mtu 1500
inet 192.168.1.2  netmask 255.255.255.0  broadcast 192.168.1.255
ether 00:27:13:64:6a:0d  txqueuelen 1000  (Ethernet)
RX packets 52008  bytes 3354071 (3.1 MiB)
RX errors 0  dropped 0  overruns 0  frame 0
TX packets 436  bytes 81829 (79.9 KiB)
TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
device interrupt 20  memory 0xfc00-fc02  

lo: flags=73  mtu 65536
inet 127.0.0.1  netmask 255.0.0.0
loop  txqueuelen 1000  (Local Loopback)
RX packets 0  bytes 0 (0.0 B)
RX errors 0  dropped 0  overruns 0  frame 0
TX packets 0  bytes 0 (0.0 B)
TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wlan0: flags=4098  mtu 1500
ether 00:26:c6:4a:b4:92  txqueuelen 1000  (Ethernet)
RX packets 0  bytes 0 (0.0 B)
RX errors 0  dropped 0  overruns 0  frame 0
TX packets 0  bytes 0 (0.0 B)
TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0


-- 
Walter Dnes 
I don't run "desktop environments"; I run useful applications



Re: [gentoo-user] No wifi

2020-07-14 Thread Michael
On Tuesday, 14 July 2020 18:20:39 BST Walter Dnes wrote:
> On Tue, Jul 14, 2020 at 10:05:52AM +0100, Michael wrote

> > Does dmesg reveal anything untoward in the kernel failing to find
> > or load this firmware?
> 
>   Still no wireless, but one bit of progress.  It seems that the kernel
> does *NOT* like using subdirectories below /lib/firmware.  I copied the
> ucode file to /lib/firmware and changed the path appropriately before
> building the kernel.  Now dmesg at bootup shows...

That's OK, up to a point ...


> [0.757370] Intel(R) Wireless WiFi driver for Linux
> [0.757372] Copyright(c) 2003- 2015 Intel Corporation
> [0.757478] iwlwifi :03:00.0: can't disable ASPM; OS doesn't have
> ASPM control [0.757877] iwlwifi :03:00.0: loaded firmware version
> 8.83.5.1 build 33692 op_mode iwldvm [0.757963] iwlwifi :03:00.0:
> CONFIG_IWLWIFI_DEBUG disabled [0.757967] iwlwifi :03:00.0:
> CONFIG_IWLWIFI_DEBUGFS disabled [0.757970] iwlwifi :03:00.0:
> CONFIG_IWLWIFI_DEVICE_TRACING disabled [0.757973] iwlwifi :03:00.0:
> Detected Intel(R) WiFi Link 5100 AGN, REV=0x54 [0.761128] [drm] HPD
> interrupt storm detected on connector DP-3: switching from hotplug
> detection to polling [0.762028] fbcon: i915drmfb (fb0) is primary
> device
> [0.795312] ieee80211 phy0: Selected rate control algorithm 'iwl-agn-rs'

Normally you should see something like this following the above entries:

[   16.017699] iwlwifi :04:00.0 wlp4s0: renamed from wlan0
[   16.167105] EXT4-fs (sda4): mounted filesystem with ordered data mode. 
Opts: (null)
[   18.384509] iwlwifi :04:00.0: Radio type=0x1-0x2-0x0
[   18.500644] iwlwifi :04:00.0: Radio type=0x1-0x2-0x0


> > Also, make sure the wireless NIC is enabled in the BIOS and powered
> > up by toggling the appropriate Fn key combo, e.g. Fn+F5 or whatever
> > it is on your laptop.
> 
>   It's enabled in BIOS and the Gentoo minimal install usb stick brings
> up wlan0 just fine.  In my first post, I listed what kernel settings I
> had set.  Is there anything else required that I'm missing?  After all
> these years of hard-wired, I'm still a newbie at wireless, so I could be
> missing something glaringly obvious.

In addition to your kernel selections I also have:

CONFIG_RFKILL=y
CONFIG_RFKILL_LEDS=y
CONFIG_RFKILL_INPUT=y
CONFIG_RFKILL_GPIO=y
...

CONFIG_WLAN=y
# CONFIG_WLAN_VENDOR_ADMTEK is not set
# CONFIG_WLAN_VENDOR_ATH is not set
# CONFIG_WLAN_VENDOR_ATMEL is not set
# CONFIG_WLAN_VENDOR_BROADCOM is not set
# CONFIG_WLAN_VENDOR_CISCO is not set
CONFIG_WLAN_VENDOR_INTEL=y
# CONFIG_IPW2100 is not set
# CONFIG_IPW2200 is not set
# CONFIG_IWL4965 is not set
# CONFIG_IWL3945 is not set
CONFIG_IWLWIFI=m
CONFIG_IWLWIFI_LEDS=y
CONFIG_IWLDVM=m
# CONFIG_IWLMVM is not set
CONFIG_IWLWIFI_OPMODE_MODULAR=y

As you can see I'm using modules and the kernel loads the firmware without me 
including it in the kernel config.  Not sure if there is a difference between 
built-in and module configuration for the Wireless devices, but you could try 
it.  If you have not built RFKILL in your kernel I suggest you do so and 
reboot.  Finally, may be worth checking the troubleshooting section here:

https://wiki.gentoo.org/wiki/Iwlwifi

HTH.

signature.asc
Description: This is a digitally signed message part.


Re: [gentoo-user] No wifi

2020-07-14 Thread Ashley Dixon
On Tue, Jul 14, 2020 at 01:20:39PM -0400, Walter Dnes wrote:
>   Still no wireless, but one bit of progress.  It seems that the kernel
> does *NOT* like using subdirectories below /lib/firmware.  I copied the
> ucode file to /lib/firmware and changed the path appropriately before
> building the kernel.

I can't imagine why that would be the case. My /lib/firmware structure looks a
bit like this, for my video card:

/lib/firmware/
├── amdgpu
│   ├── polaris10_ce_2.bin
│   ├── polaris10_ce.bin
│   ├── polaris10_k2_smc.bin
│   ├── polaris10_k_mc.bin
│   ├── polaris10_k_smc.bin
│   ├── polaris10_mc.bin
│   ├── polaris10_me_2.bin
│   ├── polaris10_me.bin
│   ├── polaris10_mec2_2.bin
│   ├── polaris10_mec_2.bin
│   ├── polaris10_mec2.bin
│   ├── polaris10_mec.bin
│   ├── polaris10_pfp_2.bin
│   ├── polaris10_pfp.bin
│   ├── polaris10_rlc.bin
│   ├── polaris10_sdma1.bin
│   ├── polaris10_sdma.bin
│   ├── polaris10_smc.bin
│   ├── polaris10_smc_sk.bin
│   ├── polaris10_uvd.bin
│   ├── polaris10_vce.bin
│   ├── TAHITI_uvd.bin
│   └── TAHITI_vce.bin
├── regulatory.db
└── regulatory.db.p7s

1 directory, 25 files

... And the kernel .config:

CONFIG_EXTRA_FIRMWARE_DIR="/lib/firmware/"
CONFIG_EXTRA_FIRMWARE="amdgpu/polaris10_ce.bin amdgpu/polaris10_ce_2.bin
amdgpu/polaris10_k_smc.bin amdgpu/polaris10_k2_smc.bin
amdgpu/polaris10_k_mc.bin amdgpu/polaris10_mc.bin
amdgpu/polaris10_me.bin amdgpu/polaris10_me_2.bin
amdgpu/polaris10_mec2.bin amdgpu/polaris10_mec2_2.bin
amdgpu/polaris10_mec.bin amdgpu/polaris10_mec_2.bin
amdgpu/polaris10_pfp.bin amdgpu/polaris10_pfp_2.bin
amdgpu/polaris10_rlc.bin amdgpu/polaris10_sdma1.bin
amdgpu/polaris10_sdma.bin amdgpu/polaris10_smc.bin
amdgpu/polaris10_smc_sk.bin amdgpu/polaris10_uvd.bin
amdgpu/polaris10_vce.bin"

It's tedious, but there's no reason that the kernel shouldn't find  firmware  in
subdirectories.  Perhaps you needed to add a  trailing  oblique  ('/')  to  your
CONFIG_EXTRA_FIRMWARE_DIR, such that the concatenated path is correct ?

-- 

Ashley Dixon
suugaku.co.uk

2A9A 4117
DA96 D18A
8A7B B0D2
A30E BF25
F290 A8AA



signature.asc
Description: PGP signature


Re: [gentoo-user] No wifi

2020-07-14 Thread Walter Dnes
On Tue, Jul 14, 2020 at 10:05:52AM +0100, Michael wrote

> Is there a subdirectory 'iwlwifi-5000-ucode-5.4.A.11' in /lib/firmware/ ?
> 
> I'm asking because the vanilla sys-kernel/linux-firmware does not create such 
> a subdirectory.  This is what is listed here:
> 
> $ ls -la /lib/firmware/iwlwifi-5000*
> -rw-r--r-- 1 root root 345008 Jun 27 08:58 /lib/firmware/iwlwifi-5000-1.ucode
> -rw-r--r-- 1 root root 353240 Jun 27 08:58 /lib/firmware/iwlwifi-5000-2.ucode
> -rw-r--r-- 1 root root 340696 Jun 27 08:58 /lib/firmware/iwlwifi-5000-5.ucode
> 
> Does dmesg reveal anything untoward in the kernel failing to find
> or load this firmware?

  Still no wireless, but one bit of progress.  It seems that the kernel
does *NOT* like using subdirectories below /lib/firmware.  I copied the
ucode file to /lib/firmware and changed the path appropriately before
building the kernel.  Now dmesg at bootup shows...

[0.757370] Intel(R) Wireless WiFi driver for Linux
[0.757372] Copyright(c) 2003- 2015 Intel Corporation
[0.757478] iwlwifi :03:00.0: can't disable ASPM; OS doesn't have ASPM 
control
[0.757877] iwlwifi :03:00.0: loaded firmware version 8.83.5.1 build 
33692 op_mode iwldvm
[0.757963] iwlwifi :03:00.0: CONFIG_IWLWIFI_DEBUG disabled
[0.757967] iwlwifi :03:00.0: CONFIG_IWLWIFI_DEBUGFS disabled
[0.757970] iwlwifi :03:00.0: CONFIG_IWLWIFI_DEVICE_TRACING disabled
[0.757973] iwlwifi :03:00.0: Detected Intel(R) WiFi Link 5100 AGN, 
REV=0x54
[0.761128] [drm] HPD interrupt storm detected on connector DP-3: switching 
from hotplug detection to polling
[0.762028] fbcon: i915drmfb (fb0) is primary device
[0.795312] ieee80211 phy0: Selected rate control algorithm 'iwl-agn-rs'

> Also, make sure the wireless NIC is enabled in the BIOS and powered
> up by toggling the appropriate Fn key combo, e.g. Fn+F5 or whatever
> it is on your laptop.

  It's enabled in BIOS and the Gentoo minimal install usb stick brings
up wlan0 just fine.  In my first post, I listed what kernel settings I
had set.  Is there anything else required that I'm missing?  After all
these years of hard-wired, I'm still a newbie at wireless, so I could be
missing something glaringly obvious.

-- 
Walter Dnes 
I don't run "desktop environments"; I run useful applications



Re: [gentoo-user] No wifi

2020-07-14 Thread Jack

On 2020.07.14 12:23, Walter Dnes wrote:

On Tue, Jul 14, 2020 at 10:05:52AM +0100, Michael wrote
>
> Is there a subdirectory 'iwlwifi-5000-ucode-5.4.A.11' in  
/lib/firmware/ ?


  Yes.  It was created when I untarred the tarball from kernel.org

[thimk][root][~] ll /lib/firmware/iwlwifi-5000-ucode-5.4.A.11
total 364
drwxr-sr-x 2 root root   4096 Jun  4  2008 .
drwxr-xr-x 4 root root   4096 Jul 15 09:45 ..
-rw-r--r-- 1 root root   2114 Jun  4  2008 LICENSE.iwlwifi-5000-ucode
-rw-r--r-- 1 root root   5099 Jun  4  2008 README.iwlwifi-5000-ucode
-rw-r--r-- 1 root root 345008 Jun  2  2008 iwlwifi-5000-1.ucode

> Does dmesg reveal anything untoward in the kernel failing to find
> or load this firmware?

  See my message to Ashley for error listing.

> Also, make sure the wireless NIC is enabled in the BIOS and powered
> up by toggling the appropriate Fn key combo, e.g. Fn+F5 or whatever
> it is on your laptop.

  I should have mentioned that wlan0 shows up fine booting from the
minimal install usb stick.

What does dmesg say about loaded firmware in that case?



Re: [gentoo-user] No wifi

2020-07-14 Thread Walter Dnes
On Tue, Jul 14, 2020 at 10:05:52AM +0100, Michael wrote
> 
> Is there a subdirectory 'iwlwifi-5000-ucode-5.4.A.11' in /lib/firmware/ ?

  Yes.  It was created when I untarred the tarball from kernel.org

[thimk][root][~] ll /lib/firmware/iwlwifi-5000-ucode-5.4.A.11
total 364
drwxr-sr-x 2 root root   4096 Jun  4  2008 .
drwxr-xr-x 4 root root   4096 Jul 15 09:45 ..
-rw-r--r-- 1 root root   2114 Jun  4  2008 LICENSE.iwlwifi-5000-ucode
-rw-r--r-- 1 root root   5099 Jun  4  2008 README.iwlwifi-5000-ucode
-rw-r--r-- 1 root root 345008 Jun  2  2008 iwlwifi-5000-1.ucode

> Does dmesg reveal anything untoward in the kernel failing to find
> or load this firmware?

  See my message to Ashley for error listing.

> Also, make sure the wireless NIC is enabled in the BIOS and powered
> up by toggling the appropriate Fn key combo, e.g. Fn+F5 or whatever
> it is on your laptop.

  I should have mentioned that wlan0 shows up fine booting from the
minimal install usb stick.

-- 
Walter Dnes 
I don't run "desktop environments"; I run useful applications



Re: [gentoo-user] No wifi

2020-07-14 Thread Ashley Dixon
On Tue, Jul 14, 2020 at 10:31:21AM -0400, Walter Dnes wrote:
>   One thing I should've mentioned in the first post is that booting from
> the minimal install USB, wlan0 does show up, so the hardware works.

That's because the "minimal" install disk actually has  quite  a  lot  of  stuff
installed/enabled, to support all (or, as much as possible) common hardware in a
live environment, as this generally runs before the point at which the user  can
configure their own kernel.

> On Tue, Jul 14, 2020 at 05:59:37AM +0100, Ashley Dixon wrote
> > It doesn't look like it's loading the firmware.  Are there any obvious
> > firmware-loading errors in dmesg ?
> 
>   What is ASPM and what is error -2?  BTW, on my first attempt, when I
> accidentally tried a non-existant firmware path, the kernel compile died
> early on.  Here is what I get in dmesg with ucode 8.83.5.1-1

Error -2 means that  it  can't  find  the  file:  "ENOENT  2  No  such  file  or
directory". You should install the firmware through `sys-kernel/linux-firmware`,
and then edit your .config accordingly (as Michael mentioned, no  subdirectories
are added by the Gentoo package):

CONFIG_EXTRA_FIRMWARE_DIR="/lib/firmware/"
CONFIG_EXTRA_FIRMWARE="iwlwifi-5000-1.ucode iwlwifi-5000-2.ucode 
iwlwifi-5000-5.ucode"

> > That looks fine, although why are you using such an outdated version
> > of the microcode ? For kernels 2.6.38+, you can use 8.83.5.1-1.
> 
>   The way the items lined up on the webpage, I mis-interpreted it to
> mean one driver for 5100AGN, one for 5300AGN, and one for 5350AGN.  See
> attachment.

The table is slightly misleading, but I think that any of  the  listed  firmware
packages can work for any of  the  listed  devices,  and  the  only  distinction
between the files is the supported kernel versions.  Thus, you should be able to
safely use the latest version.

> > Perhaps it would be better to  install  it  from
> > the  Gentoo-provided  firmware package ?  Amend
> > /etc/portage/savedconfig/sys-kernel/linux-firmware  to  include the
> > appropriate entries (listing at [1]), and emerge `linux-firmware`
> > with  the `savedconfig` USE-flag.
> 
>   I'll do that next if there's nothing obvious here.

Yes, that is your next step.  Append the appropriate entries to your savedconfig
file and emerge `linux-firmware` with `savedconfig`:

iwlwifi-5000-1.ucode
iwlwifi-5000-2.ucode
iwlwifi-5000-5.ucode

-- 

Ashley Dixon
suugaku.co.uk

2A9A 4117
DA96 D18A
8A7B B0D2
A30E BF25
F290 A8AA



signature.asc
Description: PGP signature


Re: [gentoo-user] No wifi

2020-07-14 Thread Walter Dnes
  One thing I should've mentioned in the first post is that booting from
the minimal install USB, wlan0 does show up, so the hardware works.

On Tue, Jul 14, 2020 at 05:59:37AM +0100, Ashley Dixon wrote
> 
> It doesn't look like it's loading the firmware.  Are there any obvious
> firmware-loading errors in dmesg ?

  What is ASPM and what is error -2?  BTW, on my first attempt, when I
accidentally tried a non-existant firmware path, the kernel compile died
early on.  Here is what I get in dmesg with ucode 8.83.5.1-1

[0.728996] Intel(R) Wireless WiFi driver for Linux
[0.728998] Copyright(c) 2003- 2015 Intel Corporation
[0.729099] iwlwifi :03:00.0: can't disable ASPM; OS doesn't have ASPM 
control
[0.729298] iwlwifi :03:00.0: Direct firmware load for 
iwlwifi-5000-5.ucode failed with error -2
[0.729311] iwlwifi :03:00.0: Direct firmware load for 
iwlwifi-5000-4.ucode failed with error -2
[0.729322] iwlwifi :03:00.0: Direct firmware load for 
iwlwifi-5000-3.ucode failed with error -2
[0.729334] iwlwifi :03:00.0: Direct firmware load for 
iwlwifi-5000-2.ucode failed with error -2
[0.729346] iwlwifi :03:00.0: Direct firmware load for 
iwlwifi-5000-1.ucode failed with error -2
[0.729351] iwlwifi :03:00.0: no suitable firmware found!
[0.729354] iwlwifi :03:00.0: minimum version required: iwlwifi-5000-1
[0.729359] iwlwifi :03:00.0: maximum version supported: iwlwifi-5000-5
[0.729362] iwlwifi :03:00.0: check 
git://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git

> That looks fine, although why are you using such an outdated version
> of the microcode ? For kernels 2.6.38+, you can use 8.83.5.1-1.

  The way the items lined up on the webpage, I mis-interpreted it to
mean one driver for 5100AGN, one for 5300AGN, and one for 5350AGN.  See
attachment.

> Perhaps it would be better to  install  it  from
> the  Gentoo-provided  firmware package ?  Amend
> /etc/portage/savedconfig/sys-kernel/linux-firmware  to  include the
> appropriate entries (listing at [1]), and emerge `linux-firmware`
> with  the `savedconfig` USE-flag.
> 
> [1] 
> https://git.kernel.org/pub/scm/linux/kernel/git/firmware/linux-firmware.git/tree/

  I'll do that next if there's nothing obvious here.

-- 
Walter Dnes 
I don't run "desktop environments"; I run useful applications


Re: [gentoo-user] No wifi

2020-07-14 Thread Michael
On Tuesday, 14 July 2020 05:59:37 BST Ashley Dixon wrote:
> On Tue, Jul 14, 2020 at 12:19:51AM -0400, Walter Dnes wrote:
> > [thimk][root][~] lspci -k | grep -i -B 1 5100
> > 
> > Kernel driver in use: i801_smbus
> > 
> > 03:00.0 Network controller: Intel Corporation PRO/Wireless 5100 AGN
> > [Shiloh] Network Connection> 
> > Subsystem: Intel Corporation WiFi Link 5100 AGN
> >   
> >   Note that that it's not being "loaded" as a module.  I'm building into
> > 
> > the kernel itself.  Here's a snippet from .config
> 
> It doesn't look like it's loading the firmware.  Are there any obvious
> firmware- loading errors in dmesg ?  If not, it might be worth installing 
> `sys-apps/lshw` and running `lshw -C network` to see kernel resource
> information  regarding  the device.
> 
> > #
> > # Firmware loader
> > #
> > CONFIG_FW_LOADER=y
> > CONFIG_EXTRA_FIRMWARE="iwlwifi-5000-ucode-5.4.A.11/iwlwifi-5000-1.ucode"
> > CONFIG_EXTRA_FIRMWARE_DIR="/lib/firmware"
> 
> That looks fine, although why are you using such an outdated version of the
> microcode ? For kernels 2.6.38+, you can use 8.83.5.1-1.

Is there a subdirectory 'iwlwifi-5000-ucode-5.4.A.11' in /lib/firmware/ ?

I'm asking because the vanilla sys-kernel/linux-firmware does not create such 
a subdirectory.  This is what is listed here:

$ ls -la /lib/firmware/iwlwifi-5000*
-rw-r--r-- 1 root root 345008 Jun 27 08:58 /lib/firmware/iwlwifi-5000-1.ucode
-rw-r--r-- 1 root root 353240 Jun 27 08:58 /lib/firmware/iwlwifi-5000-2.ucode
-rw-r--r-- 1 root root 340696 Jun 27 08:58 /lib/firmware/iwlwifi-5000-5.ucode


Does dmesg reveal anything untoward in the kernel failing to find or load this 
firmware?

Also, make sure the wireless NIC is enabled in the BIOS and powered up by 
toggling the appropriate Fn key combo, e.g. Fn+F5 or whatever it is on your 
laptop.

signature.asc
Description: This is a digitally signed message part.