if such loan includes— (A) repayment terms which are substantially similar to the terms of the loan of such corporation from a lender described in subsection (a), or (B) repayment terms providing for more rapid repayment of principal or interest on such loan, but only if allocations under the plan attributable to such repayment do not discriminate in favor of highly compensated employees (within the meaning of section 414(q)). (4) Controlled group of corporations For purposes of this subsection, the term controlled group of corporations has the meaning given such term by section 409(l)(4). (5) Treatment of refinancings The term securities acquisition loan shall include any loan which— (A) is (or is part of a series of loans) used to refinance a loan described in subparagraph (A) or (B) of paragraph (1), and (B) meets the requirements of paragraphs (2) and (3). (6) Plan requirements (A) In general A loan shall not be treated as a securities acquisition loan for purposes of this section unless, immediately after the acquisition or transfer referred to in subparagraph (A) or (B) of paragraph (1), respectively, the employee stock ownership plan meets the requirements of subparagraphs (B) and (C). (B) Plan must hold more than 5 percent of stock after acquisition or transfer An employee stock ownership plan meets the requirements of this subparagraph if the plan owns more than 5 percent of— (i) each class of outstanding stock of the corporation issuing the employer securities, or (ii) the total value of all outstanding stock of the corporation. (C) Plan must cover at least 50 percent of nonhighly compensated employees (i) In general An employee stock ownership plan meets the requirements of this subparagraph if at least 50 percent of the employees of each employer maintaining the plan who are not highly compensated employees (as defined in section 414(q)) are participants in the plan. (ii) Certain employees may be excluded For purposes of clause (i), an employer may elect to exclude under the plan employees— (I) who