The Atheros chipset makes available to the OS what pulses it sees on the Physical RF layer - it is then up to the OS to decide how to interpret those messages. But different chipsets provide different levels of data, some better than others. So it is also hardware dependent as well as down to the OS's method of analysing the data provided.
The AR5416 chipset for example can only report if it has what it thinks is radar in the primary 20MHz channel, if you enable 40MHz on such a chipset, it only reports radar on the primary 20MHz channel it ignores the secondary 20MHz channel. Later chipsets such as the AR9130/AR9160, AR9280/AR9285/AR9287 and AR93xx/AR94xx report both pulse width and RSSI level, making it much easier to figure out if the noise really is a radar or not.
I have one client that uses Ubiquiti links and at one site if we enable DFS it never finds a clear channel as it claims they all have Radar interference on every channel, when this is not true.