您好专家
我有一个问题、即 CPU 无法在非常高的温度下进入睡眠模式、
因为 SD 卡的 POW 和 CD 信号处理的硬件问题。
似乎、当 POW 信号在非常高的温度环境中变成高电平时、
由于 H/W 问题、它会导致 CD 信号电平高。
这种现象会干扰器件进入睡眠模式。
是否有任何文档可用于了解 POW 与 CD 之间的关系?
哪个源代码控制这些信号?
我们的硬件工程师说、POW 的开漏可以在不修复 H/W 的情况下解决这个问题。
我是否可以将 PoE 信号模式设置为开漏?
如果需要、我应该修改哪个源代码?
内核版本为4.19和5.10。
对于内核5.10、记录如下所示的这种现象:
[ 569.455360] mmc0: Timeout waiting for hardware cmd interrupt. [ 569.461263] mmc0: sdhci: ============ SDHCI REGISTER DUMP =========== [ 569.467790] mmc0: sdhci: Sys addr: 0x00000000 | Version: 0x00003101 [ 569.474308] mmc0: sdhci: Blk size: 0x00000000 | Blk cnt: 0x00000000 [ 569.480823] mmc0: sdhci: Argument: 0x00000000 | Trn mode: 0x00000000 [ 569.487340] mmc0: sdhci: Present: 0x01ff0000 | Host ctl: 0x00000000 [ 569.493853] mmc0: sdhci: Power: 0x0000000e | Blk gap: 0x00000000 [ 569.500367] mmc0: sdhci: Wake-up: 0x00000000 | Clock: 0x0000f007 [ 569.506883] mmc0: sdhci: Timeout: 0x00000000 | Int stat: 0x000000c0 [ 569.513399] mmc0: sdhci: Int enab: 0x007f0003 | Sig enab: 0x007f0003 [ 569.519913] mmc0: sdhci: ACmd stat: 0x00000000 | Slot int: 0x00000000 [ 569.526428] mmc0: sdhci: Caps: 0x05e10080 | Caps_1: 0x00000000 [ 569.532943] mmc0: sdhci: Cmd: 0x00000102 | Max curr: 0x00000000 [ 569.539456] mmc0: sdhci: Resp[0]: 0x00000000 | Resp[1]: 0x00000000 [ 569.545970] mmc0: sdhci: Resp[2]: 0x00000000 | Resp[3]: 0x00000000 [ 569.552479] mmc0: sdhci: Host ctl2: 0x00000000 [ 569.556980] mmc0: sdhci: ============================================ [ 570.669124] ------------[ cut here ]------------ [ 570.673884] WARNING: CPU: 0 PID: 1912 at drivers/mmc/host/sdhci-omap.c:760 sdhci_set_ios+0xc0/0x580 [ 570.715523] Modules linked in: 8021q cdc_ether usbnet cdc_acm g_serial wl18xx wlcore mac80211 libarc4 cfg80211 omap_aes_driver omap_sham omap_crypto crypto_engine pm33xx ti_emif_sram c_can_platform c_can can_dev wlcore_sdio musb_dsps musb_hdrc phy_am335x phy_generic wkup_m3_ipc phy_am335x_control omap_wdt wkup_m3_rproc uio_module_drv(O) uio cryptodev(O) [ 570.780354] CPU: 0 PID: 1912 Comm: kworker/0:0 Tainted: G W O 5.10.100+ #1 [ 570.789920] Hardware name: Generic AM33XX (Flattened Device Tree) [ 570.797055] Workqueue: events_freezable mmc_rescan [ 570.801953] [<c010d584>] (unwind_backtrace) from [<c010a12c>] (show_stack+0x10/0x14) [ 570.811380] [<c010a12c>] (show_stack) from [<c0a44b54>] (__warn+0xd4/0xec) [ 570.819121] [<c0a44b54>] (__warn) from [<c0a44bd0>] (warn_slowpath_fmt+0x64/0xc8) [ 570.828154] [<c0a44bd0>] (warn_slowpath_fmt) from [<c082de9c>] (sdhci_set_ios+0xc0/0x580) [ 570.837409] [<c082de9c>] (sdhci_set_ios) from [<c0838818>] (sdhci_omap_set_ios+0xd0/0x10c) [ 570.846598] [<c0838818>] (sdhci_omap_set_ios) from [<c0815708>] (mmc_power_up.part.0+0x90/0xc4) [ 570.856016] [<c0815708>] (mmc_power_up.part.0) from [<c08163bc>] (mmc_rescan+0x33c/0x53c) [ 570.864278] [<c08163bc>] (mmc_rescan) from [<c013f790>] (process_one_work+0x1c4/0x44c) [ 570.873877] [<c013f790>] (process_one_work) from [<c013fa70>] (worker_thread+0x58/0x5cc) [ 570.882815] [<c013fa70>] (worker_thread) from [<c01445e0>] (kthread+0x140/0x184) [ 570.891074] [<c01445e0>] (kthread) from [<c0100148>] (ret_from_fork+0x14/0x2c) [ 570.898978] Exception stack(0xc3433fb0 to 0xc3433ff8) [ 570.904081] 3fa0: 00000000 00000000 00000000 00000000 [ 570.913277] 3fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000 [ 570.922644] 3fe0: 00000000 00000000 00000000 00000000 00000013 00000000 [ 570.930224] ---[ end trace ce1233480319579d ]--- [ 580.975419] mmc0: Timeout waiting for hardware cmd interrupt. [ 580.981321] mmc0: sdhci: ============ SDHCI REGISTER DUMP =========== [ 580.987848] mmc0: sdhci: Sys addr: 0x00000000 | Version: 0x00003101 [ 580.994366] mmc0: sdhci: Blk size: 0x00000000 | Blk cnt: 0x00000000 [ 581.000881] mmc0: sdhci: Argument: 0x00000c00 | Trn mode: 0x00000000 [ 581.007395] mmc0: sdhci: Present: 0x01ff0000 | Host ctl: 0x00000000 [ 581.013909] mmc0: sdhci: Power: 0x0000000e | Blk gap: 0x00000000 [ 581.020424] mmc0: sdhci: Wake-up: 0x00000000 | Clock: 0x00003c07 [ 581.026938] mmc0: sdhci: Timeout: 0x00000000 | Int stat: 0x000000c0 [ 581.033453] mmc0: sdhci: Int enab: 0x007f0003 | Sig enab: 0x007f0003 [ 581.039969] mmc0: sdhci: ACmd stat: 0x00000000 | Slot int: 0x00000000 [ 581.046483] mmc0: sdhci: Caps: 0x05e10080 | Caps_1: 0x00000000 [ 581.052997] mmc0: sdhci: Cmd: 0x0000341a | Max curr: 0x00000000 [ 581.059510] mmc0: sdhci: Resp[0]: 0x00000000 | Resp[1]: 0x00000000 [ 581.066023] mmc0: sdhci: Resp[2]: 0x00000000 | Resp[3]: 0x00000000 [ 581.072532] mmc0: sdhci: Host ctl2: 0x00000000 [ 581.077035] mmc0: sdhci: ============================================
器件树如下所示:
mmc1_pins: pinmux_mmc1_pins { pinctrl-single,pins = < AM33XX_IOPAD(0x990, PIN_INPUT | MUX_MODE4) /* A13 mcasp0_aclkx.gpio3_14 CD */ AM33XX_IOPAD(0x8fc, PIN_INPUT | MUX_MODE0) /* mmc0_dat0.mmc0_dat0 */ AM33XX_IOPAD(0x8f8, PIN_INPUT | MUX_MODE0) /* mmc0_dat1.mmc0_dat1 */ AM33XX_IOPAD(0x8f4, PIN_INPUT | MUX_MODE0) /* mmc0_dat2.mmc0_dat2 */ AM33XX_IOPAD(0x8f0, PIN_INPUT | MUX_MODE0) /* mmc0_dat3.mmc0_dat3 */ AM33XX_IOPAD(0x904, PIN_INPUT | MUX_MODE0) /* mmc0_cmd.mmc0_cmd */ AM33XX_IOPAD(0x900, PIN_INPUT | MUX_MODE0) /* mmc0_clk.mmc0_clk */ AM33XX_IOPAD(0x964, PIN_INPUT | MUX_MODE5) /* C18 ecap0_in_pwm0_out.mmc0_sdwp WP */ AM33XX_IOPAD(0x960, PIN_INPUT | MUX_MODE3) /* C15 spi0_cs1.gpio0_6 POW */ >; }; &mmc1 { status = "okay"; vmmc-supply = <&vmmc_reg>; bus-width = <4>; pinctrl-names = "default"; pinctrl-0 = <&mmc1_pins>; cd-gpios = <&gpio3 14 GPIO_ACTIVE_HIGH>; cap-poweroff-card; };
此致、
胜山市