Skip to content

google-crosshatch: switch to LineageOS kernel, enable /dev/mem

Zhuowei Zhang requested to merge zhuowei/pmaports:crosshatch-kernel into master

Tested on crosshatch.

  • still boots into plasma-mobile.
  • /dev/mem works. (Tested with a statically linked busybox with devmem support:)
google-crosshatch:/home/user# ./busybox devmem 0x5040000 32
0x00E01E36
  • Wi-Fi still doesn't work.

I tried to boot the Wi-Fi by running echo 1 >/sys/kernel/boot_wlan/boot_wlan. This didn't help:

[  438.996345] wlan: Loading driver v5.3.1.1Q.1 ( +PANIC_ON_BUG)
[  438.996739] CHRDEV "qcwlanstate" major number 223 goes below the dynamic allocation range
[  438.997618] wlan_hdd_state wlan major(223) initialized
[  438.997621] wlan: driver loaded

then nothing more is shown. There's nothing in the firmware load log, either:

# cat /var/log/firmwareload.log 
cannot find firmware file 'venus.mdt'
(repeated 10 times)

The new device mentioned in the log is this:

# stat /dev/wlan 
  File: /dev/wlan
  Size: 0         	Blocks: 0          IO Block: 4096   character special file
Device: 6h/6d	Inode: 32392       Links: 1     Device type: df,0
Access: (0600/crw-------)  Uid: (    0/    root)   Gid: (    0/    root)
Access: 2019-01-27 04:38:22.000000000
Modify: 2019-01-27 04:38:22.000000000
Change: 2019-01-27 04:38:22.000000000

So I guess I need to run another command to further boot the Wi-Fi.

I tried the commands from main/wcnss_wlan, but that didn't help:

echo 1 > /dev/wlan
echo sta > /sys/module/wlan/parameters/fwpath

Nothing happened, no firmware loading attempt in the kernel log.

Thus, this change doesn't get Wi-Fi working, but it gives a good starting point.

This kernel takes more than one hour to build, so you might want to skip CI.


Update google-crosshatch's kernel from the original AOSP December source to the lineage-16.0 source.

The LineageOS kernel integrates the Wi-Fi driver into the kernel source, unlike the AOSP kernel (which has it as an external module), which should help get Wi-Fi working on this device.

Also enabled /dev/mem since I thought it may be useful for dumping device registers to compare against mainline. (If you don't want this, feel free to remove this commit.)

Edited by Zhuowei Zhang

Merge request reports