What should Hashem do to him if he will not tell?
Rashi: Like the same curse [that Eli received] 1 , that he will not have proper children. And so occurred to Shmuel, even though he told him and did not withhold. Chachamim learned from here that a Chacham's curse is fulfilled, even if it was conditional (and the condition was not fulfilled - Makos 11a).
Radak: It is the custom to say so in a Shevu'ah. We find like this - "Ko Ya'aseh Li Elokim" (Shmuel 2 19:14).
Radak: That his sons will not inherit his position.
Why was Eli so adamant that Shmuel tell him the prophecy?
Malbim (16): Eli understood that it was about his own house, for he already received the prophecy of Ish ha'Elokim that day. "The heart knows the bitterness of its soul" (Mishlei 14:10).