The whole cache invalidation and flushing functions only ended up flusing the first N-1 levels of cache due to an off by one error. This resovles that issue and makes consistent the usage of levels as they relate to caching.