Third Amendment to Restated Loan Agreement



 Exhibit 10.1 
 THIRD AMENDMENT TO RESTATED LOAN AGREEMENT 
 This Third Amendment to Restated Loan
Agreement (this “Amendment”) dated as of August 2, 2011, is made among GMX RESOURCES INC., an Oklahoma corporation (the “Borrower”), the LENDERS (as defined below), CAPITAL ONE, NATIONAL ASSOCIATION, a national
banking association, as administrative agent, arranger and bookrunner, for the Lenders (and individually as a Lender), and BNP PARIBAS, as syndication agent (and individually as a Lender), who agree as follows: 

RECITALS 
 A.
This Amendment pertains to that certain Fifth Amended and Restated Loan Agreement dated effective as of February 2, 2011, among the Borrower, the Agent and the Lenders, as amended by the First Amendment dated as of February 3, 2011, and by
the Second Amendment dated as of March 1, 2011 (as amended, the “Loan Agreement”). As used in this Amendment, capitalized terms used herein without definition herein shall have the meanings provided in the Loan Agreement.

 B. The Borrower, the Agent and the Lenders desire to amend the Loan Agreement to modify a financial covenant, to amend in
certain circumstances the pricing of the Loan, and otherwise to provide for other matters with respect to the Loan. 
 AGREEMENT

 NOW, THEREFORE, in consideration of the terms and conditions contained herein, and the loans and extensions of credit
heretofore, now or hereafter made to the Borrower by the Lenders, subject to the conditions precedent in Paragraph 3.5 below, the parties hereto hereby agree as follows: 
 ARTICLE 1.  
 AMENDMENT 

1.1 Section 1.2 of the Loan Agreement is hereby amended to amend and restate the definitions of Applicable LIBO Rate Margin and
Applicable Prime Rate Margin, each to read in its entirety as follows: 
 “Applicable LIBO Rate Margin” shall
mean, on any day, the following per annum interest rate from time to time, determined on each Business Day (except as provided in the last sentence of this definition) by reference to the Percentage Outstanding on such day in accordance with the
following schedule: 
  

					
	 Percentage Outstanding
	  	Applicable LIBO
Rate Margin	 
		
	 0 to 35%
	  	 	2.00	% 
	 above 35% to 65%
	  	 	2.50	% 
	 above 65% to 80%
	  	 	2.75	% 
	 above 80%
	  	 	3.50	% 








 For each separate LIBO Rate tranche, the Applicable LIBO Rate Margin shall be initially set
by reference to the Percentage Outstanding on the first day of that tranche’s LIBO Rate Interest Period. Changes in the Applicable LIBO Rate Margin shall become effective on the Business Day on which a change occurs in the Percentage
Outstanding that results in a shift between which of the above schedule lines is in effect. However, for any period ending before January 1, 2012, when the Borrower’s ratio of EBITDA to Interest Expense under Subsection 5.15(b) is
less than 2.50 to 1.00, the Applicable LIBO Rate Margin shall be increased by 1.50% in accordance with Subsection 2.1(h); provided; however, in the event the ratio of EBITDA to Interest Expense is lower than the required level during the
applicable period described in Subsection 5.15(b), the Default Rate shall apply instead if the Agent and the Required Lenders so elect in accordance with Section 2.7. 

“Applicable Prime Rate Margin” shall mean, on any day, the following per annum interest rate from time to time,
determined on each Business Day (except as provided in the last sentence of this definition) based on the Percentage Outstanding on such day, in accordance with the following schedule: 

 

					
	 Percentage Outstanding
	  	Applicable Prime
Rate Margin	 
		
	 0 to 35%
	  	 	1.00	% 
	 above 35% to 65%
	  	 	1.50	% 
	 above 65% to 80%
	  	 	1.75	% 
	 above 80%
	  	 	2.50	% 

 Changes to the Applicable Prime Rate Margin shall become effective on the Business Day on which a change
occurs in the Percentage Outstanding that results in a shift between which of the above schedule lines is in effect. However, for any period ending before January 1, 2012, when the Borrower’s ratio of EBITDA to


  
 2 








 
Interest Expense under Subsection 5.15(b) is less than 2.50 to 1.00, the Applicable Prime Rate Margin shall be increased by 1.50% in accordance with Subsection 2.1(h); provided;
however, in the event the ratio of EBITDA to Interest Expense is less than the required level during the applicable period described in Subsection 5.15(b), the Default Rate shall apply instead if the Agent and the Required Lenders so elect in
accordance with Section 2.7. 
 1.2 Section 2.1 of the Loan Agreement is amended to add a new subsection (h),
to read in its entirety as follows: 
 (h) Interest Rate Adjustment – Financial Covenant. Upon delivery of a monthly
EBITDA certificate by the Borrower to the Agent pursuant to Subsection 5.2(o) or a quarterly EBITDA certificate pursuant to Subsection 5.2(l) which sets forth the EBITDA to Interest Expense ratio as being less than 2.50 to 1.00 for
any period ending before January 1, 2012, the Applicable LIBO Rate Margin and the Applicable Prime Rate Margin shall automatically be adjusted in accordance with the last sentence of their respective definitions, and the unused facility fee
shall automatically be adjusted in accordance with Subsection 2.5(b), each such adjustment to become effective on the first day of the next month following the month end covered by such EBITDA certificate; provided that if at any time
an EBITDA certificate is not delivered at the time required pursuant to Subsection 5.2(o), then from the first day of the month in which such certificate was required to be delivered until delivery of such certificate, the Applicable LIBO
Rate Margin shall be increased by 1.50% and the applicable Prime Rate Margin shall be increased by 1.50%, and the unused facility fee shall be increased by 0.50%. Such increased margins and fee shall remain in effect until the day that the Borrower
delivers an EBITDA certificate to the Agent pursuant to Subsection 5.2(o) that sets forth the EBITDA ratio as being equal to or greater than 2.50 to 1.00. If an EBITDA certificate erroneously indicates the Borrower’s actual EBITDA to
Interest Expense ratio, which error results in an applicable margin being used which is more favorable to Borrower than should be afforded by the actual calculation of such ratio (i.e., a proper calculation would have resulted in higher pricing), or
if, as a result of any restatement of or other adjustment to the financial statements of the Borrower or for any other reason, the Agent determines that (i) the EBITDA to Interest Expense ratio as calculated by the Borrower as of any applicable
date was inaccurate and (ii) a proper calculation of the EBITDA to Interest Expense ratio would have resulted in higher pricing for such period, the Borrower shall retroactively be 

  
 3 








 
obligated to pay to the Agent for the account of the Lenders, promptly (and in any event within 15 days) on demand by the Agent (or, after the occurrence of an actual or deemed entry of an order
for relief with respect to the Borrower under the Federal Bankruptcy Code, automatically and without further action by the Agent, any Lender or the Issuing Bank), an amount equal to the excess of the amount of interest and letter of credit fees and
unused facility fee that should have been paid for such period over the amount of interest and letter of credit fees and unused facility fee actually paid for such period. If an EBITDA certificate erroneously indicates the Borrower’s actual
EBITDA to Interest Expense ratio, which error results in an applicable margin being used which is less favorable to the Borrower than should be afforded by the actual calculation of such ratio (i.e., a proper calculation would have resulted in lower
pricing), or if as a result of any restatement of or other adjustment to the financial statements of the Borrower or for any other reason, the Agent determines that (i) the EBITDA to Interest Expense ratio as calculated by the Borrower as of
any applicable date was inaccurate and (ii) a proper calculation of the EBITDA to Interest Expense ratio would have resulted in lower pricing for such period, the Borrower shall be afforded a credit against future payments of interest on the
Advances and letter of credit fees and unused facility fee in an amount equal to any excess so paid (but in no event shall such credit be offset against the principal amount of the Loan or any other Indebtedness of the Borrower or its Subsidiaries
or be required to be paid by the Lenders in cash; provided that if the total amount of interest and letter of credit fees and unused facility fee remaining to be paid hereunder is less than such credit, the remaining balance of such credit shall be
applied to the principal amount of the Loan) to correct for such error; provided that such credit shall only be available to the Borrower for any such excess interest or letter of credit fees or unused facility fee paid during the ninety
(90) day period prior to the Agent receiving written notice from the Borrower of such an error and such credit shall only be available against the interest on Advances and letter of credit fees and unused facility fee payable to Lenders who
received such excess interest and letter of credit fee and unused facility fee payment (and in any event in an amount no greater than the excess so received by such Lenders). This subsection shall not limit the rights of the Agent, any Lender or the
Issuing Bank, as the case may be, under any other provision of this Agreement or the other Loan Documents. For the avoidance of doubt, this subsection does not permit the Borrower to avoid a Default under Subsection 5.15(b) by paying
increased margins and fees. 

  
 4 








 1.3 Subsection (b) of Section 2.4 of the Loan Agreement is hereby amended and
restated, to read in the entirety as follows: 
 (b) Mandatory. The Agent shall notify the Borrower of the result of each
Borrowing Base redetermination in accordance herewith. If at any time the Agent determines that a Loan Excess exists, then such Borrowing Base deficiency shall be immediately due and payable in full upon demand, and accordingly immediately upon
written notice from the Agent the Borrower shall prepay the Advances (together with accrued interest on the amount to be prepaid to the date of payment) in an amount sufficient to reduce the Advances plus the face amount of all standby letters of
credit then outstanding to the then Commitment Limit. The Borrower specifically acknowledges that no additional grace period is applicable under this Agreement to any failure to make such mandatory prepayment before such failure is an Event of
Default hereunder. 
 1.4 Subsection (c) of Section 2.4 of the Loan Agreement is hereby amended to delete the
following sentence: 
 The Borrower specifically acknowledges that the ninety (90) day grace period set forth in
Subsection 2.4(b) pertaining to a Loan Excess resulting from a Borrowing Base redetermination is not applicable to any failure to make such mandatory prepayment triggered by a Loan Excess due to a Periodic Reduction as provided in this
Subsection 2.4(c). 
 1.5 Subsection (b) of Section 2.5 is hereby amended and restated, to read in its entirety
as follows: 
 (b) The Borrower shall pay the Agent, for disbursement in accordance with Subsection 9.1(a) hereof to the
Lenders, an unused facility fee quarterly in arrears beginning March 31, 2011 (for the period from the Closing Date through such date) and on the last day of each succeeding March, June, September and December and on the Maturity Date of the
Loan, in an amount (except as provided in the last sentence of this subsection) equal to one-half of one percent (0.50%) per annum on (x) the Commitment Limit less (y) the average outstanding aggregate principal balance of the Advances
under the Notes plus the undisbursed amount of all standby letters of credit then outstanding during such quarter 

  
 5 








 
(or lesser time period, as applicable.) However, for any period ending before January 1, 2012, when the Borrower’s ratio of EBITDA to Interest Expense under Subsection 5.15(b) is
less than 2.50 to 1.00 (or otherwise as provided by Subsection 2.1(h) above), the unused facility fee shall be increased by 0.50% to be one percent (1.00%) per annum. 

1.6 Section 5.2 of the Loan Agreement is hereby amended to add a new subsection (o), to read in its entirety as follows: 

(o) Monthly EBITDA Certificate – Accompanying each request for an Advance or issuance of an letter of credit before
January 1, 2012, and further in any event within 15 days after the end of any month in 2011 in which the Borrower’s ratio (on a rolling twelve month basis) of EBITDA to Interest Expense during the trailing twelve months for such prior
month end was less than 2.50 to 1.00, a certificate signed by the principal financial officer of the Borrower setting forth covenant calculations in reasonable detail demonstrating the EBITDA to Interest Expense ratio for the preceding twelve months
and certifying to its accuracy. This certificate shall include details of the components of EBITDA and Interest Expense. 
 1.7
Subsection (b) of Section 5.15 of the Loan Agreement is hereby amended and restated to read in its entirety as follows: 
 (b) Minimum EBITDA to (Cash) Interest Expense. The Borrower shall maintain, on a quarterly basis as of the last day of each fiscal quarter, a ratio (on a rolling four fiscal quarter basis) of
EBITDA to Interest Expense during the four preceding fiscal quarters of not less than the levels in the following table: 
  

					
	FROM	  	THROUGH	  	MINIMUM RATIO
			
	 Closing Date
	  	 June 30, 2011
	  	2.50 to 1.00
	 July 1, 2011
	  	 December 31, 2011
	  	2.00 to 1.00
	 January 1, 2012
	  	 Maturity Date
	  	2.50 to 1.00

 1.8 On the effective date of this Amendment, the Borrower shall pay the Agent, for disbursement pro rata
to the Lenders (on the basis of each Lender’s allocated portion of the Borrowing Base), a fee equal to one percent (1.00%) of the existing Borrowing Base, equal to a total for all Lenders of $600,000.00 (being 1.00% of $60,000,000.00).


  
 6 








 ARTICLE 2. 
 ACKNOWLEDGMENT OF COLLATERAL 
 2.1 The Borrower hereby specifically
reaffirms all of the Collateral Documents. The Borrower hereby confirms and agrees that the Collateral Documents secure the Loan Agreement as amended by this Amendment. 
 ARTICLE 3. 
 MISCELLANEOUS; CONDITIONS TO EFFECTIVENESS 

3.1 The Borrower represents and warrants to the Agent and the Lenders (which representations and warranties will survive the execution of
this Amendment) that, after giving effect to the amendments described herein, (i) all representations and warranties contained in the Loan Agreement and the Collateral Documents are true and correct on and as of the date hereof as though made
on and as of such date, except to the extent such representations and warranties specifically relate to an earlier date, in which case such representations and warranties shall have been true and correct on and as of such earlier date, (ii) no
event has occurred and is continuing as of the date hereof which constitutes a Default or Event of Default, and (iii) there has not occurred any material adverse change in the Collateral or other assets, liabilities, financial condition,
business operations, affairs or circumstances of the Borrower and the Subsidiaries taken as a whole or any other information (financial or otherwise) provided or delivered by or on behalf of the Borrower upon which a Lender has relied or utilized in
making its decision to enter into this Amendment. 
 3.2 Except as expressly modified by this Amendment, all terms and
provisions of the Loan Agreement are hereby ratified and confirmed and shall be and shall remain in full force and effect, enforceable in accordance with its terms. The definition of “Agreement” in the Loan Agreement shall include this
Amendment and all prior amendments to the Loan Agreement. 
 3.3 The Borrower agrees to pay on demand all costs and expenses of
the Agent and the Lenders in connection with the preparation, reproduction, execution and delivery of this Amendment and the other instruments and documents to be delivered hereunder (including the reasonable fees and expenses of counsel for the
Agent). In addition, Borrower shall pay any and all stamp or other taxes, recordation fees and other fees payable in connection with the execution, delivery, filing or recording of this Amendment and the other instruments and documents to be
delivered hereunder and agrees to hold Agent and the Lenders harmless from and against any and all liabilities with respect to or resulting from any delay or omission in paying such taxes or fees. 

3.4 This Amendment may be executed in multiple separate counterparts, and it shall not be necessary that the signatures of all parties
hereto be contained on any one counterpart hereof; each party’s signature may appear on a separate counterpart but all such counterparts taken together shall constitute one and the same instrument. The parties specifically confirm their intent
to be bound by delivery of such signed counterparts by telecopier or pdf email. 

  
 7 








 3.5 The provisions of Article 1 of this Amendment shall become effective if and when, and
only when, the Agent has received (i) duly executed counterparts of this Amendment by all parties thereto and (ii) for the account of the Lenders, payment of the fee under Paragraph 1.8 of this Amendment. 

3.6 THIS AMENDMENT, TOGETHER WITH THE LOAN DOCUMENTS, AND ANY OTHER WRITTEN INSTRUMENTS EXECUTED PURSUANT TO THIS AMENDMENT REPRESENT,
COLLECTIVELY, THE FINAL AGREEMENT BETWEEN THE PARTIES HERETO WITH RESPECT TO THE SUBJECT HEREOF AND MAY NOT BE CONTRADICTED BY EVIDENCE OF PRIOR, CONTEMPORANEOUS, OR SUBSEQUENT ORAL AGREEMENTS OF THE PARTIES AND SHALL SUPERSEDE ANY PRIOR AGREEMENT
BETWEEN THE PARTIES HEREOF, WHETHER WRITTEN OR ORAL, RELATING TO THE SUBJECT HEREOF. 
 THERE ARE NO UNWRITTEN ORAL AGREEMENTS
BETWEEN THE PARTIES. 
 3.7 The execution, delivery and effectiveness of this Amendment shall not, except as expressly provided
herein, operate as a waiver of any right, power or remedy of any Lender or the Agent under the Loan Agreement or any of the Collateral Documents, nor, except as expressly provided herein, constitute a waiver or amendment of any provision of the Loan
Agreement or any of the Collateral Documents. 
 3.8 Notwithstanding that such consent is not required under the guaranty
agreements or the other Collateral Documents, Endeavor and Diamond each consents to the execution and delivery of this Amendment by the parties hereto. As a material inducement to the Agent and the Banks to amend the Loan Agreement as set forth
herein, Endeavor and Diamond each (i) acknowledges and confirms the continuing existence, validity and effectiveness of its Restated Guaranty Agreement and each of the other Collateral Documents to which it is a party and (ii) agrees that
the execution, delivery and performance of this Amendment shall not in any way release, diminish, impair, reduce or otherwise affect its obligations thereunder. 
 [The rest of this page intentionally left blank.] 

  
 8 








 IN WITNESS WHEREOF, the parties hereto have caused this Amendment to be duly executed and
delivered by their proper and duly authorized officers as of the date first above written. 
  

									
	BORROWER:	 		 	GMX RESOURCES INC.
				
		 		 	By:	 	 /s/ James A. Merrill

		 		 		 	Name:	 	James A. Merrill
		 		 		 	Title:	 	Chief Financial Officer and Treasurer
			
	AGENT:	 		 	CAPITAL ONE, NATIONAL ASSOCIATION
				
		 		 	By:	 	 /s/ Nancy M. Mak

		 		 		 	Name:	 	Nancy M. Mak
		 		 		 	Title:	 	Vice President
			
	LENDERS:	 		 	CAPITAL ONE, NATIONAL ASSOCIATION,
		 		 	as a Lender
				
		 		 	By:	 	 /s/ Nancy M. Mak

		 		 		 	Name:	 	Nancy M. Mak
		 		 		 	Title:	 	Vice President
			
		 		 	BNP PARIBAS
				
		 		 	By:	 	 /s/ Edward Pak

		 		 		 	Name:	 	Edward Pak
		 		 		 	Title:	 	Director
				
		 		 	By:	 	 /s/ Greg Smothers

		 		 		 	Name:	 	Greg Smothers
		 		 		 	Title:	 	Director


  
 9 








 AGREED TO AND ACKNOWLEDGED by the undersigned for the purposes set forth in Paragraph 3.8.

  

					
	ENDEAVOR PIPELINE INC.
		
	By:	 	 /s/ James A. Merrill

		 	Name:	 	James A. Merrill
		 	Title:	 	Vice President and Secretary
	
	DIAMOND BLUE DRILLING CO.
		
	By:	 	 /s/ James A. Merrill

		 	Name:	 	James A. Merrill
		 	Title:	 	Vice President and Secretary



  
 10