It depends on the value of timer T300
This setting determines how long the UE waits for the RRC Connection Setup after sending an RRC Connection Setup Request.
T300 can be set to one of the following values: 400, 600, 800, 1000, 1200, 1400, 1600, 1800, 2000, 3000, 4000, 6000, 8000 ms.