Flashing back to Stock 2.2

I am not planning on doing this, but this just popped into my head. If you have installed a custom kernal while rooted, and you want to flash back to 2.2, do you need to install the stock kernal, or do you not need to worry about it?

I don't think so, cuz ROM Manager says you can select whether you want rooted or unrooted for that ROM. So if you select unrooted, presumably you are left unrooted. No idea if it flashes over the stock recovery though. You'd think...