WASHINGTON, March 22 (Reuters) - The Democratic-majority U.S. Senate on Friday was trying to pass a $1.2 trillion government funding bill after House of Representatives passage angered a Republican hardliner in that chamber, who threatened to try to oust Speaker Mike Johnson.

The House's 286-134 vote sent the measure to the Democratic-majority Senate, which has hours to act ahead of a midnight deadline (0400 GMT Saturday) to prevent parts of the Department of Homeland Security, Internal Revenue Service and Justice Department to Treasury and State departments from closing.

The Senate began a procedural vote on the matter on Friday, while leadership negotiated behind the scenes to bypass some of the chamber's Byzantine rules and allow for a swifter vote on passage.

The move marks a critical step toward ending a more-than-six-month battle over the scope of Washington's spending for the fiscal year that began Oct. 1. Ratings agencies have warned that the repeated brinkmanship could hurt the creditworthiness of a federal government that currently has more than $34.6 trillion in debt.

The measure passed the House with 185 Democrats and 101 Republican votes, which led hardline conservative Representative Marjorie Taylor Greene to introduce a measure to oust Republican Johnson.

Johnson himself ascended to that role in October after hardliners furious that his predecessor, Kevin McCarthy, had passed a temporary funding measure over their objections, ousted him as leader.

But Greene said she would not push for an immediate vote.

"I filed a motion to vacate today. But it's more of a warning than a pink slip," the Georgia Republican told reporters.

Photo from Reuters