399 Star 1.4K Fork 1.3K

GVPopenEuler / kernel

 / 详情

The SPI driver failed to obtain the GPIO pin.

已完成
任务
创建于  
2024-04-30 15:15

The SPI driver fails to obtain the GPIO pin. In the original code, the SPI driver fails to be registered. As a result, the TPM driver fails to be loaded. The error message indicates that the dependent GPIO resource is not prepared.

Self-verification:
root@localhost:/# uname -a
Linux (none) 6.6.0+ #4 SMP Fri May 10 14:36:14 CST 2024 aarch64 GNU/Linux
root@localhost:/#
root@localhost:/#
root@localhost:/# zcat /proc/config.gz | grep -i CONFIG_GPIO_DWAPB
CONFIG_GPIO_DWAPB=y
root@localhost:/#
root@localhost:/# zcat /proc/config.gz | grep -i CONFIG_SPI_DESIGNWARE
CONFIG_SPI_DESIGNWARE=y
root@localhost:/#
root@localhost:/# zcat /proc/config.gz | grep -i CONFIG_SPI_DW_MMIO
CONFIG_SPI_DW_MMIO=y
root@localhost:/#
root@localhost:/# zcat /proc/config.gz | grep -i CONFIG_TCG_TIS_CORE
CONFIG_TCG_TIS_CORE=y
root@localhost:/#
root@localhost:/# zcat /proc/config.gz | grep -i CONFIG_TCG_TIS_SPI
CONFIG_TCG_TIS_SPI=y
root@localhost:/#
root@localhost:/# ls /dev/spi*
ls: /dev/spi*: No such file or directory
root@localhost:/#
root@localhost:/#
root@localhost:/# ls
bin hclgevf.ko init root sys var
data hnae3.ko io_test run sysroot vendor
dev hns3.cfg lib sbin tmp
etc hns3.ko lib64 spidev.ko unic
hclge.ko home proc spidev_test usr
root@localhost:/#
root@localhost:/# insmod spidev.ko
[ 355.731206][ T897] spidev spi-SPT0001:00: do not use this driver in production systems!
root@localhost:/#
root@localhost:/# ls /dev/spidev0.1
/dev/spidev0.1
root@localhost:/# spidev_test -D /dev/spidev0.1 -b 8 -p "hellospi" -v
-l
spi mode: 0x20
bits per word: 8
max speed: 500000 Hz (500 kHz)
TX | 68 65 6C 6C 6F 73 70 69 __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ |hellospi|
RX | 68 65 6C 6C 6F 73 70 69 __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ __ |hellospi|
root@localhost:/# cat /sys/kernel/debug/gpio
gpiochip0: GPIOs 512-543, parent: platform/HISI0181:00, HISI0181:00:

gpiochip1: GPIOs 544-575, parent: platform/HISI0181:01, HISI0181:01:

gpiochip2: GPIOs 576-607, parent: platform/HISI0181:02, HISI0181:02:
gpio-583 ( |spi0 CS0 ) out hi

gpiochip3: GPIOs 608-639, parent: platform/HISI0181:03, HISI0181:03:

gpiochip4: GPIOs 640-671, parent: platform/HISI0181:04, HISI0181:04:

gpiochip5: GPIOs 672-703, parent: platform/HISI0181:05, HISI0181:05:
root@localhost:/#

评论 (1)

lujunhua 创建了任务

Hi lujunhuaHW, welcome to the openEuler Community.
I'm the Bot here serving you. You can find the instructions on how to interact with me at Here.
If you have any questions, please contact the SIG: Kernel, and any of the maintainers.

openeuler-ci-bot 添加了
 
sig/Kernel
标签
lujunhua 修改了标题
lujunhua 修改了描述
lujunhua 修改了描述
lujunhua 修改了描述
lujunhua 修改了描述
lujunhua 修改了描述
lujunhua 通过openeuler/kernel Pull Request !7136任务状态待办的 修改为已完成

登录 后才可以发表评论

状态
负责人
项目
里程碑
Pull Requests
关联的 Pull Requests 被合并后可能会关闭此 issue
分支
开始日期   -   截止日期
-
置顶选项
优先级
预计工期 (小时)
参与者(2)
5329419 openeuler ci bot 1632792936
C
1
https://gitee.com/openeuler/kernel.git
git@gitee.com:openeuler/kernel.git
openeuler
kernel
kernel

搜索帮助

53164aa7 5694891 3bd8fe86 5694891