Fix for grains_cache setting on windows

On Windows, when ensuring the grains cache file is not read only, it was referencing self.state, which was not defined.  The only way I could figure out to access cmd.run was by using the same technique used in grains/core.py to define __salt__['cmd.run']