linux-riscv.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Vincent Chen <deanbo422@gmail.com>
To: Palmer Dabbelt <palmer@sifive.com>
Cc: linux-riscv@lists.infradead.org, aou@eecs.berkeley.edu,
	linux@roeck-us.net
Subject: Re: [PATCH] RISC-V: Add CONFIG_PREEMPT=y to defconfig
Date: Thu, 3 Jan 2019 10:59:11 +0800	[thread overview]
Message-ID: <CAJsyPhyA_u2Syoq1tN73qx=sgddb1KS9DY7Tn98jetoCU+R8ug@mail.gmail.com> (raw)
In-Reply-To: <mhng-856d9dbc-a4f1-47c3-a71c-d1f7ae82184b@palmer-si-x1c4>

Palmer Dabbelt <palmer@sifive.com> 於 2018年12月27日 週四 上午1:19寫道:
>
> On Tue, 25 Dec 2018 19:23:50 PST (-0800), linux@roeck-us.net wrote:
> > On Wed, Dec 19, 2018 at 09:25:21PM -0800, Guenter Roeck wrote:
> >> On Wed, Dec 19, 2018 at 05:45:11PM -0800, Guenter Roeck wrote:
> >> > On Wed, Nov 21, 2018 at 10:58:05AM -0800, Palmer Dabbelt wrote:
> >> > > I don't remember who suggested this, but I was talking to someone at
> >> > > Plumbers about all the horrible bugs we've had lurking around in our
> >> > > port despite it still getting to userspace and they suggested that I
> >> > > enable CONFIG_PREEMPT in our defconfig as it'll help shake out more
> >> > > issues.
> >> > >
> >> > > This patch enables CONFIG_PREEMPT in the single RISC-V defconfig.  It
> >> > > still passes my tests (ie, booting Fedora on QEMU).  Maybe I'm too
> >> > > paranoid, but I still don't trust our port enough to just pull the
> >> > > trigger on this without at least accumulating some "Tested-by"s on it.
> >> > >
> >> > > Signed-off-by: Palmer Dabbelt <palmer@sifive.com>
> >> >
> >> > I can only give you a
> >> >
> >> > Fails-miserably-for: Guenter Roeck <linux@roeck-us.net>
> >> >
> >> > Not the new defconfig itself, but the new defconfig plus a variety of
> >> > selftest options. I don't know what exactly is failing, but here is
> >> > my list of enabled selftests on top of defconfig:
> >> >
> >> > CONFIG_CRYPTO_MANAGER_DISABLE_TESTS=y
> >> > CONFIG_CRC32_SELFTEST=y
> >> > CONFIG_DEBUG_LOCKING_API_SELFTESTS=y
> >> > CONFIG_DEBUG_NMI_SELFTEST=y
> >> > CONFIG_DEBUG_RODATA_TEST=y
> >> > CONFIG_DEBUG_TLBFLUSH=y
> >> > CONFIG_DMATEST=y
> >> > CONFIG_GLOB_SELFTEST=y
> >> > CONFIG_OF_UNITTEST=y
> >> > CONFIG_PCI_EPF_TEST=y
> >> > CONFIG_PCI_ENDPOINT_TEST=y
> >> > CONFIG_PROVE_LOCKING=y
> >> > CONFIG_PROVE_RCU=y
> >> > CONFIG_RCU_EQS_DEBUG=y
> >> > CONFIG_STATIC_KEYS_SELFTEST=y
> >> > CONFIG_STRING_SELFTEST=y
> >> > CONFIG_TEST_BITMAP=y
> >> > CONFIG_TEST_FIRMWARE=y
> >> > CONFIG_TEST_SORT=y
> >> > CONFIG_TEST_SYSCTL=y
> >> > CONFIG_TEST_UUID=y
> >> > CONFIG_USB_TEST=y
> >> > CONFIG_USB_EHSET_TEST_FIXTURE=y
> >> > CONFIG_USB_LINK_LAYER_TEST=y
> >> > CONFIG_WW_MUTEX_SELFTEST=y
> >> > CONFIG_TORTURE_TEST=y
> >> > CONFIG_LOCK_TORTURE_TEST=y
> >> > CONFIG_RCU_TORTURE_TEST=y
> >> > CONFIG_RBTREE_TEST=y
> >> > CONFIG_INTERVAL_TREE_TEST=y
> >> >
> >>
> >> Update: defconfig+CONFIG_LOCK_TORTURE_TEST=y causes the hang
> >> if CONFIG_PREEMPT=y.
> >>
> >
> > Another update. CONFIG_RCU_TORTURE_TEST=y or CONFIG_WW_MUTEX_SELFTEST=y
> > also result in hangs, only a bit later. I have now disabled all three test
> > options in my riscv boot tests if CONFIG_PREEMPT=y. The lack of error
> > reports in the future does _not_ mean that the problem has magically
> > disappeared. I just find it pointless to keep testing a known broken
> > configuration, even more so since doing so would hide other potential
> > problems.
>
> Thanks.  I agree it's pointless to test more, as there appear to be lots of
> bugs to fix already and this will just mask other bugs.
>

Last week, I encountered some locking issues in the kernel, so I tried
to test the
kernel with some relative selftests. Since I had already set CONFIG_PREEMPT=y,
I encountered the same results in RCU_TORTURE_TEST and
LOCK_TORTURE_TEST. I tried to debug it and found the hang was due to
the lack of _TIF_NEED_RESCHED check for kernel threads in entry.S. I will send a
patch to solve this problem and I hope you can give me some comments
if you find some
mistakes.

Vincent Chen

_______________________________________________
linux-riscv mailing list
linux-riscv@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-riscv

  reply	other threads:[~2019-01-03  2:59 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-20  1:45 [PATCH] RISC-V: Add CONFIG_PREEMPT=y to defconfig Guenter Roeck
2018-12-20  5:25 ` Guenter Roeck
2018-12-26  3:23   ` Guenter Roeck
2018-12-26 17:19     ` Palmer Dabbelt
2019-01-03  2:59       ` Vincent Chen [this message]
2019-01-03  3:51         ` Guenter Roeck
2019-01-03  5:21           ` Vincent Chen
2019-01-03  5:29             ` Guenter Roeck
2019-01-08 19:24         ` Palmer Dabbelt
2018-12-20 21:33 ` Palmer Dabbelt

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='CAJsyPhyA_u2Syoq1tN73qx=sgddb1KS9DY7Tn98jetoCU+R8ug@mail.gmail.com' \
    --to=deanbo422@gmail.com \
    --cc=aou@eecs.berkeley.edu \
    --cc=linux-riscv@lists.infradead.org \
    --cc=linux@roeck-us.net \
    --cc=palmer@sifive.com \
    /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 NNTP newsgroup(s).