R' Yanai says that a talmid should not stand for his rebbi more than twice a day so that the kavod for the rebbi doesn't exceed kavod for hashem (krias shema which is kabalas malchus shamayim and only twice a day). The Ri"f holds that R' Elazar who says that if you don't stand for your rebbi you are called a rasha, argues on R' Yanai and we pasken like R' elazar (gr"a y.d. 242:53). But the Rambam paskens like R' Yanai.
Tosafos asks, why do we find that the rava was makpid that his talmidim didn't stand for him, maybe they already stood up twice that day without him realizing? Tosafos answers that when one is in a situation where the people don't realize that you already stood up, you are required to stand up more than twice. It is only if the people around all know that you already stood up twice that you don't have to stand up.
The Tosafos Yeshanim asks the same question as Tosafos and answers that אין תלמיד רשאי לעמוד מפני רבו אלא שחרית וערבית doesn't mean that he is not allowed to, rather it means he does not have to. Since he is allowed to, the Rebbi can be makpid if the talmid chooses not to stand. Based on the answer of the Tosafos Yeshanim (using the definition of "r'shai" from tosafos 33a), there is nothing that compels the chiddush of Tosafos that when you are in the presence of people who don't know that you stood up, you have to stand more than twice.
In other words, if "אין ת"ח רשאי" means "he is not allowed", then we are compelled to say that when in the presence of people who don't know he already stood twice, he has to stand again. But if it means "he is not required" then he is never required more than twice a day even when in the presence of new people who don't know that he already stood up. Based on this, there is a question on the Rama (y.d. 242:16) who translates "not required" implying that he is allowed to stand multiple times like the tosafos yeshanim, yet he writes that when in the presence of new people who don't know that he already stood twice, he must stand again, like Tosafos! Why does the Rama feel compelled to make the distinction of Tosafos if he is learning the words אין ת"ח רשאי like the tosafos yeshanim?