JPMorgan Chase & Co. agreed to drop a lawsuit it filed against Tesla Inc. three years ago seeking $162 million tied to stock warrant transactions.