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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20211224131300.18198-9-prabhakar.mahadev-lad.rj@bp.renesas.com>
Date:   Fri, 24 Dec 2021 13:12:57 +0000
From:   Lad Prabhakar <prabhakar.mahadev-lad.rj@...renesas.com>
To:     Damien Le Moal <damien.lemoal@...nsource.wdc.com>
Cc:     Sergey Shtylyov <s.shtylyov@....ru>,
        Rob Herring <robh+dt@...nel.org>, linux-kernel@...r.kernel.org,
        Prabhakar <prabhakar.csengg@...il.com>,
        Lad Prabhakar <prabhakar.mahadev-lad.rj@...renesas.com>,
        linux-ide@...r.kernel.org
Subject: [PATCH v3 08/10] ata: pata_platform: Drop validating num_resources count

Drop validating num_resources count as pata_platform_get_resources()
already does this check for us.

Signed-off-by: Lad Prabhakar <prabhakar.mahadev-lad.rj@...renesas.com>
---
v2-->v3
* New patch
---
 drivers/ata/pata_platform.c | 8 --------
 1 file changed, 8 deletions(-)

diff --git a/drivers/ata/pata_platform.c b/drivers/ata/pata_platform.c
index 4273f1a9abd2..88a9bdc81e68 100644
--- a/drivers/ata/pata_platform.c
+++ b/drivers/ata/pata_platform.c
@@ -265,14 +265,6 @@ static int pata_platform_get_pdata(struct platform_device *pdev,
 	struct pata_platform_info *pp_info = dev_get_platdata(&pdev->dev);
 	int ret;
 
-	/*
-	 * Simple resource validation ..
-	 */
-	if ((pdev->num_resources != 3) && (pdev->num_resources != 2)) {
-		dev_err(&pdev->dev, "invalid number of resources\n");
-		return -EINVAL;
-	}
-
 	ret = pata_platform_get_resources(pdev, priv);
 	if (ret)
 		return ret;
-- 
2.17.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ