From: greg@kroah.com (Greg KH)
To: lm-sensors@vger.kernel.org
Subject: [BK PATCH] i2c driver fixes for 2.6.0-test5
Date: Thu, 19 May 2005 06:24:19 +0000 [thread overview]
Message-ID: <20030924180956.GG10443@kroah.com> (raw)
In-Reply-To: <20030802052904.GA9782@kroah.com>
On Wed, Sep 24, 2003 at 02:01:54AM -0400, Mark M. Hoffman wrote:
> (drivers/i2c/busses/i2c-i810.c)
>
> > -static unsigned long ioaddr;
> > +static void *ioaddr;
>
> But later we're doing arithmetic on ioaddr(!) Apparently the readl/writel
> macros are recasting that... but to me this is an obfuscating change.
I did it this way, as ioremap returns a void *. And it's ok to do math
on a void pointer, works the same way as math on a char *. It got rid
of two casts in the driver with this change.
> > @@ -261,49 +225,32 @@
> > {
> > i2c_bit_del_bus(&i810_ddc_adapter);
> > i2c_bit_del_bus(&i810_i2c_adapter);
> > + iounmap(ioaddr);
> > }
> >
> > -
> > -/* Don't register driver to avoid driver conflicts */
> > -/*
> > static struct pci_driver i810_driver = {
> > .name = "i810 smbus",
> > .id_table = i810_ids,
> > .probe = i810_probe,
> > .remove = __devexit_p(i810_remove),
> > };
> > -*/
> >
> > static int __init i2c_i810_init(void)
> > {
> > - struct pci_dev *dev;
> > - const struct pci_device_id *id;
> > -
> > - printk("i2c-i810.o version %s (%s)\n", LM_VERSION, LM_DATE);
> > -/*
> > return pci_module_init(&i810_driver);
> > -*/
> > - pci_for_each_dev(dev) {
> > - id = pci_match_device(i810_ids, dev);
> > - if(id)
> > - if(i810_probe(dev, id) >= 0)
> > - return 0;
> > - }
> > - return -ENODEV;
> > }
>
> Didn't you advise mds earlier that the correct solution here is to
> combine this code into the driver with which it now conflicts? (See
> drivers/video/i810/...) Likewise for i2c-via.c and i2c-voodoo3.c.
I did say this. But just "grabbing" the device like you are doing in
2.4 isn't an ok thing to do (the device can disappear underneath you
quite easily in pci hotplug systems.) It is not safe to do this at all.
So if people complain about both drivers trying to grab the device, then
people will work on merging the drivers properly, and will send me a
patch :)
There are also some devices that these drivers match up to, that do not
match up to some existing video drivers, from what I could tell, so it
isn't a complete overlap.
Thanks for looking over the changes.
greg k-h
next prev parent reply other threads:[~2005-05-19 6:24 UTC|newest]
Thread overview: 125+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-08-02 5:29 [BK PATCH] i2c driver fixes for 2.6.0-test2 Greg KH
2005-05-19 6:24 ` Greg KH
2005-05-19 6:24 ` Jean Delvare
2005-05-19 6:24 ` Mark M. Hoffman
2005-05-19 6:24 ` Greg KH
2005-05-19 6:24 ` Greg KH
2005-05-19 6:24 ` Mark M. Hoffman
2003-08-14 5:13 ` Mark M. Hoffman
2005-05-19 6:24 ` Mark M. Hoffman
2003-08-14 21:14 ` Greg KH
2005-05-19 6:24 ` Greg KH
2005-05-19 6:24 ` [BK PATCH] i2c driver fixes for 2.6.0-test5 Jean Delvare
2005-05-19 6:24 ` Mark M. Hoffman
2005-05-19 6:24 ` Mark M. Hoffman
2005-05-19 6:24 ` Greg KH [this message]
-- strict thread matches above, loose matches on Subject: below --
2003-08-15 18:32 [BK PATCH] i2c driver fixes for 2.6.0-test3 Greg KH
2005-05-19 6:24 ` Greg KH
2003-08-15 18:33 ` [PATCH] i2c driver changes 2.6.0-test3 Greg KH
2005-05-19 6:24 ` Greg KH
2003-08-15 18:33 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-08-15 18:33 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-08-15 18:33 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-08-15 18:33 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-08-15 18:33 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-08-15 18:33 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-08-15 18:33 ` Greg KH
2005-05-19 6:24 ` Greg KH
2005-05-19 6:24 ` Philip Pokorny
2005-05-19 6:24 ` Jean Delvare
2005-05-19 6:24 ` Mark D. Studebaker
2005-05-19 6:24 ` Jean Delvare
2005-05-19 6:24 ` Greg KH
2003-09-22 23:28 [BK PATCH] i2c driver fixes for 2.6.0-test5 Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` [PATCH] " Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-22 23:30 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-23 8:16 ` Christoph Hellwig
2005-05-19 6:24 ` Christoph Hellwig
2003-09-23 16:19 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-23 16:22 ` Christoph Hellwig
2005-05-19 6:24 ` Christoph Hellwig
2003-09-23 19:04 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-09-23 19:08 ` Christoph Hellwig
2005-05-19 6:24 ` Christoph Hellwig
2003-10-10 23:10 [BK PATCH] i2c driver fixes for 2.6.0-test7 Greg KH
2005-05-19 6:24 ` Greg KH
2003-10-10 23:11 ` [PATCH] " Greg KH
2005-05-19 6:24 ` Greg KH
2003-10-10 23:11 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-10-10 23:11 ` Greg KH
2005-05-19 6:24 ` Greg KH
2003-10-10 23:11 ` Greg KH
2005-05-19 6:24 ` Greg KH
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=20030924180956.GG10443@kroah.com \
--to=greg@kroah.com \
--cc=lm-sensors@vger.kernel.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.