code: func (s *Ethereum) StopMining() {
  	// Update the thread count within the consensus engine
  	type threaded interface {
  		SetThreads(threads int)
  	}
  	if th, ok := s.engine.(threaded); ok {
  		th.SetThreads(-1)
  	}
  	// Stop the block creating itself
  	s.miner.Stop()
  }
docs: // StopMining terminates the miner, both at the consensus engine level as well as
  // at the block creation level.