2021-07-22 13:50:33

by Andreas Schwab

[permalink] [raw]
Subject: [PATCH] spi: update modalias_show after of_device_uevent_modalias support

Commit 3ce6c9e2617e ("spi: add of_device_uevent_modalias support") is
incomplete, as it didn't update the modalias_show function to generate the
of: modalias string if available.

Fixes: 3ce6c9e2617e ("spi: add of_device_uevent_modalias support")
Signed-off-by: Andreas Schwab <[email protected]>
---
drivers/spi/spi.c | 4 ++++
1 file changed, 4 insertions(+)

diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c
index c99181165321..e4dc593b1f32 100644
--- a/drivers/spi/spi.c
+++ b/drivers/spi/spi.c
@@ -58,6 +58,10 @@ modalias_show(struct device *dev, struct device_attribute *a, char *buf)
const struct spi_device *spi = to_spi_device(dev);
int len;

+ len = of_device_modalias(dev, buf, PAGE_SIZE);
+ if (len != -ENODEV)
+ return len;
+
len = acpi_device_modalias(dev, buf, PAGE_SIZE - 1);
if (len != -ENODEV)
return len;
--
2.32.0


--
Andreas Schwab, SUSE Labs, [email protected]
GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7
"And now for something completely different."


2021-07-22 14:09:09

by Mark Brown

[permalink] [raw]
Subject: Re: [PATCH] spi: update modalias_show after of_device_uevent_modalias support

On Thu, Jul 22, 2021 at 03:48:45PM +0200, Andreas Schwab wrote:
> Commit 3ce6c9e2617e ("spi: add of_device_uevent_modalias support") is
> incomplete, as it didn't update the modalias_show function to generate the
> of: modalias string if available.

Please don't send new patches in reply to old patches or serieses, this
makes it harder for both people and tools to understand what is going
on - it can bury things in mailboxes and make it difficult to keep track
of what current patches are, both for the new patches and the old ones.


Attachments:
(No filename) (546.00 B)
signature.asc (499.00 B)
Download all attachments

2021-07-22 17:12:18

by Mark Brown

[permalink] [raw]
Subject: Re: [PATCH] spi: update modalias_show after of_device_uevent_modalias support

On Thu, 22 Jul 2021 15:48:45 +0200, Andreas Schwab wrote:
> Commit 3ce6c9e2617e ("spi: add of_device_uevent_modalias support") is
> incomplete, as it didn't update the modalias_show function to generate the
> of: modalias string if available.

Applied to

https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-next

Thanks!

[1/1] spi: update modalias_show after of_device_uevent_modalias support
commit: e09f2ab8eecc6dcbd7013a1303cbe56b00dc9fb0

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark