AM5718: TI E2E Forum Post: Persistent Mailbox Probe Deferral (-EPROBE_DEFER) on AM571x DSP IPC

Part Number: AM5718


 Issue Summary

We are unable to successfully initialize the Mailbox channel for DSP Inter-Processor Communication (IPC) on a custom AM571x board. The driver probe fails when calling mbox_request_channel() with a persistent -EPROBE_DEFER (-517) error, indicating that a fundamental dependency for the Mailbox Controller is not ready, despite extensive Device Tree (DT) and kernel configuration checks.

 Hardware & Configuration Context

  • SoC: TI AM571x (OMAP2+ Architecture).

  • Communication: Mailbox 5 controller, used for Linux (ARM) to DSP IPC.

  • Kernel Config: CONFIG_OMAP2PLUS_MBOX=y (Built-in TI Mailbox Controller driver).

  • Driver: Custom Mailbox Client Platform Driver (C code provided below).

 Device Tree (DTS) Configuration (Verified as status = "okay" on Target)

The following overrides and definitions were made to address initial setup failures:

DT Node Fixes Applied Purpose & Current Status
&mailbox5 status = "okay"; \#mbox-cells = <2>; (No clocks property) Controller is enabled; uses HWMOD framework for clocking. Confirmed status = okay on target.
&mbox_dsp1_ipc3x status = "okay"; \#mbox-cells = <2>; Channel is enabled and explicitly satisfies the kernel's cell size requirement. Confirmed status = okay on target.
my_dsp_client status = "okay"; mbox-names = "dsp_tx", "dsp_rx"; mboxes = <&mbox_dsp1_ipc3x 0 0>, <&mbox_dsp1_ipc3x 0 1>; Defines the client device and channel names used by the C driver.
&dsp1 (RPROC) status = "okay"; mboxes = <&mailbox5 5 0>, <&mailbox5 1 0>; Enabled the DSP core using the standard RPROC/Mailbox linking style.

Troubleshooting Steps & Results

  1. Initial Failure (-ENODEV, -19): This was traced to missing status = "okay"; and \#mbox-cells = <2>; on the Mailbox nodes. Fixes applied.

  2. Code Change: Switched driver code to request the channel by index 0 to rule out mbox-names parsing issues.

  3. Current Failure (-EPROBE_DEFER, -517): After all DT fixes, the error changed to probe deferral.

  4. Test 1: Disable RPROC: Set &dsp1 { status = "disabled"; };. Result: The error persisted (-517). (This rules out a conflict with the Remoteproc driver's mailbox initialization.)

  5. Conclusion: The probe deferral is caused by the omap2plus-mailbox driver failing to initialize because a dependency (likely the L4 Interconnect or PRCM Power Domain) is not ready or enabled in the DT.

Sample Driver Code (Client Logic)

The failure occurs on the first mbox_request_channel call.

C
// Inside dsp_client_probe(struct platform_device *pdev)
// ... setup and devm_kzalloc ...

// Failure occurs here, returning -517
ipc->tx_channel = mbox_request_channel(&ipc->cl, 0); // Requesting channel by index 0

if (IS_ERR(ipc->tx_channel)) {
    int ret = PTR_ERR(ipc->tx_channel);
    // Log shows: Failed to get TX channel by index 0: -517
    dev_err(&pdev->dev, "Failed to get TX channel by index 0: %d\n", ret); 
    return ret; 
}
// ... rest of the probe ...
  • Hello  ,

    Custom drivers are not part of our standard support. Please use the TI implementations as a guide.

    Best,

    Josue

  • kindly provide us examples or how to test this Mailbox concepts which is officially supported..

  • The official TI driver, drivers/mailbox/mailbox-test.c, is failing to acquire Mailbox channels with the error "invalid resource". This confirms that the underlying Mailbox 5 hardware resource is not being initialized correctly by the built-in TI drivers.

    Configuration Verified

    1. Kernel: Running with CONFIG_OMAP2PLUS_MBOX=y (built-in omap-mailbox.c).

    2. Driver Under Test: Official mailbox-test.c module.

    3. DT Status: The status for &mailbox5, &mbox_dsp1_ipc3x, and the test node are all set to "okay" and verified on the target system.

    Device Tree Binding (Verified against Source Code)

    The test node is configured to precisely match the requirements of the mailbox-test.c driver:

    DTS
    mailbox_test: mailbox-test {
        compatible = "ti,mailbox-test";
        
        // Exact channel names requested by the driver's C code
        mbox-names = "tx", "rx"; 
        
        // Hardware links pointing to the enabled channel sub-node
        mboxes = <&mbox_dsp1_ipc3x 0 0>, <&mbox_dsp1_ipc3x 0 1>; 
        
        status = "okay";
    };


    Failure Analysis

    When we insert the mailbox-test.ko module, the kernel execution hits the following failure chain:

    1. The driver successfully probes (due to the correct compatible string).

    2. It calls mbox_request_channel(..., "tx").

    3. The request fails immediately with the error message: "invalid resource, failed to request tx and rx channels error."

    This indicates the resource specified in mboxes is not valid because the Mailbox Controller driver (omap-mailbox.c) is failing to successfully register the channel resources.

    Root Cause Diagnosis

    Previous troubleshooting showed a persistent -EPROBE_DEFER (-517) error on the omap-mailbox.c driver itself. The current "invalid resource" error is a direct consequence of that deferral. The resource is invalid because the controller that provides it is never fully probed.

    Since the omap-mailbox.c driver uses the TI HWMOD framework for clock and power management:

    TI Support Request (Action Required)

    We have isolated the problem entirely to the TI-supported drivers and Device Tree structure. We need to resolve the -EPROBE_DEFER blocking the omap-mailbox.c driver.

    Please provide the exact status = "okay"; configuration required for the L4 Interconnect and/or the necessary PRCM Power Domain node(s) on the AM571x that are mandatory dependencies for the mailbox5 HWMOD to probe successfully.

    dts files looks like this

    // 1. The Physical Mailbox Controller (Root of the resource)
    mailbox5: mailbox@48840000 {
    compatible = "ti,omap4-mailbox";
    reg = <0x48840000 0x200>;
    // Includes interrupts...
    ti,hwmods = "mailbox5"; // Relies on HWMOD for clock/power
    #mbox-cells = <2>;

     // VERIFIED: This MUST be set to "okay"
    status = "okay";
    };

    // 2. The Channel Sub-Node (Used for linking to clients)
    mbox_dsp1_ipc3x: mbox_dsp1_ipc3x {
    #mbox-cells = <2>;

     // VERIFIED: This MUST be set to "okay"
    status = "okay";
    };

    -----------------------------------------------------------------------------------------------

    // 3. DSP Core Node (Used by Remoteproc Driver)
    &dsp1 {
    // Other RPROC related memory properties...

     // Key VERIFIED: Reverted to "okay" for standard operation
    status = "okay";

    // Channels required by the omap_remoteproc driver
    // Note: The RPROC driver uses the simple <&mailbox5 ID 0> style
    mbox-names = "dsp_tx", "dsp_rx";
    mboxes = <&mailbox5 5 0>, <&mailbox5 1 0>;
    };

    // 4. Official Test Client Node (Used for diagnosing the -517 failure)
    / {
    mailbox_test: mailbox-test {
     // VERIFIED: The exact string for the official driver
    compatible = "ti,mailbox-test";

     // VERIFIED: The exact names requested by the driver's C code
    mbox-names = "tx", "rx";

    // Links the names above to the enabled channel sub-node
    mboxes = <&mbox_dsp1_ipc3x 0 0>, <&mbox_dsp1_ipc3x 0 1>;

     //VERIFIED: This MUST be set to "okay"
    status = "okay";
    };
    };

  •  ,

    Can you please share how you are testing this on SDK 11.1? Are you using TI HW? 

    Please submit your procedure.

    -Josue

  • We are making use of following versions.

    Linux SDK version : ti-processor-sdk-linux-am57xx-evm-06.03.00.106

    RTOS : processor_sdk_rtos_am57xx_6_03_00_106.

    Files changed

    1. in .config

    CONFIG_MAILBOX_TEST=m --> enabled kernel module

    2. in am571x-idk.dts

    .........../ {

    ..............

    //Added this node

    mailbox-test {
    compatible = "ti,mailbox-test";
    //mbox-names = "dsp_tx", "dsp_rx";
    mbox-names = "tx", "rx";
    mboxes = <&mbox_dsp1_ipc3x 0 0>, <&mbox_dsp1_ipc3x 0 1>;
    status = "okay";
    };

    };

    &dsp1 {
    memory-region = <&dsp1_memory_region>;
    mboxes = <&mbox_dsp1_ipc3x 0 0>, <&mbox_dsp1_ipc3x 0 1>; ---> Added this line 
    //mboxes = <&mailbox5 0 0>, <&mailbox5 0 1>;
    status = "okay";
    };


    3. in dra7-ipu-dsp-common.dtsi makes mailbox5 node okay

    &dsp1 {
    //mboxes = <&mailbox5 &mbox_dsp1_ipc3x>; ---> commented this line 
    timers = <&timer5>;
    watchdog-timers = <&timer10>;
    };

    4. in dra7.dtsi

    mailbox5: mailbox@48840000 {
    compatible = "ti,omap4-mailbox";
    reg = <0x48840000 0x200>;
    interrupts = <GIC_SPI 249 IRQ_TYPE_LEVEL_HIGH>,
    <GIC_SPI 250 IRQ_TYPE_LEVEL_HIGH>,
    <GIC_SPI 251 IRQ_TYPE_LEVEL_HIGH>,
    <GIC_SPI 252 IRQ_TYPE_LEVEL_HIGH>;
    ti,hwmods = "mailbox5";
    #mbox-cells = <2>;  ---> Added this line 
    ti,mbox-num-users = <4>;
    ti,mbox-num-fifos = <12>;
    status = "disabled";
    };

    5. in dra72x.dtsi

    &mailbox5 {
    mbox_ipu1_ipc3x: mbox_ipu1_ipc3x {
    ti,mbox-tx = <6 2 2>;
    ti,mbox-rx = <4 2 2>;
    status = "disabled";
    };
    mbox_dsp1_ipc3x: mbox_dsp1_ipc3x {
    #mbox-cells = <2>;   ---> Added this line 
    ti,mbox-tx = <5 2 2>;
    ti,mbox-rx = <1 2 2>;
    status = "disabled";
    };
    };

    At Dsp side MessageQ application was loaded ln -s /home/root/server_dsp1.xe66 dra7-dsp1-fw.xe66

    logs are as follows...

    root@am57xx-evm:/lib/firmware# rm dra7-dsp1-fw.xe66
    root@am57xx-evm:/lib/firmware# ln -s /home/root/server_dsp1.xe66 dra7-dsp1-fw.xe66
    root@am57xx-evm:/lib/firmware# cd /sys/bus/platform/drivers/omap-rproc/
    root@am57xx-evm:/sys/bus/platform/drivers/omap-rproc# echo 40800000.dsp > unbind;echo 40800000.dsp > bind
    [ 445.212171] remoteproc remoteproc2: releasing 40800000.dsp
    [ 445.217980] omap-rproc 40800000.dsp: ignoring dependency for device, assuming no driver
    [ 445.235235] omap-rproc 40800000.dsp: ignoring dependency for device, assuming no driver
    [ 445.244156] omap-rproc 40800000.dsp: assigned reserved memory node dsp1-memory@99000000
    [ 445.253641] remoteproc remoteproc2: 40800000.dsp is available
    [ 445.266072] remoteproc remoteproc2: powering up 40800000.dsp
    root@am57xx-evm:/sys/bus/platform/drivers/omap-rproc# [ 445.280246] remoteproc remoteproc2: Booting fw image dra7-dsp1-fw.xe66, size 5081576
    [ 445.290292] omap-iommu 40d01000.mmu: 40d01000.mmu: version 3.0
    [ 445.296228] omap-iommu 40d02000.mmu: 40d02000.mmu: version 3.0
    [ 445.303494] mailbox_test mailbox-test: invalid resource
    [ 445.308754] Inside ************my test Mailbox***************
    [ 445.315399] mailbox_test mailbox-test: invalid resource
    [ 445.320662] mailbox_test mailbox-test: Failed to request tx channel
    [ 445.327952] mailbox_test mailbox-test: Failed to request rx channel
    [ 445.342466] omap-rproc 40800000.dsp: mbox_request_channel failed: -517
    [ 445.349183] remoteproc remoteproc2: can't start rproc 40800000.dsp: -16

    root@am57xx-evm:/sys/bus/platform/drivers/omap-rproc# rmmod rmmod mailbox-test.ko
    rmmod: ERROR: Module rmmod is not currently loaded
    root@am57xx-evm:/sys/bus/platform/drivers/omap-rproc# cd -
    /lib/firmware
    root@am57xx-evm:/lib/firmware# cd -
    /sys/bus/platform/drivers/omap-rproc
    root@am57xx-evm:/sys/bus/platform/drivers/omap-rproc# cd ~
    root@am57xx-evm:~# rmmod mailbox-test.ko
    rmmod: ERROR: Module mailbox_test is not currently loaded
    root@am57xx-evm:~# cd -
    /sys/bus/platform/drivers/omap-rproc
    root@am57xx-evm:/sys/bus/platform/drivers/omap-rproc# echo 40800000.dsp > unbind;echo 40800000.dsp > bind
    [ 503.882173] remoteproc remoteproc2: releasing 40800000.dsp
    [ 503.887985] omap-rproc 40800000.dsp: ignoring dependency for device, assuming no driver
    [ 503.905110] omap-rproc 40800000.dsp: ignoring dependency for device, assuming no driver
    [ 503.914069] omap-rproc 40800000.dsp: assigned reserved memory node dsp1-memory@99000000
    [ 503.924533] remoteproc remoteproc2: 40800000.dsp is available
    [ 503.936260] remoteproc remoteproc2: powering up 40800000.dsp
    root@am57xx-evm:/sys/bus/platform/drivers/omap-rproc# [ 503.950436] remoteproc remoteproc2: Booting fw image dra7-dsp1-fw.xe66, size 5081576
    [ 503.960493] omap-iommu 40d01000.mmu: 40d01000.mmu: version 3.0
    [ 503.966427] omap-iommu 40d02000.mmu: 40d02000.mmu: version 3.0
    [ 503.974013] alloc_contig_range: [99004, 99007) PFNs busy
    [ 503.986508] omap-rproc 40800000.dsp: mbox_request_channel failed: -517
    [ 503.993125] remoteproc remoteproc2: can't start rproc 40800000.dsp: -16

    root@am57xx-evm:/sys/bus/platform/drivers/omap-rproc# cd -
    /home/root
    root@am57xx-evm:~# insmod mailbox-test.ko
    [ 583.959088] mailbox_test mailbox-test: invalid resource
    [ 583.969194] Inside ************my test Mailbox***************
    [ 583.975961] mailbox_test mailbox-test: invalid resource
    [ 583.981233] mailbox_test mailbox-test: Failed to request tx channel
    [ 583.988962] mailbox_test mailbox-test: Failed to request rx channel
    root@am57xx-evm:~# cd -
    /sys/bus/platform/drivers/omap-rproc
    root@am57xx-evm:/sys/bus/platform/drivers/omap-rproc# echo 40800000.dsp > unbind;echo 40800000.dsp > bind
    [ 603.792161] remoteproc remoteproc2: releasing 40800000.dsp
    [ 603.797975] omap-rproc 40800000.dsp: ignoring dependency for device, assuming no driver
    [ 603.815114] omap-rproc 40800000.dsp: ignoring dependency for device, assuming no driver
    [ 603.824068] omap-rproc 40800000.dsp: assigned reserved memory node dsp1-memory@99000000
    [ 603.834433] remoteproc remoteproc2: 40800000.dsp is available
    [ 603.846129] remoteproc remoteproc2: powering up 40800000.dsp
    root@am57xx-evm:/sys/bus/platform/drivers/omap-rproc# [ 603.860269] remoteproc remoteproc2: Booting fw image dra7-dsp1-fw.xe66, size 5081576
    [ 603.870343] omap-iommu 40d01000.mmu: 40d01000.mmu: version 3.0
    [ 603.876280] omap-iommu 40d02000.mmu: 40d02000.mmu: version 3.0
    [ 603.883664] mailbox_test mailbox-test: invalid resource      //From ARM driver 
    [ 603.888925] Inside ************my test Mailbox***************
    [ 603.895615] mailbox_test mailbox-test: invalid resource
    [ 603.900882] mailbox_test mailbox-test: Failed to request tx channel
    [ 603.908183] mailbox_test mailbox-test: Failed to request rx channel
    [ 603.921935] omap-rproc 40800000.dsp: mbox_request_channel failed: -517 // From DSP
    [ 603.928502] remoteproc remoteproc2: can't start rproc 40800000.dsp: -16   

    kindly guide us 

  •   ,

    This SDK is way past its support window and the activity you seem to be doing is not supported.  This Mailbox test is not a TI example.

    Please reach out to the corresponding open source community for support.

    See: https://software-dl.ti.com/processor-sdk-linux/esd/docs/06_03_00_106/linux/Overview_Technical_Support.html#open-source-software-support-disclaimer

    -Josue

  • Atleast you can guide right? tell us what is the correct procedure to test irrespective of any SDK  version? 

    I appreciate you providing the support disclaimer, but I must respectfully state that your conclusion that this activity is unsupported is incorrect and misses the core technical issue.

    1. Rebuttal: The Issue is a TI Driver Failure

    This is not a custom driver problem; it is a failure of the built-in, TI-supported kernel drivers to initialize core platform resources.

    • The Driver: We are currently testing with mailbox-test.c, which resides in the standard Linux kernel tree (drivers/mailbox/) and is a generic kernel component used to validate Mailbox functionality. If this generic driver fails, it is because the underlying platform hardware support is broken.

    • The Evidence: Our kernel logs confirm that the root cause is the omap-mailbox.c driver (which handles the ti,omap4-mailbox compatible string and uses the ti,hwmods framework) is throwing a persistent -EPROBE_DEFER (-517) error.

    • The Conclusion: The resource is "invalid" because the official TI Mailbox Controller driver cannot initialize the hardware due to a failure in the power/clock dependency chain (L4 Interconnect/PRCM). This is a kernel integration issue that is 100% dependent on the Device Tree configuration provided by TI for the AM571x.

    We are simply asking for the necessary configuration to make the TI-provided kernel components functional on the TI hardware.

    2. Required Guidance on Procedure and Resources

    If the specific SDK version is obsolete, then the underlying platform architecture is not. Since the AM571x architecture remains consistent, the basic IPC procedure must be documented.

      your core duty is to provide guidance on the intended development path, even if it directs us to a newer, equivalent document.

    Please confirm the following:

    1. PRCM/L4 Enabling: What is the exact, supported procedure for enabling the PRCM and L4 Interconnect nodes on the AM571x in the Device Tree to resolve the -EPROBE_DEFER error on the Mailbox controller? We require the specific node phandles.

    2. Official IPC Example: Please confirm the name and location of the currently supported DSP firmware binary (e.g., a .xe66 file) that must be loaded via Remoteproc to establish a valid IPC endpoint for communication testing.

    We need technical guidance on the platform dependencies, not a refusal to support fundamental platform functionality. Please escalate this request internally to a support engineer who can provide the necessary Device Tree configuration to resolve the -517 error.

  •  

    TI does not offer free support for  custom driver development.  That is the purpose for the generic use "mailbox-test.c" as well as your original post:

    Driver: Custom Mailbox Client Platform Driver (C code provided below).

    This SDK release has been used by many customers and we do not have any indication of your inference above.

    it is a failure of the built-in, TI-supported kernel drivers to initialize core platform resources.

    Please share an example of using TI SW/FW-examples only and perhaps we can try to reproduce as time permits (This will be done on latest supported SDK). Otherwise, we can help connect with our trusted third party sources that can help you.

    Best,

    Josue

  • in that case how to test the mailbox concept working? If i use generic driver you are saying it is not officialiy supported, if I use mailbox-test.c which is existing in the kernel itself that also not supported .. then guide us how we can test the mailbox ? kindly provide atleast this much support.

    give us some guidance on mentioned SDK how we can test Mailbox concept...

  • Prassanna,

    You can observe how this works in the kernel drivers with the TI examples, alongside TRM that has a very thorough description alongside a programming guide:



    Code inspection, code tracing etc. 

    Best,

    Josue