Hello Fernandos,
It looks like you have the pin-mux settings correct so I think we can rule out a problem with the device tree configuration.
How are you controlling the can modules? From the command line using 'ip link set can0...', or can-utils (canconfig...)?
The first thing to check would be what state the can controller is going into during the exercise. When you set it to 'bus on' mode does it very quickly go into 'error passive' (bus off) mode? If this is the case you probably have one of the following problems:
1) No receiving device: The can bus module relies on their being at least one other device on the network to acknowledge (pull the bus low) any transmitted message - if there is no such device the can bus will very quickly go into error passive mode after trying to tx your first message 127 consecutive times.
2) Incorrect bit timing: You may have another 'know good' device on the network, but you may have used incorrect bit timing and hence made your device incompatible with other devices on the bus. Check the specs of the other devices.
3) Incorrect physical layer wiring/termination: Make sure all your CAN-H's are wired together in parallel and that all your CAN-Ls are also, and that their is at least one 120Ohm resistor between these lines.
The fact that you can rx from another device in listen-only mode means you are close to having this working and that the physical layer is probably ok - although double check everything. It may be that there is some kind of auto baud rate detection going on in listen-only mode, so when you manually set your bit timings and go bus on things get broken.
Hope this helps.
Regards,
Andrew Glen.