Linux-Watchdog Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH] coresight: etm4x: Fix merge resolution for amba rework
@ 2021-02-05 13:08 Uwe Kleine-König
  2021-02-05 14:04 ` Greg Kroah-Hartman
  0 siblings, 1 reply; 2+ messages in thread
From: Uwe Kleine-König @ 2021-02-05 13:08 UTC (permalink / raw)
  To: Greg Kroah-Hartman
  Cc: Alexandre Belloni, Dmitry Torokhov, kvm, David Airlie,
	Linus Walleij, linux-fbdev, dri-devel, Jaroslav Kysela,
	Eric Anholt, Uwe Kleine-König, linux-i2c, Jiri Slaby,
	linux-stm32, linux-watchdog, linux-rtc, Herbert Xu, Takashi Iwai,
	Russell King - ARM Linux admin, Krzysztof Kozlowski,
	Alexander Shishkin, linux-serial, linux-input, Ulf Hansson,
	Guenter Roeck, Mike Leach, Maxime Coquelin, Alexandre Torgue,
	alsa-devel, Suzuki K Poulose, coresight, Vladimir Zapolskiy,
	Eric Auger, Alex Williamson, Mark Brown, Matt Mackall,
	Dan Williams, Wim Van Sebroeck, kernel, linux-arm-kernel,
	Alessandro Zummo, Mathieu Poirier, Cornelia Huck, linux-mmc,
	linux-kernel, linux-spi, Vinod Koul, Arnd Bergmann, linux-crypto,
	Daniel Vetter, Leo Yan, dmaengine

This was non-trivial to get right because commits
c23bc382ef0e ("coresight: etm4x: Refactor probing routine") and
5214b563588e ("coresight: etm4x: Add support for sysreg only devices")
changed the code flow considerably. With this change the driver can be
built again.

Fixes: 0573d3fa4864 ("Merge branch 'devel-stable' of git://git.armlinux.org.uk/~rmk/linux-arm into char-misc-next")
Signed-off-by: Uwe Kleine-König <uwe@kleine-koenig.org>
---
On Fri, Feb 05, 2021 at 12:07:09PM +0100, Greg Kroah-Hartman wrote:
> On Fri, Feb 05, 2021 at 11:56:15AM +0100, Uwe Kleine-König wrote:
> > I didn't compile test, but I'm willing to bet your resolution is wrong.
> > You have no return statement in etm4_remove_dev() but its return type is
> > int and etm4_remove_amba() still returns int but should return void.
> 
> Can you send a patch to fix this up?

Sure, here it comes. As I'm unsure if you want to squash it into the
merge or want to keep it separate I crafted a commit message. If you
prefer squashing feel free to do so.

This change corresponds to the merge resolution I suggested before.

Best regards
Uwe

 drivers/hwtracing/coresight/coresight-etm4x-core.c | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/drivers/hwtracing/coresight/coresight-etm4x-core.c b/drivers/hwtracing/coresight/coresight-etm4x-core.c
index bc55b261af23..c8ecd91e289e 100644
--- a/drivers/hwtracing/coresight/coresight-etm4x-core.c
+++ b/drivers/hwtracing/coresight/coresight-etm4x-core.c
@@ -1906,15 +1906,16 @@ static int __exit etm4_remove_dev(struct etmv4_drvdata *drvdata)
 	cpus_read_unlock();
 
 	coresight_unregister(drvdata->csdev);
+
+	return 0;
 }
 
-static int __exit etm4_remove_amba(struct amba_device *adev)
+static void __exit etm4_remove_amba(struct amba_device *adev)
 {
 	struct etmv4_drvdata *drvdata = dev_get_drvdata(&adev->dev);
 
 	if (drvdata)
-		return etm4_remove_dev(drvdata);
-	return 0;
+		etm4_remove_dev(drvdata);
 }
 
 static int __exit etm4_remove_platform_dev(struct platform_device *pdev)
-- 
2.29.2


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

* Re: [PATCH] coresight: etm4x: Fix merge resolution for amba rework
  2021-02-05 13:08 [PATCH] coresight: etm4x: Fix merge resolution for amba rework Uwe Kleine-König
@ 2021-02-05 14:04 ` Greg Kroah-Hartman
  0 siblings, 0 replies; 2+ messages in thread
From: Greg Kroah-Hartman @ 2021-02-05 14:04 UTC (permalink / raw)
  To: Uwe Kleine-König
  Cc: Alexandre Belloni, Dmitry Torokhov, kvm, David Airlie,
	Linus Walleij, linux-fbdev, dri-devel, Jaroslav Kysela,
	Eric Anholt, Uwe Kleine-König, linux-i2c, Jiri Slaby,
	linux-stm32, linux-watchdog, linux-rtc, Herbert Xu, Takashi Iwai,
	Russell King - ARM Linux admin, Krzysztof Kozlowski,
	Alexander Shishkin, linux-serial, linux-input, Ulf Hansson,
	Guenter Roeck, Mike Leach, Maxime Coquelin, Alexandre Torgue,
	alsa-devel, Suzuki K Poulose, coresight, Vladimir Zapolskiy,
	Eric Auger, Alex Williamson, Mark Brown, Matt Mackall,
	Dan Williams, Wim Van Sebroeck, kernel, linux-arm-kernel,
	Alessandro Zummo, Mathieu Poirier, Cornelia Huck, linux-mmc,
	linux-kernel, linux-spi, Vinod Koul, Arnd Bergmann, linux-crypto,
	Daniel Vetter, Leo Yan, dmaengine

On Fri, Feb 05, 2021 at 02:08:47PM +0100, Uwe Kleine-König wrote:
> This was non-trivial to get right because commits
> c23bc382ef0e ("coresight: etm4x: Refactor probing routine") and
> 5214b563588e ("coresight: etm4x: Add support for sysreg only devices")
> changed the code flow considerably. With this change the driver can be
> built again.
> 
> Fixes: 0573d3fa4864 ("Merge branch 'devel-stable' of git://git.armlinux.org.uk/~rmk/linux-arm into char-misc-next")
> Signed-off-by: Uwe Kleine-König <uwe@kleine-koenig.org>

Now queued up, thanks!

greg k-h

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

end of thread, back to index

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-05 13:08 [PATCH] coresight: etm4x: Fix merge resolution for amba rework Uwe Kleine-König
2021-02-05 14:04 ` Greg Kroah-Hartman

Linux-Watchdog Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-watchdog/0 linux-watchdog/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-watchdog linux-watchdog/ https://lore.kernel.org/linux-watchdog \
		linux-watchdog@vger.kernel.org
	public-inbox-index linux-watchdog

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-watchdog


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git