In order to achieve high-precision clock synchronization among instrument nodes in distributed LXI bus test systems. A Hardware time stamping method for PTP messages is introduced in this paper. It is implemented in Linux systems, which runs on ARM9 S3C2440 processor. The special PHYTER DP83640 is used to mark the time of PTP messages in physical layer. The new socket option SO-TIMESTAMPING is used to obtain the hardware timestamps in user space programming. A clock synchronization test has been done after transplanting the open source protocol software PTPd on this platform.