utilities: fixup infinite wait in waiting for path

The function to wait for a path to exist never exited if the path
did not exist. Fix that to have a proper timeout, and make the
timeout accurate.

Tested:
put on an nvl32-obmc and tested with a path that doesn't
exist

```
root@nvl32-obmc:~# ./platform init nvidia-nvl32
waiting for /sys/bus/i2c-300 to exist
Failed to wait for /sys/bus/i2c-300 to exist
```

Change-Id: Ibf083a2ecd5d1b1b0a29644767c87086139682ec
Signed-off-by: Marc Olberding <molberding@nvidia.com>
1 file changed