drivers/s390/net/ctcmain.c: fix build bug

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=799b37b5ee6b4c197f38611eb7f02552e4f14e70
Commit: 799b37b5ee6b4c197f38611eb7f02552e4f14e70
Parent: 09b56adc98e0f8a21644fcb4d20ad367c3fceb55
Author: Ingo Molnar [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 11:32:38 2007 +0100
Committer:  Linus Torvalds [EMAIL PROTECTED]
CommitDate: Tue Dec 4 09:22:41 2007 -0800

drivers/s390/net/ctcmain.c: fix build bug

SET_MODULE_OWNER() is obsolete.

Signed-off-by: Ingo Molnar [EMAIL PROTECTED]
Signed-off-by: Linus Torvalds [EMAIL PROTECTED]
---
 drivers/s390/net/ctcmain.c |1 -
 1 files changed, 0 insertions(+), 1 deletions(-)

diff --git a/drivers/s390/net/ctcmain.c b/drivers/s390/net/ctcmain.c
index b3b6f65..97adc70 100644
--- a/drivers/s390/net/ctcmain.c
+++ b/drivers/s390/net/ctcmain.c
@@ -2802,7 +2802,6 @@ void ctc_init_netdevice(struct net_device * dev)
dev-type = ARPHRD_SLIP;
dev-tx_queue_len = 100;
dev-flags = IFF_POINTOPOINT | IFF_NOARP;
-   SET_MODULE_OWNER(dev);
 }
 
 
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


MAINTAINERS: remove the MTRR entry

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=220821028cd764c24e60485251c4d0bc1732bdfa
Commit: 220821028cd764c24e60485251c4d0bc1732bdfa
Parent: 799b37b5ee6b4c197f38611eb7f02552e4f14e70
Author: Adrian Bunk [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 14:35:00 2007 +0100
Committer:  Linus Torvalds [EMAIL PROTECTED]
CommitDate: Tue Dec 4 09:28:10 2007 -0800

MAINTAINERS: remove the MTRR entry

I haven't seen Richard doing MTRR related work for quite some time, and
the X86 ARCHITECTURE entry in MAINTAINERS already covers the people
currently responsible for this code.

Signed-off-by: Adrian Bunk [EMAIL PROTECTED]
Signed-off-by: Ingo Molnar [EMAIL PROTECTED]
Signed-off-by: Thomas Gleixner [EMAIL PROTECTED]
Signed-off-by: Linus Torvalds [EMAIL PROTECTED]
---
 MAINTAINERS |7 ---
 1 files changed, 0 insertions(+), 7 deletions(-)

diff --git a/MAINTAINERS b/MAINTAINERS
index 2bbe40e..3002cc8 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -2598,13 +2598,6 @@ L:   
https://tango.0pointer.de/mailman/listinfo/s270-linux
 W: http://0pointer.de/lennart/tchibo.html
 S: Maintained
 
-MTRR AND SIMILAR SUPPORT [i386]
-P: Richard Gooch
-M: [EMAIL PROTECTED]
-L: [EMAIL PROTECTED]
-W: http://www.atnf.csiro.au/~rgooch/linux/kernel-patches.html
-S: Maintained
-
 MULTIMEDIA CARD (MMC), SECURE DIGITAL (SD) AND SDIO SUBSYSTEM
 P: Pierre Ossman
 M: [EMAIL PROTECTED]
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


sched: fix crash in sys_sched_rr_get_interval()

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=77034937dc4575ca0a76bf209838ecd39e804089
Commit: 77034937dc4575ca0a76bf209838ecd39e804089
Parent: 09b56adc98e0f8a21644fcb4d20ad367c3fceb55
Author: Ingo Molnar [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 17:04:39 2007 +0100
Committer:  Ingo Molnar [EMAIL PROTECTED]
CommitDate: Tue Dec 4 17:04:39 2007 +0100

sched: fix crash in sys_sched_rr_get_interval()

Luiz Fernando N. Capitulino reported that sched_rr_get_interval()
crashes for SCHED_OTHER tasks that are on an idle runqueue.

The fix is to return a 0 timeslice for tasks that are on an idle
runqueue. (and which are not running, obviously)

this also shrinks the code a bit:

   textdata bss dec hex filename
  479033934 336   52173cbcd sched.o.before
  478853934 336   52155cbbb sched.o.after

Reported-by: Luiz Fernando N. Capitulino [EMAIL PROTECTED]
Signed-off-by: Ingo Molnar [EMAIL PROTECTED]
---
 kernel/sched.c |   14 +-
 1 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/kernel/sched.c b/kernel/sched.c
index 59ff6b1..b062856 100644
--- a/kernel/sched.c
+++ b/kernel/sched.c
@@ -4850,17 +4850,21 @@ long sys_sched_rr_get_interval(pid_t pid, struct 
timespec __user *interval)
if (retval)
goto out_unlock;
 
-   if (p-policy == SCHED_FIFO)
-   time_slice = 0;
-   else if (p-policy == SCHED_RR)
+   /*
+* Time slice is 0 for SCHED_FIFO tasks and for SCHED_OTHER
+* tasks that are on an otherwise idle runqueue:
+*/
+   time_slice = 0;
+   if (p-policy == SCHED_RR) {
time_slice = DEF_TIMESLICE;
-   else {
+   } else {
struct sched_entity *se = p-se;
unsigned long flags;
struct rq *rq;
 
rq = task_rq_lock(p, flags);
-   time_slice = NS_TO_JIFFIES(sched_slice(cfs_rq_of(se), se));
+   if (rq-cfs.load.weight)
+   time_slice = NS_TO_JIFFIES(sched_slice(rq-cfs, se));
task_rq_unlock(rq, flags);
}
read_unlock(tasklist_lock);
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


sched: default to more agressive yield for SCHED_BATCH tasks

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=db292ca302e83534f5f0f7139e13d7e6976e51f9
Commit: db292ca302e83534f5f0f7139e13d7e6976e51f9
Parent: 77034937dc4575ca0a76bf209838ecd39e804089
Author: Ingo Molnar [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 17:04:39 2007 +0100
Committer:  Ingo Molnar [EMAIL PROTECTED]
CommitDate: Tue Dec 4 17:04:39 2007 +0100

sched: default to more agressive yield for SCHED_BATCH tasks

do more agressive yield for SCHED_BATCH tuned tasks: they are all
about throughput anyway. This allows a gentler migration path for
any apps that relied on stronger yield.

Signed-off-by: Ingo Molnar [EMAIL PROTECTED]
---
 kernel/sched_fair.c |7 ---
 1 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/kernel/sched_fair.c b/kernel/sched_fair.c
index 37bb265..c33f0ce 100644
--- a/kernel/sched_fair.c
+++ b/kernel/sched_fair.c
@@ -799,8 +799,9 @@ static void dequeue_task_fair(struct rq *rq, struct 
task_struct *p, int sleep)
  */
 static void yield_task_fair(struct rq *rq)
 {
-   struct cfs_rq *cfs_rq = task_cfs_rq(rq-curr);
-   struct sched_entity *rightmost, *se = rq-curr-se;
+   struct task_struct *curr = rq-curr;
+   struct cfs_rq *cfs_rq = task_cfs_rq(curr);
+   struct sched_entity *rightmost, *se = curr-se;
 
/*
 * Are we the only task in the tree?
@@ -808,7 +809,7 @@ static void yield_task_fair(struct rq *rq)
if (unlikely(cfs_rq-nr_running == 1))
return;
 
-   if (likely(!sysctl_sched_compat_yield)) {
+   if (likely(!sysctl_sched_compat_yield)  curr-policy != SCHED_BATCH) {
__update_rq_clock(rq);
/*
 * Update run-time statistics of the 'current'.
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


x86: revert CONFIG_X86_HT semantics change

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=ee0011a798ba0e9134506830c58323f2bfcd2443
Commit: ee0011a798ba0e9134506830c58323f2bfcd2443
Parent: 09b56adc98e0f8a21644fcb4d20ad367c3fceb55
Author: Adrian Bunk [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 17:19:07 2007 +0100
Committer:  Ingo Molnar [EMAIL PROTECTED]
CommitDate: Tue Dec 4 17:19:07 2007 +0100

x86: revert CONFIG_X86_HT semantics change

The recent Kconfig changes in x86 resulted in CONFIG_X86_HT no longer
being set if (X86_32  MK8).

After grep'ing through the tree I think the problem is that different
places have different assumptions about the semantics of CONFIG_X86_HT,
either:

- hyperthreading or
- multicore

This should be sorted out properly, but until then we should keep the
2.6.23 status quo.

Signed-off-by: Adrian Bunk [EMAIL PROTECTED]
Signed-off-by: Ingo Molnar [EMAIL PROTECTED]
Signed-off-by: Thomas Gleixner [EMAIL PROTECTED]
---
 arch/x86/Kconfig |3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index 368864d..391cb18 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -148,7 +148,8 @@ config X86_SMP
 
 config X86_HT
bool
-   depends on SMP  !(X86_VISWS || X86_VOYAGER || MK8)
+   depends on SMP
+   depends on (X86_32  !(X86_VISWS || X86_VOYAGER)) || (X86_64  !MK8)
default y
 
 config X86_BIOS_REBOOT
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


x86: add the word 'WARNING' in check_nmi_watchdog() output

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=75bc122c2dc4d497909248e85d86139e54c8fd13
Commit: 75bc122c2dc4d497909248e85d86139e54c8fd13
Parent: ee0011a798ba0e9134506830c58323f2bfcd2443
Author: Don Zickus [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 17:19:07 2007 +0100
Committer:  Ingo Molnar [EMAIL PROTECTED]
CommitDate: Tue Dec 4 17:19:07 2007 +0100

x86: add the word 'WARNING' in check_nmi_watchdog() output

Our automated test suite looks for keywords like error, fail, warning in
the boot log.  In the case when the nmi watchdog is determined to be
stuck in check_nmi_watchdog(), none of those keywords are displayed.

This patch adds a keyword, WARNING:, so it makes it easier to notice
when the nmi watchdog isn't working correctly. Also add a proper
KERN_WARNING mark to this printout.

Signed-off-by: Don Zickus [EMAIL PROTECTED]
Signed-off-by: Ingo Molnar [EMAIL PROTECTED]
Signed-off-by: Thomas Gleixner [EMAIL PROTECTED]
---
 arch/x86/kernel/nmi_32.c |3 ++-
 arch/x86/kernel/nmi_64.c |3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/arch/x86/kernel/nmi_32.c b/arch/x86/kernel/nmi_32.c
index f5cc47c..80ca72e 100644
--- a/arch/x86/kernel/nmi_32.c
+++ b/arch/x86/kernel/nmi_32.c
@@ -106,7 +106,8 @@ static int __init check_nmi_watchdog(void)
if (!per_cpu(wd_enabled, cpu))
continue;
if (nmi_count(cpu) - prev_nmi_count[cpu] = 5) {
-   printk(CPU#%d: NMI appears to be stuck (%d-%d)!\n,
+   printk(KERN_WARNING WARNING: CPU#%d: NMI 
+   appears to be stuck (%d-%d)!\n,
cpu,
prev_nmi_count[cpu],
nmi_count(cpu));
diff --git a/arch/x86/kernel/nmi_64.c b/arch/x86/kernel/nmi_64.c
index a576fd7..4253c4e 100644
--- a/arch/x86/kernel/nmi_64.c
+++ b/arch/x86/kernel/nmi_64.c
@@ -109,7 +109,8 @@ int __init check_nmi_watchdog (void)
if (!per_cpu(wd_enabled, cpu))
continue;
if (cpu_pda(cpu)-__nmi_count - counts[cpu] = 5) {
-   printk(CPU#%d: NMI appears to be stuck (%d-%d)!\n,
+   printk(KERN_WARNING WARNING: CPU#%d: NMI 
+  appears to be stuck (%d-%d)!\n,
   cpu,
   counts[cpu],
   cpu_pda(cpu)-__nmi_count);
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


x86: free_cache_attributes() section fix

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=f22d9bc1e87270586610216084b00cb2fb09abba
Commit: f22d9bc1e87270586610216084b00cb2fb09abba
Parent: 75bc122c2dc4d497909248e85d86139e54c8fd13
Author: Adrian Bunk [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 17:19:07 2007 +0100
Committer:  Ingo Molnar [EMAIL PROTECTED]
CommitDate: Tue Dec 4 17:19:07 2007 +0100

x86: free_cache_attributes() section fix

free_cache_attributes() must be __cpuinit since it calls the
__cpuinit cache_remove_shared_cpu_map().

This patch fixes the following section mismatch reported by
Chris Clayton:

 ...
 WARNING: vmlinux.o(.text+0x90b6): Section mismatch: reference to 
.init.text:cache_remove_shared_cpu_map (between 'free_cache_attributes' and 
'show_level')
 ...

Signed-off-by: Adrian Bunk [EMAIL PROTECTED]
Signed-off-by: Ingo Molnar [EMAIL PROTECTED]
Signed-off-by: Thomas Gleixner [EMAIL PROTECTED]
---
 arch/x86/kernel/cpu/intel_cacheinfo.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/arch/x86/kernel/cpu/intel_cacheinfo.c 
b/arch/x86/kernel/cpu/intel_cacheinfo.c
index 9921b01..606fe4d 100644
--- a/arch/x86/kernel/cpu/intel_cacheinfo.c
+++ b/arch/x86/kernel/cpu/intel_cacheinfo.c
@@ -497,7 +497,7 @@ static void __cpuinit cache_shared_cpu_map_setup(unsigned 
int cpu, int index) {}
 static void __cpuinit cache_remove_shared_cpu_map(unsigned int cpu, int index) 
{}
 #endif
 
-static void free_cache_attributes(unsigned int cpu)
+static void __cpuinit free_cache_attributes(unsigned int cpu)
 {
int i;
 
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[S390] cio: Issue SenseID per path.

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=c94dec99f9759c41cadf0f2781846da5b40a98f6
Commit: c94dec99f9759c41cadf0f2781846da5b40a98f6
Parent: 09b56adc98e0f8a21644fcb4d20ad367c3fceb55
Author: Cornelia Huck [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 16:09:01 2007 +0100
Committer:  Martin Schwidefsky [EMAIL PROTECTED]
CommitDate: Tue Dec 4 16:09:57 2007 +0100

[S390] cio: Issue SenseID per path.

We may receive a unit check for every path when we issue a SenseID.
Unfortunately, the channel subsystem will try on a different path
every time if we use a lpm of 0xff, which will exhaust our retry
counter.

Therefore, revert SenseID to its previous per-path behaviour and
just leave out the suspend multipath reconnect.

Signed-off-by: Cornelia Huck [EMAIL PROTECTED]
Signed-off-by: Martin Schwidefsky [EMAIL PROTECTED]
---
 drivers/s390/cio/device_id.c |   37 -
 1 files changed, 28 insertions(+), 9 deletions(-)

diff --git a/drivers/s390/cio/device_id.c b/drivers/s390/cio/device_id.c
index 2f6bf46..156f3f9 100644
--- a/drivers/s390/cio/device_id.c
+++ b/drivers/s390/cio/device_id.c
@@ -113,6 +113,7 @@ __ccw_device_sense_id_start(struct ccw_device *cdev)
 {
struct subchannel *sch;
struct ccw1 *ccw;
+   int ret;
 
sch = to_subchannel(cdev-dev.parent);
/* Setup sense channel program. */
@@ -124,9 +125,25 @@ __ccw_device_sense_id_start(struct ccw_device *cdev)
 
/* Reset device status. */
memset(cdev-private-irb, 0, sizeof(struct irb));
-   cdev-private-flags.intretry = 0;
 
-   return cio_start(sch, ccw, LPM_ANYPATH);
+   /* Try on every path. */
+   ret = -ENODEV;
+   while (cdev-private-imask != 0) {
+   if ((sch-opm  cdev-private-imask) != 0 
+   cdev-private-iretry  0) {
+   cdev-private-iretry--;
+   /* Reset internal retry indication. */
+   cdev-private-flags.intretry = 0;
+   ret = cio_start (sch, cdev-private-iccws,
+cdev-private-imask);
+   /* ret is 0, -EBUSY, -EACCES or -ENODEV */
+   if (ret != -EACCES)
+   return ret;
+   }
+   cdev-private-imask = 1;
+   cdev-private-iretry = 5;
+   }
+   return ret;
 }
 
 void
@@ -136,7 +153,8 @@ ccw_device_sense_id_start(struct ccw_device *cdev)
 
memset (cdev-private-senseid, 0, sizeof (struct senseid));
cdev-private-senseid.cu_type = 0x;
-   cdev-private-iretry = 3;
+   cdev-private-imask = 0x80;
+   cdev-private-iretry = 5;
ret = __ccw_device_sense_id_start(cdev);
if (ret  ret != -EBUSY)
ccw_device_sense_id_done(cdev, ret);
@@ -252,13 +270,14 @@ ccw_device_sense_id_irq(struct ccw_device *cdev, enum 
dev_event dev_event)
ccw_device_sense_id_done(cdev, ret);
break;
case -EACCES:   /* channel is not operational. */
+   sch-lpm = ~cdev-private-imask;
+   cdev-private-imask = 1;
+   cdev-private-iretry = 5;
+   /* fall through. */
case -EAGAIN:   /* try again. */
-   cdev-private-iretry--;
-   if (cdev-private-iretry  0) {
-   ret = __ccw_device_sense_id_start(cdev);
-   if (ret == 0 || ret == -EBUSY)
-   break;
-   }
+   ret = __ccw_device_sense_id_start(cdev);
+   if (ret == 0 || ret == -EBUSY)
+   break;
/* fall through. */
default:/* Sense ID failed. Try asking VM. */
if (MACHINE_IS_VM) {
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[S390] cio: add missing reprobe loop end statement

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=671756162cfb0b3ccbb6a0047baa3010885561a2
Commit: 671756162cfb0b3ccbb6a0047baa3010885561a2
Parent: c94dec99f9759c41cadf0f2781846da5b40a98f6
Author: Peter Oberparleiter [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 16:09:02 2007 +0100
Committer:  Martin Schwidefsky [EMAIL PROTECTED]
CommitDate: Tue Dec 4 16:09:57 2007 +0100

[S390] cio: add missing reprobe loop end statement

Add loop end statement to prevent looping over empty subchannel sets.

Signed-off-by: Peter Oberparleiter [EMAIL PROTECTED]
Signed-off-by: Martin Schwidefsky [EMAIL PROTECTED]
---
 drivers/s390/cio/css.c |1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/drivers/s390/cio/css.c b/drivers/s390/cio/css.c
index 6db3108..c3df2cd 100644
--- a/drivers/s390/cio/css.c
+++ b/drivers/s390/cio/css.c
@@ -451,6 +451,7 @@ static int reprobe_subchannel(struct subchannel_id schid, 
void *data)
break;
case -ENXIO:
case -ENOMEM:
+   case -EIO:
/* These should abort looping */
break;
default:
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[S390] dcssblk: prevent early access without own make_request function

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=436d1bc7fe6e78e37fe5f5022ea4d5c133d825eb
Commit: 436d1bc7fe6e78e37fe5f5022ea4d5c133d825eb
Parent: 671756162cfb0b3ccbb6a0047baa3010885561a2
Author: Christian Borntraeger [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 16:09:03 2007 +0100
Committer:  Martin Schwidefsky [EMAIL PROTECTED]
CommitDate: Tue Dec 4 16:09:57 2007 +0100

[S390] dcssblk: prevent early access without own make_request function

When loading a dcss segment with the dcssblk driver, sometimes the
following kind of message appears:

bio too big device dcssblk0 (8  0)
Buffer I/O error on device dcssblk0, logical block 172016
..

The fix is to move the disk registration after setting the
make_request function, to avoid calls into generic_make_request
for dcssblock without having the make_request function set up
properly.

Cc: Gerald Schaefer [EMAIL PROTECTED]
Signed-off-by: Christian Borntraeger [EMAIL PROTECTED]
Signed-off-by: Martin Schwidefsky [EMAIL PROTECTED]
---
 drivers/s390/block/dcssblk.c |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/s390/block/dcssblk.c b/drivers/s390/block/dcssblk.c
index 5e083d1..15a5789 100644
--- a/drivers/s390/block/dcssblk.c
+++ b/drivers/s390/block/dcssblk.c
@@ -472,11 +472,11 @@ dcssblk_add_store(struct device *dev, struct 
device_attribute *attr, const char
if (rc)
goto unregister_dev;
 
-   add_disk(dev_info-gd);
-
blk_queue_make_request(dev_info-dcssblk_queue, dcssblk_make_request);
blk_queue_hardsect_size(dev_info-dcssblk_queue, 4096);
 
+   add_disk(dev_info-gd);
+
switch (dev_info-segment_type) {
case SEG_TYPE_SR:
case SEG_TYPE_ER:
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[S390] Fix compile error on 31bit without preemption

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=ab1809b4ed9a3aaf3b34133a776a94f9fad54cc4
Commit: ab1809b4ed9a3aaf3b34133a776a94f9fad54cc4
Parent: 436d1bc7fe6e78e37fe5f5022ea4d5c133d825eb
Author: Christian Borntraeger [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 16:09:04 2007 +0100
Committer:  Martin Schwidefsky [EMAIL PROTECTED]
CommitDate: Tue Dec 4 16:09:58 2007 +0100

[S390] Fix compile error on 31bit without preemption

Commit b8e7a54cd06b0b0174029ef3a7f5a1415a2c28f2 introduced a compile
error if CONFIG_PREEMPT is not set:

arch/s390/kernel/built-in.o: In function `cleanup_io_leave_insn':
/space/kvm/arch/s390/kernel/entry.S:(.text+0xbfce): undefined reference to 
`preempt_schedule_irq'

This patch hides preempt_schedule_irq if CONFIG_PREEMPT is not set.

Signed-off-by: Christian Borntraeger [EMAIL PROTECTED]
Signed-off-by: Martin Schwidefsky [EMAIL PROTECTED]
---
 arch/s390/kernel/entry.S |2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/arch/s390/kernel/entry.S b/arch/s390/kernel/entry.S
index b2b2edc..1a6dac8 100644
--- a/arch/s390/kernel/entry.S
+++ b/arch/s390/kernel/entry.S
@@ -1079,8 +1079,10 @@ cleanup_io_leave_insn:
 .Lexecve_tail: .long   execve_tail
 .Ljump_table:  .long   pgm_check_table
 .Lschedule:.long   schedule
+#ifdef CONFIG_PREEMPT
 .Lpreempt_schedule_irq:
.long   preempt_schedule_irq
+#endif
 .Ltrace:   .long   syscall_trace
 .Lschedtail:   .long   schedule_tail
 .Lsysc_table:  .long   sys_call_table
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[S390] Make sure the restore psw masks are initialized.

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=7af0d6f753f5adf773f99470666b50490d3379f1
Commit: 7af0d6f753f5adf773f99470666b50490d3379f1
Parent: ab1809b4ed9a3aaf3b34133a776a94f9fad54cc4
Author: Heiko Carstens [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 16:09:05 2007 +0100
Committer:  Martin Schwidefsky [EMAIL PROTECTED]
CommitDate: Tue Dec 4 16:09:58 2007 +0100

[S390] Make sure the restore psw masks are initialized.

In case of TRACE_IRQFLAGS the restore psw masks will not be
initialized if noexec is turned on. This will lead to an
immediate system crash.

Signed-off-by: Heiko Carstens [EMAIL PROTECTED]
Signed-off-by: Martin Schwidefsky [EMAIL PROTECTED]
---
 arch/s390/kernel/setup.c |4 +---
 1 files changed, 1 insertions(+), 3 deletions(-)

diff --git a/arch/s390/kernel/setup.c b/arch/s390/kernel/setup.c
index 50f8f1e..577aa7d 100644
--- a/arch/s390/kernel/setup.c
+++ b/arch/s390/kernel/setup.c
@@ -486,9 +486,7 @@ static void setup_addressing_mode(void)
if (s390_noexec) {
printk(S390 execute protection active, );
set_amode_and_uaccess(PSW_ASC_SECONDARY, PSW32_ASC_SECONDARY);
-   return;
-   }
-   if (switch_amode) {
+   } else if (switch_amode) {
printk(S390 address spaces switched, );
set_amode_and_uaccess(PSW_ASC_PRIMARY, PSW32_ASC_PRIMARY);
}
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


sata_mv: Warn about HPT RocketRAID BIOS treatment of Legacy drives

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=306b30f74d37f289033c696285e07ce0158a5d7b
Commit: 306b30f74d37f289033c696285e07ce0158a5d7b
Parent: 3f3debdbfb7713aa06c4370bab6bef277dfd7a37
Author: Mark Lord [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 14:07:52 2007 -0500
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 14:07:52 2007 -0500

sata_mv:  Warn about HPT RocketRAID BIOS treatment of Legacy drives

The Highpoint RocketRAID boards using Marvell 7042 chips
overwrite the 9th sector of attached drives at boot time,
when those drives are configured as Legacy (the default)
in the HighPoint BIOS.

This kills GRUB, and probably other stuff.
But it all happens *before* Linux is even loaded.

So, for now we'll log a WARNING when such boards are detected,
and advise users to configure BIOS JBOD volumes instead,
which don't appear to suffer from this problem.

Signed-off-by: Mark Lord [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 drivers/ata/sata_mv.c |9 +
 1 files changed, 9 insertions(+), 0 deletions(-)

diff --git a/drivers/ata/sata_mv.c b/drivers/ata/sata_mv.c
index 8d864e5..fe0105d 100644
--- a/drivers/ata/sata_mv.c
+++ b/drivers/ata/sata_mv.c
@@ -2503,6 +2503,15 @@ static int mv_chip_id(struct ata_host *host, unsigned 
int board_idx)
 
case chip_7042:
hp_flags |= MV_HP_PCIE;
+   if (pdev-vendor == PCI_VENDOR_ID_TTI 
+   (pdev-device == 0x2300 || pdev-device == 0x2310))
+   {
+   printk(KERN_WARNING sata_mv: Highpoint RocketRAID BIOS
+will CORRUPT DATA on attached drives when
+configured as \Legacy\.  BEWARE!\n);
+   printk(KERN_WARNING sata_mv: Use BIOS \JBOD\ volumes
+instead for safety.\n);
+   }
case chip_6042:
hpriv-ops = mv6xxx_ops;
hp_flags |= MV_HP_GEN_IIE;
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


sata_nv: don't use legacy DMA in ADMA mode (v3)

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=3f3debdbfb7713aa06c4370bab6bef277dfd7a37
Commit: 3f3debdbfb7713aa06c4370bab6bef277dfd7a37
Parent: 2254c2e0184c603f92fc9b81016ff4bb53da622d
Author: Robert Hancock [EMAIL PROTECTED]
AuthorDate: Sun Nov 25 16:59:36 2007 -0600
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 14:01:18 2007 -0500

sata_nv: don't use legacy DMA in ADMA mode (v3)

We need to run any DMA command with result taskfile requested in ADMA mode
when the port is in ADMA mode, otherwise it may try to use the legacy DMA 
engine
in ADMA mode which is not allowed. Enforce this with BUG_ON() since data
corruption could potentially result if this happened. Also, fail any 
attempt to
try and issue NCQ commands with result taskfile requested, since the 
hardware
doesn't allow this.

Signed-off-by: Robert Hancock [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 drivers/ata/sata_nv.c |   32 +++-
 1 files changed, 23 insertions(+), 9 deletions(-)

diff --git a/drivers/ata/sata_nv.c b/drivers/ata/sata_nv.c
index 44f9e5d..ed5dc7c 100644
--- a/drivers/ata/sata_nv.c
+++ b/drivers/ata/sata_nv.c
@@ -791,11 +791,13 @@ static int nv_adma_check_atapi_dma(struct ata_queued_cmd 
*qc)
 
 static void nv_adma_tf_read(struct ata_port *ap, struct ata_taskfile *tf)
 {
-   /* Since commands where a result TF is requested are not
-  executed in ADMA mode, the only time this function will be called
-  in ADMA mode will be if a command fails. In this case we
-  don't care about going into register mode with ADMA commands
-  pending, as the commands will all shortly be aborted anyway. */
+   /* Other than when internal or pass-through commands are executed,
+  the only time this function will be called in ADMA mode will be
+  if a command fails. In the failure case we don't care about going
+  into register mode with ADMA commands pending, as the commands will
+  all shortly be aborted anyway. We assume that NCQ commands are not
+  issued via passthrough, which is the only way that switching into
+  ADMA mode could abort outstanding commands. */
nv_adma_register_mode(ap);
 
ata_tf_read(ap, tf);
@@ -1359,11 +1361,9 @@ static int nv_adma_use_reg_mode(struct ata_queued_cmd 
*qc)
struct nv_adma_port_priv *pp = qc-ap-private_data;
 
/* ADMA engine can only be used for non-ATAPI DMA commands,
-  or interrupt-driven no-data commands, where a result taskfile
-  is not required. */
+  or interrupt-driven no-data commands. */
if ((pp-flags  NV_ADMA_ATAPI_SETUP_COMPLETE) ||
-  (qc-tf.flags  ATA_TFLAG_POLLING) ||
-  (qc-flags  ATA_QCFLAG_RESULT_TF))
+  (qc-tf.flags  ATA_TFLAG_POLLING))
return 1;
 
if ((qc-flags  ATA_QCFLAG_DMAMAP) ||
@@ -1381,6 +1381,8 @@ static void nv_adma_qc_prep(struct ata_queued_cmd *qc)
   NV_CPB_CTL_IEN;
 
if (nv_adma_use_reg_mode(qc)) {
+   BUG_ON(!(pp-flags  NV_ADMA_ATAPI_SETUP_COMPLETE) 
+   (qc-flags  ATA_QCFLAG_DMAMAP));
nv_adma_register_mode(qc-ap);
ata_qc_prep(qc);
return;
@@ -1425,9 +1427,21 @@ static unsigned int nv_adma_qc_issue(struct 
ata_queued_cmd *qc)
 
VPRINTK(ENTER\n);
 
+   /* We can't handle result taskfile with NCQ commands, since
+  retrieving the taskfile switches us out of ADMA mode and would abort
+  existing commands. */
+   if (unlikely(qc-tf.protocol == ATA_PROT_NCQ 
+(qc-flags  ATA_QCFLAG_RESULT_TF))) {
+   ata_dev_printk(qc-dev, KERN_ERR,
+   NCQ w/ RESULT_TF not allowed\n);
+   return AC_ERR_SYSTEM;
+   }
+
if (nv_adma_use_reg_mode(qc)) {
/* use ATA register mode */
VPRINTK(using ATA register mode: 0x%lx\n, qc-flags);
+   BUG_ON(!(pp-flags  NV_ADMA_ATAPI_SETUP_COMPLETE) 
+   (qc-flags  ATA_QCFLAG_DMAMAP));
nv_adma_register_mode(qc-ap);
return ata_qc_issue_prot(qc);
} else
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


ahci: add the Device IDs of MCP79 AHCI controller to ahci.c

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=6ba8695870a5a2ebf6f3d1ee3ac1e4d96d667cf6
Commit: 6ba8695870a5a2ebf6f3d1ee3ac1e4d96d667cf6
Parent: 306b30f74d37f289033c696285e07ce0158a5d7b
Author: peerchen [EMAIL PROTECTED]
AuthorDate: Mon Dec 3 22:20:37 2007 +0800
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 14:10:14 2007 -0500

ahci: add the Device IDs of MCP79 AHCI controller to ahci.c

Add the device IDs of legacy mode of MCP79 AHCI controller to ahci.c

Signed-off-by: Peer Chen [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 drivers/ata/ahci.c |4 
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/drivers/ata/ahci.c b/drivers/ata/ahci.c
index ed9b407..4688dbf 100644
--- a/drivers/ata/ahci.c
+++ b/drivers/ata/ahci.c
@@ -536,6 +536,10 @@ static const struct pci_device_id ahci_pci_tbl[] = {
{ PCI_VDEVICE(NVIDIA, 0x0ad9), board_ahci },/* MCP77 */
{ PCI_VDEVICE(NVIDIA, 0x0ada), board_ahci },/* MCP77 */
{ PCI_VDEVICE(NVIDIA, 0x0adb), board_ahci },/* MCP77 */
+   { PCI_VDEVICE(NVIDIA, 0x0ab4), board_ahci },/* MCP79 */
+   { PCI_VDEVICE(NVIDIA, 0x0ab5), board_ahci },/* MCP79 */
+   { PCI_VDEVICE(NVIDIA, 0x0ab6), board_ahci },/* MCP79 */
+   { PCI_VDEVICE(NVIDIA, 0x0ab7), board_ahci },/* MCP79 */
{ PCI_VDEVICE(NVIDIA, 0x0ab8), board_ahci },/* MCP79 */
{ PCI_VDEVICE(NVIDIA, 0x0ab9), board_ahci },/* MCP79 */
{ PCI_VDEVICE(NVIDIA, 0x0aba), board_ahci },/* MCP79 */
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


pata_amd/pata_via: de-couple programming of PIO/MWDMA and UDMA timings

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=943547abdfe9b4e27e36a25987909619908dffbf
Commit: 943547abdfe9b4e27e36a25987909619908dffbf
Parent: 6ba8695870a5a2ebf6f3d1ee3ac1e4d96d667cf6
Author: Bartlomiej Zolnierkiewicz [EMAIL PROTECTED]
AuthorDate: Sun Dec 2 03:47:01 2007 +0100
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 14:11:36 2007 -0500

pata_amd/pata_via: de-couple programming of PIO/MWDMA and UDMA timings

* Don't program UDMA timings when programming PIO or MWDMA modes.

  This has also a nice side-effect of fixing regression added by commit
  681c80b5d96076f447e8101ac4325c82d8dce508 (libata: correct handling of
  SRST reset sequences) (-set_piomode method for PIO0 is called before
  -cable_detect method which checks UDMA timings to get the cable type).

* Bump driver version.

Signed-off-by: Bartlomiej Zolnierkiewicz [EMAIL PROTECTED]
Tested-by: Thomas Lindroth [EMAIL PROTECTED]
Acked-by: Alan Cox [EMAIL PROTECTED]
Cc: Tejun Heo [EMAIL PROTECTED]
Signed-off-by: Andrew Morton [EMAIL PROTECTED]
Signed-off-by: Bartlomiej Zolnierkiewicz [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 drivers/ata/pata_amd.c |5 +++--
 drivers/ata/pata_via.c |4 ++--
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/drivers/ata/pata_amd.c b/drivers/ata/pata_amd.c
index c5779ad..3cc27b5 100644
--- a/drivers/ata/pata_amd.c
+++ b/drivers/ata/pata_amd.c
@@ -25,7 +25,7 @@
 #include linux/libata.h
 
 #define DRV_NAME pata_amd
-#define DRV_VERSION 0.3.9
+#define DRV_VERSION 0.3.10
 
 /**
  * timing_setup-   shared timing computation and load
@@ -115,7 +115,8 @@ static void timing_setup(struct ata_port *ap, struct 
ata_device *adev, int offse
}
 
/* UDMA timing */
-   pci_write_config_byte(pdev, offset + 0x10 + (3 - dn), t);
+   if (at.udma)
+   pci_write_config_byte(pdev, offset + 0x10 + (3 - dn), t);
 }
 
 /**
diff --git a/drivers/ata/pata_via.c b/drivers/ata/pata_via.c
index a4175fb..453d72b 100644
--- a/drivers/ata/pata_via.c
+++ b/drivers/ata/pata_via.c
@@ -63,7 +63,7 @@
 #include linux/dmi.h
 
 #define DRV_NAME pata_via
-#define DRV_VERSION 0.3.2
+#define DRV_VERSION 0.3.3
 
 /*
  * The following comes directly from Vojtech Pavlik's ide/pci/via82cxxx
@@ -296,7 +296,7 @@ static void via_do_set_mode(struct ata_port *ap, struct 
ata_device *adev, int mo
}
 
/* Set UDMA unless device is not UDMA capable */
-   if (udma_type) {
+   if (udma_type  t.udma) {
u8 cable80_status;
 
/* Get 80-wire cable detection bit */
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


cxgb - revert file mode changes.

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=4c14fe91d0209897fda4dea0102c8cd2e1ddd860
Commit: 4c14fe91d0209897fda4dea0102c8cd2e1ddd860
Parent: 2254c2e0184c603f92fc9b81016ff4bb53da622d
Author: Divy Le Ray [EMAIL PROTECTED]
AuthorDate: Sat Dec 1 15:57:17 2007 -0800
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 14:52:58 2007 -0500

cxgb - revert file mode changes.

revert inavertant file mode changes

Signed-off-by: Divy Le Ray [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 0 files changed, 0 insertions(+), 0 deletions(-)

diff --git a/drivers/net/chelsio/cxgb2.c b/drivers/net/chelsio/cxgb2.c
old mode 100755
new mode 100644
diff --git a/drivers/net/chelsio/pm3393.c b/drivers/net/chelsio/pm3393.c
old mode 100755
new mode 100644
diff --git a/drivers/net/chelsio/sge.c b/drivers/net/chelsio/sge.c
old mode 100755
new mode 100644
diff --git a/drivers/net/chelsio/sge.h b/drivers/net/chelsio/sge.h
old mode 100755
new mode 100644
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Don't claim to do IPv6 checksum offload

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=0581d3f53053de597ef4956568c15785e59828ef
Commit: 0581d3f53053de597ef4956568c15785e59828ef
Parent: 4c14fe91d0209897fda4dea0102c8cd2e1ddd860
Author: David Woodhouse [EMAIL PROTECTED]
AuthorDate: Mon Dec 3 04:34:32 2007 +
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 14:53:07 2007 -0500

Don't claim to do IPv6 checksum offload

Signed-off-by: David Woodhouse [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 drivers/net/pasemi_mac.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/pasemi_mac.c b/drivers/net/pasemi_mac.c
index 09b4fde..a8db5d7 100644
--- a/drivers/net/pasemi_mac.c
+++ b/drivers/net/pasemi_mac.c
@@ -1362,7 +1362,7 @@ pasemi_mac_probe(struct pci_dev *pdev, const struct 
pci_device_id *ent)
 
netif_napi_add(dev, mac-napi, pasemi_mac_poll, 64);
 
-   dev-features = NETIF_F_HW_CSUM | NETIF_F_LLTX | NETIF_F_SG;
+   dev-features = NETIF_F_IP_CSUM | NETIF_F_LLTX | NETIF_F_SG;
 
/* These should come out of the device tree eventually */
mac-dma_txch = index;
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


Fix memory corruption in fec_mpc52xx

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=4c537e6371a9510c82eb96fb7e1e66017e0e2053
Commit: 4c537e6371a9510c82eb96fb7e1e66017e0e2053
Parent: 0581d3f53053de597ef4956568c15785e59828ef
Author: Jon Smirl [EMAIL PROTECTED]
AuthorDate: Mon Dec 3 22:38:10 2007 +
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 14:53:14 2007 -0500

Fix memory corruption in fec_mpc52xx

The mpc5200 fec driver is corrupting memory. This patch fixes two bugs
where the wrong skb was being referenced.

Signed-off-by: Jon Smirl [EMAIL PROTECTED]
Acked-by: Domen Puncer [EMAIL PROTECTED]
Signed-off-by: Grant Likely [EMAIL PROTECTED]
Signed-off-by: David Woodhouse [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 drivers/net/fec_mpc52xx.c |4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/net/fec_mpc52xx.c b/drivers/net/fec_mpc52xx.c
index bf5a7ca..79f7ead 100644
--- a/drivers/net/fec_mpc52xx.c
+++ b/drivers/net/fec_mpc52xx.c
@@ -422,7 +422,7 @@ static irqreturn_t mpc52xx_fec_rx_interrupt(int irq, void 
*dev_id)
 
rskb = bcom_retrieve_buffer(priv-rx_dmatsk, status,
(struct bcom_bd **)bd);
-   dma_unmap_single(dev-dev, bd-skb_pa, skb-len, 
DMA_FROM_DEVICE);
+   dma_unmap_single(dev-dev, bd-skb_pa, rskb-len, 
DMA_FROM_DEVICE);
 
/* Test for errors in received frame */
if (status  BCOM_FEC_RX_BD_ERRORS) {
@@ -467,7 +467,7 @@ static irqreturn_t mpc52xx_fec_rx_interrupt(int irq, void 
*dev_id)
bcom_prepare_next_buffer(priv-rx_dmatsk);
 
bd-status = FEC_RX_BUFFER_SIZE;
-   bd-skb_pa = dma_map_single(dev-dev, rskb-data,
+   bd-skb_pa = dma_map_single(dev-dev, skb-data,
FEC_RX_BUFFER_SIZE, DMA_FROM_DEVICE);
 
bcom_submit_next_buffer(priv-rx_dmatsk, skb);
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


sky2: recovery deadlock fix

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=8cfcbe998aa0459e20bbad61376f81c1715b25d6
Commit: 8cfcbe998aa0459e20bbad61376f81c1715b25d6
Parent: 4c537e6371a9510c82eb96fb7e1e66017e0e2053
Author: Stephen Hemminger [EMAIL PROTECTED]
AuthorDate: Mon Dec 3 17:02:17 2007 -0800
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 14:53:22 2007 -0500

sky2: recovery deadlock fix

Prevent deadlock in sky2 recovery logic. sky2_down calls napi_synchronize
which gets stuck if napi was already disabled.

Fix by rearranging slightly and not calling napi_disable until after
both ports are stopped. The napi_disable probably is being overly
paranoid, but it is safe now.

Signed-off-by: Stephen Hemminger [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 drivers/net/sky2.c |6 ++
 1 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/net/sky2.c b/drivers/net/sky2.c
index 3d1dfc9..6197afb 100644
--- a/drivers/net/sky2.c
+++ b/drivers/net/sky2.c
@@ -2906,16 +2906,14 @@ static void sky2_restart(struct work_struct *work)
int i, err;
 
rtnl_lock();
-   sky2_write32(hw, B0_IMSK, 0);
-   sky2_read32(hw, B0_IMSK);
-   napi_disable(hw-napi);
-
for (i = 0; i  hw-ports; i++) {
dev = hw-dev[i];
if (netif_running(dev))
sky2_down(dev);
}
 
+   napi_disable(hw-napi);
+   sky2_write32(hw, B0_IMSK, 0);
sky2_reset(hw);
sky2_write32(hw, B0_IMSK, Y2_IS_BASE);
napi_enable(hw-napi);
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


SMC911X: Fix using of dereferenced skb after netif_rx

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=d30f53aeb31d453a5230f526bea592af07944564
Commit: d30f53aeb31d453a5230f526bea592af07944564
Parent: 8cfcbe998aa0459e20bbad61376f81c1715b25d6
Author: Wang Chen [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 10:01:37 2007 +0800
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 14:53:43 2007 -0500

SMC911X: Fix using of dereferenced skb after netif_rx

Signed-off-by: Wang Chen [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 drivers/net/smc911x.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/smc911x.c b/drivers/net/smc911x.c
index 1a3d80b..76cc1d3 100644
--- a/drivers/net/smc911x.c
+++ b/drivers/net/smc911x.c
@@ -1299,9 +1299,9 @@ smc911x_rx_dma_irq(int dma, void *data)
PRINT_PKT(skb-data, skb-len);
dev-last_rx = jiffies;
skb-protocol = eth_type_trans(skb, dev);
-   netif_rx(skb);
dev-stats.rx_packets++;
dev-stats.rx_bytes += skb-len;
+   netif_rx(skb);
 
spin_lock_irqsave(lp-lock, flags);
pkts = (SMC_GET_RX_FIFO_INF()  RX_FIFO_INF_RXSUSED_)  16;
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


pasemi_mac: Fix reuse of free'd skb

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=4352d82647f679fb8dd9440b34400fa49beedb2c
Commit: 4352d82647f679fb8dd9440b34400fa49beedb2c
Parent: d30f53aeb31d453a5230f526bea592af07944564
Author: Olof Johansson [EMAIL PROTECTED]
AuthorDate: Mon Dec 3 21:34:14 2007 -0600
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 14:53:49 2007 -0500

pasemi_mac: Fix reuse of free'd skb

Turns out we're freeing the skb when we detect CRC error, but we're
not clearing out info-skb. We could either clear it and have the stack
reallocate it, or just leave it and the rx ring refill code will reuse
the one that was allocated.

Reusing a freed skb obviously caused some nasty crashes of various kind,
as reported by Brent Baude and David Woodhouse.

Signed-off-by: Olof Johansson [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 drivers/net/pasemi_mac.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/pasemi_mac.c b/drivers/net/pasemi_mac.c
index a8db5d7..816a59e 100644
--- a/drivers/net/pasemi_mac.c
+++ b/drivers/net/pasemi_mac.c
@@ -586,7 +586,7 @@ static int pasemi_mac_clean_rx(struct pasemi_mac *mac, int 
limit)
/* CRC error flagged */
mac-netdev-stats.rx_errors++;
mac-netdev-stats.rx_crc_errors++;
-   dev_kfree_skb_irq(skb);
+   /* No need to free skb, it'll be reused */
goto next;
}
 
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


gianfar: fix compile warning

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=f9663aea2a938f9dc60dbfef34b9e7847a69c947
Commit: f9663aea2a938f9dc60dbfef34b9e7847a69c947
Parent: 4352d82647f679fb8dd9440b34400fa49beedb2c
Author: Grant Likely [EMAIL PROTECTED]
AuthorDate: Sat Dec 1 22:10:03 2007 -0700
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 15:06:11 2007 -0500

gianfar: fix compile warning

Eliminate an uninitialized variable warning.  The code is correct, but
a pointer to the automatic variable 'addr' is passed to dma_alloc_coherent.
Since addr has never been initialized, and the compiler doesn't know
what dma_alloc_coherent will do with it, it complains.

Signed-off-by: Grant Likely [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 drivers/net/gianfar.c |2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/net/gianfar.c b/drivers/net/gianfar.c
index 38268d7..0431e9e 100644
--- a/drivers/net/gianfar.c
+++ b/drivers/net/gianfar.c
@@ -696,7 +696,7 @@ int startup_gfar(struct net_device *dev)
 {
struct txbd8 *txbdp;
struct rxbd8 *rxbdp;
-   dma_addr_t addr;
+   dma_addr_t addr = 0;
unsigned long vaddr;
int i;
struct gfar_private *priv = netdev_priv(dev);
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html


PHY: Add the phy_device_release device method.

2007-12-04 Thread Linux Kernel Mailing List
Gitweb: 
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=6f4a7f4183bdbd02741dcd8edbd10b8628acc5d5
Commit: 6f4a7f4183bdbd02741dcd8edbd10b8628acc5d5
Parent: f9663aea2a938f9dc60dbfef34b9e7847a69c947
Author: Anton Vorontsov [EMAIL PROTECTED]
AuthorDate: Tue Dec 4 16:17:33 2007 +0300
Committer:  Jeff Garzik [EMAIL PROTECTED]
CommitDate: Tue Dec 4 15:06:33 2007 -0500

PHY: Add the phy_device_release device method.

Lately I've got this nice badness on mdio bus removal:

Device 'e0103120:06' does not have a release() function, it is broken and 
must be fixed.
[ cut here ]
Badness at drivers/base/core.c:107
NIP: c015c1a8 LR: c015c1a8 CTR: c0157488
REGS: c34bdcf0 TRAP: 0700   Not tainted  (2.6.23-rc5-g9ebadfbb-dirty)
MSR: 00029032 EE,ME,IR,DR  CR: 24088422  XER: 
...
[c34bdda0] [c015c1a8] device_release+0x78/0x80 (unreliable)
[c34bddb0] [c01354cc] kobject_cleanup+0x80/0xbc
[c34bddd0] [c01365f0] kref_put+0x54/0x6c
[c34bdde0] [c013543c] kobject_put+0x24/0x34
[c34bddf0] [c015c384] put_device+0x1c/0x2c
[c34bde00] [c0180e84] mdiobus_unregister+0x2c/0x58
...

Though actually there is nothing broken, it just device
subsystem core expects another pattern of resource managment.

This patch implement phy device's release function, thus
we're getting rid of this badness.

Also small hidden bug fixed, hope none other introduced. ;-)

Signed-off-by: Anton Vorontsov [EMAIL PROTECTED]
Acked-by: Andy Fleming [EMAIL PROTECTED]
Signed-off-by: Jeff Garzik [EMAIL PROTECTED]
---
 drivers/net/phy/mdio_bus.c   |9 +
 drivers/net/phy/phy_device.c |   12 
 include/linux/phy.h  |1 +
 3 files changed, 18 insertions(+), 4 deletions(-)

diff --git a/drivers/net/phy/mdio_bus.c b/drivers/net/phy/mdio_bus.c
index fc2f0e6..c30196d 100644
--- a/drivers/net/phy/mdio_bus.c
+++ b/drivers/net/phy/mdio_bus.c
@@ -91,9 +91,12 @@ int mdiobus_register(struct mii_bus *bus)
 
err = device_register(phydev-dev);
 
-   if (err)
+   if (err) {
printk(KERN_ERR phy %d failed to register\n,
i);
+   phy_device_free(phydev);
+   phydev = NULL;
+   }
}
 
bus-phy_map[i] = phydev;
@@ -110,10 +113,8 @@ void mdiobus_unregister(struct mii_bus *bus)
int i;
 
for (i = 0; i  PHY_MAX_ADDR; i++) {
-   if (bus-phy_map[i]) {
+   if (bus-phy_map[i])
device_unregister(bus-phy_map[i]-dev);
-   kfree(bus-phy_map[i]);
-   }
}
 }
 EXPORT_SYMBOL(mdiobus_unregister);
diff --git a/drivers/net/phy/phy_device.c b/drivers/net/phy/phy_device.c
index f6e4848..5b9e175 100644
--- a/drivers/net/phy/phy_device.c
+++ b/drivers/net/phy/phy_device.c
@@ -44,6 +44,16 @@ static struct phy_driver genphy_driver;
 extern int mdio_bus_init(void);
 extern void mdio_bus_exit(void);
 
+void phy_device_free(struct phy_device *phydev)
+{
+   kfree(phydev);
+}
+
+static void phy_device_release(struct device *dev)
+{
+   phy_device_free(to_phy_device(dev));
+}
+
 struct phy_device* phy_device_create(struct mii_bus *bus, int addr, int phy_id)
 {
struct phy_device *dev;
@@ -54,6 +64,8 @@ struct phy_device* phy_device_create(struct mii_bus *bus, int 
addr, int phy_id)
if (NULL == dev)
return (struct phy_device*) PTR_ERR((void*)-ENOMEM);
 
+   dev-dev.release = phy_device_release;
+
dev-speed = 0;
dev-duplex = -1;
dev-pause = dev-asym_pause = 0;
diff --git a/include/linux/phy.h b/include/linux/phy.h
index e10763d..554836e 100644
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
@@ -403,6 +403,7 @@ int phy_mii_ioctl(struct phy_device *phydev,
 int phy_start_interrupts(struct phy_device *phydev);
 void phy_print_status(struct phy_device *phydev);
 struct phy_device* phy_device_create(struct mii_bus *bus, int addr, int 
phy_id);
+void phy_device_free(struct phy_device *phydev);
 
 extern struct bus_type mdio_bus_type;
 #endif /* __PHY_H */
-
To unsubscribe from this list: send the line unsubscribe git-commits-head in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html