linux-sg2042/drivers/pinctrl/qcom
Marc Zyngier 91a29af413 gpio: Remove dynamic allocation from populate_parent_alloc_arg()
The gpiolib is unique in the way it uses intermediate fwspecs
when feeding an interrupt specifier to the parent domain, as it
relies on the populate_parent_alloc_arg() callback to perform
a dynamic allocation.

This is pretty inefficient (we free the structure almost immediately),
and the only reason this isn't a stack allocation is that our
ThunderX friend uses MSIs rather than a FW-constructed structure.

Let's solve it by providing a new type composed of the union
of a struct irq_fwspec and a msi_info_t, which satisfies both
requirements. This allows us to use a stack allocation, and we
can move the handful of users to this new scheme.

Also perform some additional cleanup, such as getting rid of the
stub versions of the irq_domain_translate_*cell helpers, which
are never used when CONFIG_IRQ_DOMAIN_HIERARCHY isn't selected.

Tested on a Tegra186.

Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Marc Zyngier <maz@kernel.org>
Cc: Daniel Palmer <daniel@thingy.jp>
Cc: Romain Perier <romain.perier@gmail.com>
Cc: Bartosz Golaszewski <brgl@bgdev.pl>
Cc: Thierry Reding <thierry.reding@gmail.com>
Cc: Jonathan Hunter <jonathanh@nvidia.com>
Cc: Robert Richter <rric@kernel.org>
Cc: Nobuhiro Iwamatsu <nobuhiro1.iwamatsu@toshiba.co.jp>
Cc: Andy Gross <agross@kernel.org>
Cc: Bjorn Andersson <bjorn.andersson@linaro.org>
Acked-by: Bartosz Golaszewski <brgl@bgdev.pl>
Link: https://lore.kernel.org/r/20220707182314.66610-2-prabhakar.mahadev-lad.rj@bp.renesas.com
2022-07-10 09:30:00 +01:00
..
Kconfig pinctrl: qcom: Add SC7280 lpass pin configuration 2022-04-23 00:04:43 +02:00
Makefile pinctrl: qcom: Add SC7280 lpass pin configuration 2022-04-23 00:04:43 +02:00
pinctrl-apq8064.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 284 2019-06-05 17:36:37 +02:00
pinctrl-apq8084.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 284 2019-06-05 17:36:37 +02:00
pinctrl-ipq4019.c pinctrl: qcom: ipq4019: add open drain support 2020-07-16 10:46:24 +02:00
pinctrl-ipq6018.c pinctrl: qcom: ipq6018 Add missing pins in qpic pin group 2020-06-20 22:05:24 +02:00
pinctrl-ipq8064.c ipq8064: pinctrl: Fixed missing RGMII pincontrol definitions 2020-02-21 16:23:26 +01:00
pinctrl-ipq8074.c pinctrl: qcom: ipq8074: route gpio interrupts to APPS 2020-07-11 23:11:00 +02:00
pinctrl-lpass-lpi.c pinctrl: qcom: Update clock voting as optional 2022-04-23 00:04:44 +02:00
pinctrl-lpass-lpi.h pinctrl: qcom: Update clock voting as optional 2022-04-23 00:04:44 +02:00
pinctrl-mdm9607.c pinctrl: qcom: Add MDM9607 pinctrl driver 2021-07-23 17:44:13 +02:00
pinctrl-mdm9615.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 284 2019-06-05 17:36:37 +02:00
pinctrl-msm.c pinctrl: msmgpio: Make the irqchip immutable 2022-04-19 15:22:26 +01:00
pinctrl-msm.h pinctrl: qcom: Add egpio feature support 2021-11-22 00:27:54 +01:00
pinctrl-msm8x74.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 284 2019-06-05 17:36:37 +02:00
pinctrl-msm8226.c pinctrl: qcom: msm8226: fill in more functions 2021-09-18 00:31:10 +02:00
pinctrl-msm8660.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 284 2019-06-05 17:36:37 +02:00
pinctrl-msm8916.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 284 2019-06-05 17:36:37 +02:00
pinctrl-msm8953.c pinctrl: qcom: add pinctrl driver for msm8953 2020-11-10 14:58:14 +01:00
pinctrl-msm8960.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 284 2019-06-05 17:36:37 +02:00
pinctrl-msm8976.c pinctrl: qcom: pinctrl-msm8976: Remove unused variable 'nav_tsync_groups' 2020-07-16 15:12:38 +02:00
pinctrl-msm8994.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 284 2019-06-05 17:36:37 +02:00
pinctrl-msm8996.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 284 2019-06-05 17:36:37 +02:00
pinctrl-msm8998.c pinctrl: msm8998: Squash TSIF pins together 2019-07-29 23:28:57 +02:00
pinctrl-qcm2290.c pinctrl: qcom: qcm2290: Add GPIO wakeirq map 2022-02-19 01:59:19 +01:00
pinctrl-qcs404.c This is the bulk of pin control changes for the v5.1 kernel cycle. 2019-03-11 11:12:50 -07:00
pinctrl-qdf2xxx.c pinctrl: qdf2xxx: Switch to use device_property_count_uXX() 2019-08-05 12:01:45 +02:00
pinctrl-sc7180.c pinctrl: qcom: Handle broken/missing PDC dual edge IRQs on sc7180 2020-07-16 15:41:41 +02:00
pinctrl-sc7280-lpass-lpi.c pinctrl: qcom: Update clock voting as optional 2022-04-23 00:04:44 +02:00
pinctrl-sc7280.c pinctrl: qcom: sc7280: Add egpio support 2021-11-22 00:27:54 +01:00
pinctrl-sc8180x.c pinctrl: qcom: cleanup comments 2022-03-15 01:30:37 +01:00
pinctrl-sc8280xp.c pinctrl: qcom: Introduce sc8280xp TLMM driver 2022-03-15 02:03:46 +01:00
pinctrl-sdm660.c pinctrl: sdm660: Set tile property for pingroups 2018-11-19 15:40:55 +01:00
pinctrl-sdm845.c pinctrl: qcom: sdm845: Enable dual edge errata 2021-11-16 02:19:15 +01:00
pinctrl-sdx55.c pinctrl: qcom: Fix duplication in gpio_groups 2021-06-07 00:18:55 +02:00
pinctrl-sdx65.c pinctrl: qcom: Add SDX65 pincontrol driver 2021-11-21 23:48:27 +01:00
pinctrl-sm6115.c drivers: qcom: pinctrl: Add pinctrl driver for sm6115 2021-07-31 23:23:06 +02:00
pinctrl-sm6125.c pinctrl: qcom: cleanup comments 2022-03-15 01:30:37 +01:00
pinctrl-sm6350.c pinctrl: qcom: sm6350: fix order of UFS & SDC pins 2022-04-18 01:38:24 +02:00
pinctrl-sm8150.c pinctrl: qcom: sm8150: Specify PDC map 2022-04-18 01:09:42 +02:00
pinctrl-sm8250-lpass-lpi.c pinctrl: qcom: Extract chip specific LPASS LPI code 2022-04-23 00:04:43 +02:00
pinctrl-sm8250.c pinctrl: qcom: sm8250: Specify PDC map 2020-11-10 14:57:05 +01:00
pinctrl-sm8350.c pinctrl: qcom: sm8350: Correct UFS and SDC offsets 2021-11-16 02:19:15 +01:00
pinctrl-sm8450.c pinctrl: qcom: sm8450: Add egpio support 2022-02-19 01:53:55 +01:00
pinctrl-spmi-gpio.c gpio: Remove dynamic allocation from populate_parent_alloc_arg() 2022-07-10 09:30:00 +01:00
pinctrl-spmi-mpp.c pinctrl: qcom: spmi-mpp: Add PM8226 compatible 2022-02-11 01:08:06 +01:00
pinctrl-ssbi-gpio.c pinctrl: Get rid of duplicate of_node assignment in the drivers 2021-12-16 04:18:30 +01:00
pinctrl-ssbi-mpp.c pinctrl: Get rid of duplicate of_node assignment in the drivers 2021-12-16 04:18:30 +01:00