<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def rpc_stop(server_state):
 """ Stop the global RPC server thread """

    rpc_srv = server_state['rpc']

    if rpc_srv is not None:
        log.info("Shutting down RPC")
        rpc_srv.stop_server()
        rpc_srv.join()
        log.info("RPC joined")

    else:
        log.info("RPC already joined")

    server_state['rpc'] = None