lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20101117064415.18139.28996.sendpatchset@t400s>
Date:	Wed, 17 Nov 2010 15:44:15 +0900
From:	Magnus Damm <magnus.damm@...il.com>
To:	linux-kernel@...r.kernel.org
Cc:	Magnus Damm <magnus.damm@...il.com>, lethal@...ux-sh.org,
	g.liakhovetski@....de, linux-sh@...r.kernel.org
Subject: [PATCH 01/05] fbdev: sh_mipi_dsi: Remove request/release mem region

From: Magnus Damm <damm@...nsource.se>

The driver core already manages resources for us, so
there is no need to perform request_mem_region() and
release_mem_region() in the MIPI-DSI driver.

Signed-off-by: Magnus Damm <damm@...nsource.se>
---

 drivers/video/sh_mipi_dsi.c |   11 -----------
 1 file changed, 11 deletions(-)

--- 0001/drivers/video/sh_mipi_dsi.c
+++ work/drivers/video/sh_mipi_dsi.c	2010-11-16 17:34:08.000000000 +0900
@@ -344,12 +344,6 @@ static int __init sh_mipi_probe(struct p
 		goto ealloc;
 	}
 
-	if (!request_mem_region(res->start, resource_size(res), pdev->name)) {
-		dev_err(&pdev->dev, "MIPI register region already claimed\n");
-		ret = -EBUSY;
-		goto ereqreg;
-	}
-
 	mipi->base = ioremap(res->start, resource_size(res));
 	if (!mipi->base) {
 		ret = -ENOMEM;
@@ -433,8 +427,6 @@ esettrate:
 eclktget:
 	iounmap(mipi->base);
 emap:
-	release_mem_region(res->start, resource_size(res));
-ereqreg:
 	kfree(mipi);
 ealloc:
 efindslot:
@@ -446,7 +438,6 @@ efindslot:
 static int __exit sh_mipi_remove(struct platform_device *pdev)
 {
 	struct sh_mipi_dsi_info *pdata = pdev->dev.platform_data;
-	struct resource *res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
 	struct sh_mipi *mipi = platform_get_drvdata(pdev);
 	int i, ret;
 
@@ -476,8 +467,6 @@ static int __exit sh_mipi_remove(struct 
 	clk_put(mipi->dsit_clk);
 	clk_put(mipi->dsip_clk);
 	iounmap(mipi->base);
-	if (res)
-		release_mem_region(res->start, resource_size(res));
 	platform_set_drvdata(pdev, NULL);
 	kfree(mipi);
 
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ