Chrysler Group LLC is in advanced discussions with banks on refinancing about $7 billion in government debt and establishing a credit facility in a process that would help clear the way for its initial public offering later this year.

Chrysler, led by Chief Executive Sergio Marchionne, is looking to refinance a little over $7 billion of debt owed to the U.S. and Canadian governments, in a deal expected to include both bank term loans and bonds, six people with knowledge of the discussions said.

As part of the refinancing package, the No. 3 U.S. automaker is also expected to seek a credit facility of between $2 billion and $3 billion, these people said, asking not to be named because the discussions remain confidential.

Chrysler, which emerged from its 2009 U.S. government-financed bankruptcy under the control of Fiat SpA , has been focused on shoring up its balance sheet as it gears up for its return to the U.S. stock market.

Clinching a credit revolver ahead of the IPO would mirror the path taken by General Motors Co last year, which secured a $5 billion credit facility ahead of its record-setting $23.1 billion IPO in November.

The United Auto Workers union, which owns a 63.5 percent stake in Chrysler through its affiliated VEBA healthcare trust, has also been involved in the discussions, one of the sources said.

(Reporting by Soyoung Kim in New York and Philipp Halstrick in Frankfurt; additional reporting by Clare Baldwin in New York and Deepa Seetharaman in Detroit)