Skip to content

Commit 012825d

Browse files
Eddie Jameslag-linaro
authored andcommitted
Revert "leds-pca955x: Remove the unused function pca95xx_num_led_regs()"
This reverts commit 38bcb51. This function is needed by the hardware blink support just introduced. Also rename the function to pca955x_num_led_regs() to match the rest of the functions in the driver. Signed-off-by: Eddie James <eajames@linux.ibm.com> Link: https://lore.kernel.org/r/20250221155144.2109806-1-eajames@linux.ibm.com Signed-off-by: Lee Jones <lee@kernel.org>
1 parent 2f372a5 commit 012825d

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

drivers/leds/leds-pca955x.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,12 @@ static inline int pca955x_num_input_regs(int bits)
147147
return (bits + 7) / 8;
148148
}
149149

150+
/* 4 bits per LED selector register */
151+
static inline int pca955x_num_led_regs(int bits)
152+
{
153+
return (bits + 3) / 4;
154+
}
155+
150156
/*
151157
* Return an LED selector register value based on an existing one, with
152158
* the appropriate 2-bit state value set for the given LED number (0-3).

0 commit comments

Comments
 (0)