How would native speaker say that phase?
So do you like doing homework. Do spend on it barely enough time to pass by? Or you working hard on it to get the best possible score?
To spend barely enou time to pass by on something is implying that you don't spend time at all on it- so maybe wrong context...
As a native speaker, I would say:
So I hear you like homework. Do you spend a tonne of time on time? Or are you just doing heaps to boost your grades? (Or get higher marks)