All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrei Coardos <aboutphysycs@gmail.com>
To: linux-kernel@vger.kernel.org, linux-rtc@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org
Cc: alexandre.belloni@bootlin.com, a.zummo@towertech.it,
	sebastian.hesselbarth@gmail.com, gregory.clement@bootlin.com,
	andrew@lunn.ch, alex@shruggie.ro,
	Andrei Coardos <aboutphysycs@gmail.com>
Subject: [PATCH] rtc: armada38x: remove unneeded call to platform_set_drvdata()
Date: Mon,  7 Aug 2023 15:48:11 +0300	[thread overview]
Message-ID: <20230807124811.16763-1-aboutphysycs@gmail.com> (raw)

This function call was found to be unnecessary as there is no equivalent
platform_get_drvdata() call to access the private data of the driver. Also,
the private data is defined in this driver, so there is no risk of it being
accessed outside of this driver file.

Signed-off-by: Andrei Coardos <aboutphysycs@gmail.com>
---
 drivers/rtc/rtc-armada38x.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/rtc/rtc-armada38x.c b/drivers/rtc/rtc-armada38x.c
index b4139c200676..5ed028429565 100644
--- a/drivers/rtc/rtc-armada38x.c
+++ b/drivers/rtc/rtc-armada38x.c
@@ -527,7 +527,6 @@ static __init int armada38x_rtc_probe(struct platform_device *pdev)
 		dev_warn(&pdev->dev, "Interrupt not available.\n");
 		rtc->irq = -1;
 	}
-	platform_set_drvdata(pdev, rtc);
 
 	if (rtc->irq != -1)
 		device_init_wakeup(&pdev->dev, 1);
-- 
2.34.1


WARNING: multiple messages have this Message-ID (diff)
From: Andrei Coardos <aboutphysycs@gmail.com>
To: linux-kernel@vger.kernel.org, linux-rtc@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org
Cc: alexandre.belloni@bootlin.com, a.zummo@towertech.it,
	sebastian.hesselbarth@gmail.com, gregory.clement@bootlin.com,
	andrew@lunn.ch, alex@shruggie.ro,
	Andrei Coardos <aboutphysycs@gmail.com>
Subject: [PATCH] rtc: armada38x: remove unneeded call to platform_set_drvdata()
Date: Mon,  7 Aug 2023 15:48:11 +0300	[thread overview]
Message-ID: <20230807124811.16763-1-aboutphysycs@gmail.com> (raw)

This function call was found to be unnecessary as there is no equivalent
platform_get_drvdata() call to access the private data of the driver. Also,
the private data is defined in this driver, so there is no risk of it being
accessed outside of this driver file.

Signed-off-by: Andrei Coardos <aboutphysycs@gmail.com>
---
 drivers/rtc/rtc-armada38x.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/rtc/rtc-armada38x.c b/drivers/rtc/rtc-armada38x.c
index b4139c200676..5ed028429565 100644
--- a/drivers/rtc/rtc-armada38x.c
+++ b/drivers/rtc/rtc-armada38x.c
@@ -527,7 +527,6 @@ static __init int armada38x_rtc_probe(struct platform_device *pdev)
 		dev_warn(&pdev->dev, "Interrupt not available.\n");
 		rtc->irq = -1;
 	}
-	platform_set_drvdata(pdev, rtc);
 
 	if (rtc->irq != -1)
 		device_init_wakeup(&pdev->dev, 1);
-- 
2.34.1


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

             reply	other threads:[~2023-08-07 12:48 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-07 12:48 Andrei Coardos [this message]
2023-08-07 12:48 ` [PATCH] rtc: armada38x: remove unneeded call to platform_set_drvdata() Andrei Coardos
2023-08-07 17:32 ` Alexandru Ardelean
2023-08-07 17:32   ` Alexandru Ardelean
2023-08-07 22:36 ` Russell King (Oracle)
2023-08-07 22:36   ` Russell King (Oracle)

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230807124811.16763-1-aboutphysycs@gmail.com \
    --to=aboutphysycs@gmail.com \
    --cc=a.zummo@towertech.it \
    --cc=alex@shruggie.ro \
    --cc=alexandre.belloni@bootlin.com \
    --cc=andrew@lunn.ch \
    --cc=gregory.clement@bootlin.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rtc@vger.kernel.org \
    --cc=sebastian.hesselbarth@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.