linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 0/6] crypto/hwrng: Simplify with of_device_get_match_data()
@ 2025-11-07  8:15 Krzysztof Kozlowski
  2025-11-07  8:15 ` [PATCH v2 1/6] hwrng: bcm2835 - Move MODULE_DEVICE_TABLE() to table definition Krzysztof Kozlowski
                   ` (6 more replies)
  0 siblings, 7 replies; 9+ messages in thread
From: Krzysztof Kozlowski @ 2025-11-07  8:15 UTC (permalink / raw)
  To: Olivia Mackall, Herbert Xu, Florian Fainelli,
	Broadcom internal kernel review list, Ray Jui, Scott Branden,
	Jesper Nilsson, Lars Persson, David S. Miller, Tom Lendacky,
	John Allen, Srujana Challa, Bharat Bhushan
  Cc: linux-crypto, linux-rpi-kernel, linux-arm-kernel, linux-kernel,
	linux-arm-kernel, Krzysztof Kozlowski

Changes in v2:
- crypto: artpec6: Add missing (enum artpec6_crypto_variant) cast (to
  fix 32-bit builds)
- Add Acks/Rb tags.
- Link to v1: https://patch.msgid.link/20251106-crypto-of-match-v1-0-36b26cd35cff@linaro.org

Few simple cleanups, not tested on the hardware.

Care has to be taken when converting of_match_data() into
of_device_get_match_data(), because first can check arbitrary
device_node and the latter checks device's node.  Cases here should be
safe because of_match_data() uses 'dev.of_node'.

Best regards,
Krzysztof

---
Krzysztof Kozlowski (6):
      hwrng: bcm2835 - Move MODULE_DEVICE_TABLE() to table definition
      hwrng: bcm2835 - Simplify with of_device_get_match_data()
      crypto: artpec6 - Simplify with of_device_get_match_data()
      crypto: ccp - Constify 'dev_vdata' member
      crypto: ccp - Simplify with of_device_get_match_data()
      crypto: cesa - Simplify with of_device_get_match_data()

 drivers/char/hw_random/bcm2835-rng.c | 11 +++--------
 drivers/crypto/axis/artpec6_crypto.c |  9 +++------
 drivers/crypto/ccp/sp-dev.h          |  2 +-
 drivers/crypto/ccp/sp-platform.c     | 17 +++--------------
 drivers/crypto/marvell/cesa/cesa.c   |  7 ++-----
 5 files changed, 12 insertions(+), 34 deletions(-)
---
base-commit: cec65c58b74636b6410fc766be1ca89247fbc68e
change-id: 20251106-crypto-of-match-22726ffd20b4

Best regards,
-- 
Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>



^ permalink raw reply	[flat|nested] 9+ messages in thread

* [PATCH v2 1/6] hwrng: bcm2835 - Move MODULE_DEVICE_TABLE() to table definition
  2025-11-07  8:15 [PATCH v2 0/6] crypto/hwrng: Simplify with of_device_get_match_data() Krzysztof Kozlowski
@ 2025-11-07  8:15 ` Krzysztof Kozlowski
  2025-11-07  8:15 ` [PATCH v2 2/6] hwrng: bcm2835 - Simplify with of_device_get_match_data() Krzysztof Kozlowski
                   ` (5 subsequent siblings)
  6 siblings, 0 replies; 9+ messages in thread
From: Krzysztof Kozlowski @ 2025-11-07  8:15 UTC (permalink / raw)
  To: Olivia Mackall, Herbert Xu, Florian Fainelli,
	Broadcom internal kernel review list, Ray Jui, Scott Branden,
	Jesper Nilsson, Lars Persson, David S. Miller, Tom Lendacky,
	John Allen, Srujana Challa, Bharat Bhushan
  Cc: linux-crypto, linux-rpi-kernel, linux-arm-kernel, linux-kernel,
	linux-arm-kernel, Krzysztof Kozlowski

Convention is to place MODULE_DEVICE_TABLE() immediately after
definition of the affected table, so one can easily spot missing such.
There is on the other hand no benefits of putting MODULE_DEVICE_TABLE()
far away.

Reviewed-by: Florian Fainelli <florian.fainelli@broadcom.com>
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/char/hw_random/bcm2835-rng.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/char/hw_random/bcm2835-rng.c b/drivers/char/hw_random/bcm2835-rng.c
index aa2b135e3ee2..0b67cfd15b11 100644
--- a/drivers/char/hw_random/bcm2835-rng.c
+++ b/drivers/char/hw_random/bcm2835-rng.c
@@ -138,6 +138,7 @@ static const struct of_device_id bcm2835_rng_of_match[] = {
 	{ .compatible = "brcm,bcm6368-rng"},
 	{},
 };
+MODULE_DEVICE_TABLE(of, bcm2835_rng_of_match);
 
 static int bcm2835_rng_probe(struct platform_device *pdev)
 {
@@ -191,8 +192,6 @@ static int bcm2835_rng_probe(struct platform_device *pdev)
 	return err;
 }
 
-MODULE_DEVICE_TABLE(of, bcm2835_rng_of_match);
-
 static const struct platform_device_id bcm2835_rng_devtype[] = {
 	{ .name = "bcm2835-rng" },
 	{ .name = "bcm63xx-rng" },

-- 
2.48.1



^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH v2 2/6] hwrng: bcm2835 - Simplify with of_device_get_match_data()
  2025-11-07  8:15 [PATCH v2 0/6] crypto/hwrng: Simplify with of_device_get_match_data() Krzysztof Kozlowski
  2025-11-07  8:15 ` [PATCH v2 1/6] hwrng: bcm2835 - Move MODULE_DEVICE_TABLE() to table definition Krzysztof Kozlowski
@ 2025-11-07  8:15 ` Krzysztof Kozlowski
  2025-11-07  8:15 ` [PATCH v2 3/6] crypto: artpec6 " Krzysztof Kozlowski
                   ` (4 subsequent siblings)
  6 siblings, 0 replies; 9+ messages in thread
From: Krzysztof Kozlowski @ 2025-11-07  8:15 UTC (permalink / raw)
  To: Olivia Mackall, Herbert Xu, Florian Fainelli,
	Broadcom internal kernel review list, Ray Jui, Scott Branden,
	Jesper Nilsson, Lars Persson, David S. Miller, Tom Lendacky,
	John Allen, Srujana Challa, Bharat Bhushan
  Cc: linux-crypto, linux-rpi-kernel, linux-arm-kernel, linux-kernel,
	linux-arm-kernel, Krzysztof Kozlowski

Driver's probe function matches against driver's of_device_id table,
where each entry has non-NULL match data, so of_match_node() can be
simplified with of_device_get_match_data().

Reviewed-by: Florian Fainelli <florian.fainelli@broadcom.com>
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/char/hw_random/bcm2835-rng.c | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/drivers/char/hw_random/bcm2835-rng.c b/drivers/char/hw_random/bcm2835-rng.c
index 0b67cfd15b11..6d6ac409efcf 100644
--- a/drivers/char/hw_random/bcm2835-rng.c
+++ b/drivers/char/hw_random/bcm2835-rng.c
@@ -142,9 +142,7 @@ MODULE_DEVICE_TABLE(of, bcm2835_rng_of_match);
 
 static int bcm2835_rng_probe(struct platform_device *pdev)
 {
-	const struct bcm2835_rng_of_data *of_data;
 	struct device *dev = &pdev->dev;
-	const struct of_device_id *rng_id;
 	struct bcm2835_rng_priv *priv;
 	int err;
 
@@ -172,12 +170,10 @@ static int bcm2835_rng_probe(struct platform_device *pdev)
 	priv->rng.cleanup = bcm2835_rng_cleanup;
 
 	if (dev_of_node(dev)) {
-		rng_id = of_match_node(bcm2835_rng_of_match, dev->of_node);
-		if (!rng_id)
-			return -EINVAL;
+		const struct bcm2835_rng_of_data *of_data;
 
 		/* Check for rng init function, execute it */
-		of_data = rng_id->data;
+		of_data = of_device_get_match_data(dev);
 		if (of_data)
 			priv->mask_interrupts = of_data->mask_interrupts;
 	}

-- 
2.48.1



^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH v2 3/6] crypto: artpec6 - Simplify with of_device_get_match_data()
  2025-11-07  8:15 [PATCH v2 0/6] crypto/hwrng: Simplify with of_device_get_match_data() Krzysztof Kozlowski
  2025-11-07  8:15 ` [PATCH v2 1/6] hwrng: bcm2835 - Move MODULE_DEVICE_TABLE() to table definition Krzysztof Kozlowski
  2025-11-07  8:15 ` [PATCH v2 2/6] hwrng: bcm2835 - Simplify with of_device_get_match_data() Krzysztof Kozlowski
@ 2025-11-07  8:15 ` Krzysztof Kozlowski
  2025-11-07  9:39   ` Jesper Nilsson
  2025-11-07  8:15 ` [PATCH v2 4/6] crypto: ccp - Constify 'dev_vdata' member Krzysztof Kozlowski
                   ` (3 subsequent siblings)
  6 siblings, 1 reply; 9+ messages in thread
From: Krzysztof Kozlowski @ 2025-11-07  8:15 UTC (permalink / raw)
  To: Olivia Mackall, Herbert Xu, Florian Fainelli,
	Broadcom internal kernel review list, Ray Jui, Scott Branden,
	Jesper Nilsson, Lars Persson, David S. Miller, Tom Lendacky,
	John Allen, Srujana Challa, Bharat Bhushan
  Cc: linux-crypto, linux-rpi-kernel, linux-arm-kernel, linux-kernel,
	linux-arm-kernel, Krzysztof Kozlowski

Driver's probe function matches against driver's of_device_id table, so
of_match_node() can be simplified with of_device_get_match_data().

This requires changing the enum used in the driver match data entries to
non-zero, to be able to recognize error case of
of_device_get_match_data().

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/crypto/axis/artpec6_crypto.c | 9 +++------
 1 file changed, 3 insertions(+), 6 deletions(-)

diff --git a/drivers/crypto/axis/artpec6_crypto.c b/drivers/crypto/axis/artpec6_crypto.c
index 75ee065da1ec..b04d6379244a 100644
--- a/drivers/crypto/axis/artpec6_crypto.c
+++ b/drivers/crypto/axis/artpec6_crypto.c
@@ -252,7 +252,7 @@ struct artpec6_crypto_dma_descriptors {
 };
 
 enum artpec6_crypto_variant {
-	ARTPEC6_CRYPTO,
+	ARTPEC6_CRYPTO = 1,
 	ARTPEC7_CRYPTO,
 };
 
@@ -2842,7 +2842,6 @@ MODULE_DEVICE_TABLE(of, artpec6_crypto_of_match);
 
 static int artpec6_crypto_probe(struct platform_device *pdev)
 {
-	const struct of_device_id *match;
 	enum artpec6_crypto_variant variant;
 	struct artpec6_crypto *ac;
 	struct device *dev = &pdev->dev;
@@ -2853,12 +2852,10 @@ static int artpec6_crypto_probe(struct platform_device *pdev)
 	if (artpec6_crypto_dev)
 		return -ENODEV;
 
-	match = of_match_node(artpec6_crypto_of_match, dev->of_node);
-	if (!match)
+	variant = (enum artpec6_crypto_variant)of_device_get_match_data(dev);
+	if (!variant)
 		return -EINVAL;
 
-	variant = (enum artpec6_crypto_variant)match->data;
-
 	base = devm_platform_ioremap_resource(pdev, 0);
 	if (IS_ERR(base))
 		return PTR_ERR(base);

-- 
2.48.1



^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH v2 4/6] crypto: ccp - Constify 'dev_vdata' member
  2025-11-07  8:15 [PATCH v2 0/6] crypto/hwrng: Simplify with of_device_get_match_data() Krzysztof Kozlowski
                   ` (2 preceding siblings ...)
  2025-11-07  8:15 ` [PATCH v2 3/6] crypto: artpec6 " Krzysztof Kozlowski
@ 2025-11-07  8:15 ` Krzysztof Kozlowski
  2025-11-07  8:15 ` [PATCH v2 5/6] crypto: ccp - Simplify with of_device_get_match_data() Krzysztof Kozlowski
                   ` (2 subsequent siblings)
  6 siblings, 0 replies; 9+ messages in thread
From: Krzysztof Kozlowski @ 2025-11-07  8:15 UTC (permalink / raw)
  To: Olivia Mackall, Herbert Xu, Florian Fainelli,
	Broadcom internal kernel review list, Ray Jui, Scott Branden,
	Jesper Nilsson, Lars Persson, David S. Miller, Tom Lendacky,
	John Allen, Srujana Challa, Bharat Bhushan
  Cc: linux-crypto, linux-rpi-kernel, linux-arm-kernel, linux-kernel,
	linux-arm-kernel, Krzysztof Kozlowski

sp_device->dev_vdata points to only const data (see 'static const struct
sp_dev_vdata dev_vdata'), so can be made pointer to const for code
safety.

Update also sp_get_acpi_version() function which returns this pointer to
'pointer to const' for code readability, even though it is not needed.

On the other hand, do not touch similar function sp_get_of_version()
because it will be immediately removed in next patches.

Acked-by: Tom Lendacky <thomas.lendacky@amd.com>
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/crypto/ccp/sp-dev.h      | 2 +-
 drivers/crypto/ccp/sp-platform.c | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/crypto/ccp/sp-dev.h b/drivers/crypto/ccp/sp-dev.h
index 6f9d7063257d..1335a83fe052 100644
--- a/drivers/crypto/ccp/sp-dev.h
+++ b/drivers/crypto/ccp/sp-dev.h
@@ -95,7 +95,7 @@ struct sp_device {
 
 	struct device *dev;
 
-	struct sp_dev_vdata *dev_vdata;
+	const struct sp_dev_vdata *dev_vdata;
 	unsigned int ord;
 	char name[SP_MAX_NAME_LEN];
 
diff --git a/drivers/crypto/ccp/sp-platform.c b/drivers/crypto/ccp/sp-platform.c
index 3933cac1694d..de8a8183efdb 100644
--- a/drivers/crypto/ccp/sp-platform.c
+++ b/drivers/crypto/ccp/sp-platform.c
@@ -63,13 +63,13 @@ static struct sp_dev_vdata *sp_get_of_version(struct platform_device *pdev)
 	return NULL;
 }
 
-static struct sp_dev_vdata *sp_get_acpi_version(struct platform_device *pdev)
+static const struct sp_dev_vdata *sp_get_acpi_version(struct platform_device *pdev)
 {
 	const struct acpi_device_id *match;
 
 	match = acpi_match_device(sp_acpi_match, &pdev->dev);
 	if (match && match->driver_data)
-		return (struct sp_dev_vdata *)match->driver_data;
+		return (const struct sp_dev_vdata *)match->driver_data;
 
 	return NULL;
 }

-- 
2.48.1



^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH v2 5/6] crypto: ccp - Simplify with of_device_get_match_data()
  2025-11-07  8:15 [PATCH v2 0/6] crypto/hwrng: Simplify with of_device_get_match_data() Krzysztof Kozlowski
                   ` (3 preceding siblings ...)
  2025-11-07  8:15 ` [PATCH v2 4/6] crypto: ccp - Constify 'dev_vdata' member Krzysztof Kozlowski
@ 2025-11-07  8:15 ` Krzysztof Kozlowski
  2025-11-07  8:15 ` [PATCH v2 6/6] crypto: cesa " Krzysztof Kozlowski
  2025-11-14 10:22 ` [PATCH v2 0/6] crypto/hwrng: " Herbert Xu
  6 siblings, 0 replies; 9+ messages in thread
From: Krzysztof Kozlowski @ 2025-11-07  8:15 UTC (permalink / raw)
  To: Olivia Mackall, Herbert Xu, Florian Fainelli,
	Broadcom internal kernel review list, Ray Jui, Scott Branden,
	Jesper Nilsson, Lars Persson, David S. Miller, Tom Lendacky,
	John Allen, Srujana Challa, Bharat Bhushan
  Cc: linux-crypto, linux-rpi-kernel, linux-arm-kernel, linux-kernel,
	linux-arm-kernel, Krzysztof Kozlowski

Driver's probe function matches against driver's of_device_id table,
where each entry has non-NULL match data, so of_match_node() can be
simplified with of_device_get_match_data().

Acked-by: Tom Lendacky <thomas.lendacky@amd.com>
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/crypto/ccp/sp-platform.c | 13 +------------
 1 file changed, 1 insertion(+), 12 deletions(-)

diff --git a/drivers/crypto/ccp/sp-platform.c b/drivers/crypto/ccp/sp-platform.c
index de8a8183efdb..3f9843fa7782 100644
--- a/drivers/crypto/ccp/sp-platform.c
+++ b/drivers/crypto/ccp/sp-platform.c
@@ -52,17 +52,6 @@ static const struct of_device_id sp_of_match[] = {
 };
 MODULE_DEVICE_TABLE(of, sp_of_match);
 
-static struct sp_dev_vdata *sp_get_of_version(struct platform_device *pdev)
-{
-	const struct of_device_id *match;
-
-	match = of_match_node(sp_of_match, pdev->dev.of_node);
-	if (match && match->data)
-		return (struct sp_dev_vdata *)match->data;
-
-	return NULL;
-}
-
 static const struct sp_dev_vdata *sp_get_acpi_version(struct platform_device *pdev)
 {
 	const struct acpi_device_id *match;
@@ -123,7 +112,7 @@ static int sp_platform_probe(struct platform_device *pdev)
 		goto e_err;
 
 	sp->dev_specific = sp_platform;
-	sp->dev_vdata = pdev->dev.of_node ? sp_get_of_version(pdev)
+	sp->dev_vdata = pdev->dev.of_node ? of_device_get_match_data(&pdev->dev)
 					 : sp_get_acpi_version(pdev);
 	if (!sp->dev_vdata) {
 		ret = -ENODEV;

-- 
2.48.1



^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [PATCH v2 6/6] crypto: cesa - Simplify with of_device_get_match_data()
  2025-11-07  8:15 [PATCH v2 0/6] crypto/hwrng: Simplify with of_device_get_match_data() Krzysztof Kozlowski
                   ` (4 preceding siblings ...)
  2025-11-07  8:15 ` [PATCH v2 5/6] crypto: ccp - Simplify with of_device_get_match_data() Krzysztof Kozlowski
@ 2025-11-07  8:15 ` Krzysztof Kozlowski
  2025-11-14 10:22 ` [PATCH v2 0/6] crypto/hwrng: " Herbert Xu
  6 siblings, 0 replies; 9+ messages in thread
From: Krzysztof Kozlowski @ 2025-11-07  8:15 UTC (permalink / raw)
  To: Olivia Mackall, Herbert Xu, Florian Fainelli,
	Broadcom internal kernel review list, Ray Jui, Scott Branden,
	Jesper Nilsson, Lars Persson, David S. Miller, Tom Lendacky,
	John Allen, Srujana Challa, Bharat Bhushan
  Cc: linux-crypto, linux-rpi-kernel, linux-arm-kernel, linux-kernel,
	linux-arm-kernel, Krzysztof Kozlowski

Driver's probe function matches against driver's of_device_id table,
where each entry has non-NULL match data, so of_match_node() can be
simplified with of_device_get_match_data().

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
---
 drivers/crypto/marvell/cesa/cesa.c | 7 ++-----
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git a/drivers/crypto/marvell/cesa/cesa.c b/drivers/crypto/marvell/cesa/cesa.c
index 9c21f5d835d2..301bdf239e7d 100644
--- a/drivers/crypto/marvell/cesa/cesa.c
+++ b/drivers/crypto/marvell/cesa/cesa.c
@@ -420,7 +420,6 @@ static int mv_cesa_probe(struct platform_device *pdev)
 {
 	const struct mv_cesa_caps *caps = &orion_caps;
 	const struct mbus_dram_target_info *dram;
-	const struct of_device_id *match;
 	struct device *dev = &pdev->dev;
 	struct mv_cesa_dev *cesa;
 	struct mv_cesa_engine *engines;
@@ -433,11 +432,9 @@ static int mv_cesa_probe(struct platform_device *pdev)
 	}
 
 	if (dev->of_node) {
-		match = of_match_node(mv_cesa_of_match_table, dev->of_node);
-		if (!match || !match->data)
+		caps = of_device_get_match_data(dev);
+		if (!caps)
 			return -ENOTSUPP;
-
-		caps = match->data;
 	}
 
 	cesa = devm_kzalloc(dev, sizeof(*cesa), GFP_KERNEL);

-- 
2.48.1



^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [PATCH v2 3/6] crypto: artpec6 - Simplify with of_device_get_match_data()
  2025-11-07  8:15 ` [PATCH v2 3/6] crypto: artpec6 " Krzysztof Kozlowski
@ 2025-11-07  9:39   ` Jesper Nilsson
  0 siblings, 0 replies; 9+ messages in thread
From: Jesper Nilsson @ 2025-11-07  9:39 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Olivia Mackall, Herbert Xu, Florian Fainelli,
	Broadcom internal kernel review list, Ray Jui, Scott Branden,
	Jesper Nilsson, Lars Persson, David S. Miller, Tom Lendacky,
	John Allen, Srujana Challa, Bharat Bhushan, linux-crypto,
	linux-rpi-kernel, linux-arm-kernel, linux-kernel,
	linux-arm-kernel

On Fri, Nov 07, 2025 at 09:15:50AM +0100, Krzysztof Kozlowski wrote
> Driver's probe function matches against driver's of_device_id table, so
> of_match_node() can be simplified with of_device_get_match_data().
> 
> This requires changing the enum used in the driver match data entries to
> non-zero, to be able to recognize error case of
> of_device_get_match_data().
> 
> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

Acked-by: Jesper Nilsson <jesper.nilsson@axis.com>

/^JN - Jesper Nilsson
-- 
               Jesper Nilsson -- jesper.nilsson@axis.com


^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [PATCH v2 0/6] crypto/hwrng: Simplify with of_device_get_match_data()
  2025-11-07  8:15 [PATCH v2 0/6] crypto/hwrng: Simplify with of_device_get_match_data() Krzysztof Kozlowski
                   ` (5 preceding siblings ...)
  2025-11-07  8:15 ` [PATCH v2 6/6] crypto: cesa " Krzysztof Kozlowski
@ 2025-11-14 10:22 ` Herbert Xu
  6 siblings, 0 replies; 9+ messages in thread
From: Herbert Xu @ 2025-11-14 10:22 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Olivia Mackall, Florian Fainelli,
	Broadcom internal kernel review list, Ray Jui, Scott Branden,
	Jesper Nilsson, Lars Persson, David S. Miller, Tom Lendacky,
	John Allen, Srujana Challa, Bharat Bhushan, linux-crypto,
	linux-rpi-kernel, linux-arm-kernel, linux-kernel,
	linux-arm-kernel

On Fri, Nov 07, 2025 at 09:15:47AM +0100, Krzysztof Kozlowski wrote:
> Changes in v2:
> - crypto: artpec6: Add missing (enum artpec6_crypto_variant) cast (to
>   fix 32-bit builds)
> - Add Acks/Rb tags.
> - Link to v1: https://patch.msgid.link/20251106-crypto-of-match-v1-0-36b26cd35cff@linaro.org
> 
> Few simple cleanups, not tested on the hardware.
> 
> Care has to be taken when converting of_match_data() into
> of_device_get_match_data(), because first can check arbitrary
> device_node and the latter checks device's node.  Cases here should be
> safe because of_match_data() uses 'dev.of_node'.
> 
> Best regards,
> Krzysztof
> 
> ---
> Krzysztof Kozlowski (6):
>       hwrng: bcm2835 - Move MODULE_DEVICE_TABLE() to table definition
>       hwrng: bcm2835 - Simplify with of_device_get_match_data()
>       crypto: artpec6 - Simplify with of_device_get_match_data()
>       crypto: ccp - Constify 'dev_vdata' member
>       crypto: ccp - Simplify with of_device_get_match_data()
>       crypto: cesa - Simplify with of_device_get_match_data()
> 
>  drivers/char/hw_random/bcm2835-rng.c | 11 +++--------
>  drivers/crypto/axis/artpec6_crypto.c |  9 +++------
>  drivers/crypto/ccp/sp-dev.h          |  2 +-
>  drivers/crypto/ccp/sp-platform.c     | 17 +++--------------
>  drivers/crypto/marvell/cesa/cesa.c   |  7 ++-----
>  5 files changed, 12 insertions(+), 34 deletions(-)
> ---
> base-commit: cec65c58b74636b6410fc766be1ca89247fbc68e
> change-id: 20251106-crypto-of-match-22726ffd20b4
> 
> Best regards,
> -- 
> Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>

All applied.  Thanks.
-- 
Email: Herbert Xu <herbert@gondor.apana.org.au>
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2025-11-14 10:23 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-11-07  8:15 [PATCH v2 0/6] crypto/hwrng: Simplify with of_device_get_match_data() Krzysztof Kozlowski
2025-11-07  8:15 ` [PATCH v2 1/6] hwrng: bcm2835 - Move MODULE_DEVICE_TABLE() to table definition Krzysztof Kozlowski
2025-11-07  8:15 ` [PATCH v2 2/6] hwrng: bcm2835 - Simplify with of_device_get_match_data() Krzysztof Kozlowski
2025-11-07  8:15 ` [PATCH v2 3/6] crypto: artpec6 " Krzysztof Kozlowski
2025-11-07  9:39   ` Jesper Nilsson
2025-11-07  8:15 ` [PATCH v2 4/6] crypto: ccp - Constify 'dev_vdata' member Krzysztof Kozlowski
2025-11-07  8:15 ` [PATCH v2 5/6] crypto: ccp - Simplify with of_device_get_match_data() Krzysztof Kozlowski
2025-11-07  8:15 ` [PATCH v2 6/6] crypto: cesa " Krzysztof Kozlowski
2025-11-14 10:22 ` [PATCH v2 0/6] crypto/hwrng: " Herbert Xu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).