darwin: clean up some code. remove a clang warning

The check for NULL != cached_device was unnecessary and caused clang's
static analysis to print out a warning.