Only select Apple Mac products support audio over DisplayPort/HDMI. You can check if your Mac supports audio over DisplayPort/HDMI by opening up the Apple System Profiler:
1) Open the Apple menu and choose About This Mac; it brings up the About This Mac box.
2) Click the More Info button. This brings up the System Profiler.
3) Check the Audio panel. If your System Profiler reports "HDMI / DisplayPort Out", then your Mac will support audio over DisplayPort or HDMI. If you are using a mini-DisplayPort to HDMI adapter, please make sure the adapter supports audio as well as video.