Don't touch it yet. List it for sale and ask the potential buyer if they wanted it rooted with a ROM, or stock. If they want it rooted with a ROM, simply wipe all data, load the ROM, ensure that it boots up, and send it off.
If they want it stock, or if you don't want to be their customer support, do the following:
-set S-On
-run the latest RUU
-load it up to ensure it works, then factory rest
In addition to software, make sure the phone itself is clean.