mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hugh Dickins <hugh.dickins@tiscali.co.uk>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Matt Mackall <mpm@selenic.com>,
	Mateusz Kaduk <mateusz.kaduk@gmail.com>,
	Eric Anholt <eric@anholt.net>,
	Linus Torvalds <torvalds@linux-foundation.org>,
	bugme-daemon@bugzilla.kernel.org, linux-kernel@vger.kernel.org
Subject: [Bug 14662] drm/i915: Select CONFIG_SHMEM
Date: Tue, 1 Dec 2009 19:26:32 +0000 (GMT)	[thread overview]
Message-ID: <Pine.LNX.4.64.0912011906290.8058@sister.anvils> (raw)

Hi Chris,

I'm slightly worried by this patch which went into Linus's git yesterday.

Thank you for looking into the issue, and coming up with what Mateusz
has found to be a good workaround.

But is it the right fix?

drm/i915 ought to be working without CONFIG_SHMEM: it then falls back
to using ramfs instead of shmem.  So why isn't that working here?

I'd take the NULL function pointer in read_cache_page_async() to be a
NULL filler function; but that should be pointing to simple_readpage(),
as specified in ramfs_aops.

You don't go into more detail in the comments: do you have any more
info on how this came about?  I don't get it.

I'd prefer not to "select SHMEM" there, because it shouldn't be
necessary; and will put CONFIG_SHMEM=y into the .configs of users
who chose not to have it before, and who will forget to reverse it
if we come up with a better fix letter.

If there is a better fix: I just don't understand what happened here.

Thanks,
Hugh

From: Chris Wilson <chris@chris-wilson.co.uk>
Date: Sun, 22 Nov 2009 15:40:31 +0000 (+0000)
Subject: drm/i915: Select CONFIG_SHMEM
X-Git-Url: http://git.kernel.org/gitweb.cgi?p=linux%2Fkernel%2Fgit%2Ftorvalds%2Flinux-2.6.git;a=commitdiff_plain;h=ca9ab10033d190c1ede85fdf456307bdfdabf079

drm/i915: Select CONFIG_SHMEM

The driver requires shmfs as the backing filesystem to handle the buffer
objects, so ensure it is selected if the user chooses to build our
driver.

Fixes: Bug 14662 - Dell E5500 kernel panic with KMS
http://bugzilla.kernel.org/show_bug.cgi?id=14662

The revealing nature of the panic is the NULL function pointer
dereference in read_cache_page_async().

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reported-and-tested-by: Mateusz Kaduk <mateusz.kaduk@gmail.com>
Signed-off-by: Eric Anholt <eric@anholt.net>
Cc: stable@kernel.org
---

diff --git a/drivers/gpu/drm/Kconfig b/drivers/gpu/drm/Kconfig
index f831ea1..96eddd1 100644
--- a/drivers/gpu/drm/Kconfig
+++ b/drivers/gpu/drm/Kconfig
@@ -92,6 +92,7 @@ config DRM_I830
 config DRM_I915
 	tristate "i915 driver"
 	depends on AGP_INTEL
+	select SHMEM
 	select DRM_KMS_HELPER
 	select FB_CFB_FILLRECT
 	select FB_CFB_COPYAREA

             reply	other threads:[~2009-12-01 19:26 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-01 19:26 Hugh Dickins [this message]
2009-12-01 20:31 ` Matt Mackall

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=Pine.LNX.4.64.0912011906290.8058@sister.anvils \
    --to=hugh.dickins@tiscali.co.uk \
    --cc=bugme-daemon@bugzilla.kernel.org \
    --cc=chris@chris-wilson.co.uk \
    --cc=eric@anholt.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mateusz.kaduk@gmail.com \
    --cc=mpm@selenic.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

all inboxes | Powered by JetHome®