Basically, when they say 320 GB they mean, 320,000,000,000 bytes...
When in reality, 320 GB is actually 343,597,383,680 bytes.
So if you convert 320,000,000,000 bytes into gigabytes, using the actual 1024 bytes per KB, 1024 KB per MB and 1024 MB per GB, you get 298.02 GB.
This is an industry standard way of representing hard drive storage...no matter how corrupt it seems.