Change dump_hex to take a log level so that aren't forced to hexdump all or nothing.