namesky777 发表于 2018-8-31 13:25:56

【求助】如何修改新加载的开源i2c在设备里的名称?

新加载了开源的I2C,但设备名称叫i2c-2,可读性不强,有没有办法可以修改它的,如改成i2c-oc?

root@socfpga:~# ls /dev
bus               ptyp9               tty3                tty62
console             ptypa               tty30               tty63
cpu_dma_latency   ptypb               tty31               tty7
fb0               ptypc               tty32               tty8
full                ptypd               tty33               tty9
i2c-0               ptype               tty34               ttyAL0
i2c-1               ptypf               tty35               ttyAL1
i2c-2             ram0                tty36               ttyLCD0
initctl             ram1                tty37               ttyS0
input               random            tty38               ttyS1
kmem                spidev32764.0       tty39               ttyp0
kmsg                spidev32765.0       tty4                ttyp1
log               tty               tty40               ttyp2
mem               tty0                tty41               ttyp3
memory_bandwidth    tty1                tty42               ttyp4
mmcblk0             tty10               tty43               ttyp5
mmcblk0p1         tty11               tty44               ttyp6
mmcblk0p2         tty12               tty45               ttyp7
mmcblk0p3         tty13               tty46               ttyp8
mtab                tty14               tty47               ttyp9
network_latency   tty15               tty48               ttypa
network_throughputtty16               tty49               ttypb
null                tty17               tty5                ttypc
psaux               tty18               tty50               ttypd
ptmx                tty19               tty51               ttype
ptp0                tty2                tty52               ttypf
pts               tty20               tty53               urandom
ptyp0               tty21               tty54               vcs
ptyp1               tty22               tty55               vcs1
ptyp2               tty23               tty56               vcsa
ptyp3               tty24               tty57               vcsa1
ptyp4               tty25               tty58               watchdog
ptyp5               tty26               tty59               zero
ptyp6               tty27               tty6
ptyp7               tty28               tty60
ptyp8               tty29               tty61


fzwwj95 发表于 2018-9-1 09:31:32

召唤小梅哥出来解答~

admin 发表于 2018-9-1 10:19:47

这个是操作系统自动命令的,无法修改。除非不用系统自带的驱动,自己写驱动创建节点

fzwwj95 发表于 2018-9-2 06:28:40

admin 发表于 2018-9-1 10:19
这个是操作系统自动命令的,无法修改。除非不用系统自带的驱动,自己写驱动创建节点 ...

学习到了,谢谢梅哥
页: [1]
查看完整版本: 【求助】如何修改新加载的开源i2c在设备里的名称?