General syntax error fixes discovered by pyflakes.

pyflakes runs a basic syntax checker against python code.
The added check-syntax.sh script and Makefile run pyflakes
on the python code within the teuthology directory reporting
any syntax errors that are found.

This commit includes a number of minor syntax errors discovered
by pyflakes.

Signed-off-by: Sam Lang <sam.lang@inktank.com>