(Bloomberg) -- Air Canada reached a deal with the Canadian government for loans and equity worth nearly C$5.9 billion ($4.7 billion), a package to help the airline get through the pandemic and restore flights to remote parts of the country. The state, which sold off its ownership interest in the 1980s, will once again own a piece of Canada’s largest airline, buying C$500 million of shares at a discount. Prime Minister Justin Trudeau’s government also negotiated warrants as part of a broad financing agreement that makes Air Canada eligible for five new credit facilities totaling C$5.38 billion, according to a company statement.In return for the money, Air Canada agreed to restrict share buybacks and dividends, keep employment at April 1 levels and follow through on a deal to buy 33 Airbus SE A220s made at a factory in Quebec. Executives won’t be allowed to earn more than C$1 million.And the airline will resume service on routes its suspended to distant locations such as Gander, Newfoundland and Yellowknife, in the country’s far north. The long-anticipated announcement will ease tensions between the industry and Trudeau’s government, which since last March has barred most foreign travelers from entering the country and recently made the rules even tougher.Air Canada repeatedly complained that its home country was the only Group of Seven member without an aid plan specifically for the aviation sector -- although the company has used federal wage subsidies available to all industries hit by the pandemic.“We wanted a good deal, not just any deal. And getting a good deal can sometimes take a little time,” Finance Minister Chrystia Freeland said at a news conference Monday evening.Air Canada also committed to paying back customers who didn’t take flights they had booked because of Covid-19. One of the credit facilities, a C$1.4 billion line, is dedicated to financing refunds.‘Solid Guarantees’ Air Canada will issue 21.6 million new shares. While the equity component is “somewhat surprising,” the package is “the money that’s needed,” said Robert Kokonis, managing director of Toronto-based aviation consulting firm AirTrav Inc.“It’s going to take a lot of aid for carriers. We’ve been through a lot. We’ve been on standby while airlines in countries around the world have received one or more aid packages,” Kokonis said. Freeland said talks are ongoing with other airlines, including WestJet Airlines Ltd., controlled by Toronto-based investment firm Onex Corp. Tour operator Transat AT Inc. also needs money and has said it’s talking to the government after a deal to be taken over by Air Canada fell apart. “Wherever and whenever the federal government provides public aid, the supported company will have to give solid guarantees, as Air Canada did, that the public interest will be respected, workers protected, and travelers’ interest defended,” Freeland said.As of March 18, government financing for the airline industry globally -- including loans and equity stakes in exchange for cash -- has totaled more than $183 billion, according to Ishka Ltd., an aviation finance and investment consultancy.Before Monday’s agreement, Canada’s most visible lifeline to the industry was a combined C$375 million in emergency loans to Sunwing Airlines Inc. and Sunwing Vacations Inc., a small vacation operator.Air Canada said it will only draw down the new credit facilities “as required”. The package includes C$2.48 billion in unsecured loans. “This program provides additional liquidity, if required, to rebuild our business to the benefit of all stakeholders and to remain a significant contributor to the Canadian economy through its recovery and for the long term,” Chief Executive Officer Michael Rousseau said in a statement.(Updates with new details, analyst quote.)For more articles like this, please visit us at bloomberg.comSubscribe now to stay ahead with the most trusted business news source.©2021 Bloomberg L.P.