With modern bodies being able to reach silly high ISOs with more than acceptable results, the argument about using f/2.8 over f/4 isnt as valid, although it's still a major consideration when thinking about AF and viewfinder brightness. Of course, DoF is more flexible with the wider lens also, which is a given.
However, you're on a 40D, which was never renowned for being amazing at high ISO, so I'd probably opt for a fast lens instead of relying on the sensor to make up the shortfall in available light. Plus, the majority of 17-50/55mm f/2.8 lenses are top-notch and you'll be impressed by the image quality you get from them. Tamron, Sigma, Tokina plus Canon all make variants tht cover that range, all at varying prices. The Canon is supposed to be very good, but the Tamron I use is very good also for half the price.
Plus, 17-XXmm is a much easier option to use every day on a crop body over a 24-105, which although it has the range, is an awkward wide end for crop body use.
Now, a 17-105mm f/2.8 would be handy. but I don't think we'll be seeing one of those any time soon.