linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Mark M. Hoffman" <mhoffman@lightlink.com>
To: Martin Schlemmer <azarah@gentoo.org>
Cc: Greg KH <greg@kroah.com>, LKML <linux-kernel@vger.kernel.org>,
	Sensors <sensors@Stimpy.netroedge.com>
Subject: Re: OOPS w83781d during rmmod (2.5.70-bk1[1234])
Date: Tue, 10 Jun 2003 01:41:07 -0400	[thread overview]
Message-ID: <20030610054107.GA22719@earth.solarsys.private> (raw)
In-Reply-To: <1055136870.5280.196.camel@workshop.saharacpt.lan>

* Martin Schlemmer <azarah@gentoo.org> [2003-06-09 07:34:30 +0200]:
> 
> Anyhow, Only change I have made to the w83781d driver, is one line
> (just tell it to that if the chip id is 0x72, its also of type
> w83726HF), but now (2.5.70-bk1[123]) it segfaults for me on rmmod, where
> it did not with 2.5.68 kernels when I still had the other board.  I will
> attach a oops tomorrow or such when I get home.

I reproduced the segfault here.  It looks like i2c_del_driver() tries
to call w83781d_detach_client() more than once now, partly because of
the safe list fix in 2.5.70-bk11.  But that function should only be
called for the "primary" client, not the subclients.

The quick/ugly patch below fixes the symptom, but maybe not the disease.
There might be more fundamental brokenness in the whole subclient scheme.
I'll keep looking when I get the chance.

--- linux-2.5.70-bk14/drivers/i2c/chips/w83781d.c	2003-06-10 00:49:19.831210956 -0400
+++ linux-2.5.70/drivers/i2c/chips/w83781d.c	2003-06-10 00:53:35.041027614 -0400
@@ -1412,6 +1412,10 @@
 	struct w83781d_data *data = i2c_get_clientdata(client);
 	int err;
 
+	/* if this is a subclient, do nothing */
+	if (!data)
+		return 0;
+
 	/* release ISA region or I2C subclients first */
 	if (i2c_is_isa_client(client)) {
 		release_region(client->addr, W83781D_EXTENT);

Regards,

-- 
Mark M. Hoffman
mhoffman@lightlink.com


  parent reply	other threads:[~2003-06-10  5:27 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-05-24 18:37 [OOPS] w83781d during rmmod (2.5.69-bk17) Mark M. Hoffman
     [not found] ` <3ED8067E.1050503@paradyne.com>
2003-06-01 14:38   ` [RFC PATCH] " Mark M. Hoffman
2003-06-02 17:20     ` Greg KH
2003-06-03  5:22       ` Martin Schlemmer
2003-06-03 19:43         ` Philip Pokorny
2003-06-04  5:57           ` Martin Schlemmer
2003-06-05  2:39       ` Mark M. Hoffman
2003-06-05 19:47         ` Greg KH
2003-06-09  5:34           ` Martin Schlemmer
2003-06-10  5:38             ` Martin Schlemmer
2003-06-10  5:41             ` Mark M. Hoffman [this message]
2003-06-10  5:51               ` OOPS w83781d during rmmod (2.5.70-bk1[1234]) Martin Schlemmer
2003-06-11  5:44                 ` Martin Schlemmer
2003-06-12  6:57               ` [RFC][2.5] list_for_each_safe not so safe (was Re: OOPS w83781d during rmmod (2.5.70-bk1[1234])) Martin Schlemmer
2003-06-13  2:36                 ` Mark M. Hoffman
2003-06-13  6:08                   ` Martin Schlemmer
2003-06-14  6:26                   ` Martin Schlemmer
2003-06-16 18:41                     ` Greg KH
2003-09-03 20:54                       ` [PATCH 2.6] Fix conversion from milli volts in store_in_reg() for w83781d.c Martin Schlemmer
2003-09-04 18:40                         ` Greg KH
2003-09-07 15:41                         ` Andrey Borzenkov

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=20030610054107.GA22719@earth.solarsys.private \
    --to=mhoffman@lightlink.com \
    --cc=azarah@gentoo.org \
    --cc=greg@kroah.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sensors@Stimpy.netroedge.com \
    /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;
as well as URLs for NNTP newsgroup(s).