You could limit your function to only accept units of time:
ClearAll[d]
d[t : Quantity[_, unit_]?(CompatibleUnitQ[#, "Seconds"] &)] := 10*t^2
d[Quantity[5, "Seconds"]]
or, similarly, one could use UnitDimensions to check if the input has time-dimensions... Of course the 'variables' 10, 5, and 25 in your equation should have commensurate dimensions...