使用USB的wifi模组,型号是RTL8188F,编译驱动后放进去insmod,没有看见报错,有一些信息打出来,但ifconfig wlan0 up,提示ifconfig: SIOCGIFFLAGS: No such device
可能是什么问题?
log
# dmesg
[ 0.000000] Booting Linux on physical CPU 0x0
[ 0.000000] Linux version 5.4.99 (teddy@teddyUbuntuVM) (gcc version 9.4.0 (Buildroot -g1f0bf4d70-dirty)) #73 Sat Jun 11 19:52:12 CST 2022
[ 0.000000] CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=0005317f
[ 0.000000] CPU: VIVT data cache, VIVT instruction cache
[ 0.000000] OF: fdt: Machine model: Widora MangoPi R3
[ 0.000000] Memory policy: Data cache writeback
[ 0.000000] cma: Failed to reserve 16 MiB
[ 0.000000] On node 0 totalpages: 7967
[ 0.000000] Normal zone: 63 pages used for memmap
[ 0.000000] Normal zone: 0 pages reserved
[ 0.000000] Normal zone: 7967 pages, LIFO batch:0
[ 0.000000] pcpu-alloc: s0 r0 d32768 u32768 alloc=1*32768
[ 0.000000] pcpu-alloc: [0] 0
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 7904
[ 0.000000] Kernel command line: console=ttyS0,115200 panic=5 rootwait root=/dev/mmcblk0p2 earlyprintk rw net.ifnames=0 vt.global_cursor_default=0
[ 0.000000] Dentry cache hash table entries: 4096 (order: 2, 16384 bytes, linear)
[ 0.000000] Inode-cache hash table entries: 2048 (order: 1, 8192 bytes, linear)
[ 0.000000] mem auto-init: stack:off, heap alloc:off, heap free:off
[ 0.000000] Memory: 17624K/31868K available (7168K kernel code, 291K rwdata, 1816K rodata, 4096K init, 227K bss, 14244K reserved, 0K cma-reserved)
[ 0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
[ 0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
[ 0.000000] random: get_random_bytes called from start_kernel+0x258/0x45c with crng_init=0
[ 0.000046] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 89478484971ns
[ 0.000120] clocksource: timer: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[ 0.000639] Console: colour dummy device 80x30
[ 0.000726] Calibrating delay loop... 346.52 BogoMIPS (lpj=1732608)
[ 0.060152] pid_max: default: 32768 minimum: 301
[ 0.060562] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes, linear)
[ 0.060596] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes, linear)
[ 0.062145] CPU: Testing write buffer coherency: ok
[ 0.064026] Setting up static identity map for 0x80100000 - 0x80100058
[ 0.065213] devtmpfs: initialized
[ 0.072884] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[ 0.072937] futex hash table entries: 256 (order: -1, 3072 bytes, linear)
[ 0.073185] pinctrl core: initialized pinctrl subsystem
[ 0.075306] NET: Registered protocol family 16
[ 0.076719] DMA: preallocated 256 KiB pool for atomic coherent allocations
[ 0.078379] cpuidle: using governor menu
[ 0.114413] SCSI subsystem initialized
[ 0.114832] usbcore: registered new interface driver usbfs
[ 0.114968] usbcore: registered new interface driver hub
[ 0.115103] usbcore: registered new device driver usb
[ 0.115501] mc: Linux media interface: v0.10
[ 0.115619] videodev: Linux video capture interface: v2.00
[ 0.115706] pps_core: LinuxPPS API ver. 1 registered
[ 0.115717] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[ 0.115784] PTP clock support registered
[ 0.116686] ion_parse_dt_heap_common: id 4 type 4 name cma align 1000
[ 0.117485] Advanced Linux Sound Architecture Driver Initialized.
[ 0.119814] clocksource: Switched to clocksource timer
[ 0.121340] simple-framebuffer 81f1f000.framebuffer: framebuffer at 0x81f1f000, 0xe1000 bytes, mapped to 0x(ptrval)
[ 0.121382] simple-framebuffer 81f1f000.framebuffer: format=x8r8g8b8, mode=480x480x32, linelength=1920
[ 0.131258] Console: switching to colour frame buffer device 60x30
[ 0.147327] simple-framebuffer 81f1f000.framebuffer: fb0: simplefb registered!
[ 0.172158] thermal_sys: Registered thermal governor 'step_wise'
[ 0.172758] NET: Registered protocol family 2
[ 0.173998] tcp_listen_portaddr_hash hash table entries: 512 (order: 0, 4096 bytes, linear)
[ 0.174065] TCP established hash table entries: 1024 (order: 0, 4096 bytes, linear)
[ 0.174100] TCP bind hash table entries: 1024 (order: 0, 4096 bytes, linear)
[ 0.174133] TCP: Hash tables configured (established 1024 bind 1024)
[ 0.174367] UDP hash table entries: 256 (order: 0, 4096 bytes, linear)
[ 0.174410] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes, linear)
[ 0.174836] NET: Registered protocol family 1
[ 0.176761] NetWinder Floating Point Emulator V0.97 (double precision)
[ 0.178272] Initialise system trusted keyrings
[ 0.178865] workingset: timestamp_bits=30 max_order=13 bucket_order=0
[ 0.194524] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[ 0.194997] jffs2: version 2.2. (NAND) (SUMMARY) © 2001-2006 Red Hat, Inc.
[ 0.294438] Key type asymmetric registered
[ 0.294474] Asymmetric key parser 'x509' registered
[ 0.294633] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 249)
[ 0.294658] io scheduler mq-deadline registered
[ 0.294671] io scheduler kyber registered
[ 0.304686] suniv-f1c100s-pinctrl 1c20800.pinctrl: initialized sunXi PIO driver
[ 0.322767] Serial: 8250/16550 driver, 8 ports, IRQ sharing disabled
[ 0.327557] suniv-f1c100s-pinctrl 1c20800.pinctrl: 1c20800.pinctrl supply vcc-pe not found, using dummy regulator
[ 0.328724] printk: console [ttyS0] disabled
[ 0.349009] 1c25000.serial: ttyS0 at MMIO 0x1c25000 (irq = 26, base_baud = 6250000) is a 16550A
[ 0.967280] printk: console [ttyS0] enabled
[ 1.009059] 1c25800.serial: ttyS1 at MMIO 0x1c25800 (irq = 27, base_baud = 6250000) is a 16550A
[ 1.024814] SCSI Media Changer driver v0.25
[ 1.030595] suniv-f1c100s-pinctrl 1c20800.pinctrl: 1c20800.pinctrl supply vcc-pc not found, using dummy regulator
[ 1.063103] random: fast init done
[ 1.450105] spi-nand: probe of spi0.0 failed with error -110
[ 1.456134] MACsec IEEE 802.1AE
[ 1.459681] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[ 1.466343] ehci-platform: EHCI generic platform driver
[ 1.471916] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[ 1.478131] ohci-platform: OHCI generic platform driver
[ 1.483784] usbcore: registered new interface driver usb-storage
[ 1.552836] sunxi-wdt 1c20ca0.watchdog: Watchdog enabled (timeout=16 sec, nowayout=0)
[ 1.566631] suniv-f1c100s-pinctrl 1c20800.pinctrl: 1c20800.pinctrl supply vcc-pf not found, using dummy regulator
[ 1.608186] sunxi-mmc 1c0f000.mmc: initialized, max. request size: 16384 KB
[ 1.617099] usbcore: registered new interface driver usbhid
[ 1.622787] usbhid: USB HID core driver
[ 1.626895] sunxi-cedar 1c0e000.video-codec: sunxi cedar version 0.01alpha
[ 1.634169] sunxi-cedar 1c0e000.video-codec: cedar-ve the get irq is 19
[ 1.661236] debugfs: Directory '1c23c00.codec' with parent 'F1C100s Audio Codec' already present!
[ 1.674594] sun4i-codec 1c23c00.codec: Codec <-> 1c23c00.codec mapping ok
[ 1.688579] NET: Registered protocol family 17
[ 1.693248] Key type dns_resolver registered
[ 1.698501] Loading compiled-in X.509 certificates
[ 1.703911] show welcome
[ 1.744465] cfg80211: Loading compiled-in X.509 certificates for regulatory database
[ 1.759405] cfg80211: Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7'
[ 1.766219] ALSA device list:
[ 1.769203] #0: F1C100s Audio Codec
[ 1.773426] platform regulatory.0: Direct firmware load for regulatory.db failed with error -2
[ 1.782161] cfg80211: failed to load regulatory.db
[ 1.787894] Waiting for root device /dev/mmcblk0p2...
[ 1.809141] mmc0: host does not support reading read-only switch, assuming write-enable
[ 1.821488] mmc0: new high speed SD card at address 1388
[ 1.828820] mmcblk0: mmc0:1388 CS011 119 MiB
[ 1.837664] mmcblk0: p1 p2
[ 1.888201] EXT4-fs (mmcblk0p2): recovery complete
[ 1.894781] EXT4-fs (mmcblk0p2): mounted filesystem with ordered data mode. Opts: (null)
[ 1.903089] VFS: Mounted root (ext4 filesystem) on device 179:2.
[ 1.910515] devtmpfs: mounted
[ 1.932836] Freeing unused kernel memory: 4096K
[ 1.937532] Run /sbin/init as init process
[ 2.053426] EXT4-fs (mmcblk0p2): re-mounted. Opts: (null)
[ 2.521437] random: dd: uninitialized urandom read (512 bytes read)
[ 2.606979] random: dbus-uuidgen: uninitialized urandom read (12 bytes read)
[ 2.614502] random: dbus-uuidgen: uninitialized urandom read (8 bytes read)
[ 4.181193] random: crng init done
[ 4.184623] random: 1 urandom warning(s) missed due to ratelimiting
[ 35.049909] vcc3v0: disabling
[ 35.052955] vcc5v0: disabling
[ 52.668340] 8188fu: loading out-of-tree module taints kernel.
[ 52.733961] RTW: module init start
[ 52.737394] RTW: rtl8188fu v5.11.5-13-g2482755ff.20210615
[ 52.742938] RTW: build time: Jun 11 2022 20:04:38
[ 52.747747] RTW: rtw_inetaddr_notifier_register
[ 52.752551] usbcore: registered new interface driver rtl8188fu
[ 52.758376] RTW: module init ret=0
设备树:
&usb_otg {
dr_mode = "host";
status = "okay";
};
内核选项是按这个链接中添加的:https://whycan.com/viewtopic.php?id=5687
localtion
-*- Wireless --->
<*> cfg80211 - wireless configuration API
[*] support CRDA
[*] cfg80211 wireless extensions compatibility
<*> Generic IEEE 802.11 Networking Stack (mac80211)
[*] Minstrel
[*] Networking support --->
<*> RF switch subsystem support --->
->Device Drivers
[*] Network device support --->
[*] Network core driver support
<*> IEEE 802.1AE MAC-level encryption (MACsec)
[*] Wireless LAN --->
[*] mac80211-based legacy WDS support
[*] Ralink devices
<*> Ralink driver support --->
[*] Realtek devices
<M> Realtek 8188E USB WiFi
[*] USB support --->
<*> Support for Host-side USB
*** USB Host Controller Drivers ***
<*> EHCI HCD (USB 2.0) support
<*> Generic EHCI driver for a platform device
<*> OHCI HCD (USB 1.1) support
<*> Generic OHCI driver for a platform device
MUSB Mode Selection (Host only mode) ---> #别错过这里,否则USB模式可能会出错
<*> Inventra Highspeed Dual Role Controller
<*> ChipIdea Highspeed Dual Role Controller
[*] ChipIdea host controller
顺便再问一个:
F1C200S的USB-DP应该接模组的D-还是D+?
我是用飞线试的,线长大概20CM,这个会影响吗?
离线
用这个命名 ls /sys/class/net/ 查看一下看看wlan0有没有被命名为其他网卡
$ ls /sys/class/net/ eth0 eth1 lo sit0 usb0 usb1 wlan1 wlx30eb1f1f3b8f wwan0 wwan1 # 出现wlan0和wlan1,其中wlan0被系统重命名为wlx30eb1f1f3b8f
已解决,USB驱动有问题。。。
没有设置为host模式
离线