lint: take care of various warnings/errors issued by cppcheck

- [ ] ~~4860~~ 1688  style (unusedStructMember)
- [x]   ~~68~~ ~~51  error (nullPointer)~~
- [x]   ~~15  style (unreadVariable)~~
- [x]    ~~12  performance (redundantAssignment)~~
- [x]      ~~8  style (unusedVariable)~~
- [ ]      8  performance (passedByValue)
- [x]      ~~7  style (unassignedVariable)~~
- [x]     ~~3  warning (nullPointer)~~
- [x]      ~~1  warning (uselessAssignmentPtrArg)~~
- [x]      ~~1  warning (invalidPrintfArgType_sint)~~
- [x]      ~~1  style (obsoleteFunctionsasctime)~~
- [x]      ~~1  performance (redundantCopy)~~
- [x]      ~~1  error (syntaxError)~~

See #480 

Yeah - just checked it myself - the NULL-pointer stuff was in `cpu/stm32f4/periph/pwm.c` and `cpu/stm32f1/periph/spi.c` - I just used a similar approch to solve other errors (like unreadVariable) here and in some other files (instead of just suppressing these errors).