Linux kernel staging patches
 help / color / mirror / Atom feed
* Re: [PATCH 1/4] staging: axis-fifo: fix grammar in Kconfig help text
From: Ethan Tidmore @ 2026-03-01 21:27 UTC (permalink / raw)
  To: Josh Law, Ethan Tidmore
  Cc: Greg Kroah-Hartman, Ovidiu Panait, linux-staging, linux-kernel,
	Josh Law
In-Reply-To: <08a72969-af76-4515-87d5-f792516dc5b5@gmail.com>

On Sun Mar 1, 2026 at 12:54 PM CST, Josh Law wrote:
> Hello, are you still going to merge my patch? I am new to this, and I hate using my Gmail to merge stuff like this (bit unprofessional lol), I am sorry for the inconvenience, because my objecting.org email can't send emails
>

Please stop top posting, reply inline like how I'm doing here. Also, I
don't merge patches I'm just a reviewer, Greg KH merges them.

About gmail, it is not unprofessional at all. Lots of people even
maintainers use it.

Simply put, if your From: and your SOB don't match your patch will not
be accepted and Greg will not manually fix it for you. You're going to
have to send a v2.

Read this on which email clients you could use:

Documentation/process/email-clients.rst

And here is a source on how to send a v2:

https://staticthinking.wordpress.com/2022/07/27/how-to-send-a-v2-patch/

Thanks,

ET

^ permalink raw reply

* [PATCH] staging: atomisp: remove useless return statement in atomisp_cmd.c
From: Oskar Ray-Frayssinet @ 2026-03-01 21:29 UTC (permalink / raw)
  To: hansg, gregkh; +Cc: linux-staging, linux-media, Oskar Ray-Frayssinet

Remove unnecessary return statement at the end of void function.

Signed-off-by: Oskar Ray-Frayssinet <rayfraytech@gmail.com>
---
 drivers/staging/media/atomisp/pci/atomisp_cmd.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/staging/media/atomisp/pci/atomisp_cmd.c b/drivers/staging/media/atomisp/pci/atomisp_cmd.c
index d5c5895e06e2..de0446997154 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_cmd.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_cmd.c
@@ -1417,7 +1417,6 @@ static void atomisp_update_grid_info(struct atomisp_sub_device *asd,
 
 err:
 	atomisp_css_free_stat_buffers(asd);
-	return;
 }
 
 static void atomisp_curr_user_grid_info(struct atomisp_sub_device *asd,
-- 
2.43.0


^ permalink raw reply related

* Re: [PATCH] staging: atomisp: remove useless return statement in atomisp_cmd.c
From: Ethan Tidmore @ 2026-03-01 21:39 UTC (permalink / raw)
  To: Oskar Ray-Frayssinet, hansg, gregkh; +Cc: linux-staging, linux-media
In-Reply-To: <20260301212900.3783-1-rayfraytech@gmail.com>

On Sun Mar 1, 2026 at 3:29 PM CST, Oskar Ray-Frayssinet wrote:
> Remove unnecessary return statement at the end of void function.
>
> Signed-off-by: Oskar Ray-Frayssinet <rayfraytech@gmail.com>
> ---

LGTM.

Reviewed-by: Ethan Tidmore <ethantidmore06@gmail.com>

Thanks,

ET

^ permalink raw reply

* [PATCH] staging: atomisp: use __func__ in debug message in atomisp_cmd.c
From: Oskar Ray-Frayssinet @ 2026-03-01 21:44 UTC (permalink / raw)
  To: hansg, gregkh; +Cc: linux-staging, linux-media, Oskar Ray-Frayssinet

Replace hardcoded function name string with __func__ macro in
dev_dbg call as recommended by kernel coding style.

Signed-off-by: Oskar Ray-Frayssinet <rayfraytech@gmail.com>
---
 drivers/staging/media/atomisp/pci/atomisp_cmd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/media/atomisp/pci/atomisp_cmd.c b/drivers/staging/media/atomisp/pci/atomisp_cmd.c
index de0446997154..be916ca13453 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_cmd.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_cmd.c
@@ -4010,7 +4010,7 @@ static int css_input_resolution_changed(struct atomisp_sub_device *asd,
 	struct atomisp_metadata_buf *md_buf = NULL, *_md_buf;
 	unsigned int i;
 
-	dev_dbg(asd->isp->dev, "css_input_resolution_changed to %ux%u\n",
+	dev_dbg(asd->isp->dev, "%s: to %ux%u\n", __func__,
 		ffmt->width, ffmt->height);
 
 	if (IS_ISP2401)
-- 
2.43.0


^ permalink raw reply related

* Re: [PATCH] staging: atomisp: remove unnecessary else after return in atomisp_cmd.c
From: Ethan Tidmore @ 2026-03-01 21:46 UTC (permalink / raw)
  To: Oskar Ray-Frayssinet, hansg, gregkh; +Cc: linux-staging, linux-media
In-Reply-To: <20260301212047.3649-1-rayfraytech@gmail.com>

On Sun Mar 1, 2026 at 3:20 PM CST, Oskar Ray-Frayssinet wrote:
> Remove unnecessary else clause after return statement as the else
> branch is not needed when the if branch alsways returns.

Typo alsways.

>
> Signed-off-by: Oskar Ray-Frayssinet <rayfraytech@gmail.com>
> ---

...


>  	if (from_user)
>  		return copy_from_user(to, (void __user *)from, n);
> -	else
> -		memcpy(to, from, n);

Put blank line here.

> +	memcpy(to, from, n);
>  	return 0;
>  }
>  

Also from what I can tell your sending a few patches affecting the
same driver, typically you'd make it a patch series with a cover letter.

Thanks,

ET

^ permalink raw reply

* [PATCH v2 01/10] staging: axis-fifo: fix alignment and line length in wait_event_interruptible
From: Josh Law @ 2026-03-01 21:48 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Ovidiu Panait
  Cc: Gabriel Shahrouzi, linux-staging, linux-kernel, Josh Law

From: Josh Law <objecting@objecting.org>

Signed-off-by: Josh Law <objecting@objecting.org>
---
 drivers/staging/axis-fifo/axis-fifo.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
index aa90b27197cf..aac2c58ef9b3 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -246,7 +246,8 @@ static ssize_t axis_fifo_write(struct file *f, const char __user *buf,
 		mutex_lock(&fifo->write_lock);
 
 		ret = wait_event_interruptible(fifo->write_queue,
-			ioread32(fifo->base_addr + XLLF_TDFV_OFFSET) >= words_to_write);
+					       ioread32(fifo->base_addr + XLLF_TDFV_OFFSET) >=
+					       words_to_write);
 		if (ret)
 			goto end_unlock;
 	}
-- 
2.43.0


^ permalink raw reply related

* [PATCH v2 02/10] staging: axis-fifo: remove redundant goto end
From: Josh Law @ 2026-03-01 21:48 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Ovidiu Panait
  Cc: Gabriel Shahrouzi, linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-1-objecting@objecting.org>

From: Josh Law <objecting@objecting.org>

Signed-off-by: Josh Law <objecting@objecting.org>
---
 drivers/staging/axis-fifo/axis-fifo.c | 17 ++++++++---------
 1 file changed, 8 insertions(+), 9 deletions(-)

diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
index aac2c58ef9b3..d83a0fd5b231 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -395,22 +395,22 @@ static int axis_fifo_parse_dt(struct axis_fifo *fifo)
 				   &value);
 	if (ret) {
 		dev_err(fifo->dt_device, "missing xlnx,axi-str-rxd-tdata-width property\n");
-		goto end;
+		return ret;
 	} else if (value != 32) {
 		dev_err(fifo->dt_device, "xlnx,axi-str-rxd-tdata-width only supports 32 bits\n");
 		ret = -EIO;
-		goto end;
+		return ret;
 	}
 
 	ret = of_property_read_u32(node, "xlnx,axi-str-txd-tdata-width",
 				   &value);
 	if (ret) {
 		dev_err(fifo->dt_device, "missing xlnx,axi-str-txd-tdata-width property\n");
-		goto end;
+		return ret;
 	} else if (value != 32) {
 		dev_err(fifo->dt_device, "xlnx,axi-str-txd-tdata-width only supports 32 bits\n");
 		ret = -EIO;
-		goto end;
+		return ret;
 	}
 
 	ret = of_property_read_u32(node, "xlnx,rx-fifo-depth",
@@ -418,7 +418,7 @@ static int axis_fifo_parse_dt(struct axis_fifo *fifo)
 	if (ret) {
 		dev_err(fifo->dt_device, "missing xlnx,rx-fifo-depth property\n");
 		ret = -EIO;
-		goto end;
+		return ret;
 	}
 
 	ret = of_property_read_u32(node, "xlnx,tx-fifo-depth",
@@ -426,7 +426,7 @@ static int axis_fifo_parse_dt(struct axis_fifo *fifo)
 	if (ret) {
 		dev_err(fifo->dt_device, "missing xlnx,tx-fifo-depth property\n");
 		ret = -EIO;
-		goto end;
+		return ret;
 	}
 
 	ret = of_property_read_u32(node, "xlnx,use-rx-data",
@@ -434,7 +434,7 @@ static int axis_fifo_parse_dt(struct axis_fifo *fifo)
 	if (ret) {
 		dev_err(fifo->dt_device, "missing xlnx,use-rx-data property\n");
 		ret = -EIO;
-		goto end;
+		return ret;
 	}
 
 	ret = of_property_read_u32(node, "xlnx,use-tx-data",
@@ -442,10 +442,9 @@ static int axis_fifo_parse_dt(struct axis_fifo *fifo)
 	if (ret) {
 		dev_err(fifo->dt_device, "missing xlnx,use-tx-data property\n");
 		ret = -EIO;
-		goto end;
+		return ret;
 	}
 
-end:
 	return ret;
 }
 
-- 
2.43.0


^ permalink raw reply related

* [PATCH v2 03/10] staging: axis-fifo: simplify resource mapping
From: Josh Law @ 2026-03-01 21:48 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Ovidiu Panait
  Cc: Gabriel Shahrouzi, linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-1-objecting@objecting.org>

From: Josh Law <objecting@objecting.org>

Use devm_platform_ioremap_resource() to simplify the code and remove the
unused struct resource pointer.

Signed-off-by: Josh Law <objecting@objecting.org>
---
 drivers/staging/axis-fifo/axis-fifo.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
index d83a0fd5b231..fc8e35696b31 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -450,7 +450,6 @@ static int axis_fifo_parse_dt(struct axis_fifo *fifo)
 
 static int axis_fifo_probe(struct platform_device *pdev)
 {
-	struct resource *r_mem;
 	struct device *dev = &pdev->dev;
 	struct axis_fifo *fifo = NULL;
 	int rc = 0; /* error return value */
@@ -469,7 +468,7 @@ static int axis_fifo_probe(struct platform_device *pdev)
 	mutex_init(&fifo->read_lock);
 	mutex_init(&fifo->write_lock);
 
-	fifo->base_addr = devm_platform_get_and_ioremap_resource(pdev, 0, &r_mem);
+	fifo->base_addr = devm_platform_ioremap_resource(pdev, 0);
 	if (IS_ERR(fifo->base_addr))
 		return PTR_ERR(fifo->base_addr);
 
-- 
2.43.0


^ permalink raw reply related

* [PATCH v2 04/10] staging: axis-fifo: use dev_err_probe() for IRQ error handling
From: Josh Law @ 2026-03-01 21:48 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Ovidiu Panait
  Cc: Gabriel Shahrouzi, linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-1-objecting@objecting.org>

From: Josh Law <objecting@objecting.org>

Simplify the error handling in the probe function by using
dev_err_probe() instead of dev_err() when devm_request_irq() fails.

Signed-off-by: Josh Law <objecting@objecting.org>
---
 drivers/staging/axis-fifo/axis-fifo.c | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
index fc8e35696b31..28268881cda2 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -484,11 +484,9 @@ static int axis_fifo_probe(struct platform_device *pdev)
 
 	rc = devm_request_irq(fifo->dt_device, irq, &axis_fifo_irq, 0,
 			      DRIVER_NAME, fifo);
-	if (rc) {
-		dev_err(fifo->dt_device, "couldn't allocate interrupt %i\n",
-			irq);
-		return rc;
-	}
+	if (rc)
+		return dev_err_probe(fifo->dt_device, rc,
+				     "couldn't allocate interrupt %i\n", irq);
 
 	fifo->id = ida_alloc(&axis_fifo_ida, GFP_KERNEL);
 	if (fifo->id < 0)
-- 
2.43.0


^ permalink raw reply related

* [PATCH v2 05/10] staging: axis-fifo: improve IRQ handler
From: Josh Law @ 2026-03-01 21:48 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Ovidiu Panait
  Cc: Gabriel Shahrouzi, linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-1-objecting@objecting.org>

From: Josh Law <objecting@objecting.org>

Return IRQ_NONE when no interrupts were triggered to avoid spurious
interrupt storms, and only clear the active interrupts instead of
blindly clearing all interrupts by writing 'intr' to the ISR instead of
XLLF_INT_CLEAR_ALL.

Signed-off-by: Josh Law <objecting@objecting.org>
---
 drivers/staging/axis-fifo/axis-fifo.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
index 28268881cda2..aad2206b481a 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -302,6 +302,9 @@ static irqreturn_t axis_fifo_irq(int irq, void *dw)
 	isr = ioread32(fifo->base_addr + XLLF_ISR_OFFSET);
 	intr = ier & isr;
 
+	if (!intr)
+		return IRQ_NONE;
+
 	if (intr & XLLF_INT_RC_MASK)
 		wake_up(&fifo->read_queue);
 
@@ -324,7 +327,7 @@ static irqreturn_t axis_fifo_irq(int irq, void *dw)
 		dev_err(fifo->dt_device,
 			"transmit length mismatch error interrupt\n");
 
-	iowrite32(XLLF_INT_CLEAR_ALL, fifo->base_addr + XLLF_ISR_OFFSET);
+	iowrite32(intr, fifo->base_addr + XLLF_ISR_OFFSET);
 
 	return IRQ_HANDLED;
 }
-- 
2.43.0


^ permalink raw reply related

* [PATCH v2 07/10] staging: axis-fifo: fix grammar in Kconfig help text
From: Josh Law @ 2026-03-01 21:48 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Ovidiu Panait
  Cc: Gabriel Shahrouzi, linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-1-objecting@objecting.org>

From: Josh Law <objecting@objecting.org>

Use 'an' instead of 'a' before 'AXI' since it begins with a vowel sound.

Signed-off-by: Josh Law <objecting@objecting.org>
---
 drivers/staging/axis-fifo/Kconfig | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/axis-fifo/Kconfig b/drivers/staging/axis-fifo/Kconfig
index f180a8e9f58a..e618f275e283 100644
--- a/drivers/staging/axis-fifo/Kconfig
+++ b/drivers/staging/axis-fifo/Kconfig
@@ -7,6 +7,6 @@ config XIL_AXIS_FIFO
 	depends on OF && HAS_IOMEM
 	help
 	  This adds support for the Xilinx AXI-Stream FIFO IP core driver.
-	  The AXI Streaming FIFO allows memory mapped access to a AXI Streaming
+	  The AXI Streaming FIFO allows memory mapped access to an AXI Streaming
 	  interface. The Xilinx AXI-Stream FIFO IP core can be used to interface
 	  to the AXI Ethernet without the need to use DMA.
-- 
2.43.0


^ permalink raw reply related

* [PATCH v2 06/10] staging: axis-fifo: minimize lock duration in write
From: Josh Law @ 2026-03-01 21:48 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Ovidiu Panait
  Cc: Gabriel Shahrouzi, linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-1-objecting@objecting.org>

From: Josh Law <objecting@objecting.org>

Memory allocation and copy from user space with vmemdup_user() is
relatively slow and can sleep. Move it outside the lock to minimize the
time the mutex is held, reducing contention for concurrent accesses.

Signed-off-by: Josh Law <objecting@objecting.org>
---
 drivers/staging/axis-fifo/axis-fifo.c | 20 +++++++++++---------
 1 file changed, 11 insertions(+), 9 deletions(-)

diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
index aad2206b481a..d5533235cefc 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -233,9 +233,15 @@ static ssize_t axis_fifo_write(struct file *f, const char __user *buf,
 	    (words_to_write > (fifo->tx_fifo_depth - 4)))
 		return -EINVAL;
 
+	txbuf = vmemdup_user(buf, len);
+	if (IS_ERR(txbuf))
+		return PTR_ERR(txbuf);
+
 	if (f->f_flags & O_NONBLOCK) {
-		if (!mutex_trylock(&fifo->write_lock))
-			return -EAGAIN;
+		if (!mutex_trylock(&fifo->write_lock)) {
+			ret = -EAGAIN;
+			goto err_free;
+		}
 
 		if (words_to_write > ioread32(fifo->base_addr +
 					      XLLF_TDFV_OFFSET)) {
@@ -252,21 +258,17 @@ static ssize_t axis_fifo_write(struct file *f, const char __user *buf,
 			goto end_unlock;
 	}
 
-	txbuf = vmemdup_user(buf, len);
-	if (IS_ERR(txbuf)) {
-		ret = PTR_ERR(txbuf);
-		goto end_unlock;
-	}
-
 	for (int i = 0; i < words_to_write; ++i)
 		iowrite32(txbuf[i], fifo->base_addr + XLLF_TDFD_OFFSET);
 
 	iowrite32(len, fifo->base_addr + XLLF_TLR_OFFSET);
 
 	ret = len;
-	kvfree(txbuf);
+
 end_unlock:
 	mutex_unlock(&fifo->write_lock);
+err_free:
+	kvfree(txbuf);
 
 	return ret;
 }
-- 
2.43.0


^ permalink raw reply related

* [PATCH v2 08/10] staging: axis-fifo: use lowercase hex constant for consistency
From: Josh Law @ 2026-03-01 21:48 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Ovidiu Panait
  Cc: Gabriel Shahrouzi, linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-1-objecting@objecting.org>

From: Josh Law <objecting@objecting.org>

All other register offset defines use lowercase hex digits. Change
0x2C to 0x2c for XLLF_TDR_OFFSET to match the rest of the file.

Signed-off-by: Josh Law <objecting@objecting.org>
---
 drivers/staging/axis-fifo/axis-fifo.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
index d5533235cefc..e154139831ea 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -46,7 +46,7 @@
 #define XLLF_RDFD_OFFSET	0x20 /* Receive Data */
 #define XLLF_RLR_OFFSET		0x24 /* Receive Length */
 #define XLLF_SRR_OFFSET		0x28 /* Local Link Reset */
-#define XLLF_TDR_OFFSET		0x2C /* Transmit Destination */
+#define XLLF_TDR_OFFSET		0x2c /* Transmit Destination */
 #define XLLF_RDR_OFFSET		0x30 /* Receive Destination */
 
 #define XLLF_RDFR_RESET_MASK	0xa5 /* Receive reset value */
-- 
2.43.0


^ permalink raw reply related

* [PATCH v2 09/10] staging: axis-fifo: remove unnecessary variable initializations
From: Josh Law @ 2026-03-01 21:48 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Ovidiu Panait
  Cc: Gabriel Shahrouzi, linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-1-objecting@objecting.org>

From: Josh Law <objecting@objecting.org>

Remove the unnecessary initialization of 'fifo' to NULL and 'rc' to 0
in axis_fifo_probe(), as both variables are assigned before their first
use.

Signed-off-by: Josh Law <objecting@objecting.org>
---
 drivers/staging/axis-fifo/axis-fifo.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
index e154139831ea..7ca0404b0875 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -456,8 +456,8 @@ static int axis_fifo_parse_dt(struct axis_fifo *fifo)
 static int axis_fifo_probe(struct platform_device *pdev)
 {
 	struct device *dev = &pdev->dev;
-	struct axis_fifo *fifo = NULL;
-	int rc = 0; /* error return value */
+	struct axis_fifo *fifo;
+	int rc;
 	int irq;
 
 	fifo = devm_kzalloc(dev, sizeof(*fifo), GFP_KERNEL);
-- 
2.43.0


^ permalink raw reply related

* [PATCH v2 10/10] staging: axis-fifo: simplify error returns in axis_fifo_parse_dt()
From: Josh Law @ 2026-03-01 21:48 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Ovidiu Panait
  Cc: Gabriel Shahrouzi, linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-1-objecting@objecting.org>

From: Josh Law <objecting@objecting.org>

Replace redundant 'ret = -EIO; return ret;' patterns with direct
'return -EIO;' statements, and change the final 'return ret;' to
'return 0;' since success is the only path that reaches it.

Signed-off-by: Josh Law <objecting@objecting.org>
---
 drivers/staging/axis-fifo/axis-fifo.c | 20 +++++++-------------
 1 file changed, 7 insertions(+), 13 deletions(-)

diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
index 7ca0404b0875..9aeb16d8a71f 100644
--- a/drivers/staging/axis-fifo/axis-fifo.c
+++ b/drivers/staging/axis-fifo/axis-fifo.c
@@ -403,8 +403,7 @@ static int axis_fifo_parse_dt(struct axis_fifo *fifo)
 		return ret;
 	} else if (value != 32) {
 		dev_err(fifo->dt_device, "xlnx,axi-str-rxd-tdata-width only supports 32 bits\n");
-		ret = -EIO;
-		return ret;
+		return -EIO;
 	}
 
 	ret = of_property_read_u32(node, "xlnx,axi-str-txd-tdata-width",
@@ -414,43 +413,38 @@ static int axis_fifo_parse_dt(struct axis_fifo *fifo)
 		return ret;
 	} else if (value != 32) {
 		dev_err(fifo->dt_device, "xlnx,axi-str-txd-tdata-width only supports 32 bits\n");
-		ret = -EIO;
-		return ret;
+		return -EIO;
 	}
 
 	ret = of_property_read_u32(node, "xlnx,rx-fifo-depth",
 				   &fifo->rx_fifo_depth);
 	if (ret) {
 		dev_err(fifo->dt_device, "missing xlnx,rx-fifo-depth property\n");
-		ret = -EIO;
-		return ret;
+		return -EIO;
 	}
 
 	ret = of_property_read_u32(node, "xlnx,tx-fifo-depth",
 				   &fifo->tx_fifo_depth);
 	if (ret) {
 		dev_err(fifo->dt_device, "missing xlnx,tx-fifo-depth property\n");
-		ret = -EIO;
-		return ret;
+		return -EIO;
 	}
 
 	ret = of_property_read_u32(node, "xlnx,use-rx-data",
 				   &fifo->has_rx_fifo);
 	if (ret) {
 		dev_err(fifo->dt_device, "missing xlnx,use-rx-data property\n");
-		ret = -EIO;
-		return ret;
+		return -EIO;
 	}
 
 	ret = of_property_read_u32(node, "xlnx,use-tx-data",
 				   &fifo->has_tx_fifo);
 	if (ret) {
 		dev_err(fifo->dt_device, "missing xlnx,use-tx-data property\n");
-		ret = -EIO;
-		return ret;
+		return -EIO;
 	}
 
-	return ret;
+	return 0;
 }
 
 static int axis_fifo_probe(struct platform_device *pdev)
-- 
2.43.0


^ permalink raw reply related

* [PATCH v2] staging: atomisp: remove unnecessary else after return in atomisp_cmd.c
From: Oskar Ray-Frayssinet @ 2026-03-01 22:30 UTC (permalink / raw)
  To: hansg, gregkh; +Cc: linux-staging, linux-media, Oskar Ray-Frayssinet

Remove unnecessary else clause after return statement as the else
branch is not needed when the if branch always returns.

Signed-off-by: Oskar Ray-Frayssinet <rayfraytech@gmail.com>
---
Changes in v2:
- Fix typo 'alsways' -> 'always' in commit message
- Add blank line after return statement

 drivers/staging/media/atomisp/pci/atomisp_cmd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/media/atomisp/pci/atomisp_cmd.c b/drivers/staging/media/atomisp/pci/atomisp_cmd.c
index 9d22ec27ea76..088aea327b9e 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_cmd.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_cmd.c
@@ -2035,8 +2035,8 @@ static unsigned int long copy_from_compatible(void *to, const void *from,
 {
 	if (from_user)
 		return copy_from_user(to, (void __user *)from, n);
-	else
-		memcpy(to, from, n);
+
+	memcpy(to, from, n);
 	return 0;
 }
 
-- 
2.43.0


^ permalink raw reply related

* [PATCH] staging: rtl8723bs: replace msleep with usleep_range in rtw_cmd.c
From: Oskar Ray-Frayssinet @ 2026-03-01 23:03 UTC (permalink / raw)
  To: gregkh; +Cc: linux-staging, linux-kernel, Oskar Ray-Frayssinet

Replace msleep(10) with usleep_range(10000, 11000) as msleep < 20ms
can sleep for up to 20ms and usleep_range is preferred for short
sleep durations.

Signed-off-by: Oskar Ray-Frayssinet <rayfraytech@gmail.com>
---
 drivers/staging/rtl8723bs/core/rtw_cmd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/rtl8723bs/core/rtw_cmd.c b/drivers/staging/rtl8723bs/core/rtw_cmd.c
index abb84f8aecbe..f6293f049c75 100644
--- a/drivers/staging/rtl8723bs/core/rtw_cmd.c
+++ b/drivers/staging/rtl8723bs/core/rtw_cmd.c
@@ -214,7 +214,7 @@ void _rtw_free_evt_priv(struct	evt_priv *pevtpriv)
 {
 	_cancel_workitem_sync(&pevtpriv->c2h_wk);
 	while (pevtpriv->c2h_wk_alive)
-		msleep(10);
+		usleep_range(10000, 11000);
 
 	while (!rtw_cbuf_empty(pevtpriv->c2h_queue)) {
 		void *c2h = rtw_cbuf_pop(pevtpriv->c2h_queue);
-- 
2.43.0


^ permalink raw reply related

* Re: [PATCH 1/4] staging: axis-fifo: fix grammar in Kconfig help text
From: Bagas Sanjaya @ 2026-03-01 23:49 UTC (permalink / raw)
  To: Josh Law, Ethan Tidmore
  Cc: Greg Kroah-Hartman, Ovidiu Panait, linux-staging, linux-kernel,
	Josh Law
In-Reply-To: <08a72969-af76-4515-87d5-f792516dc5b5@gmail.com>

On Sun, Mar 01, 2026 at 06:54:47PM +0000, Josh Law wrote:
> Hello, are you still going to merge my patch? I am new to this, and I hate using my Gmail to merge stuff like this (bit unprofessional lol), I am sorry for the inconvenience, because my objecting.org email can't send emails
> 

Have you ever tried sending patches to your objecting.org address and applying
them?

-- 
An old man doll... just what I always wanted! - Clara

^ permalink raw reply

* [PATCH] Documentation: KVM: fix punctuation for e.g. and i.e.
From: Afkari Zergaw @ 2026-03-02  1:36 UTC (permalink / raw)
  To: marvin24, gregkh; +Cc: linux-staging, linux-tegra, linux-kernel, Afkari Zergaw

Add missing commas after "e.g." and "i.e." in the KVM API
documentation to improve readability and follow standard
punctuation usage.

Signed-off-by: Afkari Zergaw <afkarizergaw12@gmail.com>
---
 Documentation/virt/kvm/api.rst | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/Documentation/virt/kvm/api.rst b/Documentation/virt/kvm/api.rst
index fc5736839edd..c8500f0e913a 100644
--- a/Documentation/virt/kvm/api.rst
+++ b/Documentation/virt/kvm/api.rst
@@ -6346,12 +6346,12 @@ A KVM_MEM_GUEST_MEMFD region _must_ have a valid guest_memfd (private memory) an
 userspace_addr (shared memory).  However, "valid" for userspace_addr simply
 means that the address itself must be a legal userspace address.  The backing
 mapping for userspace_addr is not required to be valid/populated at the time of
-KVM_SET_USER_MEMORY_REGION2, e.g. shared memory can be lazily mapped/allocated
+KVM_SET_USER_MEMORY_REGION2, e.g., shared memory can be lazily mapped/allocated
 on-demand.
 
-When mapping a gfn into the guest, KVM selects shared vs. private, i.e consumes
+When mapping a gfn into the guest, KVM selects shared vs. private, i.e., consumes
 userspace_addr vs. guest_memfd, based on the gfn's KVM_MEMORY_ATTRIBUTE_PRIVATE
-state.  At VM creation time, all memory is shared, i.e. the PRIVATE attribute
+state.  At VM creation time, all memory is shared, i.e., the PRIVATE attribute
 is '0' for all gfns.  Userspace can control whether memory is shared/private by
 toggling KVM_MEMORY_ATTRIBUTE_PRIVATE via KVM_SET_MEMORY_ATTRIBUTES as needed.
 
-- 
2.43.0


^ permalink raw reply related

* [PATCH] staging: nvec: fix block comment style
From: Afkari Zergaw @ 2026-03-02  1:40 UTC (permalink / raw)
  To: marvin24, gregkh; +Cc: linux-staging, linux-tegra, linux-kernel, Afkari Zergaw

Convert a block comment in nvec.c to follow the kernel block
comment style where subsequent lines start with '*'.

Signed-off-by: Afkari Zergaw <afkarizergaw12@gmail.com>
---
 drivers/staging/nvec/nvec.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/nvec/nvec.c b/drivers/staging/nvec/nvec.c
index e9af66a08448..0e655f79ea4a 100644
--- a/drivers/staging/nvec/nvec.c
+++ b/drivers/staging/nvec/nvec.c
@@ -660,7 +660,8 @@ static irqreturn_t nvec_interrupt(int irq, void *dev)
 			to_send = nvec->tx->data[0];
 			nvec->tx->pos = 1;
 			/* delay ACK due to AP20 HW Bug
-			   do not replace by usleep_range */
+			 * do not replace by usleep_range
+			 */
 			udelay(33);
 		} else if (status == (I2C_SL_IRQ)) {
 			nvec->rx->data[1] = received;
-- 
2.43.0


^ permalink raw reply related

* Re: [PATCH] Documentation: KVM: fix punctuation for e.g. and i.e.
From: Greg KH @ 2026-03-02  1:44 UTC (permalink / raw)
  To: Afkari Zergaw; +Cc: marvin24, linux-staging, linux-tegra, linux-kernel
In-Reply-To: <20260302013610.3815-1-afkarizergaw12@gmail.com>

On Mon, Mar 02, 2026 at 01:36:09AM +0000, Afkari Zergaw wrote:
> Add missing commas after "e.g." and "i.e." in the KVM API
> documentation to improve readability and follow standard
> punctuation usage.
> 
> Signed-off-by: Afkari Zergaw <afkarizergaw12@gmail.com>
> ---
>  Documentation/virt/kvm/api.rst | 6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)

Any reason you forgot to cc: the actual maintainers for this file?
Please always use scripts/get_maintainers.pl for who to send patches to.

thanks,

greg k-h

^ permalink raw reply

* Re: [PATCH v6 05/15] gpu: host1x: convert MIPI to use operation function pointers
From: Svyatoslav Ryhel @ 2026-03-02  8:13 UTC (permalink / raw)
  To: Luca Ceresoli
  Cc: Thierry Reding, Mikko Perttunen, David Airlie, Simona Vetter,
	Jonathan Hunter, Sowjanya Komatineni, Mauro Carvalho Chehab,
	Greg Kroah-Hartman, Hans Verkuil, linux-kernel, dri-devel,
	linux-tegra, linux-media, linux-staging
In-Reply-To: <CAPVz0n2uiF_UHK5_7-dW+AjazxTsonQQsnf96QvRu5HgmsyGSg@mail.gmail.com>

чт, 26 лют. 2026 р. о 19:09 Svyatoslav Ryhel <clamor95@gmail.com> пише:
>
> чт, 26 лют. 2026 р. о 18:52 Luca Ceresoli <luca.ceresoli@bootlin.com> пише:
> >
> > Hello Svyatoslav,
> >
> > On Fri Jan 30, 2026 at 1:49 PM CET, Svyatoslav Ryhel wrote:
> > > Convert existing MIPI code to use operation function pointers, a necessary
> > > step for supporting Tegra20/Tegra30 SoCs. All common MIPI configuration
> > > that is SoC-independent remains in mipi.c, while all SoC-specific code is
> > > moved to tegra114-mipi.c (The naming matches the first SoC generation with
> > > a dedicated calibration block). Shared structures and function calls are
> > > placed into tegra-mipi-cal.h.
> > >
> > > Tested-by: Luca Ceresoli <luca.ceresoli@bootlin.com> # tegra20, parallel camera
> > > Signed-off-by: Svyatoslav Ryhel <clamor95@gmail.com>
> > > Acked-by: Mikko Perttunen <mperttunen@nvidia.com>
> >
> > I wanted to test this series on top of v7.0-rc1, but applying this patch
> > fails (with b4 shazam). Can you rebase and send a new iteration?
> >
>
> kzalloc(sizeof(*mipidev), GFP_KERNEL) > kzalloc_obj(*mipidev)
>

Hello Luca!

Thank you for still being interested in this endeavor. Sorry for such
a brief answer, I was very short on time. I have rebased changes on
top of v7.0 but ATM I still have a bit of time constrains and I have
to test them on my device. I will send rebased v7 ASAP.

Best regards,
Svyatoslav R.

> > Best regards,
> > Luca
> >
> > --
> > Luca Ceresoli, Bootlin
> > Embedded Linux and Kernel engineering
> > https://bootlin.com

^ permalink raw reply

* Re: [PATCH v2 01/10] staging: axis-fifo: fix alignment and line length in wait_event_interruptible
From: Dan Carpenter @ 2026-03-02  8:14 UTC (permalink / raw)
  To: Josh Law
  Cc: Greg Kroah-Hartman, Ovidiu Panait, Gabriel Shahrouzi,
	linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-1-objecting@objecting.org>

On Sun, Mar 01, 2026 at 09:48:06PM +0000, Josh Law wrote:
> From: Josh Law <objecting@objecting.org>
> 
> Signed-off-by: Josh Law <objecting@objecting.org>
> ---

There isn't a commit message here so we can't merge it.  But also I would
like to see a 0/10 header email which talks about how you have tested
these.

Most of these are straight forward to review but a couple are more
complicated.

regards,
dan carpenter


^ permalink raw reply

* Re: [PATCH v2 05/10] staging: axis-fifo: improve IRQ handler
From: Dan Carpenter @ 2026-03-02  8:05 UTC (permalink / raw)
  To: Josh Law
  Cc: Greg Kroah-Hartman, Ovidiu Panait, Gabriel Shahrouzi,
	linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-5-objecting@objecting.org>

On Sun, Mar 01, 2026 at 09:48:10PM +0000, Josh Law wrote:
> From: Josh Law <objecting@objecting.org>
> 
> Return IRQ_NONE when no interrupts were triggered to avoid spurious
> interrupt storms, and only clear the active interrupts instead of
> blindly clearing all interrupts by writing 'intr' to the ISR instead of
> XLLF_INT_CLEAR_ALL.
> 

Is this something you actually experienced in real life?  The commit
message needs to be clearer about that.

regards,
dan carpenter


^ permalink raw reply

* Re: [PATCH v2 01/10] staging: axis-fifo: fix alignment and line length in wait_event_interruptible
From: Dan Carpenter @ 2026-03-02  8:42 UTC (permalink / raw)
  To: Josh Law
  Cc: Greg Kroah-Hartman, Ovidiu Panait, Gabriel Shahrouzi,
	linux-staging, linux-kernel, Josh Law
In-Reply-To: <20260301214815.2628942-1-objecting@objecting.org>

On Sun, Mar 01, 2026 at 09:48:06PM +0000, Josh Law wrote:
> From: Josh Law <objecting@objecting.org>
> 
> Signed-off-by: Josh Law <objecting@objecting.org>
> ---
>  drivers/staging/axis-fifo/axis-fifo.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/axis-fifo/axis-fifo.c b/drivers/staging/axis-fifo/axis-fifo.c
> index aa90b27197cf..aac2c58ef9b3 100644
> --- a/drivers/staging/axis-fifo/axis-fifo.c
> +++ b/drivers/staging/axis-fifo/axis-fifo.c
> @@ -246,7 +246,8 @@ static ssize_t axis_fifo_write(struct file *f, const char __user *buf,
>  		mutex_lock(&fifo->write_lock);
>  
>  		ret = wait_event_interruptible(fifo->write_queue,
> -			ioread32(fifo->base_addr + XLLF_TDFV_OFFSET) >= words_to_write);
> +					       ioread32(fifo->base_addr + XLLF_TDFV_OFFSET) >=
> +					       words_to_write);
>  		if (ret)
>  			goto end_unlock;
>  	}

Btw, Greg already NAKed this patch from someone else.

https://lore.kernel.org/all/2026022711-showoff-bakery-8235@gregkh/

regards,
dan carpenter


> -- 
> 2.43.0
> 

^ permalink raw reply


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox