The only way to absolutely, positively do this is to provide some sort of non-re-writebable value that can be read by the host.
EEPROMs can be wiped and reflashed, so that doesn't really work unless you write-protect a section of it. If you can do that you can not only encode the board rev, but a serial number as well.
If you have some OTP available, even better.
Board straps are a historically common, but not cost-friendly method. Not only does it need extra hardware, it also has the burden of managing a BOM to go with it to configure the straps, so more business units have to get involved on each release. It's painful and error-prone.
Some companies keep track by keeping a database of serial numbers and assigning the rev information in a database. This works for a push-update model like a set-top box for example, but not for a standalone device.