7011s1145 2022-03-17 16:57
浏览 106
已结题

zynq linux挂载mcp2515无设备显示

zynq启动后,dev/中和ifconfig -a都查找不到spi上的mcp2515,只有设备树里有显示,内核勾选过了mcp251x驱动选项,下面有我的设备树,请问这是什么原因?

img

/include/ "system-conf.dtsi"
#include <dt-bindings/gpio/gpio.h>

/ {

     compatible = "alientek,zynq-7020","xlnx,zynq-7000";

clocks {

            mcp2515_clock: mcp2515_clock {
                    compatible = "fixed-clock";
                    #clock-cells = <0>;
                    clock-frequency  = <8000000>; 
                    };

            };

regulators {
compatible = "simple-bus";
#address-cells = <1>;
#size-cells = <0>;

    reg_can_3v3: regulator@0 {
        compatible = "regulator-fixed";
        reg = <0>;
        regulator-name = "can-3v3";
        regulator-min-microvolt = <3300000>;
        regulator-max-microvolt = <3300000>;
        //gpios = <&gpio_spi 3 GPIO_ACTIVE_LOW>;
    };

};

};

&spi0 {

is-decoded-cs = <0>;
num-cs = <2>;
status = "okay";

       mcp2515_can0: mcp2515@0 {
     compatible = "microchip,mcp2515";
    reg = <0>;
    spi-max-frequency = <2000000>;
    clocks = <&mcp2515_clock>;
    oscillator_frequency = <8000000>;
    interrupt-parent = <&gpio0>;
    interrupts = <54 0x2>;
    status = "okay";

    vdd-supply = <&reg_can_3v3>;
            xceiver-supply = <&reg_can_3v3>;

        };

   mcp2515_can1: mcp2515@1 {
     compatible = "microchip,mcp2515";
    reg = <1>;
    spi-max-frequency = <2000000>;
    clocks = <&mcp2515_clock>;
    oscillator_frequency = <8000000>;
    interrupt-parent = <&gpio0>;
    interrupts = <55 0x2>;
    status = "okay";

    vdd-supply = <&reg_can_3v3>;
    xceiver-supply = <&reg_can_3v3>;

        };

};

  • 写回答

0条回答 默认 最新

    报告相同问题?

    问题事件

    • 系统已结题 3月25日
    • 创建了问题 3月17日

    悬赏问题

    • ¥30 STM32 INMP441无法读取数据
    • ¥100 求汇川机器人IRCB300控制器和示教器同版本升级固件文件升级包
    • ¥15 用visualstudio2022创建vue项目后无法启动
    • ¥15 x趋于0时tanx-sinx极限可以拆开算吗
    • ¥500 把面具戴到人脸上,请大家贡献智慧
    • ¥15 任意一个散点图自己下载其js脚本文件并做成独立的案例页面,不要作在线的,要离线状态。
    • ¥15 各位 帮我看看如何写代码,打出来的图形要和如下图呈现的一样,急
    • ¥30 c#打开word开启修订并实时显示批注
    • ¥15 如何解决ldsc的这条报错/index error
    • ¥15 VS2022+WDK驱动开发环境