From 8f43e18e2769b3b28383903d501b4da29e388aad Mon Sep 17 00:00:00 2001 From: Mike Dunn Date: Sun, 22 Sep 2013 09:59:56 -0700 Subject: [PATCH] pwm-backlight: Allow for non-increasing brightness levels Currently the driver assumes that the values specified in the brightness-levels device tree property increase as they are parsed from left to right. But boards that invert the signal between the PWM output and the backlight will need to specify decreasing brightness-levels. This patch removes the assumption that the last element of the array is the maximum value, and instead searches the array for the maximum value and uses that in the duty cycle calculation. Signed-off-by: Mike Dunn Signed-off-by: Thierry Reding --- Reading git-format-patch failed