A person can accumulate unlawful presence by (1) coming to the US without being inspected by immigration officials at the boarder, (2) overstaying his visa in the US by not leaving after his visa expires, or (3) by violating his status by being notified by the government of the violation of status.
If a person accumulates unlawful presence in the US, they must obtain a waiver by filing form I-601 to the USCIS. In addition, he must show by convincing evidence that his US citizen or Green Card holder spouse or parent'(s) would suffer "extreme hardship" if he is not able to join them in the US and therefore the waiver should be granted.
In 2013, the US congress expanded the I-601 and it became possible to apply for a I-601A while remaining in the US. A 2016 rule expanded the qualifying relatives needed in order to apply for a provisional waiver.
We hope that the materials linked to below help you to better understand both concepts.