Back in the day, Ethernet supported half-duplex only. Switches allowed full-duplex operation as long as point-to-point links were used. Auto-negotiation is used to determine if half- or full-duplex should be used. If auto-negotiation does not negotiate full-duplex, half-duplex is used.
Many recent switch ASICs from Broadcom do not support half-duplex operation, thus the problems with really old end systems that do not properly support auto-negotiation and/or full-duplex operation.
Duplex mismatch cannot be detected reliably using just standard Ethernet, thus some proprietary method to convey that information is used. Cisco Discovery Protocol can include information about the duplex mode used, which is used by (some) Cisco devices to report "duplex mismatch" between e.g. a Cisco router and a Cisco switch. That does not work for other device combinations.