Should I mention the name of a professor on my resume if I'm not getting a recommendation letter from him?
Whatever the reason is that you're not asking a letter from the professor, would that not also extend to being contacted about the work you did? My point being is that if you think a letter wouldn't be favorable then you would also be worried about an email or phone call also not being favorable.

If however that isn't the case, then it's entirely circumstantial. Does the program you're applying for require letters of recommendation? If so, why not just ask? If it doesn't require a letter of recommendation then you can just mention it to the professor that you've applied for a position and would it be alright if they are a reference?

Don't stick someone on your CV and not tell them about it. Professors don't like being cold called about this kind of thing.