Fix oops causing typo in keyspan driver (rhbz 870562)

This commit is contained in:
Josh Boyer 2012-11-16 08:43:51 -05:00
parent df9f4ec79e
commit d94c6eb95a
2 changed files with 105 additions and 0 deletions

View File

@ -716,6 +716,9 @@ Patch22113: smp_irq_move_cleanup_interrupt.patch
#rhbz 873001
Patch22114: iwlwifi-remove-queue-empty-warn-3.6.patch
#rhbz 870562
Patch22115: keyspan.patch
# END OF PATCH DEFINITIONS
%endif
@ -1349,6 +1352,9 @@ ApplyPatch smp_irq_move_cleanup_interrupt.patch
#rhbz 873001
ApplyPatch iwlwifi-remove-queue-empty-warn-3.6.patch
#rhbz 870562
ApplyPatch keyspan.patch
# END OF PATCH APPLICATIONS
%endif
@ -2050,6 +2056,7 @@ fi
%changelog
* Fri Nov 16 2012 Josh Boyer <jwboyer@redhat.com>
- Fix oops causing typo in keyspan driver (rhbz 870562)
- Don't WARN_ON empty queues in iwlwifi (rhbz 873001)
* Thu Nov 15 2012 Justin M. Forbes <jforbes@redhat.com>

98
keyspan.patch Normal file
View File

@ -0,0 +1,98 @@
Delivered-To: jwboyer@gmail.com
Received: by 10.58.186.240 with SMTP id fn16csp155256vec;
Sat, 10 Nov 2012 01:14:20 -0800 (PST)
Received: by 10.68.130.197 with SMTP id og5mr40733607pbb.138.1352538859530;
Sat, 10 Nov 2012 01:14:19 -0800 (PST)
Return-Path: <stable-owner@vger.kernel.org>
Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67])
by mx.google.com with ESMTP id pj1si1353832pbc.115.2012.11.10.01.14.15;
Sat, 10 Nov 2012 01:14:19 -0800 (PST)
Received-SPF: pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67;
Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of stable-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mail=stable-owner@vger.kernel.org
Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand
id S1750798Ab2KJJOO (ORCPT <rfc822;crquan@gmail.com> + 33 others);
Sat, 10 Nov 2012 04:14:14 -0500
Received: from canardo.mork.no ([148.122.252.1]:37367 "EHLO canardo.mork.no"
rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP
id S1750699Ab2KJJOM (ORCPT <rfc822;stable@vger.kernel.org>);
Sat, 10 Nov 2012 04:14:12 -0500
Received: from nemi.mork.no (nemi.mork.no [IPv6:2001:4620:9:2:216:eaff:feb3:788])
(authenticated bits=0)
by canardo.mork.no (8.14.3/8.14.3) with ESMTP id qAA9E1cX010750
(version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NOT);
Sat, 10 Nov 2012 10:14:02 +0100
Received: from bjorn by nemi.mork.no with local (Exim 4.80)
(envelope-from <bjorn@nemi.mork.no>)
id 1TX78a-0007Li-AD; Sat, 10 Nov 2012 10:14:00 +0100
From: =?UTF-8?q?Bj=C3=B8rn=20Mork?= <bjorn@mork.no>
To: Richard <richjunk@pacbell.net>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org,
=?UTF-8?q?Bj=C3=B8rn=20Mork?= <bjorn@mork.no>,
<stable@vger.kernel.org>, Johan Hovold <jhovold@gmail.com>
Subject: [PATCH usb-linus] USB: keyspan: fix typo causing GPF on open
Date: Sat, 10 Nov 2012 10:13:42 +0100
Message-Id: <1352538822-28221-1-git-send-email-bjorn@mork.no>
X-Mailer: git-send-email 1.7.10.4
In-Reply-To: <509D5BCD.3010901@pacbell.net>
References: <509D5BCD.3010901@pacbell.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-Virus-Scanned: clamav-milter 0.97.6 at canardo
X-Virus-Status: Clean
Sender: stable-owner@vger.kernel.org
Precedence: bulk
List-ID: <stable.vger.kernel.org>
X-Mailing-List: stable@vger.kernel.org
Commit f79b2d0f (USB: keyspan: fix NULL-pointer dereferences and
memory leaks) had a small typo which made the driver use wrong
offsets when mapping serial port private data. This results in
in a GPF when the port is opened.
Reported-by: Richard <richjunk@pacbell.net>
Cc: <stable@vger.kernel.org>
Cc: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Bjørn Mork <bjorn@mork.no>
---
Hello Richard,
I wonder if you are able to test and verify this? I do not guarantee
that there aren't other issues around, but this small typo looked like
an obvious killer...
Bjørn
drivers/usb/serial/keyspan.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/usb/serial/keyspan.c b/drivers/usb/serial/keyspan.c
index 7179b0c..cff8dd5 100644
--- a/drivers/usb/serial/keyspan.c
+++ b/drivers/usb/serial/keyspan.c
@@ -2430,7 +2430,7 @@ static void keyspan_release(struct usb_serial *serial)
static int keyspan_port_probe(struct usb_serial_port *port)
{
struct usb_serial *serial = port->serial;
- struct keyspan_port_private *s_priv;
+ struct keyspan_serial_private *s_priv;
struct keyspan_port_private *p_priv;
const struct keyspan_device_details *d_details;
struct callbacks *cback;
@@ -2445,7 +2445,6 @@ static int keyspan_port_probe(struct usb_serial_port *port)
if (!p_priv)
return -ENOMEM;
- s_priv = usb_get_serial_data(port->serial);
p_priv->device_details = d_details;
/* Setup values for the various callback routines */
--
1.7.10.4
--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html