<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/pinctrl/mediatek, branch v6.18.48</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=v6.18.48</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=v6.18.48'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2026-07-24T14:17:26+00:00</updated>
<entry>
<title>pinctrl: airoha: fix pinctrl function mismatch issue</title>
<updated>2026-07-24T14:17:26+00:00</updated>
<author>
<name>Chukun Pan</name>
<email>amadeus@jmu.edu.cn</email>
</author>
<published>2025-11-15T10:00:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=a888f3d5970ff21e092bc9edcf3d9ffee9ae68a7'/>
<id>urn:sha1:a888f3d5970ff21e092bc9edcf3d9ffee9ae68a7</id>
<content type='text'>
commit f2bd5a0f59d052d16749bccf637690e51947a5d6 upstream.

The blamed commit made the following changes:

-#define PINCTRL_FUNC_DESC(id)...
-		.desc = PINCTRL_PINFUNCTION(#id, ...
+#define PINCTRL_FUNC_DESC(id, table)...
+		.desc = PINCTRL_PINFUNCTION(#id, ...

-	PINCTRL_FUNC_DESC(pon)...
+	PINCTRL_FUNC_DESC("pon", pon)...

It's clear that the id of funcs doesn't match the definition.
Remove redundant #string from the definition to fix this issue:
pinctrl-airoha ...: invalid function mdio in map table

Fixes: 4043b0c45f85 ("pinctrl: airoha: generalize pins/group/function/confs handling")
Signed-off-by: Chukun Pan &lt;amadeus@jmu.edu.cn&gt;
Acked-by: Christian Marangi &lt;ansuelsmth@gmail.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
</entry>
<entry>
<title>pinctrl: airoha: an7581: fix misprint in gpio19 pinconf</title>
<updated>2026-07-24T14:16:08+00:00</updated>
<author>
<name>Mikhail Kshevetskiy</name>
<email>mikhail.kshevetskiy@iopsys.eu</email>
</author>
<published>2026-06-06T02:03:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ad6963c3bb458fc1b722627405800c32e4cd840b'/>
<id>urn:sha1:ad6963c3bb458fc1b722627405800c32e4cd840b</id>
<content type='text'>
[ Upstream commit 08a39a0617ff32a7c3962bbc38a9eee41b14659a ]

Pin 32 (gpio19) duplicate pinconf settings of pin 31. Fix it using
a proper bit number in the configuration register.

Fixes: 1c8ace2d0725 ("pinctrl: airoha: Add support for EN7581 SoC")
Signed-off-by: Mikhail Kshevetskiy &lt;mikhail.kshevetskiy@iopsys.eu&gt;
Reviewed-by: Bartosz Golaszewski &lt;bartosz.golaszewski@oss.qualcomm.com&gt;
Signed-off-by: Linus Walleij &lt;linusw@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>pinctrl: airoha: an7581: add missed gpio32 pin group</title>
<updated>2026-07-24T14:16:08+00:00</updated>
<author>
<name>Mikhail Kshevetskiy</name>
<email>mikhail.kshevetskiy@iopsys.eu</email>
</author>
<published>2026-06-06T02:03:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=5985ddfd3e83fee2e021ed6908d4026516f47278'/>
<id>urn:sha1:5985ddfd3e83fee2e021ed6908d4026516f47278</id>
<content type='text'>
[ Upstream commit bdc95d7e8de3eefa9fc062302625259c0b79136d ]

gpio32 pin group is missed for an7581 SoC. This patch add it.

Fixes: 1c8ace2d0725 ("pinctrl: airoha: Add support for EN7581 SoC")
Signed-off-by: Mikhail Kshevetskiy &lt;mikhail.kshevetskiy@iopsys.eu&gt;
Reviewed-by: Bartosz Golaszewski &lt;bartosz.golaszewski@oss.qualcomm.com&gt;
Signed-off-by: Linus Walleij &lt;linusw@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>pinctrl: airoha: generalize pins/group/function/confs handling</title>
<updated>2026-07-24T14:16:08+00:00</updated>
<author>
<name>Christian Marangi</name>
<email>ansuelsmth@gmail.com</email>
</author>
<published>2025-11-06T23:57:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=db3cd694ded4c8d492b62c7228e9c0d9230b13d0'/>
<id>urn:sha1:db3cd694ded4c8d492b62c7228e9c0d9230b13d0</id>
<content type='text'>
[ Upstream commit 4043b0c45f8555a079bdac69a19ed08695a47a7b ]

In preparation for support of Airoha AN7583, generalize
pins/group/function/confs handling and move them in match_data.
Inner function will base the values on the pinctrl priv struct instead of
relying on hardcoded struct.

This permits to use different PIN data while keeping the same logic.

Signed-off-by: Christian Marangi &lt;ansuelsmth@gmail.com&gt;
Signed-off-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Stable-dep-of: bdc95d7e8de3 ("pinctrl: airoha: an7581: add missed gpio32 pin group")
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>pinctrl: mediatek: mt8167: Fix Schmitt trigger register offset of pins 34-39</title>
<updated>2026-07-24T14:16:04+00:00</updated>
<author>
<name>Luca Leonardo Scorcia</name>
<email>l.scorcia@gmail.com</email>
</author>
<published>2026-05-31T16:23:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=648a3960e366410d8c7117b06bfae993d563e2c3'/>
<id>urn:sha1:648a3960e366410d8c7117b06bfae993d563e2c3</id>
<content type='text'>
[ Upstream commit 439bc91d20188901dac698bed4921caac76d9074 ]

The correct Schmitt trigger register offset for pins 34-39 is 0xA00. Value
was verified with SoC data sheet.

Signed-off-by: Luca Leonardo Scorcia &lt;l.scorcia@gmail.com&gt;
Fixes: 82d70627e94a ("pinctrl: mediatek: Add MT8167 Pinctrl driver")
Signed-off-by: Linus Walleij &lt;linusw@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>pinctrl: mediatek: mt8516: Fix Schmitt trigger register offset of pins 34-39</title>
<updated>2026-07-24T14:16:04+00:00</updated>
<author>
<name>Luca Leonardo Scorcia</name>
<email>l.scorcia@gmail.com</email>
</author>
<published>2026-05-31T16:22:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=44cff0737127b609c2c40bf41f439bdd031a217d'/>
<id>urn:sha1:44cff0737127b609c2c40bf41f439bdd031a217d</id>
<content type='text'>
[ Upstream commit 1c3044cab23a056ea28da47da1cdd667a39df0b8 ]

The correct Schmitt trigger register offset for pins 34-39 is 0xA00.

Signed-off-by: Luca Leonardo Scorcia &lt;l.scorcia@gmail.com&gt;
Fixes: 264667112ef0 ("pinctrl: mediatek: Add MT8516 Pinctrl driver")
Signed-off-by: Linus Walleij &lt;linusw@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>pinctrl: mediatek: eint: Drop base from mtk_eint_chip_write_mask()</title>
<updated>2026-07-24T14:15:45+00:00</updated>
<author>
<name>Chen-Yu Tsai</name>
<email>wenst@chromium.org</email>
</author>
<published>2026-04-27T02:11:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=7c79be7e634474a0914a17474ceb112013c2a619'/>
<id>urn:sha1:7c79be7e634474a0914a17474ceb112013c2a619</id>
<content type='text'>
[ Upstream commit 3ca99eed042620d12315e9272ed3ef260ca29877 ]

When support for multiple EINT base addresses was added in commit
3ef9f710efcb ("pinctrl: mediatek: Add EINT support for multiple
addresses"), mtk_eint_chip_write_mask() was changed to write interrupt
masks for all base addresses in one call. However the "base" parameter
was left around and now causes sparse warnings:

    mtk-eint.c:428:44: warning: incorrect type in argument 2 (different address spaces)
    mtk-eint.c:428:44:    expected void [noderef] __iomem *base
    mtk-eint.c:428:44:    got void [noderef] __iomem **base
    mtk-eint.c:436:44: warning: incorrect type in argument 2 (different address spaces)
    mtk-eint.c:436:44:    expected void [noderef] __iomem *base
    mtk-eint.c:436:44:    got void [noderef] __iomem **base

Since the "base" parameter is no longer needed, just drop it.

Fixes: 3ef9f710efcb ("pinctrl: mediatek: Add EINT support for multiple addresses")
Cc: Hao Chang &lt;ot_chhao.chang@mediatek.com&gt;
Cc: Qingliang Li &lt;qingliang.li@mediatek.com&gt;
Signed-off-by: Chen-Yu Tsai &lt;wenst@chromium.org&gt;
Signed-off-by: Linus Walleij &lt;linusw@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>pinctrl: mediatek: common: Fix probe failure for devices without EINT</title>
<updated>2026-04-02T11:23:04+00:00</updated>
<author>
<name>Luca Leonardo Scorcia</name>
<email>l.scorcia@gmail.com</email>
</author>
<published>2026-03-17T11:02:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=936a3c0c10e2b1340f1a7988da5ccb7483d5cbc4'/>
<id>urn:sha1:936a3c0c10e2b1340f1a7988da5ccb7483d5cbc4</id>
<content type='text'>
[ Upstream commit 8f9f64c8f90dca07d3b9f1d7ce5d34ccd246c9dd ]

Some pinctrl devices like mt6397 or mt6392 don't support EINT at all, but
the mtk_eint_init function is always called and returns -ENODEV, which
then bubbles up and causes probe failure.

To address this only call mtk_eint_init if EINT pins are present.

Tested on Xiaomi Mi Smart Clock x04g (mt6392).

Fixes: e46df235b4e6 ("pinctrl: mediatek: refactor EINT related code for all MediaTek pinctrl can fit")
Signed-off-by: Luca Leonardo Scorcia &lt;l.scorcia@gmail.com&gt;
Reviewed-by: AngeloGioacchino Del Regno &lt;angelogioacchino.delregno@collabora.com&gt;
Signed-off-by: Linus Walleij &lt;linusw@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>pinctrl: mediatek: make devm allocations safer and clearer in mtk_eint_do_init()</title>
<updated>2026-03-04T12:20:33+00:00</updated>
<author>
<name>Liang Jie</name>
<email>liangjie@lixiang.com</email>
</author>
<published>2025-12-09T10:02:17+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=822019d7516b35311827e15542cb1c67a6ea0adf'/>
<id>urn:sha1:822019d7516b35311827e15542cb1c67a6ea0adf</id>
<content type='text'>
[ Upstream commit 255b721c96046d4c57fa2268e4c72607868ce91f ]

mtk_eint_do_init() allocates several pointer arrays which are then
populated in a per-instance loop and freed on error. The arrays are
currently allocated with devm_kmalloc(), so their entries are left
uninitialised until the per-instance allocations succeed.

On a failure in the middle of the loop, the error path iterates over
the full nbase range and calls devm_kfree() on each element. For
indices which were never initialised, the corresponding array entries
contain stack garbage. If any of those happen to be non-zero,
devm_kfree() will pass them to devres_destroy(), which will WARN
because there is no matching devm_kmalloc() resource for such bogus
pointers.

Improve the robustness and readability by:

  - Using devm_kcalloc() for the pointer arrays so that all entries
    start as NULL, ensuring that only genuinely initialised elements
    may be freed and preventing spurious WARN_ON()s in the error path.
  - Switching the allocations to sizeof(*ptr) / sizeof(**ptr) forms,
    avoiding hard-coded element types and making the code more resilient
    to future type changes.
  - Dropping the redundant NULL checks before devm_kfree(), as
    devm_kfree() safely handles NULL pointers.

The functional behaviour in the successful initialisation path remains
unchanged, while the error handling becomes simpler and less
error-prone.

Reviewed-by: fanggeng &lt;fanggeng@lixiang.com&gt;
Signed-off-by: Liang Jie &lt;liangjie@lixiang.com&gt;
Signed-off-by: Linus Walleij &lt;linusw@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
<entry>
<title>pinctrl: mediatek: mt8189: restore previous register base name array order</title>
<updated>2026-01-17T15:35:20+00:00</updated>
<author>
<name>Louis-Alexis Eyraud</name>
<email>louisalexis.eyraud@collabora.com</email>
</author>
<published>2025-12-03T11:32:42+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=7fd534abaa3972cf8b8d63654b36ee26ddfdefaf'/>
<id>urn:sha1:7fd534abaa3972cf8b8d63654b36ee26ddfdefaf</id>
<content type='text'>
[ Upstream commit fa917d3d570279dc3d699cbd947d0da0fde2e402 ]

In mt8189-pinctrl driver, a previous commit changed the register base
name array (mt8189_pinctrl_register_base_names) entry name and order to
align it with the same name and order as the "mediatek,mt8189-pinctrl"
devicetree bindings. The new order (by ascending register address) now
causes an issue with MT8189 pinctrl configuration.

MT8189 SoC has multiple base addresses for the pin configuration
registers. Several constant data structures, declaring each pin
configuration, are using PIN_FIELD_BASE() macro which i_base parameter
indicates for a given pin the lookup index in the base register address
array of the driver internal data for the configuration register
read/write accesses. But in practice, this parameter is given a
hardcoded numerical value that corresponds to the expected base
register entry index in mt8189_pinctrl_register_base_names array.
Since this array reordering, the i_base index matching is no more
correct.

So, in order to avoid modifying over a thousand of PIN_FIELD_BASE()
calls, restore previous mt8189_pinctrl_register_base_names entry order.

Fixes: 518919276c41 ("pinctrl: mediatek: mt8189: align register base names to dt-bindings ones")
Signed-off-by: Louis-Alexis Eyraud &lt;louisalexis.eyraud@collabora.com&gt;
Signed-off-by: Linus Walleij &lt;linusw@kernel.org&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
</entry>
</feed>
