All I remember is the guy was sent to a planet to test something or he did something illegal, and time moved really fast on the planet but slow to the outside world. He had to fix something to leave the planet I think. His dad was also dying and he checked how many days he had left every day, but in the end his dad didn't actually die as time was fast. It took place on a sandy planet.
Could be Arrowhead (also known as Alien Arrival) from 2015.
Selected bits of the summary (emphasis mine):
While escaping a political prison on a mining colony, Kye Cortland is forced to amputate his foot to save himself and the other prisoners from being torn apart by the mining machinery. Cortland is recruited to join the rebellion against General Lang, who won a civil war against General Hatch. Hatch explains to Cortland that his father, an important figure to the rebellion, is scheduled to be executed in several months on the anniversary of Lang's victory. Hatch wants Cortland, an accomplished pilot, to hijack a scientific vessel, retrieve its data, and use it to help Hatch free Cortland's father. Cortland receives a cybernetic foot and agrees.
Cortland escapes in a shuttle, landing near the escape pods on a desert moon.
He then finds out that Hollis left the planet with another pod. Grateful, RE3F illegally grants Cortland access to confidential information, revealing that the moon is the subject of a relativistic time dilation experiment. Hatch and Lang want to use the planet offensively against each other's forces. Hatch lands on the moon, explaining that 20 minutes have passed from his point of reference.
YouTube Trailer (father and time dilation not mentioned/shown):