Is there any document/link which talks about the rust calling convention (esp between rust and risc-v assembly ). I am more interested in which registers are used for function parameters and in what order.
The standard Rust calling convention is unstable and unspecified. You can choose a different calling convention when declaring or defining a function. I don't know what the extern "C" calling convention is on RISC-V specifically, but presumably there's some standard definition for your target?