The Linux Kernel Mailing List
 help / color / mirror / Atom feed
From: Andrey Ryabinin <aryabinin@virtuozzo.com>
To: Linus Torvalds <torvalds@linux-foundation.org>,
	Fengguang Wu <fengguang.wu@intel.com>, NeilBrown <neilb@suse.com>
Cc: Oleg Drokin <oleg.drokin@intel.com>,
	Andreas Dilger <andreas.dilger@intel.com>,
	James Simmons <jsimmons@infradead.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Denis Petrovic <denis.petrovic@edu.ece.fr>,
	lustre-devel@lists.lustre.org,
	Staging subsystem List <devel@driverdev.osuosl.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	LKP <lkp@01.org>
Subject: Re: [cfs_trace_lock_tcd] BUG: KASAN: null-ptr-deref in cfs_trace_lock_tcd+0x25/0xeb
Date: Thu, 19 Apr 2018 16:55:28 +0300	[thread overview]
Message-ID: <dfa02f34-5ada-70fe-0fd7-c494d632f8e1@virtuozzo.com> (raw)
In-Reply-To: <b66f6034-7631-7fbf-56aa-e8e136e8b636@virtuozzo.com>



On 04/19/2018 04:35 PM, Andrey Ryabinin wrote:
> 
> 
> On 04/18/2018 09:37 PM, Linus Torvalds wrote:
>> Ugh, that lustre code is disgusting.
>>
>> I thought we were getting rid of it.
>>
>> Anyway, I started looking at why the stack trace is such an incredible
>> mess, with lots of stale entries.
>>
>> The reason (well, _one_ reason) seems to be "ksocknal_startup". It has
>> a 500-byte stack frame for some incomprehensible reason. I assume due
>> to excessive inlining, because the function itself doesn't seem to be
>> that bad.
>>
>> Similarly, LNetNIInit has a 300-byte stack frame. So it gets pretty deep.
>>
>> I'm getting the feeling that KASAN is making things worse because
>> probably it's disabling all the sane stack frame stuff (ie no merging
>> of stack slot entries, perhaps?).
>>
> 
> AFAIR no merging of stack slots policy enabled only if -fsanitize-address-use-after-scope 
> is on (which is CONFIG_KASAN_EXTRA). This feature does cause sometimes significant stack bloat,
> but hasn't been proven to be very useful, so I wouldn't mind disabling it completely.
> 
> So far I know only about a single BUG - https://lkml.kernel.org/r/<151238865557.4852.10258661301122491354@mail.alporthouse.com>
> it has found.

Actually, there is one more - https://syzkaller.appspot.com/bug?id=6a929b72a32ca0b1a6985126fa1bc77c03c12304
so two bugs.

> There are also a lot of other 

I didn't finish this sentence:

There are also a lot of other reports about use-after-scope, but seem all of them are false positives
caused by STRUCTLEAK plugin.

  reply	other threads:[~2018-04-19 13:55 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-04-18 13:38 [cfs_trace_lock_tcd] BUG: unable to handle kernel NULL pointer dereference at 00000050 Fengguang Wu
2018-04-18 13:40 ` [cfs_trace_lock_tcd] BUG: KASAN: null-ptr-deref in cfs_trace_lock_tcd+0x25/0xeb Fengguang Wu
2018-04-18 18:37   ` Linus Torvalds
2018-04-18 22:38     ` NeilBrown
2018-04-19 13:35     ` Andrey Ryabinin
2018-04-19 13:55       ` Andrey Ryabinin [this message]
2018-04-18 13:59 ` [cfs_trace_lock_tcd] BUG: unable to handle kernel NULL pointer dereference at 00000050 James Simmons
2018-04-18 14:13   ` Fengguang Wu
2018-04-18 14:15 ` [lnet_res_container_setup] BUG: unable to handle kernel paging request at 08000664 Fengguang Wu

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=dfa02f34-5ada-70fe-0fd7-c494d632f8e1@virtuozzo.com \
    --to=aryabinin@virtuozzo.com \
    --cc=andreas.dilger@intel.com \
    --cc=denis.petrovic@edu.ece.fr \
    --cc=devel@driverdev.osuosl.org \
    --cc=fengguang.wu@intel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=jsimmons@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkp@01.org \
    --cc=lustre-devel@lists.lustre.org \
    --cc=neilb@suse.com \
    --cc=oleg.drokin@intel.com \
    --cc=torvalds@linux-foundation.org \
    /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