Hi Dan,Yeah I was going to just remove the code but when I was writing the original code my intent was
Thank you for the patch.
On 8/23/19 9:55 PM, Dan Murphy wrote:
Fix the coccinelle issues found in the TI LMU common codeWouldn't it make more sense to remove those pointless checks?
drivers/leds/leds-ti-lmu-common.c:97:20-29: WARNING: Unsigned expression compared with zero: ramp_down < 0
drivers/leds/leds-ti-lmu-common.c:97:5-12: WARNING: Unsigned expression compared with zero: ramp_up < 0
Clearly a correct index of an array cannot be negative.
Looking at the code I would make more int -> unsigned int conversions:
- ramp_table should be unsigned int
- ti_lmu_common_convert_ramp_to_index should return unsigned int