Kernel Newbies archive mirror
 help / color / mirror / Atom feed
From: jim.cromie@gmail.com
To: Simon Lindhorst <s.lindhorst@wut.de>
Cc: kernelnewbies@kernelnewbies.org
Subject: Re: mabe a bug in kernel 5.4 since patchlevel 159 - dma error because use ttynull?
Date: Thu, 13 Oct 2022 09:11:13 -0600	[thread overview]
Message-ID: <CAJfuBxx=Sz2VeOVC28cdLK-m72FY4PbiUkb6BNg1GGooM6Ar6Q@mail.gmail.com> (raw)
In-Reply-To: <6590dbfc-1d55-71f0-b26f-73c60dee97ec@wut.de>

On Thu, Oct 13, 2022 at 4:48 AM Simon Lindhorst <s.lindhorst@wut.de> wrote:
>
> Hello all,
>
>
> when I updated my Kernel from version 5.4.155 to 5.4.215 I get an strange xhci error:
>
> xhci-hcd f10f0000.usb3: ERROR unknown event type 37
> xhci-hcd f10f0000.usb3: ERROR Transfer event TRB DMA ptr not part of current TD ep_index 2 comp_code 13
>
> After a lot of this messages, my hardware makes a reboot without any more outputs.
>
> The error only occures when i add console=null to my kernel bootargs. When I add instead console=ttyS0,115200 no error occured.
>
> Now I go back in kernelversions. The error occured first in version 5.4.159. Between patchlevel 158 and 159 there is a change:
>
> --- linux-5.4.158/kernel/printk/printk.c    2021-11-06 13:59:45.000000000 +0100
> +++ linux-5.4.159/kernel/printk/printk.c    2021-11-12 14:43:05.000000000 +0100
> @@ -2193,8 +2193,15 @@
>      char *s, *options, *brl_options = NULL;
>      int idx;
>
> -    if (str[0] == 0)
> +    /*
> +     * console="" or console=null have been suggested as a way to
> +     * disable console output. Use ttynull that has been created
> +     * for exacly this purpose.
> +     */
> +    if (str[0] == 0 || strcmp(str, "null") == 0) {
> +        __add_preferred_console("ttynull", 0, NULL, NULL);
>          return 1;
> +    }
>
>      if (_braille_console_setup(&str, &brl_options))
>          return 1;
>
> I checked my kernelconfig and found that I have no ttynull device configured (CONFIG_NULL_TTY=n). Add CONFIG_NULL_TTY=y to my kernelconfig doesn't made a change.
>
> When I undo the change above, everything works fine.
>
>
> Does anybody know, what could be the main trigger for the error above?
>

while there have been lots of change to printk,
the code you cite is still there.
If that code is a candidate for the root-cause,
and you can re-create the error on master,
you are 1/2 the way to getting it fixed.

Also, note latest:

commit 3ef4ea3d84ca568dcd57816b9521e82e3bd94f08
Merge: 30d024b5058e 5eb17c1f458c
Author: Linus Torvalds <torvalds@linux-foundation.org>
Date:   Wed Mar 23 10:54:27 2022 -0700

    Merge tag 'printk-for-5.18' of
git://git.kernel.org/pub/scm/linux/kernel/git/printk/linux

    Pull printk updates from Petr Mladek:

     - Make %pK behave the same as %p for kptr_restrict == 0 also with
       no_hash_pointers parameter

     - Ignore the default console in the device tree also when console=null
       or console="" is used on the command line

     - Document console=null and console="" behavior


that last one is pertinent.

_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@kernelnewbies.org
https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies

      reply	other threads:[~2022-10-13 15:12 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-13 10:48 mabe a bug in kernel 5.4 since patchlevel 159 - dma error because use ttynull? Simon Lindhorst
2022-10-13 15:11 ` jim.cromie [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAJfuBxx=Sz2VeOVC28cdLK-m72FY4PbiUkb6BNg1GGooM6Ar6Q@mail.gmail.com' \
    --to=jim.cromie@gmail.com \
    --cc=kernelnewbies@kernelnewbies.org \
    --cc=s.lindhorst@wut.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).