Merge pull request #239 from jeffdonahue/fix-kernel-loop-macro

Fix CUDA_KERNEL_LOOP from @blackball
fix remaining issues related to CUDA_KERNEL_LOOP
fix remaining lint errors
use CUDA_KERNEL_LOOP in padding layer