Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mfd: arizona: Add stub for wm5102_patch()

For the WM5102 there is a dependency in the core code on wm5102_patch()
which only exists when CONFIG_MFD_WM5102 is defined. To avoid having
to sprinkle #ifdefs around the code it is given an alternative empty
stub version when CONFIG_MFD_WM5102 is deselected

Signed-off-by: Richard Fitzgerald <rf@opensource.wolfsonmicro.com>
Signed-off-by: Lee Jones <lee.jones@linaro.org>

authored by

Richard Fitzgerald and committed by
Lee Jones
7e2d67e9 ec40c606

+8
+8
include/linux/mfd/arizona/core.h
··· 154 154 void arizona_free_irq(struct arizona *arizona, int irq, void *data); 155 155 int arizona_set_irq_wake(struct arizona *arizona, int irq, int on); 156 156 157 + #ifdef CONFIG_MFD_WM5102 157 158 int wm5102_patch(struct arizona *arizona); 159 + #else 160 + static inline int wm5102_patch(struct arizona *arizona) 161 + { 162 + return 0; 163 + } 164 + #endif 165 + 158 166 int wm5110_patch(struct arizona *arizona); 159 167 int wm8997_patch(struct arizona *arizona); 160 168