From: Maarten Lankhorst <maarten.lankhorst@canonical.com>
To: "nouveau@lists.freedesktop.org" <nouveau@lists.freedesktop.org>,
"dri-devel@lists.freedesktop.org"
<dri-devel@lists.freedesktop.org>
Subject: [PATCH 2/3] drm/nouveau: fix null pointer dereference in poll_changed
Date: Tue, 23 Jul 2013 15:45:11 +0200 [thread overview]
Message-ID: <51EE88E7.8010802@canonical.com> (raw)
In-Reply-To: <51EE8888.4030302@canonical.com>
Fixes vgaswitcheroo on a card without display.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@canonical.com>
---
diff --git a/drivers/gpu/drm/nouveau/nouveau_fbcon.c b/drivers/gpu/drm/nouveau/nouveau_fbcon.c
index 4c1bc06..8f6d63d 100644
--- a/drivers/gpu/drm/nouveau/nouveau_fbcon.c
+++ b/drivers/gpu/drm/nouveau/nouveau_fbcon.c
@@ -398,7 +398,8 @@ void
nouveau_fbcon_output_poll_changed(struct drm_device *dev)
{
struct nouveau_drm *drm = nouveau_drm(dev);
- drm_fb_helper_hotplug_event(&drm->fbcon->helper);
+ if (drm->fbcon)
+ drm_fb_helper_hotplug_event(&drm->fbcon->helper);
}
static int
next prev parent reply other threads:[~2013-07-23 13:45 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-07-23 13:43 [PATCH 1/3] drm/nouveau: fix vblank interrupt being called before event is setup Maarten Lankhorst
2013-07-23 13:45 ` Maarten Lankhorst [this message]
2013-07-23 13:49 ` [PATCH 3/3] drm/nouveau: fix semaphore dmabuf obj Maarten Lankhorst
2013-07-30 2:42 ` [PATCH 1/3] drm/nouveau: fix vblank interrupt being called before event is setup Ben Skeggs
2013-07-30 6:10 ` Maarten Lankhorst
2013-07-30 6:13 ` Ben Skeggs
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=51EE88E7.8010802@canonical.com \
--to=maarten.lankhorst@canonical.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=nouveau@lists.freedesktop.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.