From: Jean Delvare <khali@linux-fr.org>
To: "Adam 'dredzik' Kuczynski" <dredzik@ekg2.org>
Cc: LKML <linux-kernel@vger.kernel.org>,
Maarten Deprez <maartendeprez@users.sourceforge.net>
Subject: Re: GL520SM Sensor Chip driver fix
Date: Mon, 21 Feb 2005 20:17:30 +0100 [thread overview]
Message-ID: <20050221201730.5f880556.khali@linux-fr.org> (raw)
In-Reply-To: <20050220150604.GA658@lotus.ma.gda.pl>
Hi Adam,
> I've been recently trying to get my lmsensors working under
> 2.6.9, and i've found this:
>
> http://seclists.org/lists/linux-kernel/2005/Feb/2856.html
> http://lkml.org/lkml/2005/2/11/90
>
> kernel patch for gl520 chip, but after applying it kernel refused to
> compile. So I've fixed it using gl518sm module source code and I want
> to share the results of my work with you. I hope that it will be
> useful.
> (...)
> +static unsigned short normal_i2c_range[] = { I2C_CLIENT_END };
> +static unsigned int normal_isa_range[] = { I2C_CLIENT_ISA_END };
Ranges were taken apart in 2.6.10-rc2, and Maarten's patch was meant for
linux-2.6.11-rc3-mm2, so it comes to no surprise that you had to
reintroduce them when backporting to 2.6.9.
> static int gl520_attach_adapter(struct i2c_adapter *adapter)
> {
> - if (!(adapter->clRD_DATA))
> - goto exit;
> + if (!(adapter->class & I2C_CLASS_HWMON))
> + return 0;
> + return i2c_detect(adapter, &addr_data, gl520_detect);
> +}
>
> +static int gl520_detect(struct i2c_adapter *adapter, int address, int kind)
> +{
> + struct i2c_client *new_client;
> + struct gl520_data *data;
> + int err = 0;
> +
> + if (!i2c_check_functionality(adapter, I2C_FUNC_SMBUS_BYTE_DATA |
> + I2C_FUNC_SMBUS_WORD_DATA))
> + goto exit;
> +
I suspect that a problem happened when you retrieved the original patch
and it somehow got corrupted, because everything you restore here is
already correct in Maarten's patch.
As a summary, Maarten's patch was just fine and doesn't need any update.
Thanks,
--
Jean Delvare
prev parent reply other threads:[~2005-02-21 19:28 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-02-20 15:06 Adam 'dredzik' Kuczynski
2005-02-21 19:17 ` Jean Delvare [this message]
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=20050221201730.5f880556.khali@linux-fr.org \
--to=khali@linux-fr.org \
--cc=dredzik@ekg2.org \
--cc=linux-kernel@vger.kernel.org \
--cc=maartendeprez@users.sourceforge.net \
/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®