The K-1 includes a sales schedule whose numbers are used to populate the schedule D taking into account ordinary income and basis adjustment amounts from the sales schedule. If you use Turbotax, enter the K-1 sales schedule information in the partnership section and it will automatically populate the schedule D.
What you certainly should not do is enter the sale information from your brokerage statement directly into schedule D as that will be wrong as it will not take into account basis adjustments and ordinary gain amounts.