On Friday, 2 June 2023 04:09:50 BST Philip Webb wrote:
> Thanks for all the help so far.
> 
> I've solved the firmware problem.
> The needed files weren't in the latest stable version of  linux-firmware
> nor in the masked version (after much hassle unmasking it),
> but they are in both System Rescue + Mint /lib/firmware/mediatek .
> They are versions  7922  and  7961  with corresponding RAM_CODE files.

Are you sure?  These are all the mediatek files I have here:

 $ ls -la /lib/firmware/mediatek
total 24648
drwxr-xr-x  9 root root    4096 May 18 16:17 .
drwxr-xr-x 80 root root   20480 May 18 16:17 ..
-rw-r--r--  1 root root  511830 May 18 16:16 BT_RAM_CODE_MT7922_1_1_hdr.bin
-rw-r--r--  1 root root  532590 May 18 16:16 BT_RAM_CODE_MT7961_1_2_hdr.bin
-rw-r--r--  1 root root  137632 May 18 16:16 WIFI_MT7922_patch_mcu_1_1_hdr.bin
-rw-r--r--  1 root root   92192 May 18 16:16 WIFI_MT7961_patch_mcu_1_2_hdr.bin
-rw-r--r--  1 root root  827124 May 18 16:16 WIFI_RAM_CODE_MT7922_1.bin
-rw-r--r--  1 root root  719348 May 18 16:16 WIFI_RAM_CODE_MT7961_1.bin
-rw-r--r--  1 root root   45412 May 18 16:15 mt7601u.bin
-rw-r--r--  1 root root   80680 May 18 16:16 mt7610e.bin
-rw-r--r--  1 root root   80288 May 18 16:16 mt7610u.bin
-rw-r--r--  1 root root  122644 May 18 16:16 mt7615_cr4.bin
-rw-r--r--  1 root root  457992 May 18 16:16 mt7615_n9.bin
-rw-r--r--  1 root root   11102 May 18 16:16 mt7615_rom_patch.bin
-rw-r--r--  1 root root  300376 May 18 16:16 mt7622_n9.bin
-rw-r--r--  1 root root   82110 May 18 16:16 mt7622_rom_patch.bin
-rw-r--r--  1 root root   78158 May 18 16:16 mt7622pr2h.bin
-rw-r--r--  1 root root  368220 May 18 16:15 mt7650.bin
-rw-r--r--  1 root root  382212 May 18 16:16 mt7650e.bin
-rw-r--r--  1 root root   81908 May 18 16:16 mt7662.bin
-rw-r--r--  1 root root   26350 May 18 16:16 mt7662_rom_patch.bin
-rw-r--r--  1 root root   91412 May 18 16:16 mt7662u.bin
-rw-r--r--  1 root root   20686 May 18 16:16 mt7662u_rom_patch.bin
-rw-r--r--  1 root root  335072 May 18 16:16 mt7663_n9_rebb.bin
-rw-r--r--  1 root root  441688 May 18 16:16 mt7663_n9_v3.bin
-rw-r--r--  1 root root  278558 May 18 16:16 mt7663pr2h.bin
-rw-r--r--  1 root root  209230 May 18 16:16 mt7663pr2h_rebb.bin
-rw-r--r--  1 root root  170990 May 18 16:16 mt7668pr2h.bin
-rw-r--r--  1 root root    3584 May 18 16:16 mt7915_eeprom.bin
-rw-r--r--  1 root root    3584 May 18 16:16 mt7915_eeprom_dbdc.bin
-rw-r--r--  1 root root  144544 May 18 16:16 mt7915_rom_patch.bin
-rw-r--r--  1 root root  116160 May 18 16:16 mt7915_wa.bin
-rw-r--r--  1 root root 1260960 May 18 16:16 mt7915_wm.bin
-rw-r--r--  1 root root    4096 May 18 16:16 mt7916_eeprom.bin
-rw-r--r--  1 root root    8672 May 18 16:16 mt7916_rom_patch.bin
-rw-r--r--  1 root root  507856 May 18 16:16 mt7916_wa.bin
-rw-r--r--  1 root root 1710304 May 18 16:16 mt7916_wm.bin
-rw-r--r--  1 root root    8736 May 18 16:16 mt7981_rom_patch.bin
-rw-r--r--  1 root root  492336 May 18 16:16 mt7981_wa.bin
-rw-r--r--  1 root root 2052592 May 18 16:16 mt7981_wm.bin
-rw-r--r--  1 root root 2427600 May 18 16:16 mt7981_wo.bin
-rw-r--r--  1 root root    4096 May 18 16:16 mt7986_eeprom_mt7975_dual.bin
-rw-r--r--  1 root root    4096 May 18 16:16 mt7986_eeprom_mt7976.bin
-rw-r--r--  1 root root    4096 May 18 16:16 mt7986_eeprom_mt7976_dbdc.bin
-rw-r--r--  1 root root    4096 May 18 16:16 mt7986_eeprom_mt7976_dual.bin
-rw-r--r--  1 root root   12768 May 18 16:16 mt7986_rom_patch.bin
-rw-r--r--  1 root root   12768 May 18 16:16 mt7986_rom_patch_mt7975.bin
-rw-r--r--  1 root root  518784 May 18 16:16 mt7986_wa.bin
-rw-r--r--  1 root root 2226016 May 18 16:16 mt7986_wm.bin
-rw-r--r--  1 root root 2226016 May 18 16:16 mt7986_wm_mt7975.bin
-rw-r--r--  1 root root 2428032 May 18 16:16 mt7986_wo_0.bin
-rw-r--r--  1 root root 2428032 May 18 16:16 mt7986_wo_1.bin
drwxr-xr-x  2 root root    4096 May 18 16:17 mt8173
drwxr-xr-x  2 root root    4096 May 18 16:17 mt8183
drwxr-xr-x  2 root root    4096 May 18 16:17 mt8186
drwxr-xr-x  2 root root    4096 May 18 16:17 mt8192
drwxr-xr-x  2 root root    4096 May 18 16:17 mt8195
drwxr-xr-x  2 root root    4096 May 18 16:17 sof
drwxr-xr-x  2 root root    4096 May 18 16:17 sof-tplg


> I copied them into the new machine in the same-named dir, 'unxz' them
> & after reboot 'dmesg' announced that it had loaded  7961
> & 'ip a' showed a 4th interface 'wlp5s0'.  So far, so good.

I suggest you have another look at what files portage installed with the 
linux-firmware package to understand why these were missing.  However, if the 
interface is now initialised by the kernel, you can at least move on to the 
next step.  :-)


> What is still not good is that that interface has "NO-CARRIER".

What is the full output please?  Does it show the interface is "UP"?


> Also, 'rc-status' after a reboot shows  wpa_supplicant  as STOPPED.

This may mean the interface is not up yet.  Does running the rc-service 
command I provided previously, or '/etc/init.d/net.wlp5s0 -v start' bring it 
up?  Can you stop it, start it, check its status with either of these two 
commands?


> 'rc-service -v wpa_supplicant start' gets it STARTED,
> but 'ip a' still shows "NO-CARRIER".
> I tried 'ip link set wlp5s0 carrier on',
> but was told "operation not supported".

You need to run:

ip link set dev wlp5s0 up


> w_s seems to be finding its conf file
> at  /etc/wpa_supplicant/wpa_supplicant.conf ,
> but 'wpa_cli' continues to say "can't link to wpa_supplicant".



> I have checked the service name + password are correct in the conf file.
> 
> It's approaching supper time & I've run out of ideas for today anyway.
> 
> Any further advice is most welcome (smile).

I can think of four options to manage your wireless NIC.

1. With netifrc scripts, as per the /etc/init.d/net.wlp5s0 symlink.  When this 
service starts it will parse your /etc/conf.d/net file, find the section for 
wlp5s0 and configure it accordingly, bringing in wpa_supplicant to execute the 
authentication with the AP.  This is useful if you have particular settings 
e.g. static IP address(es) and convoluted gateways with one or more APs and 
require a more granular IP configurations.

2. With wpa_supplicant only, in which case add your wpa_service service script 
to the rc default level.

3. With ifplugd, which is more useful for laptops, when the wired/wireless 
connections are intermittent and you don't want to have to start/stop them 
manually.

4. Manually, e.g. with ip commands.

Any of the above will be able to bring your interface up and down, as long as 
the kernel driver and NIC firmware files are available.

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

Reply via email to