On this daf, we find that whoever is obligated to do yibum can do chalitzah instead.
Tragically, a certain childless woman lost her husband. The brother of the deceased thought that he had a halachic proof that he would be permitted to do yibum. He presented his rationale before the court: “Of course, the main problem is that the Shulchan Aruch rules that one who does ybbum for an ulterior motive is likened to one who marries his brother’s wife without a heter. Yet, the Aruch Hashulchan rules that one who does yibum for ulterior motives but also to do the mitzvah may do yibum. I can guarantee the bais din that I want to fulfill this mitzvah with all of my heart and I hope you will rule that I can rely on this well-reasoned psak…”
When this proposal was presented to the Divrei Malkiel, he rejected it. “This ruling of the Aruch Hashulchan is difficult to understand and cannot be relied on, since it contradicts the Gemara in Zevachim… It seems clear from there that having the correct intentions while also harboring incorrect ones is called shelo lishmah and invalidates such a union” (Shu”t Divrei Malkiel).