public inbox for linux-next@vger.kernel.org 
 help / color / mirror / Atom feed
From: Linus Torvalds <torvalds@linux-foundation•org>
To: Tony Luck <tony.luck@intel•com>
Cc: Rusty Russell <rusty@rustcorp•com.au>,
	Dave Young <hidave.darkstar@gmail•com>,
	Stephen Rothwell <sfr@canb•auug.org.au>,
	linux-next@vger•kernel.org, LKML <linux-kernel@vger•kernel.org>
Subject: Re: linux-next: Tree for June 3
Date: Fri, 4 Jun 2010 13:04:00 -0700 (PDT)	[thread overview]
Message-ID: <alpine.LFD.2.00.1006041255210.8175@i5.linux-foundation.org> (raw)
In-Reply-To: <AANLkTikN_3oLIFQ0CRiLwXUV79myy_aqriezdCgnZHFT@mail.gmail.com>



On Fri, 4 Jun 2010, Tony Luck wrote:
> 
> At the point of dereference it looks like we were trying
> to load a 4-byte data object from offset 552 into the
> "struct module *" that wa returned by load_module().

Sounds like 'mod->num_ctors' loaded by do_mod_ctors(). It's a 4-byte field 
in roughly that area.

What does a NaT consumption fault mean, and does it give the invalid 
address it was loaded off? In the successful path of "load_module()", we 
will have dereferenced the "mod" pointer we return just before, so I 
wonder if there's some error case that incorrectly returns a positive 
errno instead of a negative one, and causes us to miss the "IS_ERR()" 
check or something.

There's a couple of checking routines in module.c that do not return a 
negative error, but instead return 0/1. The one I looked at was converted 
into a negative error, but there are several cases of

	if (err)
		return ERR_PTR(err)

and if something does that on a 0/1 value, it will return a bogus pointer.

		Linus

  reply	other threads:[~2010-06-04 20:09 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-03  3:47 linux-next: Tree for June 3 Stephen Rothwell
2010-06-03  7:39 ` Dave Young
2010-06-03  8:00   ` Dave Young
2010-06-03  8:16     ` Dave Young
2010-06-03 12:52     ` Rusty Russell
2010-06-04 19:46       ` Tony Luck
2010-06-04 20:04         ` Linus Torvalds [this message]
2010-06-04 20:46           ` Luck, Tony
2010-06-04 22:05             ` Linus Torvalds
2010-06-04 22:50               ` Luck, Tony
2010-06-04 22:57                 ` Linus Torvalds
2010-06-05  2:39                   ` Rusty Russell
2010-06-05  2:51                     ` Rusty Russell
2010-06-05  4:01                       ` Rusty Russell
2010-06-07 18:16                         ` Luck, Tony
2010-06-03 15:46 ` linux-next: Tree for June 3 (qlcnic) Randy Dunlap
2010-06-03 17:31   ` Anirban Chakraborty
     [not found] ` <20100603134753.710a64b3.sfr-3FnU+UHB4dNDw9hX6IcOSA@public.gmane.org>
2010-06-03 15:55   ` linux-next: Tree for June 3 (iwlwifi) Randy Dunlap
2010-06-03 17:21     ` John W. Linville
     [not found]       ` <20100603172114.GA14597-2XuSBdqkA4R54TAoqtyWWQ@public.gmane.org>
2010-06-03 17:42         ` Guy, Wey-Yi
2010-06-03 17:45       ` reinette chatre
2010-06-03 16:39 ` [PATCH -next] classmate-laptop: fix for RFKILL=m, CMPC=y Randy Dunlap
2010-06-09 20:02   ` Thadeu Lima de Souza Cascardo
2010-06-09 20:05     ` Randy Dunlap
2010-06-09 20:11       ` Matthew Garrett
  -- strict thread matches above, loose matches on Subject: below --
2011-06-03  6:38 linux-next: Tree for June 3 Stephen Rothwell
2009-06-03  9:09 Stephen Rothwell
2008-06-03  8:30 Stephen Rothwell
2008-06-04 11:28 ` Dmitri Vorobiev

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=alpine.LFD.2.00.1006041255210.8175@i5.linux-foundation.org \
    --to=torvalds@linux-foundation$(echo .)org \
    --cc=hidave.darkstar@gmail$(echo .)com \
    --cc=linux-kernel@vger$(echo .)kernel.org \
    --cc=linux-next@vger$(echo .)kernel.org \
    --cc=rusty@rustcorp$(echo .)com.au \
    --cc=sfr@canb$(echo .)auug.org.au \
    --cc=tony.luck@intel$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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