[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20251022175556.62141-1-biancaa2210329@ssn.edu.in>
Date: Wed, 22 Oct 2025 23:25:56 +0530
From: Biancaa Ramesh <biancaa2210329@....edu.in>
To: sudipm.mukherjee@...il.com
Cc: linux-kernel@...r.kernel.org,
biancaa2210329@....edu.in,
kernel test robot <lkp@...el.com>
Subject: [PATCH] Subject: [PATCH v2] pcmcia/parport_cs: fix probe function syntax and error handling
This patch fixes compilation errors and warnings in the parport_config
function of the pcmcia/parport_cs driver.
- Correct misplaced braces and missing failed label
- Use the 'info' variable properly to avoid unused variable warnings
- Ensure consistent indentation and logical error handling flow
This is a follow-up fix patch addressing build errors reported by kernel test
robot on top of my previous patch:
https://lore.kernel.org/all/202510222115.WBPLEBsN-lkp@intel.com/
Reported-by: kernel test robot <lkp@...el.com>
Signed-off-by: Biancaa Ramesh <biancaa2210329@....edu.in>
---
drivers/parport/parport_cs.c | 32 ++++++++++++++++----------------
1 file changed, 16 insertions(+), 16 deletions(-)
diff --git a/drivers/parport/parport_cs.c b/drivers/parport/parport_cs.c
index c6d3f2ee03f7..d2bcfad08870 100644
--- a/drivers/parport/parport_cs.c
+++ b/drivers/parport/parport_cs.c
@@ -141,45 +141,45 @@ static int parport_config(struct pcmcia_device *link)
dev_dbg(&link->dev, "parport_config\n");
if (epp_mode)
- link->config_index |= FORCE_EPP_MODE;
+ link->config_index |= FORCE_EPP_MODE;
ret = pcmcia_loop_config(link, parport_config_check, NULL);
if (ret)
- goto failed;
+ goto failed;
if (!link->irq)
- goto failed;
+ goto failed;
+
ret = pcmcia_enable_device(link);
if (ret)
- goto failed;
+ goto failed;
p = parport_pc_probe_port(link->resource[0]->start,
- link->resource[1]->start,
- link->irq, PARPORT_DMA_NONE,
- &link->dev, IRQF_SHARED);
+ link->resource[1]->start,
+ link->irq, PARPORT_DMA_NONE,
+ &link->dev, IRQF_SHARED);
if (!p) {
dev_err(&link->dev,
- "parport_pc_probe_port() failed at 0x%03x, irq %u\n",
- (unsigned int)link->resource[0]->start, link->irq);
+ "parport_pc_probe_port() failed at 0x%03x, irq %u\n",
+ (unsigned int)link->resource[0]->start, link->irq);
goto failed;
- }
-
}
p->modes |= PARPORT_MODE_PCSPP;
if (epp_mode)
- p->modes |= PARPORT_MODE_TRISTATE | PARPORT_MODE_EPP;
+ p->modes |= PARPORT_MODE_TRISTATE | PARPORT_MODE_EPP;
info->ndev = 1;
info->port = p;
return 0;
failed:
- parport_cs_release(link);
- kfree(link->priv);
+ parport_cs_release(link);
+ kfree(link->priv);
link->priv = NULL;
- return -ENODEV;
-} /* parport_config */
+ return -ENODEV;
+}
+ /* parport_config */
static void parport_cs_release(struct pcmcia_device *link)
{
--
2.43.0
--
::DISCLAIMER::
---------------------------------------------------------------------
The
contents of this e-mail and any attachment(s) are confidential and
intended
for the named recipient(s) only. Views or opinions, if any,
presented in
this email are solely those of the author and may not
necessarily reflect
the views or opinions of SSN Institutions (SSN) or its
affiliates. Any form
of reproduction, dissemination, copying, disclosure,
modification,
distribution and / or publication of this message without the
prior written
consent of authorized representative of SSN is strictly
prohibited. If you
have received this email in error please delete it and
notify the sender
immediately.
---------------------------------------------------------------------
Header of this mail should have a valid DKIM signature for the domain
ssn.edu.in <http://www.ssn.edu.in/>
Powered by blists - more mailing lists