The new management of Marvel Entertainment Group Inc. reached an agreement with its banks, bondholders and the principal shareholders of Toy Biz Inc. that promises to end months of bitter legal battles and allows the comic giant to emerge from bankruptcy. Chase Manhattan Bank attorney Thomas Ambro told U.S. Bankruptcy Court Judge Helen Balick that under the agreement, two entities controlled by investor Carl Icahn will buy $610 million in secured claims that Marvel owes Chase and other banks. Last month, a dissident group of Marvel bondholders, headed by Icahn, won a prolonged legal battle to take control of the debtor companies. The group claims that Marvel controls 70% of Toy Biz, which has an exclusive, royalty-free license to make toys based on Marvel's characters, including Spiderman, X-Men and Incredible Hulk. But the toy maker contends that Marvel's stake had been reduced to only 27%. Marvel filed for Chapter 11 bankruptcy protection in December. Under the agreement, Marvel will pay its bank creditors $395 million in cash, proceeds from the sale of Marvel subsidiaries Fleer Corp. and Panini, and warrants to buy 10% of a reorganized company, which will merge Marvel with Toy Biz.