mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
gpio: Use callback presence to determine need of valid_mask
After we switched the two drivers that have .need_valid_mask set to use the callback for setting up the .valid_mask, we can just use the presence of the .init_valid_mask() callback (or the OF reserved ranges, nota bene) to determine whether to allocate the mask or not and we can drop the .need_valid_mask field altogether. Cc: Benjamin Gaignard <benjamin.gaignard@st.com> Cc: Amelie Delaunay <amelie.delaunay@st.com> Cc: Stephen Boyd <swboyd@chromium.org> Cc: Bjorn Andersson <bjorn.andersson@linaro.org> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Link: https://lore.kernel.org/r/20190819093058.10863-1-linus.walleij@linaro.org
This commit is contained in:
parent
da9b142ab2
commit
eb1e8bd6e3
4 changed files with 3 additions and 15 deletions
|
@ -403,15 +403,6 @@ struct gpio_chip {
|
|||
struct gpio_irq_chip irq;
|
||||
#endif /* CONFIG_GPIOLIB_IRQCHIP */
|
||||
|
||||
/**
|
||||
* @need_valid_mask:
|
||||
*
|
||||
* If set core allocates @valid_mask with all its values initialized
|
||||
* with init_valid_mask() or set to one if init_valid_mask() is not
|
||||
* defined
|
||||
*/
|
||||
bool need_valid_mask;
|
||||
|
||||
/**
|
||||
* @valid_mask:
|
||||
*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue