Repository navigation
Another round of Cppcheck fixes - #3849
Conversation
ternary isn't entirely clear what order happens on the left, add brackets to clarify. Cppcheck complaint Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Ret is unconditionally set later, so initialization is irrelevant. Cppcheck find. Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
cppcheck complaint Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
Cppcheck complaint Related to #3843 Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
There is a bug in upstream cppcheck where dereferencing a pointer does not result in a type check in sizeof as far as cppcheck is concerned. This results in a false divide by sizeof(pointer) error. See https://trac.cppcheck.net/ticket/10179 Signed-off-by: Curtis Malainey <cujomalainey@chromium.org>
| (void)handshake; | ||
| (void)irq; | ||
|
|
||
| tr_info(&edma_tr, "EDMA: set config"); |
There was a problem hiding this comment.
Have you considered #if 0 for this?
There was a problem hiding this comment.
checkpatch gets mad at that, tried it for the pdm_controllers_configuration removal
There was a problem hiding this comment.
@marc-hb @cujomalainey I'm fine with this change. There is git history to keep this.
There was a problem hiding this comment.
You can't find in git history what you don't even know exists, that's why it's sometimes worth keeping some dead code. In fact it's not straight forward to find deleted code in git history even when you know it was deleted. Emphasis on sometimes because I do NOT know this particular code, so maybe this one is NOT worth keeping despite the comment saying it should be kept.
As documented by the checkpatch maintainer, checkpatch is not always right and unlike cppcheck it's incremental so easy to ignore from time to time.
There was a problem hiding this comment.
@marc-hb In this specific case I'm fine with dropping the code despite my original comment. Something changed in handshake handling in the ESAI and SAI drivers and this code was indeed stale. Removing was the correct action.
paulstelian97
left a comment
There was a problem hiding this comment.
i.MX specific patches look good, the others I believe are also ok but can't fully validate.
No description provided.