<PAGE>
                                                                   EXHIBIT 10.40



                                  AMENDMENT TO
                              EMPLOYMENT AGREEMENT

                  This Agreement, executed on December ___, 2001 (the
"Agreement"), is made by and between Compaq Computer Corporation, a Delaware
corporation (the "Company"), and Michael D. Capellas (the "Executive"). The
Agreement amends in certain respects the terms of the letter agreement dated
October 20, 2000, as amended and restated December 13, 2000, between the Company
and the Executive (the "Letter Agreement").

                  For good and valuable consideration, the receipt of which is
hereby acknowledged, the Letter Agreement is hereby amended as follows,
effective as of November 1, 2001.

1.       A new paragraph shall be added following the last paragraph under the
         heading "RESTRICTED STOCK", to read as follows:

                  You acknowledge and agree that, notwithstanding the terms and
                  conditions applicable to the 2000 Restricted Stock, the 1999
                  Restricted Stock (as hereinafter defined) or any other shares
                  of restricted Compaq common stock previously granted to you,
                  the definition of the term "Change in Control" set forth on
                  Exhibit A hereto, as amended, shall apply to all restricted
                  shares held by you as of September 3, 2001, and accordingly,
                  in connection with the transaction (the "H-P Merger")
                  contemplated by that certain Agreement and Plan of
                  Reorganization, dated as of September 4, 2001, as amended from
                  time to time, by and between Hewlett-Packard Company, Heloise
                  Merger Corporation and Compaq Computer Corporation, such
                  shares shall vest on consummation of such transaction.

2.       The following sentence shall be added at the end of the paragraph under
         the heading "SEPARATION PAYMENT":

                  Notwithstanding the foregoing, in the event of a Qualifying
                  Termination within one year following a Change in Control, the
                  Separation Payment shall be paid in a single lump sum within
                  ten days following the effective date of the Qualifying
                  Termination.

3.       The following sentence shall be added at the end of the paragraph
         entitled "PRORATED ANNUAL INCENTIVE":

                  Notwithstanding the foregoing, in the event a Qualifying
                  Termination occurs within one year following a Change in
                  Control, the Prorated Annual Incentive for the measuring
                  period in which such Qualifying




<PAGE>

                  Termination occurs shall be paid in a lump sum within ten days
                  following the date of such Qualifying Termination.

4.       The following sentence shall be added at the end of the paragraph
         entitled "STOCK OPTIONS" under the heading "QUALIFYING TERMINATION":

                  If you incur a Qualifying Termination within one year
                  following a Change in Control, any outstanding options granted
                  prior to the Change in Control which had not previously become
                  exercisable shall become fully exercisable and you shall have
                  the right to exercise any outstanding stock option then held
                  by you until the third anniversary of the effective date of
                  such Qualifying Termination (in the case of options granted
                  prior to September 1, 2001) or the first anniversary of the
                  effective date of such Qualifying Termination (in the case of
                  options granted on or after September 1, 2001 and prior to the
                  Change in Control). Notwithstanding the foregoing, if you
                  retire, die or are disabled and the terms of the governing
                  Equity Incentive Plan or grant notice for a particular option
                  provide that you have longer than the time period described
                  above, you shall continue to have the longer period provided
                  for under the Plan or notice to exercise that option.

5.       The second sentence of the paragraph entitled "HEALTH BENEFIT
         CONTINUATION" under the heading "QUALIFYING TERMINATION" is hereby
         deleted and replaced with the following:

                  Compaq will pay the COBRA premiums for continuation of
                  healthcare benefits for you and your eligible dependents for
                  so long as you are otherwise eligible for such coverage during
                  the 24-month period following a Qualifying Termination. You
                  will be responsible for all other costs, such as co-payments
                  and deductibles.

6.       The first sentence of clause (2) under the paragraph entitled
         "DEFINITION OF A QUALIFYING TERMINATION", is hereby deleted and
         replaced with the following:

         (2)      Resignation within 90 days of the occurrence of an event
                  constituting Good Reason (or, if such Good Reason event occurs
                  on or following a Change in Control, resignation prior to the
                  first anniversary of such Change in Control). For purposes of
                  this Agreement, Good Reason shall mean: (a) removal from the
                  position of Chief Executive Officer, (b) removal from, or
                  failure to be elected, Chairman of the Board, (c) assignment,
                  by the Board, of duties inconsistent with the position of
                  Chief Executive Officer, (d) receipt of a Notice of
                  Non-Renewal, or (e) the Board's approval of a material
                  reduction in target


                                       2

<PAGE>

                  compensation opportunities that is not part of an
                  across-the-board reduction for all executive officers of the
                  Company.

7.       The paragraph entitled "INVOLUNTARY TERMINATION FOR CAUSE/ RESIGNATION
         WITHOUT GOOD REASON" is hereby amended in its entirety to read as
         follows:

                  INVOLUNTARY TERMINATION FOR CAUSE/RESIGNATION NOT CONSTITUTING
                  A QUALIFYING TERMINATION: If you are involuntary terminated
                  for Cause or resign your employment (other than a resignation
                  constituting a Qualifying Termination), you will not be
                  entitled to any severance payment under this Agreement. Compaq
                  will have no other obligations under this Agreement, and all
                  compensation and benefits will be determined by the terms of
                  the governing plan or program.

8.       The paragraph entitled "NON-COMPETITION AND NO SOLICITATION" is hereby
         amended by adding the following sentence after the second sentence
         thereof, to read as follows:

                  Provided, however, that, in the event of a Qualifying
                  Termination within one year following a Change in Control, the
                  restrictions described in clauses (1) and (2) of the preceding
                  sentence shall be inapplicable and the restrictions described
                  in clause (3) of the preceding sentence shall only be
                  applicable for a period of one year following such Qualifying
                  Termination.

9.       The last paragraph under the heading "ARBITRATION" is hereby amended by
         adding the following:

                  Notwithstanding the foregoing, Compaq shall promptly pay or
                  reimburse you for all reasonable legal fees incurred by you in
                  seeking in good faith to obtain or enforce any benefit or
                  right provided by this Agreement relating to the termination
                  of your employment within one year following a Change in
                  Control or in connection with any tax audit or proceeding to
                  the extent attributable to the application of Section 4999 of
                  the Code.

10.      Exhibit A, Definition of Change in Control, is hereby amended by
         deleting the words "the stockholders of the Company approve a merger or
         consolidation of the Company with any other corporation" in clause
         (iii) thereof and replacing them with the words "a merger or
         consolidation of the Company with any other corporation is
         consummated".


                                       3

<PAGE>

                  IN WITNESS WHEREOF, the Company and the Executive have
executed this Agreement on the date and year first set forth above.


COMPAQ COMPUTER CORPORATION

By:
    -----------------------------
         Lawrence T. Babbio, Jr.
         Chairman - Human Resources Committee of
         the Board of Directors



MICHAEL D. CAPELLAS

---------------------------------


                                       4