* Re: [PATCH] serial: amba-pl011: Fix RX stall when DMA is used
2024-11-13 5:10 [PATCH] serial: amba-pl011: Fix RX stall when DMA is used Kartik
@ 2024-11-13 5:31 ` Greg KH
2024-11-13 17:57 ` kernel test robot
1 sibling, 0 replies; 3+ messages in thread
From: Greg KH @ 2024-11-13 5:31 UTC (permalink / raw)
To: Kartik
Cc: linux, jirislaby, theo.lebrun, linus.walleij, ilpo.jarvinen,
l.sanfilippo, konradybcio, christophe.jaillet, arnd, linux-kernel,
linux-serial
On Wed, Nov 13, 2024 at 10:40:23AM +0530, Kartik wrote:
> Function pl011_throttle_rx() calls pl011_stop_rx() to disable RX, which
> also disables the RX DMA by clearing the RXDMAE bit of the DMACR
> register. However, to properly unthrottle RX when DMA is used, the
> function pl011_unthrottle_rx() is expected to set the RXDMAE bit of
> the DMACR register, which it currently lacks. This causes RX to stall
> after the throttle API is called.
>
> Set RXDMAE bit in the DMACR register while unthrottling RX if RX DMA is
> used.
>
> Fixes: 211565b10099 ("serial: pl011: UPSTAT_AUTORTS requires .throttle/unthrottle")
> Signed-off-by: Kartik <kkartik@nvidia.com>
> ---
> drivers/tty/serial/amba-pl011.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/tty/serial/amba-pl011.c b/drivers/tty/serial/amba-pl011.c
> index 4c4b0d470c65..f40714685166 100644
> --- a/drivers/tty/serial/amba-pl011.c
> +++ b/drivers/tty/serial/amba-pl011.c
> @@ -1819,6 +1819,11 @@ static void pl011_unthrottle_rx(struct uart_port *port)
>
> pl011_write(uap->im, uap, REG_IMSC);
>
> + if (uap->using_rx_dma) {
> + uap->dmacr |= UART011_RXDMAE;
> + pl011_write(uap->dmacr, uap, REG_DMACR);
> + }
> +
> uart_port_unlock_irqrestore(&uap->port, flags);
> }
>
> --
> 2.47.0
>
>
Hi,
This is the friendly patch-bot of Greg Kroah-Hartman. You have sent him
a patch that has triggered this response. He used to manually respond
to these common problems, but in order to save his sanity (he kept
writing the same thing over and over, yet to different people), I was
created. Hopefully you will not take offence and will fix the problem
in your patch and resubmit it so that it can be accepted into the Linux
kernel tree.
You are receiving this message because of the following common error(s)
as indicated below:
- It looks like you did not use your "real" name for the patch on either
the Signed-off-by: line, or the From: line (both of which have to
match). Please read the kernel file,
Documentation/process/submitting-patches.rst for how to do this
correctly.
- You have marked a patch with a "Fixes:" tag for a commit that is in an
older released kernel, yet you do not have a cc: stable line in the
signed-off-by area at all, which means that the patch will not be
applied to any older kernel releases. To properly fix this, please
follow the documented rules in the
Documentation/process/stable-kernel-rules.rst file for how to resolve
this.
If you wish to discuss this problem further, or you have questions about
how to resolve this issue, please feel free to respond to this email and
Greg will reply once he has dug out from the pending patches received
from other developers.
thanks,
greg k-h's patch email bot
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH] serial: amba-pl011: Fix RX stall when DMA is used
2024-11-13 5:10 [PATCH] serial: amba-pl011: Fix RX stall when DMA is used Kartik
2024-11-13 5:31 ` Greg KH
@ 2024-11-13 17:57 ` kernel test robot
1 sibling, 0 replies; 3+ messages in thread
From: kernel test robot @ 2024-11-13 17:57 UTC (permalink / raw)
To: Kartik, linux, gregkh, jirislaby, theo.lebrun, linus.walleij,
ilpo.jarvinen, l.sanfilippo, konradybcio, christophe.jaillet,
arnd, linux-kernel, linux-serial
Cc: oe-kbuild-all
Hi Kartik,
kernel test robot noticed the following build errors:
[auto build test ERROR on tty/tty-testing]
[also build test ERROR on tty/tty-next tty/tty-linus usb/usb-testing usb/usb-next usb/usb-linus soc/for-next linus/master v6.12-rc7 next-20241113]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Kartik/serial-amba-pl011-Fix-RX-stall-when-DMA-is-used/20241113-131203
base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty.git tty-testing
patch link: https://lore.kernel.org/r/20241113051023.3125-1-kkartik%40nvidia.com
patch subject: [PATCH] serial: amba-pl011: Fix RX stall when DMA is used
config: arm64-randconfig-003-20241113 (https://download.01.org/0day-ci/archive/20241114/202411140119.QKkmNN97-lkp@intel.com/config)
compiler: aarch64-linux-gcc (GCC) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241114/202411140119.QKkmNN97-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202411140119.QKkmNN97-lkp@intel.com/
All errors (new ones prefixed by >>):
drivers/tty/serial/amba-pl011.c: In function 'pl011_unthrottle_rx':
>> drivers/tty/serial/amba-pl011.c:1822:16: error: 'struct uart_amba_port' has no member named 'using_rx_dma'
1822 | if (uap->using_rx_dma) {
| ^~
>> drivers/tty/serial/amba-pl011.c:1823:20: error: 'struct uart_amba_port' has no member named 'dmacr'
1823 | uap->dmacr |= UART011_RXDMAE;
| ^~
drivers/tty/serial/amba-pl011.c:1824:32: error: 'struct uart_amba_port' has no member named 'dmacr'
1824 | pl011_write(uap->dmacr, uap, REG_DMACR);
| ^~
vim +1822 drivers/tty/serial/amba-pl011.c
1808
1809 static void pl011_unthrottle_rx(struct uart_port *port)
1810 {
1811 struct uart_amba_port *uap = container_of(port, struct uart_amba_port, port);
1812 unsigned long flags;
1813
1814 uart_port_lock_irqsave(&uap->port, &flags);
1815
1816 uap->im = UART011_RTIM;
1817 if (!pl011_dma_rx_running(uap))
1818 uap->im |= UART011_RXIM;
1819
1820 pl011_write(uap->im, uap, REG_IMSC);
1821
> 1822 if (uap->using_rx_dma) {
> 1823 uap->dmacr |= UART011_RXDMAE;
1824 pl011_write(uap->dmacr, uap, REG_DMACR);
1825 }
1826
1827 uart_port_unlock_irqrestore(&uap->port, flags);
1828 }
1829
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] 3+ messages in thread