disable the tx2 serial console (/dev/ttyS0)in ubuntu18.04

Hi,
I want to use the tx2 /dev/ttyS0 as Serial Communication with other device.but it is used as the linux console.
So,I want to disable it as the console. and use it like the other serials (/dev/ttyTHS*).
How can I do?

You might find this thread of interest:
https://devtalk.nvidia.com/default/topic/1025894/jetson-tx2/uart1-acts-as-default-debug-port-on-tx2-r28-1/post/5220368/#5220368

The thread is a bit older, but I believe this is still correct information. That thread shows how to move serial console to a different console, but all you would need to do is skip the part of moving to a new UART.