G54 is used to select work coordinate system 1.
This allows you to define different coordinate systems for different work pieces or setups.
For detailed information about G54 and work coordinate systems, see the LinuxCNC G54-G59.3 documentation.