Linus Torvalds | 1 Dec 2004 01:10

Re: [RFC] Splitting kernel headers and deprecating __KERNEL__


On Tue, 30 Nov 2004, David Woodhouse wrote:
> 
> Linus, you're arguing that it's better to let users use something which
> is non-portable and silently does the wrong thing, as long as it
> actually compiles. That this is preferable to making sure it doesn't
> compile. 

I'm saying that if it worked before, it should work after. And my 
suggestion gives a nice warning.

> But atomic.h isn't an example of that.

Even atomic.h. I could well imagine that somebody includes atomic.h just 
to get the thread-safe updates for some architectures. For example, 
asm-alpha/atomic.h does it right, and I woul dnot be at all surprised if 
somebody had noticed.

And your suggestion has the problem that the people who get bitten by a 
non-compiling thing are not necessarily the same people who can fix it.

> software'? Of course not; you have to draw the line somewhere. And I
> would draw it somewhere between atomic.h and byteorder.h -- where would
> _you_ draw it?

I'll draw it at "somebody might validly use it", because the fact is, I 
can't test it. 

Which is why I want patches to this to be OBVIOUSLY CORRECT, dammit! How 
hard is that to understand?
(Continue reading)

Greg KH | 1 Dec 2004 01:13
Gravatar

Re: [PATCH] I2C fixes for 2.6.10-rc2

ChangeSet 1.2223.2.10, 2004/11/29 15:41:38-08:00, khali <at> linux-fr.org

[PATCH] I2C: Add support for the nForce2 Ultra 400 to i2c-nforce2

This simple patch adds support for the nForce2 Ultra 400 to i2c-nforce2.
I just made a similar update on the 2.4/CVS version of the driver.

Signed-off-by: Jean Delvare <khali <at> linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <greg <at> kroah.com>

 drivers/i2c/busses/i2c-nforce2.c |    9 ++++++---
 include/linux/pci_ids.h          |    1 +
 2 files changed, 7 insertions(+), 3 deletions(-)

diff -Nru a/drivers/i2c/busses/i2c-nforce2.c b/drivers/i2c/busses/i2c-nforce2.c
--- a/drivers/i2c/busses/i2c-nforce2.c	2004-11-30 16:00:37 -08:00
+++ b/drivers/i2c/busses/i2c-nforce2.c	2004-11-30 16:00:37 -08:00
 <at>  <at>  -24,9 +24,10  <at>  <at> 
 */

 /*
-    SUPPORTED DEVICES	PCI ID
-    nForce2 MCP		0064
-    nForce3 Pro150 MCP	00D4
+    SUPPORTED DEVICES		PCI ID
+    nForce2 MCP			0064
+    nForce2 Ultra 400 MCP	0084
+    nForce3 Pro150 MCP		00D4

     This driver supports the 2 SMBuses that are included in the MCP2 of the
(Continue reading)

Greg KH | 1 Dec 2004 01:13
Gravatar

Re: [PATCH] I2C fixes for 2.6.10-rc2

ChangeSet 1.2223.2.11, 2004/11/29 15:42:04-08:00, khali <at> linux-fr.org

[PATCH] I2C: macintoch/therm_* drivers cleanups

This patch cleans the macintoch/therm_* drivers a bit. It removes
useless IDs, cleans names (no white space), some coding style fixes as
well, etc. It's exactly the same as what I posted yesterday as a
candidate fix to bug #3823:
http://bugzilla.kernel.org/show_bug.cgi?id=3823

Although it isn't the proper fix for that bug, as you underlined, this
still sounds like a sane set of cleanups for these drivers.

Signed-off-by: Jean Delvare <khali <at> linux-fr.org>
Signed-off-by: Greg Kroah-Hartman <greg <at> kroah.com>

 drivers/macintosh/therm_adt746x.c    |   11 +++++------
 drivers/macintosh/therm_pm72.c       |    3 +--
 drivers/macintosh/therm_windtunnel.c |    8 ++++----
 3 files changed, 10 insertions(+), 12 deletions(-)

diff -Nru a/drivers/macintosh/therm_adt746x.c b/drivers/macintosh/therm_adt746x.c
--- a/drivers/macintosh/therm_adt746x.c	2004-11-30 16:00:32 -08:00
+++ b/drivers/macintosh/therm_adt746x.c	2004-11-30 16:00:32 -08:00
 <at>  <at>  -170,11 +170,11  <at>  <at> 
 }

 static struct i2c_driver thermostat_driver = {  
-	.name		="Apple Thermostat ADT746x",
-	.id		=0xDEAD7467,
(Continue reading)

Blaisorblade | 1 Dec 2004 01:20
Picon
Favicon

VFS interactions with UML and other big UML changes (was: Re: [patch 1/2] Uml - first part rework of run_helper() and users.)

On Wednesday 01 December 2004 00:20, Andrew Morton wrote:
> blaisorblade_spam <at> yahoo.it wrote:
> > Fixed a file descriptor leak in the network driver when changing an IP
> > address.
> >
> > Fixed the error handling in run_helper.

> > Paolo notes:
> >
> > Actually, this is part one of the change, the exact one extracted from
> > Jeff Dike's incrementals tree before 2.6.9-rc big UML merge.
> >
> > There is some changes must be done, so I'm also sending a second patch
> > with this one, too. Separated for tracking purposes.
> >
> > Don't send this pair of ones to Linus before Jeff ACK's it - just put
> > into -mm for now.

> That makes five UML patches which I have queued up pending confirmation:
Ok, detailed answers for each one.

> hostfs-uml-set-sendfile-to-generic_file_sendfile.patch
> hostfs-uml-add-some-other-pagecache-methods.patch

For these two, I'm waiting mainline answers - the first one was tested and 
worked, while the second not, but is no more intrusive. In general, the 
patches themselves are good: hostfs already makes full use of the page cache.

My doubt (which actually is not related to the patches themselves) is here:

(Continue reading)

Greg KH | 1 Dec 2004 01:13
Gravatar

Re: [PATCH] I2C fixes for 2.6.10-rc2

ChangeSet 1.2223.2.9, 2004/11/29 15:07:15-08:00, aris <at> cathedrallabs.org

[PATCH] i2c-ite: get rid of cli()/sti()

I found only this one. Next time I'll try to make better grep
expressions :^)

[I2C] i2c-ite: get rid of cli()/sti()

Signed-off-by: Aristeu Sergio Rozanski Filho <aris <at> cathedrallabs.org>
Signed-off-by: Greg Kroah-Hartman <greg <at> kroah.com>

 drivers/i2c/busses/i2c-ite.c |   31 +++++++++++++++++++++++--------
 1 files changed, 23 insertions(+), 8 deletions(-)

diff -Nru a/drivers/i2c/busses/i2c-ite.c b/drivers/i2c/busses/i2c-ite.c
--- a/drivers/i2c/busses/i2c-ite.c	2004-11-30 16:00:43 -08:00
+++ b/drivers/i2c/busses/i2c-ite.c	2004-11-30 16:00:43 -08:00
 <at>  <at>  -62,6 +62,7  <at>  <at> 
 static struct iic_ite gpi;
 static wait_queue_head_t iic_wait;
 static int iic_pending;
+static spinlock_t lock;

 /* ----- local functions ----------------------------------------------	*/

 <at>  <at>  -108,6 +109,7  <at>  <at> 
 static void iic_ite_waitforpin(void) {

    int timeout = 2;
(Continue reading)

Greg KH | 1 Dec 2004 01:05
Gravatar

[BK PATCH] More USB fixes for 2.6.10-rc2

Hi,

Here are a number of tiny USB fixes for 2.6.10-rc2.  There is also a
documentation update in here too.

Please pull from:
	bk://kernel.bkbits.net/gregkh/linux/usb-2.6

Patches will be posted to linux-usb-devel as a follow-up thread for
those who want to see them.

thanks,

greg k-h

 Documentation/usb/gadget_serial.txt |  332 ++++++++++++++++++++++++++++++++++++
 drivers/base/firmware_class.c       |    2 
 drivers/block/ub.c                  |    9 
 drivers/usb/Makefile                |    1 
 drivers/usb/core/message.c          |    7 
 drivers/usb/core/urb.c              |    8 
 drivers/usb/core/usb.c              |    2 
 drivers/usb/core/usb.h              |   15 +
 drivers/usb/gadget/ether.c          |   14 +
 drivers/usb/gadget/file_storage.c   |    2 
 drivers/usb/gadget/gadget_chips.h   |    6 
 drivers/usb/gadget/serial.c         |    3 
 drivers/usb/gadget/zero.c           |    2 
 drivers/usb/host/ehci-hcd.c         |    8 
 drivers/usb/host/ehci-hub.c         |    3 
(Continue reading)

Greg KH | 1 Dec 2004 01:13
Gravatar

Re: [PATCH] I2C fixes for 2.6.10-rc2

ChangeSet 1.2223.2.5, 2004/11/24 14:25:49-08:00, aris <at> cathedrallabs.org

[PATCH] i2c-elektor: get rid of cli/sti

this patch get rid of cli()/sti(). while correcting this I found
that when a process wakes by an interrupt, pcf_pending doesn't
come back to 0 and next caller will return imediately. also,
there are other drivers with the exact same problem. if you
don't have any comments on this, I'll do the same for other
drivers.

[I2C] i2c-elektor: getting rid of cli()/sti() usage

Signed-off-by: Aristeu Sergio Rozanski Filho <aris <at> cathedrallabs.org>
Signed-off-by: Greg Kroah-Hartman <greg <at> kroah.com>

 drivers/i2c/busses/i2c-elektor.c |   22 ++++++++++++++++++----
 1 files changed, 18 insertions(+), 4 deletions(-)

diff -Nru a/drivers/i2c/busses/i2c-elektor.c b/drivers/i2c/busses/i2c-elektor.c
--- a/drivers/i2c/busses/i2c-elektor.c	2004-11-30 16:01:05 -08:00
+++ b/drivers/i2c/busses/i2c-elektor.c	2004-11-30 16:01:05 -08:00
 <at>  <at>  -59,6 +59,7  <at>  <at> 

 static wait_queue_head_t pcf_wait;
 static int pcf_pending;
+static spinlock_t lock;

 /* ----- local functions ----------------------------------------------	*/

(Continue reading)

Greg KH | 1 Dec 2004 01:13
Gravatar

Re: [PATCH] I2C fixes for 2.6.10-rc2

ChangeSet 1.2223.2.8, 2004/11/24 14:34:51-08:00, greg <at> kroah.com

[PATCH] I2C: make fixup_fan_min static in adm1026 driver.

Signed-off-by: Greg Kroah-Hartman <greg <at> kroah.com>

 drivers/i2c/chips/adm1026.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)

diff -Nru a/drivers/i2c/chips/adm1026.c b/drivers/i2c/chips/adm1026.c
--- a/drivers/i2c/chips/adm1026.c	2004-11-30 16:00:48 -08:00
+++ b/drivers/i2c/chips/adm1026.c	2004-11-30 16:00:48 -08:00
 <at>  <at>  -914,7 +914,7  <at>  <at> 
 fan_offset(8);

 /* Adjust fan_min to account for new fan divisor */
-void fixup_fan_min(struct device *dev, int fan, int old_div)
+static void fixup_fan_min(struct device *dev, int fan, int old_div)
 {
 	struct i2c_client *client = to_i2c_client(dev);
 	struct adm1026_data *data = i2c_get_clientdata(client);

Andrew Morton | 1 Dec 2004 01:33

Re: VFS interactions with UML and other big UML changes (was: Re: [patch 1/2] Uml - first part rework of run_helper() and users.)

Blaisorblade <blaisorblade_spam <at> yahoo.it> wrote:
>
> static struct address_space_operations hostfs_aops = {
>         .writepage      = hostfs_writepage,
>         .readpage       = hostfs_readpage,
> /*      .set_page_dirty = __set_page_dirty_nobuffers, */
>         .prepare_write  = hostfs_prepare_write,
>         .commit_write   = hostfs_commit_write
> };
> 
> Actually, hostfs is a nodev filesystem, but I simply don't know if that 
> implies that it uses no buffers. So, should
> 
>  .set_page_dirty = __set_page_dirty_nobuffers
> 
> be uncommented? Or should it be deleted (leaving it there is not a good 
> option).

See the operation of set_page_dirty().

If you have NULL ->set_page_dirty a_op then set_page_dirty() will fall
through to __set_page_dirty_buffers().

If your fs never sets PG_private then __set_page_dirty_buffers() will just
do what __set_page_dirty_nobuffers() does.

Without having looked at it, I'm sure that hostfs does not use
buffer_heads.  So setting your ->set_page_dirty a_op to point at
__set_page_dirty_nobuffers() is a reasonable thing to do - it'll provide a
slight speedup.
(Continue reading)

Greg KH | 1 Dec 2004 01:10
Gravatar

Re: [PATCH] More PCI fixes for 2.6.10-rc2

ChangeSet 1.2223.2.5, 2004/11/30 11:54:13-08:00, greg <at> kroah.com

PCI: fix build warning in pci-sysfs.c

Signed-off-by: Andrew Morton <akpm <at> osdl.org>
Signed-off-by: Greg Kroah-Hartman <greg <at> kroah.com>

 drivers/pci/pci-sysfs.c |    3 +--
 1 files changed, 1 insertion(+), 2 deletions(-)

diff -Nru a/drivers/pci/pci-sysfs.c b/drivers/pci/pci-sysfs.c
--- a/drivers/pci/pci-sysfs.c	2004-11-30 15:47:05 -08:00
+++ b/drivers/pci/pci-sysfs.c	2004-11-30 15:47:05 -08:00
 <at>  <at>  -45,8 +45,7  <at>  <at> 

 static ssize_t local_cpus_show(struct device *dev, char *buf)
 {		
-	struct pci_dev *pdev = to_pci_dev(dev);
-	cpumask_t mask = pcibus_to_cpumask(pdev->bus->number);
+	cpumask_t mask = pcibus_to_cpumask(to_pci_dev(dev)->bus->number);
 	int len = cpumask_scnprintf(buf, PAGE_SIZE-2, mask);
 	strcat(buf,"\n"); 
 	return 1+len;


Gmane