How to ensure serial transmission and reception of required data without any garbage values in the 8051?
That's actually a subtle "gotcha" in asynchronous serial communications &mdash; if there are never any gaps in the data that are at least as long as a character time, it's possible for the receiver to get out of sync with respect to the byte boundaries, and there's no way to recover. Any '1' followed by a '0' could be construed as being a stop bit/start bit pair.

One possible fix would be to send a byte of all-zeros (or all-ones) every now and then. If the receiver is out of sync, this will force it to resynchronize on the next start bit.