If you need to determine the adjusted basis of transferred property in a foreclosure or repossession (or the basis of any asset), the following IRS Publication can be helpful:
Per IRS Publication 551 Basis of Assets, on page 2:
Basis is the amount of your investment in property for tax purposes. Use the basis of property to figure depreciation, amortization, depletion, and casualty losses. Also use it to figure gain or loss on the sale or other disposition of property. You must keep accurate records of all items that affect the basis of property so you can make these computations.
Note that any link in the information above is updated each year automatically and will take you to the most recent version of the document at the time it is accessed.