Interestingly, you are asking about the total (or net) work done on the fluid, rather than how fast it travels out the "s-hole" on the other side. Intuitively, we know that the smaller the value of s, the faster the velocity of the water shooting out. So how does a change in s affect the total work done shooting all of the water out (or evacuating the piston)? The answer is that it doesn't.
This total energy is just E = P*ΔV, where P = F/A, where F is the force you are pushing, A is the cross sectional area of the piston, and ΔV is the total volume of the piston. What this means is that if you push harder, you will be putting more work into the system, thereby shooting the water out faster. But notice how this does not involve s?
But how can this be that the same total energy goes into evacuating the fluid from the piston, regardless of hole size? Well this fact comes from Bernoulii's Equation and volumetric flow rate conservation [v1*A1=v2*A2]. Let's say you are doing this in space orbit, where gravity may be neglected. Comparing two pistons of different sized holes, s, the smaller hole shoots out the water faster that that with a larger hole. But this must mean that the fluid velocity inside the piston is comparatively less for the smaller s. We know this, since the smaller s will take longer to evacuate. So for smaller s, we are actually imparting less average kinetic energy but for a longer period of time. These two effects cancel out, and make it so that both s holes take the same amount of work to evacuate, if using the same force.