Update to upstream release candidate 2.6.35-rc3
Refresh/remove patches as appropriate. Add patches for SD7220 firmware in ip_qib where it moved from ipath. svn path=/dists/trunk/linux-2.6/; revision=15933
This commit is contained in:
parent
39f01da488
commit
0c747108a8
|
@ -1,4 +1,6 @@
|
||||||
linux-2.6 (2.6.34-1~experimental.3) UNRELEASED; urgency=low
|
linux-2.6 (2.6.35~rc3-1~experimental.1) UNRELEASED; urgency=low
|
||||||
|
|
||||||
|
* New upstream snapshot
|
||||||
|
|
||||||
[ Ben Hutchings ]
|
[ Ben Hutchings ]
|
||||||
* ipr: add writeq definition if needed (Closes: #584840)
|
* ipr: add writeq definition if needed (Closes: #584840)
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
[abi]
|
[abi]
|
||||||
abiname: 1
|
abiname: trunk
|
||||||
|
|
||||||
[base]
|
[base]
|
||||||
arches:
|
arches:
|
||||||
|
|
|
@ -1,104 +0,0 @@
|
||||||
From b0cf4dfb7cd21556efd9a6a67edcba0840b4d98d Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Date: Wed, 7 Apr 2010 20:55:47 -0700
|
|
||||||
Subject: [PATCH] 3c503: Fix IRQ probing
|
|
||||||
|
|
||||||
The driver attempts to select an IRQ for the NIC automatically by
|
|
||||||
testing which of the supported IRQs are available and then probing
|
|
||||||
each available IRQ with probe_irq_{on,off}(). There are obvious race
|
|
||||||
conditions here, besides which:
|
|
||||||
1. The test for availability is done by passing a NULL handler, which
|
|
||||||
now always returns -EINVAL, thus the device cannot be opened:
|
|
||||||
<http://bugs.debian.org/566522>
|
|
||||||
2. probe_irq_off() will report only the first ISA IRQ handled,
|
|
||||||
potentially leading to a false negative.
|
|
||||||
|
|
||||||
There was another bug that meant it ignored all error codes from
|
|
||||||
request_irq() except -EBUSY, so it would 'succeed' despite this
|
|
||||||
(possibly causing conflicts with other ISA devices). This was fixed
|
|
||||||
by ab08999d6029bb2c79c16be5405d63d2bedbdfea 'WARNING: some
|
|
||||||
request_irq() failures ignored in el2_open()', which exposed bug 1.
|
|
||||||
|
|
||||||
This patch:
|
|
||||||
1. Replaces the use of probe_irq_{on,off}() with a real interrupt handler
|
|
||||||
2. Adds a delay before checking the interrupt-seen flag
|
|
||||||
3. Disables interrupts on all failure paths
|
|
||||||
4. Distinguishes error codes from the second request_irq() call,
|
|
||||||
consistently with the first
|
|
||||||
|
|
||||||
Compile-tested only.
|
|
||||||
|
|
||||||
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Signed-off-by: David S. Miller <davem@davemloft.net>
|
|
||||||
---
|
|
||||||
drivers/net/3c503.c | 42 ++++++++++++++++++++++++++++++------------
|
|
||||||
1 files changed, 30 insertions(+), 12 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/net/3c503.c b/drivers/net/3c503.c
|
|
||||||
index 66e0323..b74a0ea 100644
|
|
||||||
--- a/drivers/net/3c503.c
|
|
||||||
+++ b/drivers/net/3c503.c
|
|
||||||
@@ -380,6 +380,12 @@ out:
|
|
||||||
return retval;
|
|
||||||
}
|
|
||||||
|
|
||||||
+static irqreturn_t el2_probe_interrupt(int irq, void *seen)
|
|
||||||
+{
|
|
||||||
+ *(bool *)seen = true;
|
|
||||||
+ return IRQ_HANDLED;
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
static int
|
|
||||||
el2_open(struct net_device *dev)
|
|
||||||
{
|
|
||||||
@@ -391,23 +397,35 @@ el2_open(struct net_device *dev)
|
|
||||||
|
|
||||||
outb(EGACFR_NORM, E33G_GACFR); /* Enable RAM and interrupts. */
|
|
||||||
do {
|
|
||||||
- retval = request_irq(*irqp, NULL, 0, "bogus", dev);
|
|
||||||
- if (retval >= 0) {
|
|
||||||
+ bool seen;
|
|
||||||
+
|
|
||||||
+ retval = request_irq(*irqp, el2_probe_interrupt, 0,
|
|
||||||
+ dev->name, &seen);
|
|
||||||
+ if (retval == -EBUSY)
|
|
||||||
+ continue;
|
|
||||||
+ if (retval < 0)
|
|
||||||
+ goto err_disable;
|
|
||||||
+
|
|
||||||
/* Twinkle the interrupt, and check if it's seen. */
|
|
||||||
- unsigned long cookie = probe_irq_on();
|
|
||||||
+ seen = false;
|
|
||||||
+ smp_wmb();
|
|
||||||
outb_p(0x04 << ((*irqp == 9) ? 2 : *irqp), E33G_IDCFR);
|
|
||||||
outb_p(0x00, E33G_IDCFR);
|
|
||||||
- if (*irqp == probe_irq_off(cookie) && /* It's a good IRQ line! */
|
|
||||||
- ((retval = request_irq(dev->irq = *irqp,
|
|
||||||
- eip_interrupt, 0,
|
|
||||||
- dev->name, dev)) == 0))
|
|
||||||
- break;
|
|
||||||
- } else {
|
|
||||||
- if (retval != -EBUSY)
|
|
||||||
- return retval;
|
|
||||||
- }
|
|
||||||
+ msleep(1);
|
|
||||||
+ free_irq(*irqp, el2_probe_interrupt);
|
|
||||||
+ if (!seen)
|
|
||||||
+ continue;
|
|
||||||
+
|
|
||||||
+ retval = request_irq(dev->irq = *irqp, eip_interrupt, 0,
|
|
||||||
+ dev->name, dev);
|
|
||||||
+ if (retval == -EBUSY)
|
|
||||||
+ continue;
|
|
||||||
+ if (retval < 0)
|
|
||||||
+ goto err_disable;
|
|
||||||
} while (*++irqp);
|
|
||||||
+
|
|
||||||
if (*irqp == 0) {
|
|
||||||
+ err_disable:
|
|
||||||
outb(EGACFR_IRQOFF, E33G_GACFR); /* disable interrupts. */
|
|
||||||
return -EAGAIN;
|
|
||||||
}
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,87 +0,0 @@
|
||||||
From 91b792b2fc34cc29fc9f0ba2fd5d7251ff04a8df Mon Sep 17 00:00:00 2001
|
|
||||||
From: Tejun Heo <tj@kernel.org>
|
|
||||||
Date: Sat, 15 May 2010 19:55:32 +0200
|
|
||||||
Subject: [PATCH 6/8] SCSI: implement sd_unlock_native_capacity()
|
|
||||||
|
|
||||||
Implement sd_unlock_native_capacity() method which calls into
|
|
||||||
hostt->unlock_native_capacity() if implemented. This will be invoked
|
|
||||||
by block layer if partitions extend beyond the end of the device and
|
|
||||||
can be used to implement, for example, on-demand ATA host protected
|
|
||||||
area unlocking.
|
|
||||||
|
|
||||||
Signed-off-by: Tejun Heo <tj@kernel.org>
|
|
||||||
Cc: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
---
|
|
||||||
drivers/scsi/sd.c | 22 ++++++++++++++++++++++
|
|
||||||
include/scsi/scsi_host.h | 8 ++++++++
|
|
||||||
2 files changed, 30 insertions(+), 0 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/scsi/sd.c b/drivers/scsi/sd.c
|
|
||||||
index 8b827f3..b85906e 100644
|
|
||||||
--- a/drivers/scsi/sd.c
|
|
||||||
+++ b/drivers/scsi/sd.c
|
|
||||||
@@ -97,6 +97,7 @@ MODULE_ALIAS_SCSI_DEVICE(TYPE_RBC);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
static int sd_revalidate_disk(struct gendisk *);
|
|
||||||
+static void sd_unlock_native_capacity(struct gendisk *disk);
|
|
||||||
static int sd_probe(struct device *);
|
|
||||||
static int sd_remove(struct device *);
|
|
||||||
static void sd_shutdown(struct device *);
|
|
||||||
@@ -1100,6 +1101,7 @@ static const struct block_device_operations sd_fops = {
|
|
||||||
#endif
|
|
||||||
.media_changed = sd_media_changed,
|
|
||||||
.revalidate_disk = sd_revalidate_disk,
|
|
||||||
+ .unlock_native_capacity = sd_unlock_native_capacity,
|
|
||||||
};
|
|
||||||
|
|
||||||
static unsigned int sd_completed_bytes(struct scsi_cmnd *scmd)
|
|
||||||
@@ -2101,6 +2103,26 @@ static int sd_revalidate_disk(struct gendisk *disk)
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
+ * sd_unlock_native_capacity - unlock native capacity
|
|
||||||
+ * @disk: struct gendisk to set capacity for
|
|
||||||
+ *
|
|
||||||
+ * Block layer calls this function if it detects that partitions
|
|
||||||
+ * on @disk reach beyond the end of the device. If the SCSI host
|
|
||||||
+ * implements ->unlock_native_capacity() method, it's invoked to
|
|
||||||
+ * give it a chance to adjust the device capacity.
|
|
||||||
+ *
|
|
||||||
+ * CONTEXT:
|
|
||||||
+ * Defined by block layer. Might sleep.
|
|
||||||
+ */
|
|
||||||
+static void sd_unlock_native_capacity(struct gendisk *disk)
|
|
||||||
+{
|
|
||||||
+ struct scsi_device *sdev = scsi_disk(disk)->device;
|
|
||||||
+
|
|
||||||
+ if (sdev->host->hostt->unlock_native_capacity)
|
|
||||||
+ sdev->host->hostt->unlock_native_capacity(sdev);
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
+/**
|
|
||||||
* sd_format_disk_name - format disk name
|
|
||||||
* @prefix: name prefix - ie. "sd" for SCSI disks
|
|
||||||
* @index: index of the disk to format name for
|
|
||||||
diff --git a/include/scsi/scsi_host.h b/include/scsi/scsi_host.h
|
|
||||||
index c50a97f..b7bdecb 100644
|
|
||||||
--- a/include/scsi/scsi_host.h
|
|
||||||
+++ b/include/scsi/scsi_host.h
|
|
||||||
@@ -327,6 +327,14 @@ struct scsi_host_template {
|
|
||||||
sector_t, int []);
|
|
||||||
|
|
||||||
/*
|
|
||||||
+ * This function is called when one or more partitions on the
|
|
||||||
+ * device reach beyond the end of the device.
|
|
||||||
+ *
|
|
||||||
+ * Status: OPTIONAL
|
|
||||||
+ */
|
|
||||||
+ void (*unlock_native_capacity)(struct scsi_device *);
|
|
||||||
+
|
|
||||||
+ /*
|
|
||||||
* Can be used to export driver statistics and other infos to the
|
|
||||||
* world outside the kernel ie. userspace and it also provides an
|
|
||||||
* interface to feed the driver with information.
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,34 +0,0 @@
|
||||||
From 67b0f5b1177a0c348d1293ab78de4d1d6a736048 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Date: Sat, 15 May 2010 16:45:29 +0100
|
|
||||||
Subject: [PATCH] V4L/DVB: budget: Select correct frontends
|
|
||||||
|
|
||||||
Update the Kconfig selections to match the code.
|
|
||||||
---
|
|
||||||
drivers/media/dvb/ttpci/Kconfig | 5 +++--
|
|
||||||
1 files changed, 3 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/media/dvb/ttpci/Kconfig b/drivers/media/dvb/ttpci/Kconfig
|
|
||||||
index d8d4214..32a7ec6 100644
|
|
||||||
--- a/drivers/media/dvb/ttpci/Kconfig
|
|
||||||
+++ b/drivers/media/dvb/ttpci/Kconfig
|
|
||||||
@@ -68,13 +68,14 @@ config DVB_BUDGET
|
|
||||||
select DVB_VES1820 if !DVB_FE_CUSTOMISE
|
|
||||||
select DVB_L64781 if !DVB_FE_CUSTOMISE
|
|
||||||
select DVB_TDA8083 if !DVB_FE_CUSTOMISE
|
|
||||||
- select DVB_TDA10021 if !DVB_FE_CUSTOMISE
|
|
||||||
- select DVB_TDA10023 if !DVB_FE_CUSTOMISE
|
|
||||||
select DVB_S5H1420 if !DVB_FE_CUSTOMISE
|
|
||||||
select DVB_TDA10086 if !DVB_FE_CUSTOMISE
|
|
||||||
select DVB_TDA826X if !DVB_FE_CUSTOMISE
|
|
||||||
select DVB_LNBP21 if !DVB_FE_CUSTOMISE
|
|
||||||
select DVB_TDA1004X if !DVB_FE_CUSTOMISE
|
|
||||||
+ select DVB_ISL6423 if !DVB_FE_CUSTOMISE
|
|
||||||
+ select DVB_STV090x if !DVB_FE_CUSTOMISE
|
|
||||||
+ select DVB_STV6110x if !DVB_FE_CUSTOMISE
|
|
||||||
help
|
|
||||||
Support for simple SAA7146 based DVB cards (so called Budget-
|
|
||||||
or Nova-PCI cards) without onboard MPEG2 decoder, and without
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,178 +0,0 @@
|
||||||
From 1eebd584b590399138f9b0d99d0a8a8537cf9715 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Tejun Heo <tj@kernel.org>
|
|
||||||
Date: Sat, 15 May 2010 19:55:31 +0200
|
|
||||||
Subject: [PATCH 3/8] block,ide: simplify bdops->set_capacity() to ->unlock_native_capacity()
|
|
||||||
|
|
||||||
bdops->set_capacity() is unnecessarily generic. All that's required
|
|
||||||
is a simple one way notification to lower level driver telling it to
|
|
||||||
try to unlock native capacity. There's no reason to pass in target
|
|
||||||
capacity or return the new capacity. The former is always the
|
|
||||||
inherent native capacity and the latter can be handled via the usual
|
|
||||||
device resize / revalidation path. In fact, the current API is always
|
|
||||||
used that way.
|
|
||||||
|
|
||||||
Replace ->set_capacity() with ->unlock_native_capacity() which take
|
|
||||||
only @disk and doesn't return anything. IDE which is the only current
|
|
||||||
user of the API is converted accordingly.
|
|
||||||
|
|
||||||
Signed-off-by: Tejun Heo <tj@kernel.org>
|
|
||||||
Cc: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Cc: Jens Axboe <jens.axboe@oracle.com>
|
|
||||||
Cc: David Miller <davem@davemloft.net>
|
|
||||||
Cc: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
|
|
||||||
---
|
|
||||||
drivers/ide/ide-disk.c | 40 ++++++++++++++++------------------------
|
|
||||||
drivers/ide/ide-gd.c | 11 ++++-------
|
|
||||||
fs/partitions/check.c | 4 ++--
|
|
||||||
include/linux/blkdev.h | 3 +--
|
|
||||||
include/linux/ide.h | 2 +-
|
|
||||||
5 files changed, 24 insertions(+), 36 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/ide/ide-disk.c b/drivers/ide/ide-disk.c
|
|
||||||
index 3b128dc..33d6503 100644
|
|
||||||
--- a/drivers/ide/ide-disk.c
|
|
||||||
+++ b/drivers/ide/ide-disk.c
|
|
||||||
@@ -407,32 +407,24 @@ static int ide_disk_get_capacity(ide_drive_t *drive)
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
-static u64 ide_disk_set_capacity(ide_drive_t *drive, u64 capacity)
|
|
||||||
+static void ide_disk_unlock_native_capacity(ide_drive_t *drive)
|
|
||||||
{
|
|
||||||
- u64 set = min(capacity, drive->probed_capacity);
|
|
||||||
u16 *id = drive->id;
|
|
||||||
int lba48 = ata_id_lba48_enabled(id);
|
|
||||||
|
|
||||||
if ((drive->dev_flags & IDE_DFLAG_LBA) == 0 ||
|
|
||||||
ata_id_hpa_enabled(id) == 0)
|
|
||||||
- goto out;
|
|
||||||
+ return;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* according to the spec the SET MAX ADDRESS command shall be
|
|
||||||
* immediately preceded by a READ NATIVE MAX ADDRESS command
|
|
||||||
*/
|
|
||||||
- capacity = ide_disk_hpa_get_native_capacity(drive, lba48);
|
|
||||||
- if (capacity == 0)
|
|
||||||
- goto out;
|
|
||||||
-
|
|
||||||
- set = ide_disk_hpa_set_capacity(drive, set, lba48);
|
|
||||||
- if (set) {
|
|
||||||
- /* needed for ->resume to disable HPA */
|
|
||||||
- drive->dev_flags |= IDE_DFLAG_NOHPA;
|
|
||||||
- return set;
|
|
||||||
- }
|
|
||||||
-out:
|
|
||||||
- return drive->capacity64;
|
|
||||||
+ if (!ide_disk_hpa_get_native_capacity(drive, lba48))
|
|
||||||
+ return;
|
|
||||||
+
|
|
||||||
+ if (ide_disk_hpa_set_capacity(drive, drive->probed_capacity, lba48))
|
|
||||||
+ drive->dev_flags |= IDE_DFLAG_NOHPA; /* disable HPA on resume */
|
|
||||||
}
|
|
||||||
|
|
||||||
static void idedisk_prepare_flush(struct request_queue *q, struct request *rq)
|
|
||||||
@@ -783,13 +775,13 @@ static int ide_disk_set_doorlock(ide_drive_t *drive, struct gendisk *disk,
|
|
||||||
}
|
|
||||||
|
|
||||||
const struct ide_disk_ops ide_ata_disk_ops = {
|
|
||||||
- .check = ide_disk_check,
|
|
||||||
- .set_capacity = ide_disk_set_capacity,
|
|
||||||
- .get_capacity = ide_disk_get_capacity,
|
|
||||||
- .setup = ide_disk_setup,
|
|
||||||
- .flush = ide_disk_flush,
|
|
||||||
- .init_media = ide_disk_init_media,
|
|
||||||
- .set_doorlock = ide_disk_set_doorlock,
|
|
||||||
- .do_request = ide_do_rw_disk,
|
|
||||||
- .ioctl = ide_disk_ioctl,
|
|
||||||
+ .check = ide_disk_check,
|
|
||||||
+ .unlock_native_capacity = ide_disk_unlock_native_capacity,
|
|
||||||
+ .get_capacity = ide_disk_get_capacity,
|
|
||||||
+ .setup = ide_disk_setup,
|
|
||||||
+ .flush = ide_disk_flush,
|
|
||||||
+ .init_media = ide_disk_init_media,
|
|
||||||
+ .set_doorlock = ide_disk_set_doorlock,
|
|
||||||
+ .do_request = ide_do_rw_disk,
|
|
||||||
+ .ioctl = ide_disk_ioctl,
|
|
||||||
};
|
|
||||||
diff --git a/drivers/ide/ide-gd.c b/drivers/ide/ide-gd.c
|
|
||||||
index c32d839..c102d23 100644
|
|
||||||
--- a/drivers/ide/ide-gd.c
|
|
||||||
+++ b/drivers/ide/ide-gd.c
|
|
||||||
@@ -288,17 +288,14 @@ static int ide_gd_media_changed(struct gendisk *disk)
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
-static unsigned long long ide_gd_set_capacity(struct gendisk *disk,
|
|
||||||
- unsigned long long capacity)
|
|
||||||
+static void ide_gd_unlock_native_capacity(struct gendisk *disk)
|
|
||||||
{
|
|
||||||
struct ide_disk_obj *idkp = ide_drv_g(disk, ide_disk_obj);
|
|
||||||
ide_drive_t *drive = idkp->drive;
|
|
||||||
const struct ide_disk_ops *disk_ops = drive->disk_ops;
|
|
||||||
|
|
||||||
- if (disk_ops->set_capacity)
|
|
||||||
- return disk_ops->set_capacity(drive, capacity);
|
|
||||||
-
|
|
||||||
- return drive->capacity64;
|
|
||||||
+ if (disk_ops->unlock_native_capacity)
|
|
||||||
+ disk_ops->unlock_native_capacity(drive);
|
|
||||||
}
|
|
||||||
|
|
||||||
static int ide_gd_revalidate_disk(struct gendisk *disk)
|
|
||||||
@@ -329,7 +326,7 @@ static const struct block_device_operations ide_gd_ops = {
|
|
||||||
.locked_ioctl = ide_gd_ioctl,
|
|
||||||
.getgeo = ide_gd_getgeo,
|
|
||||||
.media_changed = ide_gd_media_changed,
|
|
||||||
- .set_capacity = ide_gd_set_capacity,
|
|
||||||
+ .unlock_native_capacity = ide_gd_unlock_native_capacity,
|
|
||||||
.revalidate_disk = ide_gd_revalidate_disk
|
|
||||||
};
|
|
||||||
|
|
||||||
diff --git a/fs/partitions/check.c b/fs/partitions/check.c
|
|
||||||
index 8f01df3..4f1fee0 100644
|
|
||||||
--- a/fs/partitions/check.c
|
|
||||||
+++ b/fs/partitions/check.c
|
|
||||||
@@ -601,10 +601,10 @@ rescan:
|
|
||||||
"%s: p%d size %llu exceeds device capacity, ",
|
|
||||||
disk->disk_name, p, (unsigned long long) size);
|
|
||||||
|
|
||||||
- if (bdops->set_capacity &&
|
|
||||||
+ if (bdops->unlock_native_capacity &&
|
|
||||||
(disk->flags & GENHD_FL_NATIVE_CAPACITY) == 0) {
|
|
||||||
printk(KERN_CONT "enabling native capacity\n");
|
|
||||||
- bdops->set_capacity(disk, ~0ULL);
|
|
||||||
+ bdops->unlock_native_capacity(disk);
|
|
||||||
disk->flags |= GENHD_FL_NATIVE_CAPACITY;
|
|
||||||
/* free state and restart */
|
|
||||||
kfree(state);
|
|
||||||
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
|
|
||||||
index 6690e8b..f2a0c33 100644
|
|
||||||
--- a/include/linux/blkdev.h
|
|
||||||
+++ b/include/linux/blkdev.h
|
|
||||||
@@ -1283,8 +1283,7 @@ struct block_device_operations {
|
|
||||||
int (*direct_access) (struct block_device *, sector_t,
|
|
||||||
void **, unsigned long *);
|
|
||||||
int (*media_changed) (struct gendisk *);
|
|
||||||
- unsigned long long (*set_capacity) (struct gendisk *,
|
|
||||||
- unsigned long long);
|
|
||||||
+ void (*unlock_native_capacity) (struct gendisk *);
|
|
||||||
int (*revalidate_disk) (struct gendisk *);
|
|
||||||
int (*getgeo)(struct block_device *, struct hd_geometry *);
|
|
||||||
struct module *owner;
|
|
||||||
diff --git a/include/linux/ide.h b/include/linux/ide.h
|
|
||||||
index 3239d1c..b6d4480 100644
|
|
||||||
--- a/include/linux/ide.h
|
|
||||||
+++ b/include/linux/ide.h
|
|
||||||
@@ -362,7 +362,7 @@ struct ide_drive_s;
|
|
||||||
struct ide_disk_ops {
|
|
||||||
int (*check)(struct ide_drive_s *, const char *);
|
|
||||||
int (*get_capacity)(struct ide_drive_s *);
|
|
||||||
- u64 (*set_capacity)(struct ide_drive_s *, u64);
|
|
||||||
+ void (*unlock_native_capacity)(struct ide_drive_s *);
|
|
||||||
void (*setup)(struct ide_drive_s *);
|
|
||||||
void (*flush)(struct ide_drive_s *);
|
|
||||||
int (*init_media)(struct ide_drive_s *, struct gendisk *);
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,70 +0,0 @@
|
||||||
From 866c02ef409514de12a6e136614e9c8db5d36c06 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Tejun Heo <tj@kernel.org>
|
|
||||||
Date: Sat, 15 May 2010 19:55:31 +0200
|
|
||||||
Subject: [PATCH 2/8] block: restart partition scan after resizing a device
|
|
||||||
|
|
||||||
Device resize via ->set_capacity() can reveal new partitions (e.g. in
|
|
||||||
chained partition table formats such as dos extended parts). Restart
|
|
||||||
partition scan from the beginning after resizing a device. This
|
|
||||||
change also makes libata always revalidate the disk after resize which
|
|
||||||
makes lower layer native capacity unlocking implementation simpler and
|
|
||||||
more robust as resize can be handled in the usual path.
|
|
||||||
|
|
||||||
Signed-off-by: Tejun Heo <tj@kernel.org>
|
|
||||||
Reported-by: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
---
|
|
||||||
fs/partitions/check.c | 16 ++++++----------
|
|
||||||
1 files changed, 6 insertions(+), 10 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/fs/partitions/check.c b/fs/partitions/check.c
|
|
||||||
index e238ab2..8f01df3 100644
|
|
||||||
--- a/fs/partitions/check.c
|
|
||||||
+++ b/fs/partitions/check.c
|
|
||||||
@@ -544,7 +544,7 @@ int rescan_partitions(struct gendisk *disk, struct block_device *bdev)
|
|
||||||
struct hd_struct *part;
|
|
||||||
struct parsed_partitions *state;
|
|
||||||
int p, highest, res;
|
|
||||||
-
|
|
||||||
+rescan:
|
|
||||||
if (bdev->bd_part_count)
|
|
||||||
return -EBUSY;
|
|
||||||
res = invalidate_partition(disk, 0);
|
|
||||||
@@ -581,7 +581,7 @@ int rescan_partitions(struct gendisk *disk, struct block_device *bdev)
|
|
||||||
/* add partitions */
|
|
||||||
for (p = 1; p < state->limit; p++) {
|
|
||||||
sector_t size, from;
|
|
||||||
-try_scan:
|
|
||||||
+
|
|
||||||
size = state->parts[p].size;
|
|
||||||
if (!size)
|
|
||||||
continue;
|
|
||||||
@@ -596,7 +596,6 @@ try_scan:
|
|
||||||
|
|
||||||
if (from + size > get_capacity(disk)) {
|
|
||||||
const struct block_device_operations *bdops = disk->fops;
|
|
||||||
- unsigned long long capacity;
|
|
||||||
|
|
||||||
printk(KERN_WARNING
|
|
||||||
"%s: p%d size %llu exceeds device capacity, ",
|
|
||||||
@@ -605,14 +604,11 @@ try_scan:
|
|
||||||
if (bdops->set_capacity &&
|
|
||||||
(disk->flags & GENHD_FL_NATIVE_CAPACITY) == 0) {
|
|
||||||
printk(KERN_CONT "enabling native capacity\n");
|
|
||||||
- capacity = bdops->set_capacity(disk, ~0ULL);
|
|
||||||
+ bdops->set_capacity(disk, ~0ULL);
|
|
||||||
disk->flags |= GENHD_FL_NATIVE_CAPACITY;
|
|
||||||
- if (capacity > get_capacity(disk)) {
|
|
||||||
- set_capacity(disk, capacity);
|
|
||||||
- check_disk_size_change(disk, bdev);
|
|
||||||
- bdev->bd_invalidated = 0;
|
|
||||||
- }
|
|
||||||
- goto try_scan;
|
|
||||||
+ /* free state and restart */
|
|
||||||
+ kfree(state);
|
|
||||||
+ goto rescan;
|
|
||||||
} else {
|
|
||||||
/*
|
|
||||||
* we can not ignore partitions of broken tables
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,36 +0,0 @@
|
||||||
From 36051e2a8f14a1d44ae0801100448013ae8d9fc1 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Tejun Heo <tj@kernel.org>
|
|
||||||
Date: Sat, 15 May 2010 19:55:31 +0200
|
|
||||||
Subject: [PATCH 1/8] buffer: make invalidate_bdev() drain all percpu LRU add caches
|
|
||||||
|
|
||||||
invalidate_bdev() should release all page cache pages which are clean
|
|
||||||
and not being used; however, if some pages are still in the percpu LRU
|
|
||||||
add caches on other cpus, those pages are considered in used and don't
|
|
||||||
get released. Fix it by calling lru_add_drain_all() before trying to
|
|
||||||
invalidate pages.
|
|
||||||
|
|
||||||
This problem was discovered while testing block automatic native
|
|
||||||
capacity unlocking. Null pages which were read before automatic
|
|
||||||
unlocking didn't get released by invalidate_bdev() and ended up
|
|
||||||
interfering with partition scan after unlocking.
|
|
||||||
|
|
||||||
Signed-off-by: Tejun Heo <tj@kernel.org>
|
|
||||||
---
|
|
||||||
fs/buffer.c | 1 +
|
|
||||||
1 files changed, 1 insertions(+), 0 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/fs/buffer.c b/fs/buffer.c
|
|
||||||
index c9c266d..08e422d 100644
|
|
||||||
--- a/fs/buffer.c
|
|
||||||
+++ b/fs/buffer.c
|
|
||||||
@@ -275,6 +275,7 @@ void invalidate_bdev(struct block_device *bdev)
|
|
||||||
return;
|
|
||||||
|
|
||||||
invalidate_bh_lrus();
|
|
||||||
+ lru_add_drain_all(); /* make sure all lru add caches are flushed */
|
|
||||||
invalidate_mapping_pages(mapping, 0, -1);
|
|
||||||
}
|
|
||||||
EXPORT_SYMBOL(invalidate_bdev);
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,127 +0,0 @@
|
||||||
[CIFS] Allow null nd (as nfs server uses) on create
|
|
||||||
|
|
||||||
While creating a file on a server which supports unix extensions
|
|
||||||
such as Samba, if a file is being created which does not supply
|
|
||||||
nameidata (i.e. nd is null), cifs client can oops when calling
|
|
||||||
cifs_posix_open.
|
|
||||||
|
|
||||||
Signed-off-by: Shirish Pargaonkar <shirishp@us.ibm.com>
|
|
||||||
Signed-off-by: Steve French <sfrench@us.ibm.com>
|
|
||||||
---
|
|
||||||
|
|
||||||
|
|
||||||
Adjusted to apply to Debian's 2.6.32 by dann frazier <dannf@debian.org>
|
|
||||||
|
|
||||||
|
|
||||||
diff -urpN a/fs/cifs/cifsproto.h b/fs/cifs/cifsproto.h
|
|
||||||
--- a/fs/cifs/cifsproto.h 2009-12-02 20:51:21.000000000 -0700
|
|
||||||
+++ b/fs/cifs/cifsproto.h 2010-04-30 00:24:18.000000000 -0600
|
|
||||||
@@ -95,8 +95,10 @@ extern struct cifsFileInfo *cifs_new_fil
|
|
||||||
__u16 fileHandle, struct file *file,
|
|
||||||
struct vfsmount *mnt, unsigned int oflags);
|
|
||||||
extern int cifs_posix_open(char *full_path, struct inode **pinode,
|
|
||||||
- struct vfsmount *mnt, int mode, int oflags,
|
|
||||||
- __u32 *poplock, __u16 *pnetfid, int xid);
|
|
||||||
+ struct vfsmount *mnt,
|
|
||||||
+ struct super_block *sb,
|
|
||||||
+ int mode, int oflags,
|
|
||||||
+ __u32 *poplock, __u16 *pnetfid, int xid);
|
|
||||||
extern void cifs_unix_basic_to_fattr(struct cifs_fattr *fattr,
|
|
||||||
FILE_UNIX_BASIC_INFO *info,
|
|
||||||
struct cifs_sb_info *cifs_sb);
|
|
||||||
diff -urpN a/fs/cifs/dir.c b/fs/cifs/dir.c
|
|
||||||
--- a/fs/cifs/dir.c 2009-12-02 20:51:21.000000000 -0700
|
|
||||||
+++ b/fs/cifs/dir.c 2010-04-30 00:24:18.000000000 -0600
|
|
||||||
@@ -183,13 +183,14 @@ cifs_new_fileinfo(struct inode *newinode
|
|
||||||
}
|
|
||||||
|
|
||||||
int cifs_posix_open(char *full_path, struct inode **pinode,
|
|
||||||
- struct vfsmount *mnt, int mode, int oflags,
|
|
||||||
- __u32 *poplock, __u16 *pnetfid, int xid)
|
|
||||||
+ struct vfsmount *mnt, struct super_block *sb,
|
|
||||||
+ int mode, int oflags,
|
|
||||||
+ __u32 *poplock, __u16 *pnetfid, int xid)
|
|
||||||
{
|
|
||||||
int rc;
|
|
||||||
FILE_UNIX_BASIC_INFO *presp_data;
|
|
||||||
__u32 posix_flags = 0;
|
|
||||||
- struct cifs_sb_info *cifs_sb = CIFS_SB(mnt->mnt_sb);
|
|
||||||
+ struct cifs_sb_info *cifs_sb = CIFS_SB(sb);
|
|
||||||
struct cifs_fattr fattr;
|
|
||||||
|
|
||||||
cFYI(1, ("posix open %s", full_path));
|
|
||||||
@@ -241,7 +242,7 @@ int cifs_posix_open(char *full_path, str
|
|
||||||
|
|
||||||
/* get new inode and set it up */
|
|
||||||
if (*pinode == NULL) {
|
|
||||||
- *pinode = cifs_iget(mnt->mnt_sb, &fattr);
|
|
||||||
+ *pinode = cifs_iget(sb, &fattr);
|
|
||||||
if (!*pinode) {
|
|
||||||
rc = -ENOMEM;
|
|
||||||
goto posix_open_ret;
|
|
||||||
@@ -250,7 +251,8 @@ int cifs_posix_open(char *full_path, str
|
|
||||||
cifs_fattr_to_inode(*pinode, &fattr);
|
|
||||||
}
|
|
||||||
|
|
||||||
- cifs_new_fileinfo(*pinode, *pnetfid, NULL, mnt, oflags);
|
|
||||||
+ if (mnt)
|
|
||||||
+ cifs_new_fileinfo(*pinode, *pnetfid, NULL, mnt, oflags);
|
|
||||||
|
|
||||||
posix_open_ret:
|
|
||||||
kfree(presp_data);
|
|
||||||
@@ -314,13 +316,14 @@ cifs_create(struct inode *inode, struct
|
|
||||||
if (nd && (nd->flags & LOOKUP_OPEN))
|
|
||||||
oflags = nd->intent.open.flags;
|
|
||||||
else
|
|
||||||
- oflags = FMODE_READ;
|
|
||||||
+ oflags = FMODE_READ | SMB_O_CREAT;
|
|
||||||
|
|
||||||
if (tcon->unix_ext && (tcon->ses->capabilities & CAP_UNIX) &&
|
|
||||||
(CIFS_UNIX_POSIX_PATH_OPS_CAP &
|
|
||||||
le64_to_cpu(tcon->fsUnixInfo.Capability))) {
|
|
||||||
- rc = cifs_posix_open(full_path, &newinode, nd->path.mnt,
|
|
||||||
- mode, oflags, &oplock, &fileHandle, xid);
|
|
||||||
+ rc = cifs_posix_open(full_path, &newinode,
|
|
||||||
+ nd ? nd->path.mnt : NULL,
|
|
||||||
+ inode->i_sb, mode, oflags, &oplock, &fileHandle, xid);
|
|
||||||
/* EIO could indicate that (posix open) operation is not
|
|
||||||
supported, despite what server claimed in capability
|
|
||||||
negotation. EREMOTE indicates DFS junction, which is not
|
|
||||||
@@ -677,6 +680,7 @@ cifs_lookup(struct inode *parent_dir_ino
|
|
||||||
(nd->flags & LOOKUP_OPEN) && !pTcon->broken_posix_open &&
|
|
||||||
(nd->intent.open.flags & O_CREAT)) {
|
|
||||||
rc = cifs_posix_open(full_path, &newInode, nd->path.mnt,
|
|
||||||
+ parent_dir_inode->i_sb,
|
|
||||||
nd->intent.open.create_mode,
|
|
||||||
nd->intent.open.flags, &oplock,
|
|
||||||
&fileHandle, xid);
|
|
||||||
diff -urpN a/fs/cifs/file.c b/fs/cifs/file.c
|
|
||||||
--- a/fs/cifs/file.c 2009-12-02 20:51:21.000000000 -0700
|
|
||||||
+++ b/fs/cifs/file.c 2010-04-30 00:24:18.000000000 -0600
|
|
||||||
@@ -295,10 +295,12 @@ int cifs_open(struct inode *inode, struc
|
|
||||||
(CIFS_UNIX_POSIX_PATH_OPS_CAP &
|
|
||||||
le64_to_cpu(tcon->fsUnixInfo.Capability))) {
|
|
||||||
int oflags = (int) cifs_posix_convert_flags(file->f_flags);
|
|
||||||
+ oflags |= SMB_O_CREAT;
|
|
||||||
/* can not refresh inode info since size could be stale */
|
|
||||||
rc = cifs_posix_open(full_path, &inode, file->f_path.mnt,
|
|
||||||
- cifs_sb->mnt_file_mode /* ignored */,
|
|
||||||
- oflags, &oplock, &netfid, xid);
|
|
||||||
+ inode->i_sb,
|
|
||||||
+ cifs_sb->mnt_file_mode /* ignored */,
|
|
||||||
+ oflags, &oplock, &netfid, xid);
|
|
||||||
if (rc == 0) {
|
|
||||||
cFYI(1, ("posix open succeeded"));
|
|
||||||
/* no need for special case handling of setting mode
|
|
||||||
@@ -510,8 +512,9 @@ reopen_error_exit:
|
|
||||||
int oflags = (int) cifs_posix_convert_flags(file->f_flags);
|
|
||||||
/* can not refresh inode info since size could be stale */
|
|
||||||
rc = cifs_posix_open(full_path, NULL, file->f_path.mnt,
|
|
||||||
- cifs_sb->mnt_file_mode /* ignored */,
|
|
||||||
- oflags, &oplock, &netfid, xid);
|
|
||||||
+ inode->i_sb,
|
|
||||||
+ cifs_sb->mnt_file_mode /* ignored */,
|
|
||||||
+ oflags, &oplock, &netfid, xid);
|
|
||||||
if (rc == 0) {
|
|
||||||
cFYI(1, ("posix reopen succeeded"));
|
|
||||||
goto reopen_success;
|
|
|
@ -1,39 +0,0 @@
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Date: Mon, 17 May 2010 05:00:00 -0400
|
|
||||||
Subject: [PATCH 1/2] ext4: Conditionally define compat ioctl numbers
|
|
||||||
|
|
||||||
commit 899ad0cea6ad7ff4ba24b16318edbc3cbbe03fad upstream.
|
|
||||||
|
|
||||||
It is unnecessary, and in general impossible, to define the compat
|
|
||||||
ioctl numbers except when building the filesystem with CONFIG_COMPAT
|
|
||||||
defined.
|
|
||||||
|
|
||||||
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
|
|
||||||
---
|
|
||||||
fs/ext4/ext4.h | 2 ++
|
|
||||||
1 files changed, 2 insertions(+), 0 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h
|
|
||||||
index 7441488..d8c28f6 100644
|
|
||||||
--- a/fs/ext4/ext4.h
|
|
||||||
+++ b/fs/ext4/ext4.h
|
|
||||||
@@ -498,6 +498,7 @@ struct ext4_new_group_data {
|
|
||||||
#define EXT4_IOC_ALLOC_DA_BLKS _IO('f', 12)
|
|
||||||
#define EXT4_IOC_MOVE_EXT _IOWR('f', 15, struct move_extent)
|
|
||||||
|
|
||||||
+#if defined(__KERNEL__) && defined(CONFIG_COMPAT)
|
|
||||||
/*
|
|
||||||
* ioctl commands in 32 bit emulation
|
|
||||||
*/
|
|
||||||
@@ -513,6 +514,7 @@ struct ext4_new_group_data {
|
|
||||||
#endif
|
|
||||||
#define EXT4_IOC32_GETVERSION_OLD FS_IOC32_GETVERSION
|
|
||||||
#define EXT4_IOC32_SETVERSION_OLD FS_IOC32_SETVERSION
|
|
||||||
+#endif
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,96 +0,0 @@
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Date: Mon, 17 May 2010 06:00:00 -0400
|
|
||||||
Subject: [PATCH 2/2] ext4: Fix compat EXT4_IOC_ADD_GROUP
|
|
||||||
|
|
||||||
commit 4d92dc0f00a775dc2e1267b0e00befb783902fe7 upstream.
|
|
||||||
|
|
||||||
struct ext4_new_group_input needs to be converted because u64 has
|
|
||||||
only 32-bit alignment on some 32-bit architectures, notably i386.
|
|
||||||
|
|
||||||
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Signed-off-by: "Theodore Ts'o" <tytso@mit.edu>
|
|
||||||
---
|
|
||||||
fs/ext4/ext4.h | 16 ++++++++++++++++
|
|
||||||
fs/ext4/ioctl.c | 25 +++++++++++++++++++++++--
|
|
||||||
2 files changed, 39 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/fs/ext4/ext4.h b/fs/ext4/ext4.h
|
|
||||||
index d8c28f6..2c1165f 100644
|
|
||||||
--- a/fs/ext4/ext4.h
|
|
||||||
+++ b/fs/ext4/ext4.h
|
|
||||||
@@ -29,6 +29,9 @@
|
|
||||||
#include <linux/wait.h>
|
|
||||||
#include <linux/blockgroup_lock.h>
|
|
||||||
#include <linux/percpu_counter.h>
|
|
||||||
+#ifdef __KERNEL__
|
|
||||||
+#include <linux/compat.h>
|
|
||||||
+#endif
|
|
||||||
|
|
||||||
/*
|
|
||||||
* The fourth extended filesystem constants/structures
|
|
||||||
@@ -432,6 +435,18 @@ struct ext4_new_group_input {
|
|
||||||
__u16 unused;
|
|
||||||
};
|
|
||||||
|
|
||||||
+#if defined(__KERNEL__) && defined(CONFIG_COMPAT)
|
|
||||||
+struct compat_ext4_new_group_input {
|
|
||||||
+ u32 group;
|
|
||||||
+ compat_u64 block_bitmap;
|
|
||||||
+ compat_u64 inode_bitmap;
|
|
||||||
+ compat_u64 inode_table;
|
|
||||||
+ u32 blocks_count;
|
|
||||||
+ u16 reserved_blocks;
|
|
||||||
+ u16 unused;
|
|
||||||
+};
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
/* The struct ext4_new_group_input in kernel space, with free_blocks_count */
|
|
||||||
struct ext4_new_group_data {
|
|
||||||
__u32 group;
|
|
||||||
@@ -509,6 +524,7 @@ struct ext4_new_group_data {
|
|
||||||
#define EXT4_IOC32_GETRSVSZ _IOR('f', 5, int)
|
|
||||||
#define EXT4_IOC32_SETRSVSZ _IOW('f', 6, int)
|
|
||||||
#define EXT4_IOC32_GROUP_EXTEND _IOW('f', 7, unsigned int)
|
|
||||||
+#define EXT4_IOC32_GROUP_ADD _IOW('f', 8, struct compat_ext4_new_group_input)
|
|
||||||
#ifdef CONFIG_JBD2_DEBUG
|
|
||||||
#define EXT4_IOC32_WAIT_FOR_READONLY _IOR('f', 99, int)
|
|
||||||
#endif
|
|
||||||
diff --git a/fs/ext4/ioctl.c b/fs/ext4/ioctl.c
|
|
||||||
index 66fa0b0..6ddec84 100644
|
|
||||||
--- a/fs/ext4/ioctl.c
|
|
||||||
+++ b/fs/ext4/ioctl.c
|
|
||||||
@@ -373,8 +373,29 @@ long ext4_compat_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
|
|
||||||
case EXT4_IOC32_SETRSVSZ:
|
|
||||||
cmd = EXT4_IOC_SETRSVSZ;
|
|
||||||
break;
|
|
||||||
- case EXT4_IOC_GROUP_ADD:
|
|
||||||
- break;
|
|
||||||
+ case EXT4_IOC32_GROUP_ADD: {
|
|
||||||
+ struct compat_ext4_new_group_input __user *uinput;
|
|
||||||
+ struct ext4_new_group_input input;
|
|
||||||
+ mm_segment_t old_fs;
|
|
||||||
+ int err;
|
|
||||||
+
|
|
||||||
+ uinput = compat_ptr(arg);
|
|
||||||
+ err = get_user(input.group, &uinput->group);
|
|
||||||
+ err |= get_user(input.block_bitmap, &uinput->block_bitmap);
|
|
||||||
+ err |= get_user(input.inode_bitmap, &uinput->inode_bitmap);
|
|
||||||
+ err |= get_user(input.inode_table, &uinput->inode_table);
|
|
||||||
+ err |= get_user(input.blocks_count, &uinput->blocks_count);
|
|
||||||
+ err |= get_user(input.reserved_blocks,
|
|
||||||
+ &uinput->reserved_blocks);
|
|
||||||
+ if (err)
|
|
||||||
+ return -EFAULT;
|
|
||||||
+ old_fs = get_fs();
|
|
||||||
+ set_fs(KERNEL_DS);
|
|
||||||
+ err = ext4_ioctl(file, EXT4_IOC_GROUP_ADD,
|
|
||||||
+ (unsigned long) &input);
|
|
||||||
+ set_fs(old_fs);
|
|
||||||
+ return err;
|
|
||||||
+ }
|
|
||||||
default:
|
|
||||||
return -ENOIOCTLCMD;
|
|
||||||
}
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,210 +0,0 @@
|
||||||
From: Jens Axboe <jens.axboe@oracle.com>
|
|
||||||
Date: Mon, 17 May 2010 12:55:07 +0200
|
|
||||||
Subject: [PATCH] writeback: fix WB_SYNC_NONE writeback from umount
|
|
||||||
|
|
||||||
commit e913fc825dc685a444cb4c1d0f9d32f372f59861 upstream.
|
|
||||||
|
|
||||||
When umount calls sync_filesystem(), we first do a WB_SYNC_NONE
|
|
||||||
writeback to kick off writeback of pending dirty inodes, then follow
|
|
||||||
that up with a WB_SYNC_ALL to wait for it. Since umount already holds
|
|
||||||
the sb s_umount mutex, WB_SYNC_NONE ends up doing nothing and all
|
|
||||||
writeback happens as WB_SYNC_ALL. This can greatly slow down umount,
|
|
||||||
since WB_SYNC_ALL writeback is a data integrity operation and thus
|
|
||||||
a bigger hammer than simple WB_SYNC_NONE. For barrier aware file systems
|
|
||||||
it's a lot slower.
|
|
||||||
|
|
||||||
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
|
|
||||||
[maks: Use earlier version for 2.6.34]
|
|
||||||
---
|
|
||||||
fs/fs-writeback.c | 48 +++++++++++++++++++++++++++++++++---------
|
|
||||||
fs/sync.c | 2 +-
|
|
||||||
include/linux/backing-dev.h | 2 +-
|
|
||||||
include/linux/writeback.h | 10 +++++++++
|
|
||||||
mm/page-writeback.c | 4 +-
|
|
||||||
5 files changed, 51 insertions(+), 15 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c
|
|
||||||
index 4b37f7c..c9ac9cb 100644
|
|
||||||
--- a/fs/fs-writeback.c
|
|
||||||
+++ b/fs/fs-writeback.c
|
|
||||||
@@ -45,6 +45,7 @@ struct wb_writeback_args {
|
|
||||||
int for_kupdate:1;
|
|
||||||
int range_cyclic:1;
|
|
||||||
int for_background:1;
|
|
||||||
+ int sb_pinned:1;
|
|
||||||
};
|
|
||||||
|
|
||||||
/*
|
|
||||||
@@ -230,6 +231,11 @@ static void bdi_sync_writeback(struct backing_dev_info *bdi,
|
|
||||||
.sync_mode = WB_SYNC_ALL,
|
|
||||||
.nr_pages = LONG_MAX,
|
|
||||||
.range_cyclic = 0,
|
|
||||||
+ /*
|
|
||||||
+ * Setting sb_pinned is not necessary for WB_SYNC_ALL, but
|
|
||||||
+ * lets make it explicitly clear.
|
|
||||||
+ */
|
|
||||||
+ .sb_pinned = 1,
|
|
||||||
};
|
|
||||||
struct bdi_work work;
|
|
||||||
|
|
||||||
@@ -245,21 +251,23 @@ static void bdi_sync_writeback(struct backing_dev_info *bdi,
|
|
||||||
* @bdi: the backing device to write from
|
|
||||||
* @sb: write inodes from this super_block
|
|
||||||
* @nr_pages: the number of pages to write
|
|
||||||
+ * @sb_locked: caller already holds sb umount sem.
|
|
||||||
*
|
|
||||||
* Description:
|
|
||||||
* This does WB_SYNC_NONE opportunistic writeback. The IO is only
|
|
||||||
* started when this function returns, we make no guarentees on
|
|
||||||
- * completion. Caller need not hold sb s_umount semaphore.
|
|
||||||
+ * completion. Caller specifies whether sb umount sem is held already or not.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
void bdi_start_writeback(struct backing_dev_info *bdi, struct super_block *sb,
|
|
||||||
- long nr_pages)
|
|
||||||
+ long nr_pages, int sb_locked)
|
|
||||||
{
|
|
||||||
struct wb_writeback_args args = {
|
|
||||||
.sb = sb,
|
|
||||||
.sync_mode = WB_SYNC_NONE,
|
|
||||||
.nr_pages = nr_pages,
|
|
||||||
.range_cyclic = 1,
|
|
||||||
+ .sb_pinned = sb_locked,
|
|
||||||
};
|
|
||||||
|
|
||||||
/*
|
|
||||||
@@ -577,7 +585,7 @@ static enum sb_pin_state pin_sb_for_writeback(struct writeback_control *wbc,
|
|
||||||
/*
|
|
||||||
* Caller must already hold the ref for this
|
|
||||||
*/
|
|
||||||
- if (wbc->sync_mode == WB_SYNC_ALL) {
|
|
||||||
+ if (wbc->sync_mode == WB_SYNC_ALL || wbc->sb_pinned) {
|
|
||||||
WARN_ON(!rwsem_is_locked(&sb->s_umount));
|
|
||||||
return SB_NOT_PINNED;
|
|
||||||
}
|
|
||||||
@@ -751,6 +759,7 @@ static long wb_writeback(struct bdi_writeback *wb,
|
|
||||||
.for_kupdate = args->for_kupdate,
|
|
||||||
.for_background = args->for_background,
|
|
||||||
.range_cyclic = args->range_cyclic,
|
|
||||||
+ .sb_pinned = args->sb_pinned,
|
|
||||||
};
|
|
||||||
unsigned long oldest_jif;
|
|
||||||
long wrote = 0;
|
|
||||||
@@ -1183,6 +1192,18 @@ static void wait_sb_inodes(struct super_block *sb)
|
|
||||||
iput(old_inode);
|
|
||||||
}
|
|
||||||
|
|
||||||
+static void __writeback_inodes_sb(struct super_block *sb, int sb_locked)
|
|
||||||
+{
|
|
||||||
+ unsigned long nr_dirty = global_page_state(NR_FILE_DIRTY);
|
|
||||||
+ unsigned long nr_unstable = global_page_state(NR_UNSTABLE_NFS);
|
|
||||||
+ long nr_to_write;
|
|
||||||
+
|
|
||||||
+ nr_to_write = nr_dirty + nr_unstable +
|
|
||||||
+ (inodes_stat.nr_inodes - inodes_stat.nr_unused);
|
|
||||||
+
|
|
||||||
+ bdi_start_writeback(sb->s_bdi, sb, nr_to_write, sb_locked);
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
/**
|
|
||||||
* writeback_inodes_sb - writeback dirty inodes from given super_block
|
|
||||||
* @sb: the superblock
|
|
||||||
@@ -1194,18 +1215,23 @@ static void wait_sb_inodes(struct super_block *sb)
|
|
||||||
*/
|
|
||||||
void writeback_inodes_sb(struct super_block *sb)
|
|
||||||
{
|
|
||||||
- unsigned long nr_dirty = global_page_state(NR_FILE_DIRTY);
|
|
||||||
- unsigned long nr_unstable = global_page_state(NR_UNSTABLE_NFS);
|
|
||||||
- long nr_to_write;
|
|
||||||
-
|
|
||||||
- nr_to_write = nr_dirty + nr_unstable +
|
|
||||||
- (inodes_stat.nr_inodes - inodes_stat.nr_unused);
|
|
||||||
-
|
|
||||||
- bdi_start_writeback(sb->s_bdi, sb, nr_to_write);
|
|
||||||
+ __writeback_inodes_sb(sb, 0);
|
|
||||||
}
|
|
||||||
EXPORT_SYMBOL(writeback_inodes_sb);
|
|
||||||
|
|
||||||
/**
|
|
||||||
+ * writeback_inodes_sb_locked - writeback dirty inodes from given super_block
|
|
||||||
+ * @sb: the superblock
|
|
||||||
+ *
|
|
||||||
+ * Like writeback_inodes_sb(), except the caller already holds the
|
|
||||||
+ * sb umount sem.
|
|
||||||
+ */
|
|
||||||
+void writeback_inodes_sb_locked(struct super_block *sb)
|
|
||||||
+{
|
|
||||||
+ __writeback_inodes_sb(sb, 1);
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
+/**
|
|
||||||
* writeback_inodes_sb_if_idle - start writeback if none underway
|
|
||||||
* @sb: the superblock
|
|
||||||
*
|
|
||||||
diff --git a/fs/sync.c b/fs/sync.c
|
|
||||||
index 92b2281..de6a441 100644
|
|
||||||
--- a/fs/sync.c
|
|
||||||
+++ b/fs/sync.c
|
|
||||||
@@ -42,7 +42,7 @@ static int __sync_filesystem(struct super_block *sb, int wait)
|
|
||||||
if (wait)
|
|
||||||
sync_inodes_sb(sb);
|
|
||||||
else
|
|
||||||
- writeback_inodes_sb(sb);
|
|
||||||
+ writeback_inodes_sb_locked(sb);
|
|
||||||
|
|
||||||
if (sb->s_op->sync_fs)
|
|
||||||
sb->s_op->sync_fs(sb, wait);
|
|
||||||
diff --git a/include/linux/backing-dev.h b/include/linux/backing-dev.h
|
|
||||||
index bd0e3c6..90e677a 100644
|
|
||||||
--- a/include/linux/backing-dev.h
|
|
||||||
+++ b/include/linux/backing-dev.h
|
|
||||||
@@ -103,7 +103,7 @@ int bdi_register_dev(struct backing_dev_info *bdi, dev_t dev);
|
|
||||||
void bdi_unregister(struct backing_dev_info *bdi);
|
|
||||||
int bdi_setup_and_register(struct backing_dev_info *, char *, unsigned int);
|
|
||||||
void bdi_start_writeback(struct backing_dev_info *bdi, struct super_block *sb,
|
|
||||||
- long nr_pages);
|
|
||||||
+ long nr_pages, int sb_locked);
|
|
||||||
int bdi_writeback_task(struct bdi_writeback *wb);
|
|
||||||
int bdi_has_dirty_io(struct backing_dev_info *bdi);
|
|
||||||
|
|
||||||
diff --git a/include/linux/writeback.h b/include/linux/writeback.h
|
|
||||||
index 36520de..3790165 100644
|
|
||||||
--- a/include/linux/writeback.h
|
|
||||||
+++ b/include/linux/writeback.h
|
|
||||||
@@ -65,6 +65,15 @@ struct writeback_control {
|
|
||||||
* so we use a single control to update them
|
|
||||||
*/
|
|
||||||
unsigned no_nrwrite_index_update:1;
|
|
||||||
+
|
|
||||||
+ /*
|
|
||||||
+ * For WB_SYNC_ALL, the sb must always be pinned. For WB_SYNC_NONE,
|
|
||||||
+ * the writeback code will pin the sb for the caller. However,
|
|
||||||
+ * for eg umount, the caller does WB_SYNC_NONE but already has
|
|
||||||
+ * the sb pinned. If the below is set, caller already has the
|
|
||||||
+ * sb pinned.
|
|
||||||
+ */
|
|
||||||
+ unsigned sb_pinned:1;
|
|
||||||
};
|
|
||||||
|
|
||||||
/*
|
|
||||||
@@ -73,6 +82,7 @@ struct writeback_control {
|
|
||||||
struct bdi_writeback;
|
|
||||||
int inode_wait(void *);
|
|
||||||
void writeback_inodes_sb(struct super_block *);
|
|
||||||
+void writeback_inodes_sb_locked(struct super_block *);
|
|
||||||
int writeback_inodes_sb_if_idle(struct super_block *);
|
|
||||||
void sync_inodes_sb(struct super_block *);
|
|
||||||
void writeback_inodes_wbc(struct writeback_control *wbc);
|
|
||||||
diff --git a/mm/page-writeback.c b/mm/page-writeback.c
|
|
||||||
index 0b19943..49d3508 100644
|
|
||||||
--- a/mm/page-writeback.c
|
|
||||||
+++ b/mm/page-writeback.c
|
|
||||||
@@ -597,7 +597,7 @@ static void balance_dirty_pages(struct address_space *mapping,
|
|
||||||
(!laptop_mode && ((global_page_state(NR_FILE_DIRTY)
|
|
||||||
+ global_page_state(NR_UNSTABLE_NFS))
|
|
||||||
> background_thresh)))
|
|
||||||
- bdi_start_writeback(bdi, NULL, 0);
|
|
||||||
+ bdi_start_writeback(bdi, NULL, 0, 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
void set_page_dirty_balance(struct page *page, int page_mkwrite)
|
|
|
@ -1,357 +0,0 @@
|
||||||
From: Stanislaw Gruszka <sgruszka@redhat.com>
|
|
||||||
Date: Mon, 29 Mar 2010 12:18:35 +0200
|
|
||||||
Subject: [PATCH] iwlwifi: manage QoS by mac stack
|
|
||||||
|
|
||||||
commit e61146e36b40fd9d346118c40285913236c329f3 upstream.
|
|
||||||
|
|
||||||
We activate/deactivate QoS and setup default queue parameters in iwlwifi
|
|
||||||
driver. Mac stack do the same, so we do not need repeat that work here.
|
|
||||||
Stack also will tell when disable QoS, this will fix driver when working
|
|
||||||
with older APs, that do not have QoS implemented.
|
|
||||||
|
|
||||||
Patch make "force = true" in iwl_active_qos() assuming we always want
|
|
||||||
to do with QoS what mac stack wish.
|
|
||||||
|
|
||||||
Patch also remove unused qos_cap bits, do not initialize qos_active = 0,
|
|
||||||
as we have it initialized to zero by kzalloc.
|
|
||||||
|
|
||||||
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
|
|
||||||
Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
|
||||||
[bwh: Adjust context for 2.6.34]
|
|
||||||
---
|
|
||||||
drivers/net/wireless/iwlwifi/iwl-agn.c | 15 ---
|
|
||||||
drivers/net/wireless/iwlwifi/iwl-core.c | 142 +++------------------------
|
|
||||||
drivers/net/wireless/iwlwifi/iwl-core.h | 3 +-
|
|
||||||
drivers/net/wireless/iwlwifi/iwl-dev.h | 21 ----
|
|
||||||
drivers/net/wireless/iwlwifi/iwl3945-base.c | 7 --
|
|
||||||
5 files changed, 17 insertions(+), 171 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.c b/drivers/net/wireless/iwlwifi/iwl-agn.c
|
|
||||||
index 3f0fd75..b431e92 100644
|
|
||||||
--- a/drivers/net/wireless/iwlwifi/iwl-agn.c
|
|
||||||
+++ b/drivers/net/wireless/iwlwifi/iwl-agn.c
|
|
||||||
@@ -2531,7 +2531,6 @@ void iwl_post_associate(struct iwl_priv *priv)
|
|
||||||
{
|
|
||||||
struct ieee80211_conf *conf = NULL;
|
|
||||||
int ret = 0;
|
|
||||||
- unsigned long flags;
|
|
||||||
|
|
||||||
if (priv->iw_mode == NL80211_IFTYPE_AP) {
|
|
||||||
IWL_ERR(priv, "%s Should not be called in AP mode\n", __func__);
|
|
||||||
@@ -2612,10 +2611,6 @@ void iwl_post_associate(struct iwl_priv *priv)
|
|
||||||
if (priv->iw_mode == NL80211_IFTYPE_ADHOC)
|
|
||||||
priv->assoc_station_added = 1;
|
|
||||||
|
|
||||||
- spin_lock_irqsave(&priv->lock, flags);
|
|
||||||
- iwl_activate_qos(priv, 0);
|
|
||||||
- spin_unlock_irqrestore(&priv->lock, flags);
|
|
||||||
-
|
|
||||||
/* the chain noise calibration will enabled PM upon completion
|
|
||||||
* If chain noise has already been run, then we need to enable
|
|
||||||
* power management here */
|
|
||||||
@@ -2792,7 +2787,6 @@ static int iwl_mac_tx(struct ieee80211_hw *hw, struct sk_buff *skb)
|
|
||||||
void iwl_config_ap(struct iwl_priv *priv)
|
|
||||||
{
|
|
||||||
int ret = 0;
|
|
||||||
- unsigned long flags;
|
|
||||||
|
|
||||||
if (test_bit(STATUS_EXIT_PENDING, &priv->status))
|
|
||||||
return;
|
|
||||||
@@ -2844,10 +2838,6 @@ void iwl_config_ap(struct iwl_priv *priv)
|
|
||||||
/* restore RXON assoc */
|
|
||||||
priv->staging_rxon.filter_flags |= RXON_FILTER_ASSOC_MSK;
|
|
||||||
iwlcore_commit_rxon(priv);
|
|
||||||
- iwl_reset_qos(priv);
|
|
||||||
- spin_lock_irqsave(&priv->lock, flags);
|
|
||||||
- iwl_activate_qos(priv, 1);
|
|
||||||
- spin_unlock_irqrestore(&priv->lock, flags);
|
|
||||||
iwl_add_bcast_station(priv);
|
|
||||||
}
|
|
||||||
iwl_send_beacon_cmd(priv);
|
|
||||||
@@ -3382,11 +3372,6 @@ static int iwl_init_drv(struct iwl_priv *priv)
|
|
||||||
|
|
||||||
iwl_init_scan_params(priv);
|
|
||||||
|
|
||||||
- iwl_reset_qos(priv);
|
|
||||||
-
|
|
||||||
- priv->qos_data.qos_active = 0;
|
|
||||||
- priv->qos_data.qos_cap.val = 0;
|
|
||||||
-
|
|
||||||
priv->rates_mask = IWL_RATES_MASK;
|
|
||||||
/* Set the tx_power_user_lmt to the lowest power level
|
|
||||||
* this value will get overwritten by channel max power avg
|
|
||||||
diff --git a/drivers/net/wireless/iwlwifi/iwl-core.c b/drivers/net/wireless/iwlwifi/iwl-core.c
|
|
||||||
index 1b4408a..38d19c1 100644
|
|
||||||
--- a/drivers/net/wireless/iwlwifi/iwl-core.c
|
|
||||||
+++ b/drivers/net/wireless/iwlwifi/iwl-core.c
|
|
||||||
@@ -223,17 +223,13 @@ EXPORT_SYMBOL(iwl_hw_detect);
|
|
||||||
/*
|
|
||||||
* QoS support
|
|
||||||
*/
|
|
||||||
-void iwl_activate_qos(struct iwl_priv *priv, u8 force)
|
|
||||||
+static void iwl_update_qos(struct iwl_priv *priv)
|
|
||||||
{
|
|
||||||
if (test_bit(STATUS_EXIT_PENDING, &priv->status))
|
|
||||||
return;
|
|
||||||
|
|
||||||
priv->qos_data.def_qos_parm.qos_flags = 0;
|
|
||||||
|
|
||||||
- if (priv->qos_data.qos_cap.q_AP.queue_request &&
|
|
||||||
- !priv->qos_data.qos_cap.q_AP.txop_request)
|
|
||||||
- priv->qos_data.def_qos_parm.qos_flags |=
|
|
||||||
- QOS_PARAM_FLG_TXOP_TYPE_MSK;
|
|
||||||
if (priv->qos_data.qos_active)
|
|
||||||
priv->qos_data.def_qos_parm.qos_flags |=
|
|
||||||
QOS_PARAM_FLG_UPDATE_EDCA_MSK;
|
|
||||||
@@ -241,118 +237,14 @@ void iwl_activate_qos(struct iwl_priv *priv, u8 force)
|
|
||||||
if (priv->current_ht_config.is_ht)
|
|
||||||
priv->qos_data.def_qos_parm.qos_flags |= QOS_PARAM_FLG_TGN_MSK;
|
|
||||||
|
|
||||||
- if (force || iwl_is_associated(priv)) {
|
|
||||||
- IWL_DEBUG_QOS(priv, "send QoS cmd with Qos active=%d FLAGS=0x%X\n",
|
|
||||||
- priv->qos_data.qos_active,
|
|
||||||
- priv->qos_data.def_qos_parm.qos_flags);
|
|
||||||
+ IWL_DEBUG_QOS(priv, "send QoS cmd with Qos active=%d FLAGS=0x%X\n",
|
|
||||||
+ priv->qos_data.qos_active,
|
|
||||||
+ priv->qos_data.def_qos_parm.qos_flags);
|
|
||||||
|
|
||||||
- iwl_send_cmd_pdu_async(priv, REPLY_QOS_PARAM,
|
|
||||||
- sizeof(struct iwl_qosparam_cmd),
|
|
||||||
- &priv->qos_data.def_qos_parm, NULL);
|
|
||||||
- }
|
|
||||||
+ iwl_send_cmd_pdu_async(priv, REPLY_QOS_PARAM,
|
|
||||||
+ sizeof(struct iwl_qosparam_cmd),
|
|
||||||
+ &priv->qos_data.def_qos_parm, NULL);
|
|
||||||
}
|
|
||||||
-EXPORT_SYMBOL(iwl_activate_qos);
|
|
||||||
-
|
|
||||||
-/*
|
|
||||||
- * AC CWmin CW max AIFSN TXOP Limit TXOP Limit
|
|
||||||
- * (802.11b) (802.11a/g)
|
|
||||||
- * AC_BK 15 1023 7 0 0
|
|
||||||
- * AC_BE 15 1023 3 0 0
|
|
||||||
- * AC_VI 7 15 2 6.016ms 3.008ms
|
|
||||||
- * AC_VO 3 7 2 3.264ms 1.504ms
|
|
||||||
- */
|
|
||||||
-void iwl_reset_qos(struct iwl_priv *priv)
|
|
||||||
-{
|
|
||||||
- u16 cw_min = 15;
|
|
||||||
- u16 cw_max = 1023;
|
|
||||||
- u8 aifs = 2;
|
|
||||||
- bool is_legacy = false;
|
|
||||||
- unsigned long flags;
|
|
||||||
- int i;
|
|
||||||
-
|
|
||||||
- spin_lock_irqsave(&priv->lock, flags);
|
|
||||||
- /* QoS always active in AP and ADHOC mode
|
|
||||||
- * In STA mode wait for association
|
|
||||||
- */
|
|
||||||
- if (priv->iw_mode == NL80211_IFTYPE_ADHOC ||
|
|
||||||
- priv->iw_mode == NL80211_IFTYPE_AP)
|
|
||||||
- priv->qos_data.qos_active = 1;
|
|
||||||
- else
|
|
||||||
- priv->qos_data.qos_active = 0;
|
|
||||||
-
|
|
||||||
- /* check for legacy mode */
|
|
||||||
- if ((priv->iw_mode == NL80211_IFTYPE_ADHOC &&
|
|
||||||
- (priv->active_rate & IWL_OFDM_RATES_MASK) == 0) ||
|
|
||||||
- (priv->iw_mode == NL80211_IFTYPE_STATION &&
|
|
||||||
- (priv->staging_rxon.flags & RXON_FLG_SHORT_SLOT_MSK) == 0)) {
|
|
||||||
- cw_min = 31;
|
|
||||||
- is_legacy = 1;
|
|
||||||
- }
|
|
||||||
-
|
|
||||||
- if (priv->qos_data.qos_active)
|
|
||||||
- aifs = 3;
|
|
||||||
-
|
|
||||||
- /* AC_BE */
|
|
||||||
- priv->qos_data.def_qos_parm.ac[0].cw_min = cpu_to_le16(cw_min);
|
|
||||||
- priv->qos_data.def_qos_parm.ac[0].cw_max = cpu_to_le16(cw_max);
|
|
||||||
- priv->qos_data.def_qos_parm.ac[0].aifsn = aifs;
|
|
||||||
- priv->qos_data.def_qos_parm.ac[0].edca_txop = 0;
|
|
||||||
- priv->qos_data.def_qos_parm.ac[0].reserved1 = 0;
|
|
||||||
-
|
|
||||||
- if (priv->qos_data.qos_active) {
|
|
||||||
- /* AC_BK */
|
|
||||||
- i = 1;
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].cw_min = cpu_to_le16(cw_min);
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].cw_max = cpu_to_le16(cw_max);
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].aifsn = 7;
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].edca_txop = 0;
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].reserved1 = 0;
|
|
||||||
-
|
|
||||||
- /* AC_VI */
|
|
||||||
- i = 2;
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].cw_min =
|
|
||||||
- cpu_to_le16((cw_min + 1) / 2 - 1);
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].cw_max =
|
|
||||||
- cpu_to_le16(cw_min);
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].aifsn = 2;
|
|
||||||
- if (is_legacy)
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].edca_txop =
|
|
||||||
- cpu_to_le16(6016);
|
|
||||||
- else
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].edca_txop =
|
|
||||||
- cpu_to_le16(3008);
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].reserved1 = 0;
|
|
||||||
-
|
|
||||||
- /* AC_VO */
|
|
||||||
- i = 3;
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].cw_min =
|
|
||||||
- cpu_to_le16((cw_min + 1) / 4 - 1);
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].cw_max =
|
|
||||||
- cpu_to_le16((cw_min + 1) / 2 - 1);
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].aifsn = 2;
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].reserved1 = 0;
|
|
||||||
- if (is_legacy)
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].edca_txop =
|
|
||||||
- cpu_to_le16(3264);
|
|
||||||
- else
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].edca_txop =
|
|
||||||
- cpu_to_le16(1504);
|
|
||||||
- } else {
|
|
||||||
- for (i = 1; i < 4; i++) {
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].cw_min =
|
|
||||||
- cpu_to_le16(cw_min);
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].cw_max =
|
|
||||||
- cpu_to_le16(cw_max);
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].aifsn = aifs;
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].edca_txop = 0;
|
|
||||||
- priv->qos_data.def_qos_parm.ac[i].reserved1 = 0;
|
|
||||||
- }
|
|
||||||
- }
|
|
||||||
- IWL_DEBUG_QOS(priv, "set QoS to default \n");
|
|
||||||
-
|
|
||||||
- spin_unlock_irqrestore(&priv->lock, flags);
|
|
||||||
-}
|
|
||||||
-EXPORT_SYMBOL(iwl_reset_qos);
|
|
||||||
|
|
||||||
#define MAX_BIT_RATE_40_MHZ 150 /* Mbps */
|
|
||||||
#define MAX_BIT_RATE_20_MHZ 72 /* Mbps */
|
|
||||||
@@ -1894,12 +1786,6 @@ int iwl_mac_conf_tx(struct ieee80211_hw *hw, u16 queue,
|
|
||||||
cpu_to_le16((params->txop * 32));
|
|
||||||
|
|
||||||
priv->qos_data.def_qos_parm.ac[q].reserved1 = 0;
|
|
||||||
- priv->qos_data.qos_active = 1;
|
|
||||||
-
|
|
||||||
- if (priv->iw_mode == NL80211_IFTYPE_AP)
|
|
||||||
- iwl_activate_qos(priv, 1);
|
|
||||||
- else if (priv->assoc_id && iwl_is_associated(priv))
|
|
||||||
- iwl_activate_qos(priv, 0);
|
|
||||||
|
|
||||||
spin_unlock_irqrestore(&priv->lock, flags);
|
|
||||||
|
|
||||||
@@ -2170,11 +2056,8 @@ int iwl_mac_beacon_update(struct ieee80211_hw *hw, struct sk_buff *skb)
|
|
||||||
IWL_DEBUG_MAC80211(priv, "leave\n");
|
|
||||||
spin_unlock_irqrestore(&priv->lock, flags);
|
|
||||||
|
|
||||||
- iwl_reset_qos(priv);
|
|
||||||
-
|
|
||||||
priv->cfg->ops->lib->post_associate(priv);
|
|
||||||
|
|
||||||
-
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
EXPORT_SYMBOL(iwl_mac_beacon_update);
|
|
||||||
@@ -2396,6 +2279,15 @@ int iwl_mac_config(struct ieee80211_hw *hw, u32 changed)
|
|
||||||
iwl_set_tx_power(priv, conf->power_level, false);
|
|
||||||
}
|
|
||||||
|
|
||||||
+ if (changed & IEEE80211_CONF_CHANGE_QOS) {
|
|
||||||
+ bool qos_active = !!(conf->flags & IEEE80211_CONF_QOS);
|
|
||||||
+
|
|
||||||
+ spin_lock_irqsave(&priv->lock, flags);
|
|
||||||
+ priv->qos_data.qos_active = qos_active;
|
|
||||||
+ iwl_update_qos(priv);
|
|
||||||
+ spin_unlock_irqrestore(&priv->lock, flags);
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
if (!iwl_is_ready(priv)) {
|
|
||||||
IWL_DEBUG_MAC80211(priv, "leave - not ready\n");
|
|
||||||
goto out;
|
|
||||||
@@ -2430,8 +2322,6 @@ void iwl_mac_reset_tsf(struct ieee80211_hw *hw)
|
|
||||||
memset(&priv->current_ht_config, 0, sizeof(struct iwl_ht_config));
|
|
||||||
spin_unlock_irqrestore(&priv->lock, flags);
|
|
||||||
|
|
||||||
- iwl_reset_qos(priv);
|
|
||||||
-
|
|
||||||
spin_lock_irqsave(&priv->lock, flags);
|
|
||||||
priv->assoc_id = 0;
|
|
||||||
priv->assoc_capability = 0;
|
|
||||||
diff --git a/drivers/net/wireless/iwlwifi/iwl-core.h b/drivers/net/wireless/iwlwifi/iwl-core.h
|
|
||||||
index 9d7a68f..bc04b43 100644
|
|
||||||
--- a/drivers/net/wireless/iwlwifi/iwl-core.h
|
|
||||||
+++ b/drivers/net/wireless/iwlwifi/iwl-core.h
|
|
||||||
@@ -316,8 +316,7 @@ struct iwl_cfg {
|
|
||||||
struct ieee80211_hw *iwl_alloc_all(struct iwl_cfg *cfg,
|
|
||||||
struct ieee80211_ops *hw_ops);
|
|
||||||
void iwl_hw_detect(struct iwl_priv *priv);
|
|
||||||
-void iwl_reset_qos(struct iwl_priv *priv);
|
|
||||||
-void iwl_activate_qos(struct iwl_priv *priv, u8 force);
|
|
||||||
+void iwl_activate_qos(struct iwl_priv *priv);
|
|
||||||
int iwl_mac_conf_tx(struct ieee80211_hw *hw, u16 queue,
|
|
||||||
const struct ieee80211_tx_queue_params *params);
|
|
||||||
void iwl_set_rxon_hwcrypto(struct iwl_priv *priv, int hw_decrypt);
|
|
||||||
diff --git a/drivers/net/wireless/iwlwifi/iwl-dev.h b/drivers/net/wireless/iwlwifi/iwl-dev.h
|
|
||||||
index 46a5740..7f38d2d 100644
|
|
||||||
--- a/drivers/net/wireless/iwlwifi/iwl-dev.h
|
|
||||||
+++ b/drivers/net/wireless/iwlwifi/iwl-dev.h
|
|
||||||
@@ -476,30 +476,9 @@ struct iwl_ht_config {
|
|
||||||
u8 non_GF_STA_present;
|
|
||||||
};
|
|
||||||
|
|
||||||
-union iwl_qos_capabity {
|
|
||||||
- struct {
|
|
||||||
- u8 edca_count:4; /* bit 0-3 */
|
|
||||||
- u8 q_ack:1; /* bit 4 */
|
|
||||||
- u8 queue_request:1; /* bit 5 */
|
|
||||||
- u8 txop_request:1; /* bit 6 */
|
|
||||||
- u8 reserved:1; /* bit 7 */
|
|
||||||
- } q_AP;
|
|
||||||
- struct {
|
|
||||||
- u8 acvo_APSD:1; /* bit 0 */
|
|
||||||
- u8 acvi_APSD:1; /* bit 1 */
|
|
||||||
- u8 ac_bk_APSD:1; /* bit 2 */
|
|
||||||
- u8 ac_be_APSD:1; /* bit 3 */
|
|
||||||
- u8 q_ack:1; /* bit 4 */
|
|
||||||
- u8 max_len:2; /* bit 5-6 */
|
|
||||||
- u8 more_data_ack:1; /* bit 7 */
|
|
||||||
- } q_STA;
|
|
||||||
- u8 val;
|
|
||||||
-};
|
|
||||||
-
|
|
||||||
/* QoS structures */
|
|
||||||
struct iwl_qos_info {
|
|
||||||
int qos_active;
|
|
||||||
- union iwl_qos_capabity qos_cap;
|
|
||||||
struct iwl_qosparam_cmd def_qos_parm;
|
|
||||||
};
|
|
||||||
|
|
||||||
diff --git a/drivers/net/wireless/iwlwifi/iwl3945-base.c b/drivers/net/wireless/iwlwifi/iwl3945-base.c
|
|
||||||
index 4995134..24c240d 100644
|
|
||||||
--- a/drivers/net/wireless/iwlwifi/iwl3945-base.c
|
|
||||||
+++ b/drivers/net/wireless/iwlwifi/iwl3945-base.c
|
|
||||||
@@ -3140,8 +3140,6 @@ void iwl3945_post_associate(struct iwl_priv *priv)
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
- iwl_activate_qos(priv, 0);
|
|
||||||
-
|
|
||||||
/* we have just associated, don't start scan too early */
|
|
||||||
priv->next_scan_jiffies = jiffies + IWL_DELAY_NEXT_SCAN;
|
|
||||||
}
|
|
||||||
@@ -3889,11 +3887,6 @@ static int iwl3945_init_drv(struct iwl_priv *priv)
|
|
||||||
priv->iw_mode = NL80211_IFTYPE_STATION;
|
|
||||||
priv->missed_beacon_threshold = IWL_MISSED_BEACON_THRESHOLD_DEF;
|
|
||||||
|
|
||||||
- iwl_reset_qos(priv);
|
|
||||||
-
|
|
||||||
- priv->qos_data.qos_active = 0;
|
|
||||||
- priv->qos_data.qos_cap.val = 0;
|
|
||||||
-
|
|
||||||
priv->rates_mask = IWL_RATES_MASK;
|
|
||||||
priv->tx_power_user_lmt = IWL_DEFAULT_TX_POWER;
|
|
||||||
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,98 +0,0 @@
|
||||||
From 79db09cf5ab4099062f2ed19a863db487ef4bf9c Mon Sep 17 00:00:00 2001
|
|
||||||
From: Tejun Heo <tj@kernel.org>
|
|
||||||
Date: Sat, 15 May 2010 19:55:32 +0200
|
|
||||||
Subject: [PATCH 8/8] libata: implement on-demand HPA unlocking
|
|
||||||
|
|
||||||
Implement ata_scsi_unlock_native_capacity() which will be called
|
|
||||||
through SCSI layer when block layer notices that partitions on a
|
|
||||||
device extend beyond the end of the device. It requests EH to unlock
|
|
||||||
HPA, waits for completion and returns the current device capacity.
|
|
||||||
|
|
||||||
This allows libata to unlock HPA on demand instead of having to decide
|
|
||||||
whether to unlock upfront. Unlocking on demand is safer than
|
|
||||||
unlocking by upfront because some BIOSes write private data to the
|
|
||||||
area beyond HPA limit. This was suggested by Ben Hutchings.
|
|
||||||
|
|
||||||
Signed-off-by: Tejun Heo <tj@kernel.org>
|
|
||||||
Suggested-by: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
---
|
|
||||||
drivers/ata/libata-core.c | 1 +
|
|
||||||
drivers/ata/libata-scsi.c | 29 +++++++++++++++++++++++++++++
|
|
||||||
include/linux/libata.h | 2 ++
|
|
||||||
3 files changed, 32 insertions(+), 0 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
|
|
||||||
index 9d6e92d..b0e379d 100644
|
|
||||||
--- a/drivers/ata/libata-core.c
|
|
||||||
+++ b/drivers/ata/libata-core.c
|
|
||||||
@@ -6797,6 +6797,7 @@ EXPORT_SYMBOL_GPL(ata_dummy_port_info);
|
|
||||||
EXPORT_SYMBOL_GPL(ata_link_next);
|
|
||||||
EXPORT_SYMBOL_GPL(ata_dev_next);
|
|
||||||
EXPORT_SYMBOL_GPL(ata_std_bios_param);
|
|
||||||
+EXPORT_SYMBOL_GPL(ata_scsi_unlock_native_capacity);
|
|
||||||
EXPORT_SYMBOL_GPL(ata_host_init);
|
|
||||||
EXPORT_SYMBOL_GPL(ata_host_alloc);
|
|
||||||
EXPORT_SYMBOL_GPL(ata_host_alloc_pinfo);
|
|
||||||
diff --git a/drivers/ata/libata-scsi.c b/drivers/ata/libata-scsi.c
|
|
||||||
index 0088cde..fc51531 100644
|
|
||||||
--- a/drivers/ata/libata-scsi.c
|
|
||||||
+++ b/drivers/ata/libata-scsi.c
|
|
||||||
@@ -415,6 +415,35 @@ int ata_std_bios_param(struct scsi_device *sdev, struct block_device *bdev,
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
+ * ata_scsi_unlock_native_capacity - unlock native capacity
|
|
||||||
+ * @sdev: SCSI device to adjust device capacity for
|
|
||||||
+ *
|
|
||||||
+ * This function is called if a partition on @sdev extends beyond
|
|
||||||
+ * the end of the device. It requests EH to unlock HPA.
|
|
||||||
+ *
|
|
||||||
+ * LOCKING:
|
|
||||||
+ * Defined by the SCSI layer. Might sleep.
|
|
||||||
+ */
|
|
||||||
+void ata_scsi_unlock_native_capacity(struct scsi_device *sdev)
|
|
||||||
+{
|
|
||||||
+ struct ata_port *ap = ata_shost_to_port(sdev->host);
|
|
||||||
+ struct ata_device *dev;
|
|
||||||
+ unsigned long flags;
|
|
||||||
+
|
|
||||||
+ spin_lock_irqsave(ap->lock, flags);
|
|
||||||
+
|
|
||||||
+ dev = ata_scsi_find_dev(ap, sdev);
|
|
||||||
+ if (dev && dev->n_sectors < dev->n_native_sectors) {
|
|
||||||
+ dev->flags |= ATA_DFLAG_UNLOCK_HPA;
|
|
||||||
+ dev->link->eh_info.action |= ATA_EH_RESET;
|
|
||||||
+ ata_port_schedule_eh(ap);
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
+ spin_unlock_irqrestore(ap->lock, flags);
|
|
||||||
+ ata_port_wait_eh(ap);
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
+/**
|
|
||||||
* ata_get_identity - Handler for HDIO_GET_IDENTITY ioctl
|
|
||||||
* @ap: target port
|
|
||||||
* @sdev: SCSI device to get identify data for
|
|
||||||
diff --git a/include/linux/libata.h b/include/linux/libata.h
|
|
||||||
index 242eb26..ab7d6de 100644
|
|
||||||
--- a/include/linux/libata.h
|
|
||||||
+++ b/include/linux/libata.h
|
|
||||||
@@ -1027,6 +1027,7 @@ extern void ata_scsi_simulate(struct ata_device *dev, struct scsi_cmnd *cmd,
|
|
||||||
extern int ata_std_bios_param(struct scsi_device *sdev,
|
|
||||||
struct block_device *bdev,
|
|
||||||
sector_t capacity, int geom[]);
|
|
||||||
+extern void ata_scsi_unlock_native_capacity(struct scsi_device *sdev);
|
|
||||||
extern int ata_scsi_slave_config(struct scsi_device *sdev);
|
|
||||||
extern void ata_scsi_slave_destroy(struct scsi_device *sdev);
|
|
||||||
extern int ata_scsi_change_queue_depth(struct scsi_device *sdev,
|
|
||||||
@@ -1181,6 +1182,7 @@ extern struct device_attribute *ata_common_sdev_attrs[];
|
|
||||||
.slave_configure = ata_scsi_slave_config, \
|
|
||||||
.slave_destroy = ata_scsi_slave_destroy, \
|
|
||||||
.bios_param = ata_std_bios_param, \
|
|
||||||
+ .unlock_native_capacity = ata_scsi_unlock_native_capacity, \
|
|
||||||
.sdev_attrs = ata_common_sdev_attrs
|
|
||||||
|
|
||||||
#define ATA_NCQ_SHT(drv_name) \
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,35 +0,0 @@
|
||||||
From e13b2d1562dcb843852e677a1cb599b94f023604 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Tejun Heo <tj@kernel.org>
|
|
||||||
Date: Sat, 15 May 2010 19:55:32 +0200
|
|
||||||
Subject: [PATCH 7/8] libata: use the enlarged capacity after late HPA unlock
|
|
||||||
|
|
||||||
After late HPA unlock, libata kept using the original capacity
|
|
||||||
ignoring the new larger native capacity. Enlarging device on the fly
|
|
||||||
doesn't cause any harm. Use the larger native capacity instead. This
|
|
||||||
will enable on-demand HPA unlocking.
|
|
||||||
|
|
||||||
Signed-off-by: Tejun Heo <tj@kernel.org>
|
|
||||||
Cc: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
---
|
|
||||||
drivers/ata/libata-core.c | 5 ++---
|
|
||||||
1 files changed, 2 insertions(+), 3 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/ata/libata-core.c b/drivers/ata/libata-core.c
|
|
||||||
index 86f405b..9d6e92d 100644
|
|
||||||
--- a/drivers/ata/libata-core.c
|
|
||||||
+++ b/drivers/ata/libata-core.c
|
|
||||||
@@ -4212,9 +4212,8 @@ int ata_dev_revalidate(struct ata_device *dev, unsigned int new_class,
|
|
||||||
dev->n_sectors > n_sectors && dev->n_sectors == n_native_sectors) {
|
|
||||||
ata_dev_printk(dev, KERN_WARNING,
|
|
||||||
"new n_sectors matches native, probably "
|
|
||||||
- "late HPA unlock, continuing\n");
|
|
||||||
- /* keep using the old n_sectors */
|
|
||||||
- dev->n_sectors = n_sectors;
|
|
||||||
+ "late HPA unlock, n_sectors updated\n");
|
|
||||||
+ /* use the larger n_sectors */
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,51 +0,0 @@
|
||||||
commit 7ba0dea4158155a68b833982199691dbc2d4e6dc
|
|
||||||
Author: Matthew Garrett <mjg@redhat.com>
|
|
||||||
Date: Mon Apr 19 16:51:39 2010 -0400
|
|
||||||
|
|
||||||
acpi: Fall back to manually changing SCI_EN
|
|
||||||
|
|
||||||
The ACPI spec tells us that the ACPI SCI_EN bit is under hardware control
|
|
||||||
and shouldn't be touched by the OS. It seems that the Leading Other OS
|
|
||||||
ignores this and some machines expect this behaviour. We have a blacklist
|
|
||||||
for these, but given that we're able to detect the failure case and the
|
|
||||||
alternative to breaking the spec is letting the machine crash and burn,
|
|
||||||
let's try falling back when we know the alternative is a mostly-dead
|
|
||||||
machine.
|
|
||||||
|
|
||||||
Signed-off-by: Matthew Garrett <mjg@redhat.com>
|
|
||||||
|
|
||||||
diff --git a/drivers/acpi/sleep.c b/drivers/acpi/sleep.c
|
|
||||||
index f74834a..79df8d4 100644
|
|
||||||
--- a/drivers/acpi/sleep.c
|
|
||||||
+++ b/drivers/acpi/sleep.c
|
|
||||||
@@ -227,6 +227,7 @@ static int acpi_suspend_begin(suspend_state_t pm_state)
|
|
||||||
static int acpi_suspend_enter(suspend_state_t pm_state)
|
|
||||||
{
|
|
||||||
acpi_status status = AE_OK;
|
|
||||||
+ acpi_status enable_status = AE_OK;
|
|
||||||
unsigned long flags = 0;
|
|
||||||
u32 acpi_state = acpi_target_sleep_state;
|
|
||||||
|
|
||||||
@@ -254,10 +255,19 @@ static int acpi_suspend_enter(suspend_state_t pm_state)
|
|
||||||
}
|
|
||||||
|
|
||||||
/* If ACPI is not enabled by the BIOS, we need to enable it here. */
|
|
||||||
- if (set_sci_en_on_resume)
|
|
||||||
+ if (!set_sci_en_on_resume)
|
|
||||||
+ enable_status = acpi_enable();
|
|
||||||
+
|
|
||||||
+ if (set_sci_en_on_resume || enable_status == AE_NO_HARDWARE_RESPONSE)
|
|
||||||
+ /* If we're still in legacy mode then we have a problem. The
|
|
||||||
+ * spec tells us that this bit is under hardware control, but
|
|
||||||
+ * there's no plausible way that the OS can transition back to
|
|
||||||
+ * legacy mode so our choices here are to either ignore the
|
|
||||||
+ * spec or crash and burn horribly. The latter doesn't seem
|
|
||||||
+ * like it's ever going to be the preferable choice, so let's
|
|
||||||
+ * live dangerously.
|
|
||||||
+ */
|
|
||||||
acpi_write_bit_register(ACPI_BITREG_SCI_ENABLE, 1);
|
|
||||||
- else
|
|
||||||
- acpi_enable();
|
|
||||||
|
|
||||||
/* Reprogram control registers and execute _BFS */
|
|
||||||
acpi_leave_sleep_state_prep(acpi_state);
|
|
|
@ -1,97 +0,0 @@
|
||||||
From: Stanislaw Gruszka <sgruszka@redhat.com>
|
|
||||||
Date: Mon, 29 Mar 2010 12:18:34 +0200
|
|
||||||
Subject: [PATCH] mac80211: explicitly disable/enable QoS
|
|
||||||
|
|
||||||
commit e1b3ec1a2a336c328c336cfa5485a5f0484cc90d upstream.
|
|
||||||
|
|
||||||
Add interface to disable/enable QoS (aka WMM or WME). Currently drivers
|
|
||||||
enable it explicitly when ->conf_tx method is called, and newer disable.
|
|
||||||
Disabling is needed for some APs, which do not support QoS, such
|
|
||||||
we should send QoS frames to them.
|
|
||||||
|
|
||||||
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
|
|
||||||
Signed-off-by: John W. Linville <linville@tuxdriver.com>
|
|
||||||
---
|
|
||||||
include/net/mac80211.h | 5 +++++
|
|
||||||
net/mac80211/mlme.c | 9 ++++++++-
|
|
||||||
net/mac80211/util.c | 5 +++++
|
|
||||||
3 files changed, 18 insertions(+), 1 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/include/net/mac80211.h b/include/net/mac80211.h
|
|
||||||
index ecaae10..dcf3c5f 100644
|
|
||||||
--- a/include/net/mac80211.h
|
|
||||||
+++ b/include/net/mac80211.h
|
|
||||||
@@ -587,11 +587,15 @@ struct ieee80211_rx_status {
|
|
||||||
* may turn the device off as much as possible. Typically, this flag will
|
|
||||||
* be set when an interface is set UP but not associated or scanning, but
|
|
||||||
* it can also be unset in that case when monitor interfaces are active.
|
|
||||||
+ * @IEEE80211_CONF_QOS: Enable 802.11e QoS also know as WMM (Wireless
|
|
||||||
+ * Multimedia). On some drivers (iwlwifi is one of know) we have
|
|
||||||
+ * to enable/disable QoS explicitly.
|
|
||||||
*/
|
|
||||||
enum ieee80211_conf_flags {
|
|
||||||
IEEE80211_CONF_MONITOR = (1<<0),
|
|
||||||
IEEE80211_CONF_PS = (1<<1),
|
|
||||||
IEEE80211_CONF_IDLE = (1<<2),
|
|
||||||
+ IEEE80211_CONF_QOS = (1<<3),
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
@@ -616,6 +620,7 @@ enum ieee80211_conf_changed {
|
|
||||||
IEEE80211_CONF_CHANGE_CHANNEL = BIT(6),
|
|
||||||
IEEE80211_CONF_CHANGE_RETRY_LIMITS = BIT(7),
|
|
||||||
IEEE80211_CONF_CHANGE_IDLE = BIT(8),
|
|
||||||
+ IEEE80211_CONF_CHANGE_QOS = BIT(9),
|
|
||||||
};
|
|
||||||
|
|
||||||
/**
|
|
||||||
diff --git a/net/mac80211/mlme.c b/net/mac80211/mlme.c
|
|
||||||
index 65eafda..c686d1b 100644
|
|
||||||
--- a/net/mac80211/mlme.c
|
|
||||||
+++ b/net/mac80211/mlme.c
|
|
||||||
@@ -586,6 +586,9 @@ static void ieee80211_sta_wmm_params(struct ieee80211_local *local,
|
|
||||||
int count;
|
|
||||||
u8 *pos, uapsd_queues = 0;
|
|
||||||
|
|
||||||
+ if (!local->ops->conf_tx)
|
|
||||||
+ return;
|
|
||||||
+
|
|
||||||
if (local->hw.queues < 4)
|
|
||||||
return;
|
|
||||||
|
|
||||||
@@ -660,11 +663,15 @@ static void ieee80211_sta_wmm_params(struct ieee80211_local *local,
|
|
||||||
params.aifs, params.cw_min, params.cw_max, params.txop,
|
|
||||||
params.uapsd);
|
|
||||||
#endif
|
|
||||||
- if (drv_conf_tx(local, queue, ¶ms) && local->ops->conf_tx)
|
|
||||||
+ if (drv_conf_tx(local, queue, ¶ms))
|
|
||||||
printk(KERN_DEBUG "%s: failed to set TX queue "
|
|
||||||
"parameters for queue %d\n",
|
|
||||||
wiphy_name(local->hw.wiphy), queue);
|
|
||||||
}
|
|
||||||
+
|
|
||||||
+ /* enable WMM or activate new settings */
|
|
||||||
+ local->hw.conf.flags |= IEEE80211_CONF_QOS;
|
|
||||||
+ drv_config(local, IEEE80211_CONF_CHANGE_QOS);
|
|
||||||
}
|
|
||||||
|
|
||||||
static u32 ieee80211_handle_bss_capability(struct ieee80211_sub_if_data *sdata,
|
|
||||||
diff --git a/net/mac80211/util.c b/net/mac80211/util.c
|
|
||||||
index c453226..7b2c170 100644
|
|
||||||
--- a/net/mac80211/util.c
|
|
||||||
+++ b/net/mac80211/util.c
|
|
||||||
@@ -796,6 +796,11 @@ void ieee80211_set_wmm_default(struct ieee80211_sub_if_data *sdata)
|
|
||||||
|
|
||||||
drv_conf_tx(local, queue, &qparam);
|
|
||||||
}
|
|
||||||
+
|
|
||||||
+ /* after reinitialize QoS TX queues setting to default,
|
|
||||||
+ * disable QoS at all */
|
|
||||||
+ local->hw.conf.flags &= ~IEEE80211_CONF_QOS;
|
|
||||||
+ drv_config(local, IEEE80211_CONF_CHANGE_QOS);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ieee80211_sta_def_wmm_params(struct ieee80211_sub_if_data *sdata,
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,164 +0,0 @@
|
||||||
Return-Path: <linux-wireless-owner@vger.kernel.org>
|
|
||||||
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on dual
|
|
||||||
X-Spam-Level:
|
|
||||||
X-Spam-Status: No, score=0.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM,
|
|
||||||
KB_DATE_CONTAINS_TAB autolearn=no version=3.3.1
|
|
||||||
X-Original-To: maks@dual
|
|
||||||
Delivered-To: maks@dual
|
|
||||||
Received: from dual (localhost.localdomain [127.0.0.1])
|
|
||||||
by dual (Postfix) with ESMTP id 6945624045
|
|
||||||
for <maks@dual>; Fri, 23 Apr 2010 04:14:42 +0200 (CEST)
|
|
||||||
X-Original-To: max@stro.at
|
|
||||||
Delivered-To: max@stro.at
|
|
||||||
Received: from baikonur.stro.at [213.239.196.228]
|
|
||||||
by dual with POP3 (fetchmail-6.3.16)
|
|
||||||
for <maks@dual> (single-drop); Fri, 23 Apr 2010 04:14:42 +0200 (CEST)
|
|
||||||
Received: from vger.kernel.org (vger.kernel.org [209.132.180.67])
|
|
||||||
by baikonur.stro.at (Postfix) with ESMTP id 0650F5C00B
|
|
||||||
for <max@stro.at>; Thu, 22 Apr 2010 19:45:05 +0200 (CEST)
|
|
||||||
Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand
|
|
||||||
id S1755708Ab0DVRxA (ORCPT <rfc822;max@stro.at>);
|
|
||||||
Thu, 22 Apr 2010 13:53:00 -0400
|
|
||||||
Received: from mail-pz0-f194.google.com ([209.85.222.194]:37203 "EHLO
|
|
||||||
mail-pz0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org
|
|
||||||
with ESMTP id S1755147Ab0DVRw7 (ORCPT
|
|
||||||
<rfc822;linux-wireless@vger.kernel.org>);
|
|
||||||
Thu, 22 Apr 2010 13:52:59 -0400
|
|
||||||
Received: by pzk32 with SMTP id 32so5663626pzk.21
|
|
||||||
for <linux-wireless@vger.kernel.org>; Thu, 22 Apr 2010 10:52:58 -0700 (PDT)
|
|
||||||
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
|
|
||||||
d=googlemail.com; s=gamma;
|
|
||||||
h=domainkey-signature:received:received:received:received:received
|
|
||||||
:from:to:subject:date:user-agent:cc:mime-version:x-length:x-uid
|
|
||||||
:content-type:content-transfer-encoding:message-id;
|
|
||||||
bh=yJz+c5/JMqOxuMrxk75S5LvVDV5la+16zQVI/xQuosY=;
|
|
||||||
b=krjzx1PwXDglH9BKcI+e7WyvVPwy284xIAAxYojJMM3AkNsVpxCyuUXkzqkrDWaN8Z
|
|
||||||
VwzlJJFO5mYy9ZmQM+utsqENnmIEpQp2eszSxI2cfx36lKpoE71gDBkK1A+vDnClheMv
|
|
||||||
MyFHfI869i03WhBAASw6oe1xhdI1bb4F49zmE=
|
|
||||||
DomainKey-Signature: a=rsa-sha1; c=nofws;
|
|
||||||
d=googlemail.com; s=gamma;
|
|
||||||
h=from:to:subject:date:user-agent:cc:mime-version:x-length:x-uid
|
|
||||||
:content-type:content-transfer-encoding:message-id;
|
|
||||||
b=kLB1kLIJwVvNYqGmlY3Ql+PqUEXjk7KvsSUZSvES9+eYqzjAQYbiuEpl40DM10BSrl
|
|
||||||
Mtdenj+I5Ce2chMF6i1JrzzNFMFz0pUVtqUuAk9iQL9Iuo7eE7DZEOS2X3Vo4xCdRLC1
|
|
||||||
S3ygbtj1GOb1JfYn7ge9GL39GsyCNQBRlfVuA=
|
|
||||||
Received: by 10.141.188.24 with SMTP id q24mr1593520rvp.0.1271958778042;
|
|
||||||
Thu, 22 Apr 2010 10:52:58 -0700 (PDT)
|
|
||||||
Received: from blech.mobile ([72.14.240.9])
|
|
||||||
by mx.google.com with ESMTPS id 22sm156714pzk.13.2010.04.22.10.52.55
|
|
||||||
(version=TLSv1/SSLv3 cipher=RC4-MD5);
|
|
||||||
Thu, 22 Apr 2010 10:52:57 -0700 (PDT)
|
|
||||||
Received: from blech.mobile ([127.0.0.1])
|
|
||||||
by localhost (localhost [127.0.0.1]) (amavisd-new, port 10024)
|
|
||||||
with ESMTP id vx9ld1JknfF5; Thu, 22 Apr 2010 19:52:44 +0200 (CEST)
|
|
||||||
Received: from blech.mobile (localhost [127.0.0.1])
|
|
||||||
by blech.mobile (Postfix) with ESMTP id 80D53342417;
|
|
||||||
Thu, 22 Apr 2010 19:52:44 +0200 (CEST)
|
|
||||||
From: Christian Lamparter <chunkeey@googlemail.com>
|
|
||||||
To: linux-wireless@vger.kernel.org
|
|
||||||
Subject: [PATCH 2/2] p54pci: fix regression from prevent stuck rx-ring on slow system
|
|
||||||
Date: Thu, 22 Apr 2010 19:52:43 +0200
|
|
||||||
User-Agent: KMail/1.12.4 (Linux/2.6.34-rc5-uber-wl; KDE/4.3.4; x86_64; ; )
|
|
||||||
Cc: linville@tuxdriver.com, hdegoede@redhat.com
|
|
||||||
MIME-Version: 1.0
|
|
||||||
X-Length: 4801
|
|
||||||
X-UID: 74
|
|
||||||
Content-Type: text/plain;
|
|
||||||
charset="iso-8859-1"
|
|
||||||
Content-Transfer-Encoding: 7bit
|
|
||||||
Message-Id: <201004221952.44071.chunkeey@googlemail.com>
|
|
||||||
Sender: linux-wireless-owner@vger.kernel.org
|
|
||||||
Precedence: bulk
|
|
||||||
List-ID: <linux-wireless.vger.kernel.org>
|
|
||||||
X-Mailing-List: linux-wireless@vger.kernel.org
|
|
||||||
Content-Length: 4096
|
|
||||||
|
|
||||||
From: Hans de Goede <hdegoede@redhat.com>
|
|
||||||
|
|
||||||
This patch fixes a recently introduced use-after-free regression
|
|
||||||
from "p54pci: prevent stuck rx-ring on slow system".
|
|
||||||
|
|
||||||
Hans de Goede reported a use-after-free regression:
|
|
||||||
>BUG: unable to handle kernel paging request at 6b6b6b6b
|
|
||||||
>IP: [<e122284a>] p54p_check_tx_ring+0x84/0xb1 [p54pci]
|
|
||||||
>*pde = 00000000
|
|
||||||
>Oops: 0000 [#1] SMP
|
|
||||||
>EIP: 0060:[<e122284a>] EFLAGS: 00010286 CPU: 0
|
|
||||||
>EIP is at p54p_check_tx_ring+0x84/0xb1 [p54pci]
|
|
||||||
>EAX: 6b6b6b6b EBX: df10b170 ECX: 00000003 EDX: 00000001
|
|
||||||
>ESI: dc471500 EDI: d8acaeb0 EBP: c098be9c ESP: c098be84
|
|
||||||
> DS: 007b ES: 007b FS: 00d8 GS: 00e0 SS: 0068
|
|
||||||
>Process swapper (pid: 0, ti=c098a000 task=c09ccfe0 task.ti=c098a000)
|
|
||||||
>Call Trace:
|
|
||||||
> [<e1222b02>] ? p54p_tasklet+0xaa/0xb5 [p54pci]
|
|
||||||
> [<c0440568>] ? tasklet_action+0x78/0xcb
|
|
||||||
> [<c0440ed3>] ? __do_softirq+0xbc/0x173
|
|
||||||
|
|
||||||
Quote from comment #17:
|
|
||||||
"The problem is the innocent looking moving of the tx processing to
|
|
||||||
after the rx processing in the tasklet. Quoting from the changelog:
|
|
||||||
This patch does it the same way, except that it also prioritize
|
|
||||||
rx data processing, simply because tx routines *can* wait.
|
|
||||||
|
|
||||||
This is causing an issue with us referencing already freed memory,
|
|
||||||
because some skb's we transmit, we immediately receive back, such
|
|
||||||
as those for reading the eeprom (*) and getting stats.
|
|
||||||
|
|
||||||
What can happen because of the moving of the tx processing to after
|
|
||||||
the rx processing is that when the tasklet first runs after doing a
|
|
||||||
special skb tx (such as eeprom) we've already received the answer
|
|
||||||
to it.
|
|
||||||
|
|
||||||
Then the rx processing ends up calling p54_find_and_unlink_skb to
|
|
||||||
find the matching tx skb for the just received special rx skb and
|
|
||||||
frees the tx skb.
|
|
||||||
|
|
||||||
Then after the processing of the rx skb answer, and thus freeing
|
|
||||||
the tx skb, we go process the completed tx ring entires, and then
|
|
||||||
dereference the free-ed skb, to see if it should free free-ed by
|
|
||||||
p54p_check_tx_ring()."
|
|
||||||
|
|
||||||
Bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=583623
|
|
||||||
Bug-Identified-by: Hans de Goede <hdegoede@redhat.com>
|
|
||||||
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
|
|
||||||
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
|
|
||||||
---
|
|
||||||
diff --git a/drivers/net/wireless/p54/p54pci.c b/drivers/net/wireless/p54/p54pci.c
|
|
||||||
index ca42ccb..07c4528 100644
|
|
||||||
--- a/drivers/net/wireless/p54/p54pci.c
|
|
||||||
+++ b/drivers/net/wireless/p54/p54pci.c
|
|
||||||
@@ -277,6 +277,14 @@ static void p54p_tasklet(unsigned long dev_id)
|
|
||||||
struct p54p_priv *priv = dev->priv;
|
|
||||||
struct p54p_ring_control *ring_control = priv->ring_control;
|
|
||||||
|
|
||||||
+ p54p_check_tx_ring(dev, &priv->tx_idx_mgmt, 3, ring_control->tx_mgmt,
|
|
||||||
+ ARRAY_SIZE(ring_control->tx_mgmt),
|
|
||||||
+ priv->tx_buf_mgmt);
|
|
||||||
+
|
|
||||||
+ p54p_check_tx_ring(dev, &priv->tx_idx_data, 1, ring_control->tx_data,
|
|
||||||
+ ARRAY_SIZE(ring_control->tx_data),
|
|
||||||
+ priv->tx_buf_data);
|
|
||||||
+
|
|
||||||
p54p_check_rx_ring(dev, &priv->rx_idx_mgmt, 2, ring_control->rx_mgmt,
|
|
||||||
ARRAY_SIZE(ring_control->rx_mgmt), priv->rx_buf_mgmt);
|
|
||||||
|
|
||||||
@@ -285,14 +293,6 @@ static void p54p_tasklet(unsigned long dev_id)
|
|
||||||
|
|
||||||
wmb();
|
|
||||||
P54P_WRITE(dev_int, cpu_to_le32(ISL38XX_DEV_INT_UPDATE));
|
|
||||||
-
|
|
||||||
- p54p_check_tx_ring(dev, &priv->tx_idx_mgmt, 3, ring_control->tx_mgmt,
|
|
||||||
- ARRAY_SIZE(ring_control->tx_mgmt),
|
|
||||||
- priv->tx_buf_mgmt);
|
|
||||||
-
|
|
||||||
- p54p_check_tx_ring(dev, &priv->tx_idx_data, 1, ring_control->tx_data,
|
|
||||||
- ARRAY_SIZE(ring_control->tx_data),
|
|
||||||
- priv->tx_buf_data);
|
|
||||||
}
|
|
||||||
|
|
||||||
static irqreturn_t p54p_interrupt(int irq, void *dev_id)
|
|
||||||
--
|
|
||||||
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
|
|
||||||
the body of a message to majordomo@vger.kernel.org
|
|
||||||
More majordomo info at http://vger.kernel.org/majordomo-info.html
|
|
||||||
|
|
|
@ -1,103 +0,0 @@
|
||||||
Return-Path: <linux-wireless-owner@vger.kernel.org>
|
|
||||||
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on dual
|
|
||||||
X-Spam-Level:
|
|
||||||
X-Spam-Status: No, score=0.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM,
|
|
||||||
KB_DATE_CONTAINS_TAB autolearn=no version=3.3.1
|
|
||||||
X-Original-To: maks@dual
|
|
||||||
Delivered-To: maks@dual
|
|
||||||
Received: from dual (localhost.localdomain [127.0.0.1])
|
|
||||||
by dual (Postfix) with ESMTP id 4027E2429D
|
|
||||||
for <maks@dual>; Thu, 15 Apr 2010 14:57:47 +0200 (CEST)
|
|
||||||
X-Original-To: max@stro.at
|
|
||||||
Delivered-To: max@stro.at
|
|
||||||
Received: from baikonur.stro.at [213.239.196.228]
|
|
||||||
by dual with POP3 (fetchmail-6.3.13)
|
|
||||||
for <maks@dual> (single-drop); Thu, 15 Apr 2010 14:57:47 +0200 (CEST)
|
|
||||||
Received: from vger.kernel.org (vger.kernel.org [209.132.180.67])
|
|
||||||
by baikonur.stro.at (Postfix) with ESMTP id 785425C00F
|
|
||||||
for <max@stro.at>; Thu, 15 Apr 2010 14:09:33 +0200 (CEST)
|
|
||||||
Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand
|
|
||||||
id S1752356Ab0DOMRR (ORCPT <rfc822;max@stro.at>);
|
|
||||||
Thu, 15 Apr 2010 08:17:17 -0400
|
|
||||||
Received: from mail-ew0-f220.google.com ([209.85.219.220]:35717 "EHLO
|
|
||||||
mail-ew0-f220.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org
|
|
||||||
with ESMTP id S1752038Ab0DOMRQ (ORCPT
|
|
||||||
<rfc822;linux-wireless@vger.kernel.org>);
|
|
||||||
Thu, 15 Apr 2010 08:17:16 -0400
|
|
||||||
Received: by ewy20 with SMTP id 20so459287ewy.1
|
|
||||||
for <linux-wireless@vger.kernel.org>; Thu, 15 Apr 2010 05:17:15 -0700 (PDT)
|
|
||||||
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
|
|
||||||
d=googlemail.com; s=gamma;
|
|
||||||
h=domainkey-signature:received:received:received:received:received
|
|
||||||
:from:to:subject:date:user-agent:cc:mime-version:content-type
|
|
||||||
:content-transfer-encoding:message-id;
|
|
||||||
bh=p4STqoMJiC6z/cKYzv2Exm9RYHj8L3PhiKgV8V/My+8=;
|
|
||||||
b=Df3+ZF5p9OAOZbcMmdGwwyRhe6KKgy9XnEhFVlpwzN2ifr78NiUNl9AwiYsHd2bCAb
|
|
||||||
DFIq9aj2Lw3AzsJziQaRZjAyi1BCwRHWYVT1z6DAUac3GKAPDbTwg8ci9O31eyKBcbQu
|
|
||||||
3d//ULPy6g8NH7caloyA+ZhU8cmIl93ddMv0I=
|
|
||||||
DomainKey-Signature: a=rsa-sha1; c=nofws;
|
|
||||||
d=googlemail.com; s=gamma;
|
|
||||||
h=from:to:subject:date:user-agent:cc:mime-version:content-type
|
|
||||||
:content-transfer-encoding:message-id;
|
|
||||||
b=n2N7kl6h8TV/cyVhTSMxV505sNe8/00nKdlLKyTn7h0M9MPZhLYgvJms0gr6wMtuoS
|
|
||||||
t78oiQsjdGsh2YMGVes/1eMoISXolb2pGF36Lp3UnoVJtJx5s6aBasGQ0oVUc2PIYozG
|
|
||||||
FyMOuuxhdfOyNOE8iJVAGWVBWLNxyIICBR4tU=
|
|
||||||
Received: by 10.213.2.81 with SMTP id 17mr25407ebi.76.1271333835129;
|
|
||||||
Thu, 15 Apr 2010 05:17:15 -0700 (PDT)
|
|
||||||
Received: from blech.mobile (nat-wh.rz.uni-karlsruhe.de [129.13.72.197])
|
|
||||||
by mx.google.com with ESMTPS id 15sm922586ewy.12.2010.04.15.05.17.14
|
|
||||||
(version=TLSv1/SSLv3 cipher=RC4-MD5);
|
|
||||||
Thu, 15 Apr 2010 05:17:14 -0700 (PDT)
|
|
||||||
Received: from blech.mobile ([127.0.0.1])
|
|
||||||
by localhost (localhost [127.0.0.1]) (amavisd-new, port 10024)
|
|
||||||
with ESMTP id gSWm7mhNvXD9; Thu, 15 Apr 2010 14:17:08 +0200 (CEST)
|
|
||||||
Received: from blech.mobile (localhost [127.0.0.1])
|
|
||||||
by blech.mobile (Postfix) with ESMTP id 6D2D834077B;
|
|
||||||
Thu, 15 Apr 2010 14:17:08 +0200 (CEST)
|
|
||||||
From: Christian Lamparter <chunkeey@googlemail.com>
|
|
||||||
To: linux-wireless@vger.kernel.org
|
|
||||||
Subject: [PATCH] p54pci: fix serious sparse warning
|
|
||||||
Date: Thu, 15 Apr 2010 14:17:07 +0200
|
|
||||||
User-Agent: KMail/1.12.4 (Linux/2.6.34-rc3-uber-wl; KDE/4.3.4; x86_64; ; )
|
|
||||||
Cc: linville@tuxdriver.com
|
|
||||||
MIME-Version: 1.0
|
|
||||||
Content-Type: Text/Plain;
|
|
||||||
charset="iso-8859-1"
|
|
||||||
Content-Transfer-Encoding: 7bit
|
|
||||||
Message-Id: <201004151417.07538.chunkeey@googlemail.com>
|
|
||||||
Sender: linux-wireless-owner@vger.kernel.org
|
|
||||||
Precedence: bulk
|
|
||||||
List-ID: <linux-wireless.vger.kernel.org>
|
|
||||||
X-Mailing-List: linux-wireless@vger.kernel.org
|
|
||||||
X-Virus-Scanned: by Amavis (ClamAV) at stro.at
|
|
||||||
Content-Length: 1202
|
|
||||||
|
|
||||||
This patch fixes a bug which was just recently introduced by
|
|
||||||
("p54pci: prevent stuck rx-ring on slow system").
|
|
||||||
|
|
||||||
make M=drivers/net/wireless/p54 C=2 CF=-D__CHECK_ENDIAN__
|
|
||||||
CHECK drivers/net/wireless/p54/p54pci.c
|
|
||||||
drivers/net/wireless/p54/p54pci.c:143:11: warning: cast to restricted __le32
|
|
||||||
CC [M] drivers/net/wireless/p54/p54pci.o
|
|
||||||
|
|
||||||
Reported-by: Johannes Berg <johannes@sipsolutions.net>
|
|
||||||
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
|
|
||||||
---
|
|
||||||
diff --git a/drivers/net/wireless/p54/p54pci.c b/drivers/net/wireless/p54/p54pci.c
|
|
||||||
index 86f3e9a..679da7e 100644
|
|
||||||
--- a/drivers/net/wireless/p54/p54pci.c
|
|
||||||
+++ b/drivers/net/wireless/p54/p54pci.c
|
|
||||||
@@ -140,7 +140,7 @@ static void p54p_refill_rx_ring(struct ieee80211_hw *dev,
|
|
||||||
|
|
||||||
idx = le32_to_cpu(ring_control->host_idx[ring_index]);
|
|
||||||
limit = idx;
|
|
||||||
- limit -= le32_to_cpu(index);
|
|
||||||
+ limit -= index;
|
|
||||||
limit = ring_limit - limit;
|
|
||||||
|
|
||||||
i = idx % ring_limit;
|
|
||||||
--
|
|
||||||
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
|
|
||||||
the body of a message to majordomo@vger.kernel.org
|
|
||||||
More majordomo info at http://vger.kernel.org/majordomo-info.html
|
|
||||||
|
|
|
@ -1,188 +0,0 @@
|
||||||
Return-Path: <linux-wireless-owner@vger.kernel.org>
|
|
||||||
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on dual
|
|
||||||
X-Spam-Level:
|
|
||||||
X-Spam-Status: No, score=0.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM,
|
|
||||||
KB_DATE_CONTAINS_TAB autolearn=no version=3.3.1
|
|
||||||
X-Original-To: maks@dual
|
|
||||||
Delivered-To: maks@dual
|
|
||||||
Received: from dual (localhost.localdomain [127.0.0.1])
|
|
||||||
by dual (Postfix) with ESMTP id 9C5E5240B2
|
|
||||||
for <maks@dual>; Sat, 10 Apr 2010 05:40:32 +0200 (CEST)
|
|
||||||
X-Original-To: max@stro.at
|
|
||||||
Delivered-To: max@stro.at
|
|
||||||
Received: from baikonur.stro.at [213.239.196.228]
|
|
||||||
by dual with POP3 (fetchmail-6.3.13)
|
|
||||||
for <maks@dual> (single-drop); Sat, 10 Apr 2010 05:40:32 +0200 (CEST)
|
|
||||||
Received: from vger.kernel.org (vger.kernel.org [209.132.180.67])
|
|
||||||
by baikonur.stro.at (Postfix) with ESMTP id 57CCD5C001
|
|
||||||
for <max@stro.at>; Fri, 9 Apr 2010 21:30:10 +0200 (CEST)
|
|
||||||
Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand
|
|
||||||
id S1755774Ab0DIThv (ORCPT <rfc822;max@stro.at>);
|
|
||||||
Fri, 9 Apr 2010 15:37:51 -0400
|
|
||||||
Received: from mail-fx0-f223.google.com ([209.85.220.223]:53451 "EHLO
|
|
||||||
mail-fx0-f223.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org
|
|
||||||
with ESMTP id S1755660Ab0DIThu (ORCPT
|
|
||||||
<rfc822;linux-wireless@vger.kernel.org>);
|
|
||||||
Fri, 9 Apr 2010 15:37:50 -0400
|
|
||||||
Received: by fxm23 with SMTP id 23so3059091fxm.21
|
|
||||||
for <linux-wireless@vger.kernel.org>; Fri, 09 Apr 2010 12:37:48 -0700 (PDT)
|
|
||||||
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
|
|
||||||
d=googlemail.com; s=gamma;
|
|
||||||
h=domainkey-signature:received:received:received:to:subject:cc:from
|
|
||||||
:date:mime-version:content-type:content-transfer-encoding:message-id;
|
|
||||||
bh=/1/MkPwABrV9B+UeF6gm0FPvrdPa07zITP+BiYkzzvw=;
|
|
||||||
b=auJ2WlRwYLTrqH7PVkjv2hQzjgsBbBZysz1x9gVsGRQoOOZ+wTxIkXHmADOz2Clurf
|
|
||||||
qKYgHxxCHnjDu6Xb3kQiYRHAmKFE9O/sRDNyWmVXKU9eLSt47cF16hKkyVPAOs/+g2P7
|
|
||||||
usGYv5VXGKFrTCJwhqjvUCrVeW/6sy2mne5qo=
|
|
||||||
DomainKey-Signature: a=rsa-sha1; c=nofws;
|
|
||||||
d=googlemail.com; s=gamma;
|
|
||||||
h=to:subject:cc:from:date:mime-version:content-type
|
|
||||||
:content-transfer-encoding:message-id;
|
|
||||||
b=jVz41M1Z71WIF8rYp/LErkkyGct/5qylglZrBSMErJB5AC3su/UaeNmI6c+tEXGrmE
|
|
||||||
RYWQDDFlrvqDy7qgL+QmxvU0RgOizjnueLLPZlD3X4dR1O7YN+CuIpK1JJ+6Roa+p2QF
|
|
||||||
e60ozvjRK1DjNk1aahW0hpaZxRDPGrFVxtxwM=
|
|
||||||
Received: by 10.223.6.153 with SMTP id 25mr453117faz.81.1270841868071;
|
|
||||||
Fri, 09 Apr 2010 12:37:48 -0700 (PDT)
|
|
||||||
Received: from debian64.daheim (p5B16D5D6.dip.t-dialin.net [91.22.213.214])
|
|
||||||
by mx.google.com with ESMTPS id e17sm3562248fke.27.2010.04.09.12.37.42
|
|
||||||
(version=TLSv1/SSLv3 cipher=RC4-MD5);
|
|
||||||
Fri, 09 Apr 2010 12:37:42 -0700 (PDT)
|
|
||||||
Received: from debian64.daheim
|
|
||||||
([192.168.0.4] helo=debian64.localnet ident=chuck)
|
|
||||||
by debian64.daheim with esmtpsa (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
|
|
||||||
(Exim 4.71)
|
|
||||||
(envelope-from <chunkeey@googlemail.com>)
|
|
||||||
id 1O0K1N-0002Xr-Ua; Fri, 09 Apr 2010 21:37:41 +0200
|
|
||||||
To: linux-wireless@vger.kernel.org
|
|
||||||
Subject: [PATCH] p54pci: prevent stuck rx-ring on slow system
|
|
||||||
Cc: linville@tuxdriver.com
|
|
||||||
From: Christian Lamparter <chunkeey@googlemail.com>
|
|
||||||
Date: Fri, 9 Apr 2010 21:37:38 +0200
|
|
||||||
MIME-Version: 1.0
|
|
||||||
Content-Type: Text/Plain;
|
|
||||||
charset="iso-8859-1"
|
|
||||||
Content-Transfer-Encoding: 7bit
|
|
||||||
Message-Id: <201004092137.39285.chunkeey@googlemail.com>
|
|
||||||
Sender: linux-wireless-owner@vger.kernel.org
|
|
||||||
Precedence: bulk
|
|
||||||
List-ID: <linux-wireless.vger.kernel.org>
|
|
||||||
X-Mailing-List: linux-wireless@vger.kernel.org
|
|
||||||
X-Virus-Scanned: by Amavis (ClamAV) at stro.at
|
|
||||||
Content-Length: 4420
|
|
||||||
|
|
||||||
From: Quintin Pitts <geek4linux@gmail.com>
|
|
||||||
|
|
||||||
This patch fixes an old problem, which - under certain
|
|
||||||
circumstances - could cause the device to become
|
|
||||||
unresponsive.
|
|
||||||
|
|
||||||
most of p54pci's rx-ring management is implemented in just
|
|
||||||
two distinct standalone functions. p54p_check_rx_ring takes
|
|
||||||
care of processing incoming data, while p54p_refill_rx_ring
|
|
||||||
tries to replenish all depleted communication buffers.
|
|
||||||
|
|
||||||
This has always worked fine on my fast machine, but
|
|
||||||
now I know there is a hidden race...
|
|
||||||
|
|
||||||
The most likely candidate here is ring_control->device_idx.
|
|
||||||
Quintin Pitts had already analyzed the culprit and posted
|
|
||||||
a patch back in Oct 2009. But sadly, no one's picked up on this.
|
|
||||||
( https://patchwork.kernel.org/patch/53079/ [2 & 3] ).
|
|
||||||
This patch does the same way, except that it also prioritize
|
|
||||||
rx data processing, simply because tx routines *can* wait.
|
|
||||||
|
|
||||||
Reported-by: Sean Young <sean@mess.org>
|
|
||||||
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=11386
|
|
||||||
Reported-by: Quintin Pitts <geek4linux@gmail.com>
|
|
||||||
Signed-off-by: Quintin Pitts <geek4linux@gmail.com>
|
|
||||||
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
|
|
||||||
---
|
|
||||||
John,
|
|
||||||
|
|
||||||
It's been nearly a week and no complains or regressions
|
|
||||||
have been reported. Therefore I think it is now save to
|
|
||||||
finally merge this patch... Preferably into -next, so
|
|
||||||
bug #11386 can be closed for 2.6.34 release.
|
|
||||||
|
|
||||||
Regards,
|
|
||||||
Chr
|
|
||||||
---
|
|
||||||
diff --git a/drivers/net/wireless/p54/p54pci.c b/drivers/net/wireless/p54/p54pci.c
|
|
||||||
index ed4bdff..aa29663 100644
|
|
||||||
--- a/drivers/net/wireless/p54/p54pci.c
|
|
||||||
+++ b/drivers/net/wireless/p54/p54pci.c
|
|
||||||
@@ -131,7 +131,7 @@ static int p54p_upload_firmware(struct ieee80211_hw *dev)
|
|
||||||
|
|
||||||
static void p54p_refill_rx_ring(struct ieee80211_hw *dev,
|
|
||||||
int ring_index, struct p54p_desc *ring, u32 ring_limit,
|
|
||||||
- struct sk_buff **rx_buf)
|
|
||||||
+ struct sk_buff **rx_buf, u32 index)
|
|
||||||
{
|
|
||||||
struct p54p_priv *priv = dev->priv;
|
|
||||||
struct p54p_ring_control *ring_control = priv->ring_control;
|
|
||||||
@@ -139,7 +139,7 @@ static void p54p_refill_rx_ring(struct ieee80211_hw *dev,
|
|
||||||
|
|
||||||
idx = le32_to_cpu(ring_control->host_idx[ring_index]);
|
|
||||||
limit = idx;
|
|
||||||
- limit -= le32_to_cpu(ring_control->device_idx[ring_index]);
|
|
||||||
+ limit -= le32_to_cpu(index);
|
|
||||||
limit = ring_limit - limit;
|
|
||||||
|
|
||||||
i = idx % ring_limit;
|
|
||||||
@@ -231,7 +231,7 @@ static void p54p_check_rx_ring(struct ieee80211_hw *dev, u32 *index,
|
|
||||||
i %= ring_limit;
|
|
||||||
}
|
|
||||||
|
|
||||||
- p54p_refill_rx_ring(dev, ring_index, ring, ring_limit, rx_buf);
|
|
||||||
+ p54p_refill_rx_ring(dev, ring_index, ring, ring_limit, rx_buf, *index);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void p54p_check_tx_ring(struct ieee80211_hw *dev, u32 *index,
|
|
||||||
@@ -276,14 +276,6 @@ static void p54p_tasklet(unsigned long dev_id)
|
|
||||||
struct p54p_priv *priv = dev->priv;
|
|
||||||
struct p54p_ring_control *ring_control = priv->ring_control;
|
|
||||||
|
|
||||||
- p54p_check_tx_ring(dev, &priv->tx_idx_mgmt, 3, ring_control->tx_mgmt,
|
|
||||||
- ARRAY_SIZE(ring_control->tx_mgmt),
|
|
||||||
- priv->tx_buf_mgmt);
|
|
||||||
-
|
|
||||||
- p54p_check_tx_ring(dev, &priv->tx_idx_data, 1, ring_control->tx_data,
|
|
||||||
- ARRAY_SIZE(ring_control->tx_data),
|
|
||||||
- priv->tx_buf_data);
|
|
||||||
-
|
|
||||||
p54p_check_rx_ring(dev, &priv->rx_idx_mgmt, 2, ring_control->rx_mgmt,
|
|
||||||
ARRAY_SIZE(ring_control->rx_mgmt), priv->rx_buf_mgmt);
|
|
||||||
|
|
||||||
@@ -292,6 +284,14 @@ static void p54p_tasklet(unsigned long dev_id)
|
|
||||||
|
|
||||||
wmb();
|
|
||||||
P54P_WRITE(dev_int, cpu_to_le32(ISL38XX_DEV_INT_UPDATE));
|
|
||||||
+
|
|
||||||
+ p54p_check_tx_ring(dev, &priv->tx_idx_mgmt, 3, ring_control->tx_mgmt,
|
|
||||||
+ ARRAY_SIZE(ring_control->tx_mgmt),
|
|
||||||
+ priv->tx_buf_mgmt);
|
|
||||||
+
|
|
||||||
+ p54p_check_tx_ring(dev, &priv->tx_idx_data, 1, ring_control->tx_data,
|
|
||||||
+ ARRAY_SIZE(ring_control->tx_data),
|
|
||||||
+ priv->tx_buf_data);
|
|
||||||
}
|
|
||||||
|
|
||||||
static irqreturn_t p54p_interrupt(int irq, void *dev_id)
|
|
||||||
@@ -444,10 +444,10 @@ static int p54p_open(struct ieee80211_hw *dev)
|
|
||||||
priv->rx_idx_mgmt = priv->tx_idx_mgmt = 0;
|
|
||||||
|
|
||||||
p54p_refill_rx_ring(dev, 0, priv->ring_control->rx_data,
|
|
||||||
- ARRAY_SIZE(priv->ring_control->rx_data), priv->rx_buf_data);
|
|
||||||
+ ARRAY_SIZE(priv->ring_control->rx_data), priv->rx_buf_data, 0);
|
|
||||||
|
|
||||||
p54p_refill_rx_ring(dev, 2, priv->ring_control->rx_mgmt,
|
|
||||||
- ARRAY_SIZE(priv->ring_control->rx_mgmt), priv->rx_buf_mgmt);
|
|
||||||
+ ARRAY_SIZE(priv->ring_control->rx_mgmt), priv->rx_buf_mgmt, 0);
|
|
||||||
|
|
||||||
P54P_WRITE(ring_control_base, cpu_to_le32(priv->ring_control_dma));
|
|
||||||
P54P_READ(ring_control_base);
|
|
||||||
--
|
|
||||||
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
|
|
||||||
the body of a message to majordomo@vger.kernel.org
|
|
||||||
More majordomo info at http://vger.kernel.org/majordomo-info.html
|
|
||||||
|
|
|
@ -1,17 +0,0 @@
|
||||||
From: Florian Fainelli <ffainelli@freebox.fr>
|
|
||||||
Subject: [PATCH] PHY: fix typo in bcm63xx PHY driver table
|
|
||||||
Date: Fri, 9 Apr 2010 13:04:45 +0200
|
|
||||||
|
|
||||||
|
|
||||||
Signed-off-by: Florian Fainelli <ffainelli@freebox.fr>
|
|
||||||
---
|
|
||||||
diff --git a/drivers/net/phy/bcm63xx.c b/drivers/net/phy/bcm63xx.c
|
|
||||||
index ac5e498..c128156 100644
|
|
||||||
--- a/drivers/net/phy/bcm63xx.c
|
|
||||||
+++ b/drivers/net/phy/bcm63xx.c
|
|
||||||
@@ -137,4 +137,4 @@ static struct mdio_device_id bcm63xx_tbl[] = {
|
|
||||||
{ }
|
|
||||||
};
|
|
||||||
|
|
||||||
-MODULE_DEVICE_TABLE(mdio, bcm64xx_tbl);
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, bcm63xx_tbl);
|
|
|
@ -1,62 +0,0 @@
|
||||||
From 1c941691a933e9c2d0314c9b84ea77b6ef2807e1 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Date: Fri, 9 Apr 2010 01:55:27 +0100
|
|
||||||
Subject: [PATCH] rndis_host: Poll status channel before control channel
|
|
||||||
|
|
||||||
Some RNDIS devices don't respond on the control channel until polled
|
|
||||||
on the status channel. In particular, this was reported to be the
|
|
||||||
case for the 2Wire HomePortal 1000SW.
|
|
||||||
|
|
||||||
This is roughly based on a patch by John Carr <john.carr@unrouted.co.uk>
|
|
||||||
which is reported to be needed for use with some Windows Mobile devices
|
|
||||||
and which is currently applied by Mandriva.
|
|
||||||
|
|
||||||
Reported-by: Mark Glassberg <vzeeaxwl@myfairpoint.net>
|
|
||||||
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Tested-by: Mark Glassberg <vzeeaxwl@myfairpoint.net>
|
|
||||||
---
|
|
||||||
drivers/net/usb/rndis_host.c | 18 ++++++++++++------
|
|
||||||
1 files changed, 12 insertions(+), 6 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/net/usb/rndis_host.c b/drivers/net/usb/rndis_host.c
|
|
||||||
index f56dec6..52faca1 100644
|
|
||||||
--- a/drivers/net/usb/rndis_host.c
|
|
||||||
+++ b/drivers/net/usb/rndis_host.c
|
|
||||||
@@ -103,8 +103,10 @@ static void rndis_msg_indicate(struct usbnet *dev, struct rndis_indicate *msg,
|
|
||||||
int rndis_command(struct usbnet *dev, struct rndis_msg_hdr *buf, int buflen)
|
|
||||||
{
|
|
||||||
struct cdc_state *info = (void *) &dev->data;
|
|
||||||
+ struct usb_cdc_notification notification;
|
|
||||||
int master_ifnum;
|
|
||||||
int retval;
|
|
||||||
+ int partial;
|
|
||||||
unsigned count;
|
|
||||||
__le32 rsp;
|
|
||||||
u32 xid = 0, msg_len, request_id;
|
|
||||||
@@ -132,13 +134,17 @@ int rndis_command(struct usbnet *dev, struct rndis_msg_hdr *buf, int buflen)
|
|
||||||
if (unlikely(retval < 0 || xid == 0))
|
|
||||||
return retval;
|
|
||||||
|
|
||||||
- // FIXME Seems like some devices discard responses when
|
|
||||||
- // we time out and cancel our "get response" requests...
|
|
||||||
- // so, this is fragile. Probably need to poll for status.
|
|
||||||
+ /* Some devices don't respond on the control channel until
|
|
||||||
+ * polled on the status channel, so do that first. */
|
|
||||||
+ retval = usb_interrupt_msg(
|
|
||||||
+ dev->udev,
|
|
||||||
+ usb_rcvintpipe(dev->udev, dev->status->desc.bEndpointAddress),
|
|
||||||
+ ¬ification, sizeof(notification), &partial,
|
|
||||||
+ RNDIS_CONTROL_TIMEOUT_MS);
|
|
||||||
+ if (unlikely(retval < 0))
|
|
||||||
+ return retval;
|
|
||||||
|
|
||||||
- /* ignore status endpoint, just poll the control channel;
|
|
||||||
- * the request probably completed immediately
|
|
||||||
- */
|
|
||||||
+ /* Poll the control channel; the request probably completed immediately */
|
|
||||||
rsp = buf->msg_type | RNDIS_MSG_COMPLETION;
|
|
||||||
for (count = 0; count < 10; count++) {
|
|
||||||
memset(buf, 0, CONTROL_BUFFER_SIZE);
|
|
||||||
--
|
|
||||||
1.7.0.3
|
|
||||||
|
|
|
@ -1,16 +0,0 @@
|
||||||
From: Matthew Garrett <mjg@redhat.com>
|
|
||||||
Date: Wed Apr 21 14:13:22 2010 UTC
|
|
||||||
Subject: Add EC path for Thinkpad X100
|
|
||||||
|
|
||||||
|
|
||||||
diff -up linux-2.6.32.noarch/drivers/platform/x86/thinkpad_acpi.c.mjg linux-2.6.32.noarch/drivers/platform/x86/thinkpad_acpi.c
|
|
||||||
--- linux-2.6.32.noarch/drivers/platform/x86/thinkpad_acpi.c.mjg 2010-04-21 10:02:53.658034129 -0400
|
|
||||||
+++ linux-2.6.32.noarch/drivers/platform/x86/thinkpad_acpi.c 2010-04-21 10:03:30.402030108 -0400
|
|
||||||
@@ -491,6 +491,7 @@ TPACPI_HANDLE(ec, root, "\\_SB.PCI0.ISA.
|
|
||||||
"\\_SB.PCI0.ISA.EC", /* A21e, A2xm/p, T20-22, X20-21 */
|
|
||||||
"\\_SB.PCI0.AD4S.EC0", /* i1400, R30 */
|
|
||||||
"\\_SB.PCI0.ICH3.EC0", /* R31 */
|
|
||||||
+ "\\_SB.PCI0.LPC0.EC", /* X100e */
|
|
||||||
"\\_SB.PCI0.LPC.EC", /* all others */
|
|
||||||
);
|
|
||||||
|
|
|
@ -1,57 +0,0 @@
|
||||||
From: Dmitry Monakhov <dmonakhov@openvz.org>
|
|
||||||
Date: Fri, 7 May 2010 13:35:44 +0400
|
|
||||||
Subject: [PATCH 3/5] writeback: Update dirty flags in two steps
|
|
||||||
|
|
||||||
commit 5547e8aac6f71505d621a612de2fca0dd988b439 upstream.
|
|
||||||
|
|
||||||
Filesystems with delalloc support may dirty inode during writepages.
|
|
||||||
As result inode will have dirty metadata flags even after write_inode.
|
|
||||||
In fact we have two dedicated functions for proper data and metadata
|
|
||||||
writeback. It is reasonable to separate flags updates in two stages.
|
|
||||||
|
|
||||||
https://bugzilla.kernel.org/show_bug.cgi?id=15906
|
|
||||||
|
|
||||||
Signed-off-by: Dmitry Monakhov <dmonakhov@openvz.org>
|
|
||||||
Reviewed-by: Christoph Hellwig <hch@lst.de>
|
|
||||||
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
|
|
||||||
---
|
|
||||||
fs/fs-writeback.c | 15 +++++++++++----
|
|
||||||
1 files changed, 11 insertions(+), 4 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c
|
|
||||||
index 67db897..0f62957 100644
|
|
||||||
--- a/fs/fs-writeback.c
|
|
||||||
+++ b/fs/fs-writeback.c
|
|
||||||
@@ -460,11 +460,9 @@ writeback_single_inode(struct inode *inode, struct writeback_control *wbc)
|
|
||||||
|
|
||||||
BUG_ON(inode->i_state & I_SYNC);
|
|
||||||
|
|
||||||
- /* Set I_SYNC, reset I_DIRTY */
|
|
||||||
- dirty = inode->i_state & I_DIRTY;
|
|
||||||
+ /* Set I_SYNC, reset I_DIRTY_PAGES */
|
|
||||||
inode->i_state |= I_SYNC;
|
|
||||||
- inode->i_state &= ~I_DIRTY;
|
|
||||||
-
|
|
||||||
+ inode->i_state &= ~I_DIRTY_PAGES;
|
|
||||||
spin_unlock(&inode_lock);
|
|
||||||
|
|
||||||
ret = do_writepages(mapping, wbc);
|
|
||||||
@@ -480,6 +478,15 @@ writeback_single_inode(struct inode *inode, struct writeback_control *wbc)
|
|
||||||
ret = err;
|
|
||||||
}
|
|
||||||
|
|
||||||
+ /*
|
|
||||||
+ * Some filesystems may redirty the inode during the writeback
|
|
||||||
+ * due to delalloc, clear dirty metadata flags right before
|
|
||||||
+ * write_inode()
|
|
||||||
+ */
|
|
||||||
+ spin_lock(&inode_lock);
|
|
||||||
+ dirty = inode->i_state & I_DIRTY;
|
|
||||||
+ inode->i_state &= ~(I_DIRTY_SYNC | I_DIRTY_DATASYNC);
|
|
||||||
+ spin_unlock(&inode_lock);
|
|
||||||
/* Don't write the inode if only I_DIRTY_PAGES was set */
|
|
||||||
if (dirty & (I_DIRTY_SYNC | I_DIRTY_DATASYNC)) {
|
|
||||||
int err = write_inode(inode, wbc);
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,93 +0,0 @@
|
||||||
From: Jens Axboe <jens.axboe@oracle.com>
|
|
||||||
Date: Tue, 18 May 2010 14:29:29 +0200
|
|
||||||
Subject: [PATCH 4/5] writeback: ensure that WB_SYNC_NONE writeback with sb pinned is sync
|
|
||||||
|
|
||||||
commit 7c8a3554c683f512dbcee26faedb42e4c05f12fa upstream.
|
|
||||||
|
|
||||||
Even if the writeout itself isn't a data integrity operation, we need
|
|
||||||
to ensure that the caller doesn't drop the sb umount sem before we
|
|
||||||
have actually done the writeback.
|
|
||||||
|
|
||||||
This is a fixup for commit e913fc82.
|
|
||||||
|
|
||||||
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
|
|
||||||
---
|
|
||||||
fs/fs-writeback.c | 16 +++++++++++-----
|
|
||||||
1 files changed, 11 insertions(+), 5 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c
|
|
||||||
index 0f62957..76f546d 100644
|
|
||||||
--- a/fs/fs-writeback.c
|
|
||||||
+++ b/fs/fs-writeback.c
|
|
||||||
@@ -193,7 +193,8 @@ static void bdi_wait_on_work_clear(struct bdi_work *work)
|
|
||||||
}
|
|
||||||
|
|
||||||
static void bdi_alloc_queue_work(struct backing_dev_info *bdi,
|
|
||||||
- struct wb_writeback_args *args)
|
|
||||||
+ struct wb_writeback_args *args,
|
|
||||||
+ int wait)
|
|
||||||
{
|
|
||||||
struct bdi_work *work;
|
|
||||||
|
|
||||||
@@ -205,6 +206,8 @@ static void bdi_alloc_queue_work(struct backing_dev_info *bdi,
|
|
||||||
if (work) {
|
|
||||||
bdi_work_init(work, args);
|
|
||||||
bdi_queue_work(bdi, work);
|
|
||||||
+ if (wait)
|
|
||||||
+ bdi_wait_on_work_clear(work);
|
|
||||||
} else {
|
|
||||||
struct bdi_writeback *wb = &bdi->wb;
|
|
||||||
|
|
||||||
@@ -279,7 +282,7 @@ void bdi_start_writeback(struct backing_dev_info *bdi, struct super_block *sb,
|
|
||||||
args.for_background = 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
- bdi_alloc_queue_work(bdi, &args);
|
|
||||||
+ bdi_alloc_queue_work(bdi, &args, sb_locked);
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
@@ -909,6 +912,7 @@ long wb_do_writeback(struct bdi_writeback *wb, int force_wait)
|
|
||||||
|
|
||||||
while ((work = get_next_work_item(bdi, wb)) != NULL) {
|
|
||||||
struct wb_writeback_args args = work->args;
|
|
||||||
+ int post_clear;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Override sync mode, in case we must wait for completion
|
|
||||||
@@ -916,11 +920,13 @@ long wb_do_writeback(struct bdi_writeback *wb, int force_wait)
|
|
||||||
if (force_wait)
|
|
||||||
work->args.sync_mode = args.sync_mode = WB_SYNC_ALL;
|
|
||||||
|
|
||||||
+ post_clear = WB_SYNC_ALL || args.sb_pinned;
|
|
||||||
+
|
|
||||||
/*
|
|
||||||
* If this isn't a data integrity operation, just notify
|
|
||||||
* that we have seen this work and we are now starting it.
|
|
||||||
*/
|
|
||||||
- if (args.sync_mode == WB_SYNC_NONE)
|
|
||||||
+ if (!post_clear)
|
|
||||||
wb_clear_pending(wb, work);
|
|
||||||
|
|
||||||
wrote += wb_writeback(wb, &args);
|
|
||||||
@@ -929,7 +935,7 @@ long wb_do_writeback(struct bdi_writeback *wb, int force_wait)
|
|
||||||
* This is a data integrity writeback, so only do the
|
|
||||||
* notification when we have completed the work.
|
|
||||||
*/
|
|
||||||
- if (args.sync_mode == WB_SYNC_ALL)
|
|
||||||
+ if (post_clear)
|
|
||||||
wb_clear_pending(wb, work);
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -1000,7 +1006,7 @@ static void bdi_writeback_all(struct super_block *sb, long nr_pages)
|
|
||||||
if (!bdi_has_dirty_io(bdi))
|
|
||||||
continue;
|
|
||||||
|
|
||||||
- bdi_alloc_queue_work(bdi, &args);
|
|
||||||
+ bdi_alloc_queue_work(bdi, &args, 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
rcu_read_unlock();
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,28 +0,0 @@
|
||||||
From: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
|
|
||||||
Subject: [PATCH] writeback: fix non-integrity write-back
|
|
||||||
Date: Wed, 26 May 2010 16:08:40 +0300
|
|
||||||
|
|
||||||
This is a fix for commit 7c8a3554. Note, I only compile-tested
|
|
||||||
this.
|
|
||||||
|
|
||||||
Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
|
|
||||||
---
|
|
||||||
fs/fs-writeback.c | 2 +-
|
|
||||||
1 files changed, 1 insertions(+), 1 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c
|
|
||||||
index ea8592b..0242855 100644
|
|
||||||
--- a/fs/fs-writeback.c
|
|
||||||
+++ b/fs/fs-writeback.c
|
|
||||||
@@ -920,7 +920,7 @@ long wb_do_writeback(struct bdi_writeback *wb, int force_wait)
|
|
||||||
if (force_wait)
|
|
||||||
work->args.sync_mode = args.sync_mode = WB_SYNC_ALL;
|
|
||||||
|
|
||||||
- post_clear = WB_SYNC_ALL || args.sb_pinned;
|
|
||||||
+ post_clear = args.sync_mode == WB_SYNC_ALL || args.sb_pinned;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* If this isn't a data integrity operation, just notify
|
|
||||||
--
|
|
||||||
1.6.6.1
|
|
||||||
|
|
|
@ -1,33 +0,0 @@
|
||||||
From 550f0d922286556c7ea43974bb7921effb5a5278 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Helge Deller <deller@gmx.de>
|
|
||||||
Date: Mon, 3 May 2010 20:44:21 +0000
|
|
||||||
Subject: [PATCH] parisc: clear floating point exception flag on SIGFPE signal
|
|
||||||
|
|
||||||
Clear the floating point exception flag before returning to
|
|
||||||
user space. This is needed, else the libc trampoline handler
|
|
||||||
may hit the same SIGFPE again while building up a trampoline
|
|
||||||
to a signal handler.
|
|
||||||
|
|
||||||
Fixes debian bug #559406.
|
|
||||||
|
|
||||||
Signed-off-by: Helge Deller <deller@gmx.de>
|
|
||||||
Signed-off-by: Kyle McMartin <kyle@mcmartin.ca>
|
|
||||||
---
|
|
||||||
arch/parisc/math-emu/decode_exc.c | 1 +
|
|
||||||
1 files changed, 1 insertions(+), 0 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/arch/parisc/math-emu/decode_exc.c b/arch/parisc/math-emu/decode_exc.c
|
|
||||||
index 3ca1c61..27a7492 100644
|
|
||||||
--- a/arch/parisc/math-emu/decode_exc.c
|
|
||||||
+++ b/arch/parisc/math-emu/decode_exc.c
|
|
||||||
@@ -342,6 +342,7 @@ decode_fpu(unsigned int Fpu_register[], unsigned int trap_counts[])
|
|
||||||
return SIGNALCODE(SIGFPE, FPE_FLTINV);
|
|
||||||
case DIVISIONBYZEROEXCEPTION:
|
|
||||||
update_trap_counts(Fpu_register, aflags, bflags, trap_counts);
|
|
||||||
+ Clear_excp_register(exception_index);
|
|
||||||
return SIGNALCODE(SIGFPE, FPE_FLTDIV);
|
|
||||||
case INEXACTEXCEPTION:
|
|
||||||
update_trap_counts(Fpu_register, aflags, bflags, trap_counts);
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,61 +0,0 @@
|
||||||
From: Aurelien Jarno <aurelien@aurel32.net>
|
|
||||||
Date: Mon, 31 May 2010 21:45:48 +0000 (+0000)
|
|
||||||
Subject: clocksource: sh_tmu: compute mult and shift before registration
|
|
||||||
|
|
||||||
commit 66f49121ffa41a19c59965b31b046d8368fec3c7 upstream.
|
|
||||||
|
|
||||||
clocksource: sh_tmu: compute mult and shift before registration
|
|
||||||
|
|
||||||
Since commit 98962465ed9e6ea99c38e0af63fe1dcb5a79dc25 ("nohz: Prevent
|
|
||||||
clocksource wrapping during idle"), the CPU of an R2D board never goes
|
|
||||||
to idle. This commit assumes that mult and shift are assigned before
|
|
||||||
the clocksource is registered. As a consequence the safe maximum sleep
|
|
||||||
time is negative and the CPU never goes into idle.
|
|
||||||
|
|
||||||
This patch fixes the problem by moving mult and shift initialization
|
|
||||||
from sh_tmu_clocksource_enable() to sh_tmu_register_clocksource().
|
|
||||||
|
|
||||||
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
|
|
||||||
Cc: stable@kernel.org
|
|
||||||
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
|
|
||||||
---
|
|
||||||
|
|
||||||
diff --git a/drivers/clocksource/sh_tmu.c b/drivers/clocksource/sh_tmu.c
|
|
||||||
index 8e44e14..de71590 100644
|
|
||||||
--- a/drivers/clocksource/sh_tmu.c
|
|
||||||
+++ b/drivers/clocksource/sh_tmu.c
|
|
||||||
@@ -199,16 +199,8 @@ static cycle_t sh_tmu_clocksource_read(struct clocksource *cs)
|
|
||||||
static int sh_tmu_clocksource_enable(struct clocksource *cs)
|
|
||||||
{
|
|
||||||
struct sh_tmu_priv *p = cs_to_sh_tmu(cs);
|
|
||||||
- int ret;
|
|
||||||
-
|
|
||||||
- ret = sh_tmu_enable(p);
|
|
||||||
- if (ret)
|
|
||||||
- return ret;
|
|
||||||
|
|
||||||
- /* TODO: calculate good shift from rate and counter bit width */
|
|
||||||
- cs->shift = 10;
|
|
||||||
- cs->mult = clocksource_hz2mult(p->rate, cs->shift);
|
|
||||||
- return 0;
|
|
||||||
+ return sh_tmu_enable(p);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void sh_tmu_clocksource_disable(struct clocksource *cs)
|
|
||||||
@@ -228,6 +220,16 @@
|
|
||||||
cs->disable = sh_tmu_clocksource_disable;
|
|
||||||
cs->mask = CLOCKSOURCE_MASK(32);
|
|
||||||
cs->flags = CLOCK_SOURCE_IS_CONTINUOUS;
|
|
||||||
+
|
|
||||||
+ /* clk_get_rate() needs an enabled clock */
|
|
||||||
+ clk_enable(p->clk);
|
|
||||||
+ /* channel will be configured at parent clock / 4 */
|
|
||||||
+ p->rate = clk_get_rate(p->clk) / 4;
|
|
||||||
+ clk_disable(p->clk);
|
|
||||||
+ /* TODO: calculate good shift from rate and counter bit width */
|
|
||||||
+ cs->shift = 10;
|
|
||||||
+ cs->mult = clocksource_hz2mult(p->rate, cs->shift);
|
|
||||||
+
|
|
||||||
pr_info("sh_tmu: %s used as clock source\n", cs->name);
|
|
||||||
clocksource_register(cs);
|
|
||||||
return 0;
|
|
|
@ -1,42 +0,0 @@
|
||||||
From c0613ff21bef2595aebd8f33f36e52a7528e8cb0 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Date: Wed, 7 Apr 2010 03:22:51 +0100
|
|
||||||
Subject: [PATCH] PCI: Disable MSI for MCP55 on P5N32-E SLI
|
|
||||||
|
|
||||||
As reported in <http://bugs.debian.org/552299>, MSI appears to be
|
|
||||||
broken for this on-board device. We already have a quirk for the
|
|
||||||
P5N32-SLI Premium; extend it to cover both variants of the board.
|
|
||||||
|
|
||||||
Reported-by: Romain DEGEZ <romain.degez@smartjog.com>
|
|
||||||
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
---
|
|
||||||
drivers/pci/quirks.c | 7 ++++---
|
|
||||||
1 files changed, 4 insertions(+), 3 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/pci/quirks.c b/drivers/pci/quirks.c
|
|
||||||
index 27c0e6e..4807825 100644
|
|
||||||
--- a/drivers/pci/quirks.c
|
|
||||||
+++ b/drivers/pci/quirks.c
|
|
||||||
@@ -2218,15 +2218,16 @@ DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_SERVERWORKS,
|
|
||||||
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_8132_BRIDGE,
|
|
||||||
ht_enable_msi_mapping);
|
|
||||||
|
|
||||||
-/* The P5N32-SLI Premium motherboard from Asus has a problem with msi
|
|
||||||
+/* The P5N32-SLI motherboards from Asus have a problem with msi
|
|
||||||
* for the MCP55 NIC. It is not yet determined whether the msi problem
|
|
||||||
* also affects other devices. As for now, turn off msi for this device.
|
|
||||||
*/
|
|
||||||
static void __devinit nvenet_msi_disable(struct pci_dev *dev)
|
|
||||||
{
|
|
||||||
- if (dmi_name_in_vendors("P5N32-SLI PREMIUM")) {
|
|
||||||
+ if (dmi_name_in_vendors("P5N32-SLI PREMIUM") ||
|
|
||||||
+ dmi_name_in_vendors("P5N32-E SLI")) {
|
|
||||||
dev_info(&dev->dev,
|
|
||||||
- "Disabling msi for MCP55 NIC on P5N32-SLI Premium\n");
|
|
||||||
+ "Disabling msi for MCP55 NIC on P5N32-SLI\n");
|
|
||||||
dev->no_msi = 1;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
--
|
|
||||||
1.7.0.3
|
|
||||||
|
|
|
@ -1,89 +0,0 @@
|
||||||
Subject: [PATCH 2/2] amd64-agp: Probe unknown AGP devices the right way
|
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
To: David Airlie <airlied@linux.ie>
|
|
||||||
Cc: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>, Greg Kroah-Hartman <gregkh@suse.de>, LKML <linux-kernel@vger.kernel.org>
|
|
||||||
Date: Wed, 24 Mar 2010 03:36:32 +0000
|
|
||||||
|
|
||||||
The current initialisation code probes 'unsupported' AGP devices
|
|
||||||
simply by calling its own probe function. It does not lock these
|
|
||||||
devices or even check whether another driver is already bound to
|
|
||||||
them.
|
|
||||||
|
|
||||||
We must use the device core to manage this. So if the specific
|
|
||||||
device id table didn't match anything and agp_try_unsupported=1,
|
|
||||||
switch the device id table and call driver_attach() again.
|
|
||||||
|
|
||||||
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
---
|
|
||||||
drivers/char/agp/amd64-agp.c | 27 +++++++++++++++------------
|
|
||||||
1 files changed, 15 insertions(+), 12 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/char/agp/amd64-agp.c b/drivers/char/agp/amd64-agp.c
|
|
||||||
index fd50ead..93f56d6 100644
|
|
||||||
--- a/drivers/char/agp/amd64-agp.c
|
|
||||||
+++ b/drivers/char/agp/amd64-agp.c
|
|
||||||
@@ -499,6 +499,10 @@ static int __devinit agp_amd64_probe(struct pci_dev *pdev,
|
|
||||||
u8 cap_ptr;
|
|
||||||
int err;
|
|
||||||
|
|
||||||
+ /* The Highlander principle */
|
|
||||||
+ if (agp_bridges_found)
|
|
||||||
+ return -ENODEV;
|
|
||||||
+
|
|
||||||
cap_ptr = pci_find_capability(pdev, PCI_CAP_ID_AGP);
|
|
||||||
if (!cap_ptr)
|
|
||||||
return -ENODEV;
|
|
||||||
@@ -562,6 +566,8 @@ static void __devexit agp_amd64_remove(struct pci_dev *pdev)
|
|
||||||
amd64_aperture_sizes[bridge->aperture_size_idx].size);
|
|
||||||
agp_remove_bridge(bridge);
|
|
||||||
agp_put_bridge(bridge);
|
|
||||||
+
|
|
||||||
+ agp_bridges_found--;
|
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef CONFIG_PM
|
|
||||||
@@ -709,6 +715,11 @@ static struct pci_device_id agp_amd64_pci_table[] = {
|
|
||||||
|
|
||||||
MODULE_DEVICE_TABLE(pci, agp_amd64_pci_table);
|
|
||||||
|
|
||||||
+static DEFINE_PCI_DEVICE_TABLE(agp_amd64_pci_promisc_table) = {
|
|
||||||
+ { PCI_DEVICE_CLASS(0, 0) },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
static struct pci_driver agp_amd64_pci_driver = {
|
|
||||||
.name = "agpgart-amd64",
|
|
||||||
.id_table = agp_amd64_pci_table,
|
|
||||||
@@ -734,7 +745,6 @@ int __init agp_amd64_init(void)
|
|
||||||
return err;
|
|
||||||
|
|
||||||
if (agp_bridges_found == 0) {
|
|
||||||
- struct pci_dev *dev;
|
|
||||||
if (!agp_try_unsupported && !agp_try_unsupported_boot) {
|
|
||||||
printk(KERN_INFO PFX "No supported AGP bridge found.\n");
|
|
||||||
#ifdef MODULE
|
|
||||||
@@ -750,17 +760,10 @@ int __init agp_amd64_init(void)
|
|
||||||
return -ENODEV;
|
|
||||||
|
|
||||||
/* Look for any AGP bridge */
|
|
||||||
- dev = NULL;
|
|
||||||
- err = -ENODEV;
|
|
||||||
- for_each_pci_dev(dev) {
|
|
||||||
- if (!pci_find_capability(dev, PCI_CAP_ID_AGP))
|
|
||||||
- continue;
|
|
||||||
- /* Only one bridge supported right now */
|
|
||||||
- if (agp_amd64_probe(dev, NULL) == 0) {
|
|
||||||
- err = 0;
|
|
||||||
- break;
|
|
||||||
- }
|
|
||||||
- }
|
|
||||||
+ agp_amd64_pci_driver.id_table = agp_amd64_pci_promisc_table;
|
|
||||||
+ err = driver_attach(&agp_amd64_pci_driver.driver);
|
|
||||||
+ if (err == 0 && agp_bridges_found == 0)
|
|
||||||
+ err = -ENODEV;
|
|
||||||
}
|
|
||||||
return err;
|
|
||||||
}
|
|
||||||
--
|
|
||||||
1.7.0
|
|
||||||
|
|
|
@ -1,37 +0,0 @@
|
||||||
Subject: [PATCH 1/2] sis-agp: Remove SIS 760, handled by amd64-agp
|
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
To: David Airlie <airlied@linux.ie>
|
|
||||||
Cc: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>, LKML <linux-kernel@vger.kernel.org>
|
|
||||||
Date: Wed, 24 Mar 2010 03:33:48 +0000
|
|
||||||
|
|
||||||
SIS 760 is listed in the device tables for both amd64-agp and sis-agp.
|
|
||||||
amd64-agp is apparently preferable since it has workarounds for some
|
|
||||||
BIOS misconfigurations that sis-agp doesn't handle.
|
|
||||||
|
|
||||||
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
---
|
|
||||||
drivers/char/agp/sis-agp.c | 8 --------
|
|
||||||
1 files changed, 0 insertions(+), 8 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/char/agp/sis-agp.c b/drivers/char/agp/sis-agp.c
|
|
||||||
index 6c3837a..95fdd4d 100644
|
|
||||||
--- a/drivers/char/agp/sis-agp.c
|
|
||||||
+++ b/drivers/char/agp/sis-agp.c
|
|
||||||
@@ -415,14 +415,6 @@ static struct pci_device_id agp_sis_pci_table[] = {
|
|
||||||
.subvendor = PCI_ANY_ID,
|
|
||||||
.subdevice = PCI_ANY_ID,
|
|
||||||
},
|
|
||||||
- {
|
|
||||||
- .class = (PCI_CLASS_BRIDGE_HOST << 8),
|
|
||||||
- .class_mask = ~0,
|
|
||||||
- .vendor = PCI_VENDOR_ID_SI,
|
|
||||||
- .device = PCI_DEVICE_ID_SI_760,
|
|
||||||
- .subvendor = PCI_ANY_ID,
|
|
||||||
- .subdevice = PCI_ANY_ID,
|
|
||||||
- },
|
|
||||||
{ }
|
|
||||||
};
|
|
||||||
|
|
||||||
--
|
|
||||||
1.7.0
|
|
||||||
|
|
|
@ -1,63 +0,0 @@
|
||||||
From 3b33fb5615618bb666f2dea6713b4e888e2eae7a Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Date: Mon, 17 Aug 2009 01:18:50 +0100
|
|
||||||
Subject: [PATCH 1/3] ib_ipath: Disable support for IBA7220
|
|
||||||
|
|
||||||
IBA7220 requires non-free firmware which is about to be removed.
|
|
||||||
---
|
|
||||||
drivers/infiniband/hw/ipath/Makefile | 8 ++++----
|
|
||||||
drivers/infiniband/hw/ipath/ipath_driver.c | 4 ++++
|
|
||||||
2 files changed, 8 insertions(+), 4 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/infiniband/hw/ipath/Makefile b/drivers/infiniband/hw/ipath/Makefile
|
|
||||||
index bf94500..42d8d4c 100644
|
|
||||||
--- a/drivers/infiniband/hw/ipath/Makefile
|
|
||||||
+++ b/drivers/infiniband/hw/ipath/Makefile
|
|
||||||
@@ -29,10 +29,10 @@ ib_ipath-y := \
|
|
||||||
ipath_user_pages.o \
|
|
||||||
ipath_user_sdma.o \
|
|
||||||
ipath_verbs_mcast.o \
|
|
||||||
- ipath_verbs.o \
|
|
||||||
- ipath_iba7220.o \
|
|
||||||
- ipath_sd7220.o \
|
|
||||||
- ipath_sd7220_img.o
|
|
||||||
+ ipath_verbs.o
|
|
||||||
+
|
|
||||||
+# IBA7220 depends on firmware to be removed
|
|
||||||
+ib_ipath-$(CONFIG_BROKEN) += ipath_iba7220.o ipath_sd7220.o
|
|
||||||
|
|
||||||
ib_ipath-$(CONFIG_HT_IRQ) += ipath_iba6110.o
|
|
||||||
ib_ipath-$(CONFIG_PCI_MSI) += ipath_iba6120.o
|
|
||||||
diff --git a/drivers/infiniband/hw/ipath/ipath_driver.c b/drivers/infiniband/hw/ipath/ipath_driver.c
|
|
||||||
index 04e88b6..20407a0 100644
|
|
||||||
--- a/drivers/infiniband/hw/ipath/ipath_driver.c
|
|
||||||
+++ b/drivers/infiniband/hw/ipath/ipath_driver.c
|
|
||||||
@@ -140,7 +140,9 @@ static int __devinit ipath_init_one(struct pci_dev *,
|
|
||||||
static const struct pci_device_id ipath_pci_tbl[] = {
|
|
||||||
{ PCI_DEVICE(PCI_VENDOR_ID_PATHSCALE, PCI_DEVICE_ID_INFINIPATH_HT) },
|
|
||||||
{ PCI_DEVICE(PCI_VENDOR_ID_PATHSCALE, PCI_DEVICE_ID_INFINIPATH_PE800) },
|
|
||||||
+#ifdef CONFIG_BROKEN
|
|
||||||
{ PCI_DEVICE(PCI_VENDOR_ID_QLOGIC, PCI_DEVICE_ID_INFINIPATH_7220) },
|
|
||||||
+#endif
|
|
||||||
{ 0, }
|
|
||||||
};
|
|
||||||
|
|
||||||
@@ -535,6 +537,7 @@ static int __devinit ipath_init_one(struct pci_dev *pdev,
|
|
||||||
"CONFIG_PCI_MSI is not enabled\n", ent->device);
|
|
||||||
return -ENODEV;
|
|
||||||
#endif
|
|
||||||
+#ifdef CONFIG_BROKEN
|
|
||||||
case PCI_DEVICE_ID_INFINIPATH_7220:
|
|
||||||
#ifndef CONFIG_PCI_MSI
|
|
||||||
ipath_dbg("CONFIG_PCI_MSI is not enabled, "
|
|
||||||
@@ -542,6 +545,7 @@ static int __devinit ipath_init_one(struct pci_dev *pdev,
|
|
||||||
#endif
|
|
||||||
ipath_init_iba7220_funcs(dd);
|
|
||||||
break;
|
|
||||||
+#endif
|
|
||||||
default:
|
|
||||||
ipath_dev_err(dd, "Found unknown QLogic deviceid 0x%x, "
|
|
||||||
"failing\n", ent->device);
|
|
||||||
--
|
|
||||||
1.6.3.3
|
|
||||||
|
|
|
@ -1,10 +0,0 @@
|
||||||
diff --git a/drivers/staging/rtl8192su/Kconfig b/drivers/staging/rtl8192su/Kconfig
|
|
||||||
index 123fa6d..5e081b1 100644
|
|
||||||
--- a/drivers/staging/rtl8192su/Kconfig
|
|
||||||
+++ b/drivers/staging/rtl8192su/Kconfig
|
|
||||||
@@ -2,5 +2,6 @@ config RTL8192SU
|
|
||||||
tristate "RealTek RTL8192SU Wireless LAN NIC driver"
|
|
||||||
depends on PCI && WLAN && USB
|
|
||||||
+ depends on BROKEN
|
|
||||||
select WIRELESS_EXT
|
|
||||||
select WEXT_PRIV
|
|
|
@ -1,12 +1,10 @@
|
||||||
diff --git a/drivers/staging/wlags49_h2/Kconfig b/drivers/staging/wlags49_h2/Kconfig
|
|
||||||
index 92053fe..b99b1b1 100644
|
|
||||||
--- a/drivers/staging/wlags49_h2/Kconfig
|
--- a/drivers/staging/wlags49_h2/Kconfig
|
||||||
+++ b/drivers/staging/wlags49_h2/Kconfig
|
+++ b/drivers/staging/wlags49_h2/Kconfig
|
||||||
@@ -1,6 +1,7 @@
|
@@ -1,6 +1,7 @@
|
||||||
config WLAGS49_H2
|
config WLAGS49_H2
|
||||||
tristate "Agere Systems HERMES II Wireless PC Card Model 0110"
|
tristate "Agere Systems HERMES II Wireless PC Card Model 0110"
|
||||||
depends on WLAN_80211 && WIRELESS_EXT && PCMCIA
|
depends on WLAN && PCMCIA
|
||||||
+ depends on BROKEN
|
+ depends on BROKEN
|
||||||
|
select WIRELESS_EXT
|
||||||
select WEXT_SPY
|
select WEXT_SPY
|
||||||
---help---
|
select WEXT_PRIV
|
||||||
Driver for wireless cards using Agere's HERMES II chipset
|
|
||||||
|
|
|
@ -1,12 +1,10 @@
|
||||||
diff --git a/drivers/staging/wlags49_h25/Kconfig b/drivers/staging/wlags49_h25/Kconfig
|
|
||||||
index 304a8c9..24365a8 100644
|
|
||||||
--- a/drivers/staging/wlags49_h25/Kconfig
|
--- a/drivers/staging/wlags49_h25/Kconfig
|
||||||
+++ b/drivers/staging/wlags49_h25/Kconfig
|
+++ b/drivers/staging/wlags49_h25/Kconfig
|
||||||
@@ -1,6 +1,7 @@
|
@@ -1,6 +1,7 @@
|
||||||
config WLAGS49_H25
|
config WLAGS49_H25
|
||||||
tristate "Linksys HERMES II.5 WCF54G_Wireless-G_CompactFlash_Card"
|
tristate "Linksys HERMES II.5 WCF54G_Wireless-G_CompactFlash_Card"
|
||||||
depends on WLAN_80211 && WIRELESS_EXT && PCMCIA
|
depends on WLAN && PCMCIA
|
||||||
+ depends on BROKEN
|
+ depends on BROKEN
|
||||||
|
select WIRELESS_EXT
|
||||||
select WEXT_SPY
|
select WEXT_SPY
|
||||||
---help---
|
select WEXT_PRIV
|
||||||
Driver for wireless cards using Agere's HERMES II.5 chipset
|
|
||||||
|
|
|
@ -39,7 +39,7 @@ rm drivers/media/dvb/dvb-usb/af9005-script.h
|
||||||
|
|
||||||
unifdef drivers/media/dvb/frontends/lgs8gxx.c -UREMOVE_DFSG
|
unifdef drivers/media/dvb/frontends/lgs8gxx.c -UREMOVE_DFSG
|
||||||
|
|
||||||
rm drivers/infiniband/hw/ipath/ipath_sd7220_img.c
|
rm drivers/infiniband/hw/qib/qib_sd7220_img.c
|
||||||
|
|
||||||
rm drivers/net/appletalk/cops.c
|
rm drivers/net/appletalk/cops.c
|
||||||
rm drivers/net/appletalk/cops.h
|
rm drivers/net/appletalk/cops.h
|
||||||
|
@ -50,12 +50,7 @@ unifdef drivers/net/r8169.c -UREMOVE_DFSG
|
||||||
|
|
||||||
rm drivers/staging/otus/hal/hp*fw*.c*
|
rm drivers/staging/otus/hal/hp*fw*.c*
|
||||||
|
|
||||||
# Next line should be removed for next upstream release/rc
|
unifdef drivers/staging/rtl8192u/r819xU_firmware_img.c -UREMOVE_DFSG
|
||||||
rm drivers/staging/rtl8192su/r8192SU_HWImg.c
|
|
||||||
|
|
||||||
# Switch to unifdef for next upstream release/rc
|
|
||||||
rm drivers/staging/rtl8192u/r819xU_firmware_img.c
|
|
||||||
#unifdef drivers/staging/rtl8192u/r819xU_firmware_img.c -UREMOVE_DFSG
|
|
||||||
|
|
||||||
rm drivers/staging/vt6656/firmware.c
|
rm drivers/staging/vt6656/firmware.c
|
||||||
|
|
||||||
|
|
|
@ -19,7 +19,7 @@ index 1c00d05..3bf888d 100644
|
||||||
fw-shipped-$(CONFIG_ATARI_DSP56K) += dsp56k/bootstrap.bin
|
fw-shipped-$(CONFIG_ATARI_DSP56K) += dsp56k/bootstrap.bin
|
||||||
-fw-shipped-$(CONFIG_ATM_AMBASSADOR) += atmsar11.fw
|
-fw-shipped-$(CONFIG_ATM_AMBASSADOR) += atmsar11.fw
|
||||||
-fw-shipped-$(CONFIG_BNX2X) += bnx2x-e1-5.2.13.0.fw bnx2x-e1h-5.2.13.0.fw
|
-fw-shipped-$(CONFIG_BNX2X) += bnx2x-e1-5.2.13.0.fw bnx2x-e1h-5.2.13.0.fw
|
||||||
-fw-shipped-$(CONFIG_BNX2) += bnx2/bnx2-mips-09-5.0.0.j9.fw \
|
-fw-shipped-$(CONFIG_BNX2) += bnx2/bnx2-mips-09-5.0.0.j15.fw \
|
||||||
- bnx2/bnx2-rv2p-09-5.0.0.j10.fw \
|
- bnx2/bnx2-rv2p-09-5.0.0.j10.fw \
|
||||||
- bnx2/bnx2-rv2p-09ax-5.0.0.j10.fw \
|
- bnx2/bnx2-rv2p-09ax-5.0.0.j10.fw \
|
||||||
- bnx2/bnx2-mips-06-5.0.0.j6.fw \
|
- bnx2/bnx2-mips-06-5.0.0.j6.fw \
|
||||||
|
|
|
@ -0,0 +1,36 @@
|
||||||
|
From: Ben Hutchings <ben@decadent.org.uk>
|
||||||
|
Date: Mon, 17 Aug 2009 02:17:09 +0100
|
||||||
|
Subject: [PATCH] ib_qib: disable use of SD7220
|
||||||
|
|
||||||
|
--- a/drivers/infiniband/hw/qib/Makefile
|
||||||
|
+++ b/drivers/infiniband/hw/qib/Makefile
|
||||||
|
@@ -6,7 +6,7 @@ ib_qib-y := qib_cq.o qib_diag.o qib_dma.o qib_driver.o qib_eeprom.o \
|
||||||
|
qib_qp.o qib_qsfp.o qib_rc.o qib_ruc.o qib_sdma.o qib_srq.o \
|
||||||
|
qib_sysfs.o qib_twsi.o qib_tx.o qib_uc.o qib_ud.o \
|
||||||
|
qib_user_pages.o qib_user_sdma.o qib_verbs_mcast.o qib_iba7220.o \
|
||||||
|
- qib_sd7220.o qib_sd7220_img.o qib_iba7322.o qib_verbs.o
|
||||||
|
+ qib_sd7220.o qib_iba7322.o qib_verbs.o
|
||||||
|
|
||||||
|
# 6120 has no fallback if no MSI interrupts, others can do INTx
|
||||||
|
ib_qib-$(CONFIG_PCI_MSI) += qib_iba6120.o
|
||||||
|
--- a/drivers/infiniband/hw/qib/qib_sd7220.c
|
||||||
|
+++ b/drivers/infiniband/hw/qib/qib_sd7220.c
|
||||||
|
@@ -881,6 +902,18 @@ int qib_sd7220_prog_vfy(struct qib_devdata *dd, int sdnum,
|
||||||
|
return errors ? -errors : sofar;
|
||||||
|
}
|
||||||
|
|
||||||
|
+int
|
||||||
|
+qib_sd7220_ib_load(struct qib_devdata *dd)
|
||||||
|
+{
|
||||||
|
+ return -1;
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
+int
|
||||||
|
+qib_sd7220_ib_vfy(struct qib_devdata *dd)
|
||||||
|
+{
|
||||||
|
+ return -1;
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
/*
|
||||||
|
* IRQ not set up at this point in init, so we poll.
|
||||||
|
*/
|
|
@ -1,168 +0,0 @@
|
||||||
From b1f1970ea2fb1788af17c8841a5bbf8a8c94c412 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Date: Fri, 18 Jun 2010 01:41:56 +0100
|
|
||||||
Subject: [PATCH 2/2] rtl8192u_usb: Remove code for using built-in firmware images
|
|
||||||
|
|
||||||
This code is already unused and will fail to link since we removed
|
|
||||||
the firmware images.
|
|
||||||
---
|
|
||||||
drivers/staging/rtl8192u/r8192U.h | 6 --
|
|
||||||
drivers/staging/rtl8192u/r819xU_firmware.c | 76 ++++++++----------------
|
|
||||||
drivers/staging/rtl8192u/r819xU_firmware_img.h | 7 --
|
|
||||||
3 files changed, 25 insertions(+), 64 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/staging/rtl8192u/r8192U.h b/drivers/staging/rtl8192u/r8192U.h
|
|
||||||
index 69a2721..e04fe7b 100644
|
|
||||||
--- a/drivers/staging/rtl8192u/r8192U.h
|
|
||||||
+++ b/drivers/staging/rtl8192u/r8192U.h
|
|
||||||
@@ -461,11 +461,6 @@ typedef enum _desc_packet_type_e{
|
|
||||||
DESC_PACKET_TYPE_NORMAL = 1,
|
|
||||||
}desc_packet_type_e;
|
|
||||||
|
|
||||||
-typedef enum _firmware_source{
|
|
||||||
- FW_SOURCE_IMG_FILE = 0,
|
|
||||||
- FW_SOURCE_HEADER_FILE = 1, //from header file
|
|
||||||
-}firmware_source_e, *pfirmware_source_e;
|
|
||||||
-
|
|
||||||
typedef enum _firmware_status{
|
|
||||||
FW_STATUS_0_INIT = 0,
|
|
||||||
FW_STATUS_1_MOVE_BOOT_CODE = 1,
|
|
||||||
@@ -1026,7 +1021,6 @@ typedef struct r8192_priv
|
|
||||||
u8 Rf_Mode; //add for Firmware RF -R/W switch
|
|
||||||
prt_firmware pFirmware;
|
|
||||||
rtl819xUsb_loopback_e LoopbackMode;
|
|
||||||
- firmware_source_e firmware_source;
|
|
||||||
u16 EEPROMTxPowerDiff;
|
|
||||||
u8 EEPROMThermalMeter;
|
|
||||||
u8 EEPROMPwDiff;
|
|
||||||
diff --git a/drivers/staging/rtl8192u/r819xU_firmware.c b/drivers/staging/rtl8192u/r819xU_firmware.c
|
|
||||||
index 3cc2d57..3b14d11 100644
|
|
||||||
--- a/drivers/staging/rtl8192u/r819xU_firmware.c
|
|
||||||
+++ b/drivers/staging/rtl8192u/r819xU_firmware.c
|
|
||||||
@@ -244,13 +244,6 @@ bool init_firmware(struct net_device *dev)
|
|
||||||
struct r8192_priv *priv = ieee80211_priv(dev);
|
|
||||||
bool rt_status = TRUE;
|
|
||||||
|
|
||||||
- u8 *firmware_img_buf[3] = { &rtl8190_fwboot_array[0],
|
|
||||||
- &rtl8190_fwmain_array[0],
|
|
||||||
- &rtl8190_fwdata_array[0]};
|
|
||||||
-
|
|
||||||
- u32 firmware_img_len[3] = { sizeof(rtl8190_fwboot_array),
|
|
||||||
- sizeof(rtl8190_fwmain_array),
|
|
||||||
- sizeof(rtl8190_fwdata_array)};
|
|
||||||
u32 file_length = 0;
|
|
||||||
u8 *mapped_file = NULL;
|
|
||||||
u32 init_step = 0;
|
|
||||||
@@ -284,59 +277,40 @@ bool init_firmware(struct net_device *dev)
|
|
||||||
* Download boot, main, and data image for System reset.
|
|
||||||
* Download data image for firmware reseta
|
|
||||||
*/
|
|
||||||
- priv->firmware_source = FW_SOURCE_IMG_FILE;
|
|
||||||
for(init_step = starting_state; init_step <= FW_INIT_STEP2_DATA; init_step++) {
|
|
||||||
/*
|
|
||||||
* Open Image file, and map file to contineous memory if open file success.
|
|
||||||
* or read image file from array. Default load from IMG file
|
|
||||||
*/
|
|
||||||
if(rst_opt == OPT_SYSTEM_RESET) {
|
|
||||||
- switch(priv->firmware_source) {
|
|
||||||
- case FW_SOURCE_IMG_FILE:
|
|
||||||
- rc = request_firmware(&fw_entry, fw_name[init_step],&priv->udev->dev);
|
|
||||||
- if(rc < 0 ) {
|
|
||||||
- RT_TRACE(COMP_ERR, "request firmware fail!\n");
|
|
||||||
- goto download_firmware_fail;
|
|
||||||
- }
|
|
||||||
-
|
|
||||||
- if(fw_entry->size > sizeof(pfirmware->firmware_buf)) {
|
|
||||||
- RT_TRACE(COMP_ERR, "img file size exceed the container buffer fail!\n");
|
|
||||||
- goto download_firmware_fail;
|
|
||||||
- }
|
|
||||||
-
|
|
||||||
- if(init_step != FW_INIT_STEP1_MAIN) {
|
|
||||||
- memcpy(pfirmware->firmware_buf,fw_entry->data,fw_entry->size);
|
|
||||||
- mapped_file = pfirmware->firmware_buf;
|
|
||||||
- file_length = fw_entry->size;
|
|
||||||
- } else {
|
|
||||||
- #ifdef RTL8190P
|
|
||||||
- memcpy(pfirmware->firmware_buf,fw_entry->data,fw_entry->size);
|
|
||||||
- mapped_file = pfirmware->firmware_buf;
|
|
||||||
- file_length = fw_entry->size;
|
|
||||||
- #else
|
|
||||||
- memset(pfirmware->firmware_buf,0,128);
|
|
||||||
- memcpy(&pfirmware->firmware_buf[128],fw_entry->data,fw_entry->size);
|
|
||||||
- mapped_file = pfirmware->firmware_buf;
|
|
||||||
- file_length = fw_entry->size + 128;
|
|
||||||
- #endif
|
|
||||||
- }
|
|
||||||
- pfirmware->firmware_buf_size = file_length;
|
|
||||||
- break;
|
|
||||||
-
|
|
||||||
- case FW_SOURCE_HEADER_FILE:
|
|
||||||
- mapped_file = firmware_img_buf[init_step];
|
|
||||||
- file_length = firmware_img_len[init_step];
|
|
||||||
- if(init_step == FW_INIT_STEP2_DATA) {
|
|
||||||
- memcpy(pfirmware->firmware_buf, mapped_file, file_length);
|
|
||||||
- pfirmware->firmware_buf_size = file_length;
|
|
||||||
- }
|
|
||||||
- break;
|
|
||||||
-
|
|
||||||
- default:
|
|
||||||
- break;
|
|
||||||
+ rc = request_firmware(&fw_entry, fw_name[init_step],&priv->udev->dev);
|
|
||||||
+ if(rc < 0 ) {
|
|
||||||
+ RT_TRACE(COMP_ERR, "request firmware fail!\n");
|
|
||||||
+ goto download_firmware_fail;
|
|
||||||
}
|
|
||||||
|
|
||||||
+ if(fw_entry->size > sizeof(pfirmware->firmware_buf)) {
|
|
||||||
+ RT_TRACE(COMP_ERR, "img file size exceed the container buffer fail!\n");
|
|
||||||
+ goto download_firmware_fail;
|
|
||||||
+ }
|
|
||||||
|
|
||||||
+ if(init_step != FW_INIT_STEP1_MAIN) {
|
|
||||||
+ memcpy(pfirmware->firmware_buf,fw_entry->data,fw_entry->size);
|
|
||||||
+ mapped_file = pfirmware->firmware_buf;
|
|
||||||
+ file_length = fw_entry->size;
|
|
||||||
+ } else {
|
|
||||||
+#ifdef RTL8190P
|
|
||||||
+ memcpy(pfirmware->firmware_buf,fw_entry->data,fw_entry->size);
|
|
||||||
+ mapped_file = pfirmware->firmware_buf;
|
|
||||||
+ file_length = fw_entry->size;
|
|
||||||
+#else
|
|
||||||
+ memset(pfirmware->firmware_buf,0,128);
|
|
||||||
+ memcpy(&pfirmware->firmware_buf[128],fw_entry->data,fw_entry->size);
|
|
||||||
+ mapped_file = pfirmware->firmware_buf;
|
|
||||||
+ file_length = fw_entry->size + 128;
|
|
||||||
+#endif
|
|
||||||
+ }
|
|
||||||
+ pfirmware->firmware_buf_size = file_length;
|
|
||||||
}else if(rst_opt == OPT_FIRMWARE_RESET ) {
|
|
||||||
/* we only need to download data.img here */
|
|
||||||
mapped_file = pfirmware->firmware_buf;
|
|
||||||
diff --git a/drivers/staging/rtl8192u/r819xU_firmware_img.h b/drivers/staging/rtl8192u/r819xU_firmware_img.h
|
|
||||||
index d9d9515..18d0a6b 100644
|
|
||||||
--- a/drivers/staging/rtl8192u/r819xU_firmware_img.h
|
|
||||||
+++ b/drivers/staging/rtl8192u/r819xU_firmware_img.h
|
|
||||||
@@ -1,9 +1,6 @@
|
|
||||||
#ifndef IMG_H
|
|
||||||
#define IMG_H
|
|
||||||
|
|
||||||
-#define BOOT_ARR_LEN 344
|
|
||||||
-#define MAIN_ARR_LEN 45136
|
|
||||||
-#define DATA_ARR_LEN 796
|
|
||||||
#define MACPHY_Array_PGLength 30
|
|
||||||
#define PHY_REG_1T2RArrayLength 296
|
|
||||||
#define AGCTAB_ArrayLength 384
|
|
||||||
@@ -16,10 +13,6 @@
|
|
||||||
#define PHY_REGArrayLength 1
|
|
||||||
|
|
||||||
|
|
||||||
-extern u8 rtl8190_fwboot_array[BOOT_ARR_LEN];
|
|
||||||
-extern u8 rtl8190_fwmain_array[MAIN_ARR_LEN];
|
|
||||||
-extern u8 rtl8190_fwdata_array[DATA_ARR_LEN];
|
|
||||||
-
|
|
||||||
extern u32 Rtl8192UsbPHY_REGArray[];
|
|
||||||
extern u32 Rtl8192UsbPHY_REG_1T2RArray[];
|
|
||||||
extern u32 Rtl8192UsbRadioA_Array[];
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,10 +1,8 @@
|
||||||
diff --git a/Makefile b/Makefile
|
|
||||||
index 59cf6da..6e1e048 100644
|
|
||||||
--- a/Makefile
|
--- a/Makefile
|
||||||
+++ b/Makefile
|
+++ b/Makefile
|
||||||
@@ -193,35 +193,6 @@ export KBUILD_BUILDHOST := $(SUBARCH)
|
@@ -192,35 +192,6 @@
|
||||||
ARCH ?= $(SUBARCH)
|
|
||||||
CROSS_COMPILE ?=
|
CROSS_COMPILE ?=
|
||||||
|
CROSS_COMPILE ?= $(CONFIG_CROSS_COMPILE:"%"=%)
|
||||||
|
|
||||||
-# Architecture as present in compile.h
|
-# Architecture as present in compile.h
|
||||||
-UTS_MACHINE := $(ARCH)
|
-UTS_MACHINE := $(ARCH)
|
||||||
|
@ -38,7 +36,7 @@ index 59cf6da..6e1e048 100644
|
||||||
KCONFIG_CONFIG ?= .config
|
KCONFIG_CONFIG ?= .config
|
||||||
|
|
||||||
# SHELL used by kbuild
|
# SHELL used by kbuild
|
||||||
@@ -339,6 +315,36 @@ LDFLAGS_MODULE =
|
@@ -340,6 +311,36 @@ LDFLAGS_MODULE =
|
||||||
AFLAGS_KERNEL =
|
AFLAGS_KERNEL =
|
||||||
CFLAGS_GCOV = -fprofile-arcs -ftest-coverage
|
CFLAGS_GCOV = -fprofile-arcs -ftest-coverage
|
||||||
|
|
||||||
|
|
|
@ -1,632 +0,0 @@
|
||||||
diff --git a/drivers/staging/rtl8192su/r8192SU_HWImg.c b/drivers/staging/rtl8192su/r8192SU_HWImg.c
|
|
||||||
new file mode 100644
|
|
||||||
index 0000000..ba8e12c
|
|
||||||
--- /dev/null
|
|
||||||
+++ b/drivers/staging/rtl8192su/r8192SU_HWImg.c
|
|
||||||
@@ -0,0 +1,626 @@
|
|
||||||
+/*Created on 2009/ 1/15, 3:10*/
|
|
||||||
+
|
|
||||||
+#include "r8192SU_HWImg.h"
|
|
||||||
+
|
|
||||||
+u8 Rtl8192SUFwMainArray[MainArrayLength] = {
|
|
||||||
+0x0, };
|
|
||||||
+
|
|
||||||
+u8 Rtl8192SUFwDataArray[DataArrayLength] = {
|
|
||||||
+0x0, };
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SUPHY_REG_2T2RArray[PHY_REG_2T2RArrayLength] = {
|
|
||||||
+0x01c,0x07000000,
|
|
||||||
+0x800,0x00040000,
|
|
||||||
+0x804,0x00008003,
|
|
||||||
+0x808,0x0000fc00,
|
|
||||||
+0x80c,0x0000000a,
|
|
||||||
+0x810,0x10005088,
|
|
||||||
+0x814,0x020c3d10,
|
|
||||||
+0x818,0x00200185,
|
|
||||||
+0x81c,0x00000000,
|
|
||||||
+0x820,0x01000000,
|
|
||||||
+0x824,0x00390004,
|
|
||||||
+0x828,0x01000000,
|
|
||||||
+0x82c,0x00390004,
|
|
||||||
+0x830,0x00000004,
|
|
||||||
+0x834,0x00690200,
|
|
||||||
+0x838,0x00000004,
|
|
||||||
+0x83c,0x00690200,
|
|
||||||
+0x840,0x00010000,
|
|
||||||
+0x844,0x00010000,
|
|
||||||
+0x848,0x00000000,
|
|
||||||
+0x84c,0x00000000,
|
|
||||||
+0x850,0x00000000,
|
|
||||||
+0x854,0x00000000,
|
|
||||||
+0x858,0x48484848,
|
|
||||||
+0x85c,0x65a965a9,
|
|
||||||
+0x860,0x0f7f0130,
|
|
||||||
+0x864,0x0f7f0130,
|
|
||||||
+0x868,0x0f7f0130,
|
|
||||||
+0x86c,0x0f7f0130,
|
|
||||||
+0x870,0x03000700,
|
|
||||||
+0x874,0x03000300,
|
|
||||||
+0x878,0x00020002,
|
|
||||||
+0x87c,0x004f0201,
|
|
||||||
+0x880,0xa8300ac1,
|
|
||||||
+0x884,0x00000058,
|
|
||||||
+0x888,0x00000008,
|
|
||||||
+0x88c,0x00000004,
|
|
||||||
+0x890,0x00000000,
|
|
||||||
+0x894,0xfffffffe,
|
|
||||||
+0x898,0x40302010,
|
|
||||||
+0x89c,0x00706050,
|
|
||||||
+0x8b0,0x00000000,
|
|
||||||
+0x8e0,0x00000000,
|
|
||||||
+0x8e4,0x00000000,
|
|
||||||
+0xe00,0x30333333,
|
|
||||||
+0xe04,0x2a2d2e2f,
|
|
||||||
+0xe08,0x00003232,
|
|
||||||
+0xe10,0x30333333,
|
|
||||||
+0xe14,0x2a2d2e2f,
|
|
||||||
+0xe18,0x30333333,
|
|
||||||
+0xe1c,0x2a2d2e2f,
|
|
||||||
+0xe30,0x01007c00,
|
|
||||||
+0xe34,0x01004800,
|
|
||||||
+0xe38,0x1000dc1f,
|
|
||||||
+0xe3c,0x10008c1f,
|
|
||||||
+0xe40,0x021400a0,
|
|
||||||
+0xe44,0x281600a0,
|
|
||||||
+0xe48,0xf8000001,
|
|
||||||
+0xe4c,0x00002910,
|
|
||||||
+0xe50,0x01007c00,
|
|
||||||
+0xe54,0x01004800,
|
|
||||||
+0xe58,0x1000dc1f,
|
|
||||||
+0xe5c,0x10008c1f,
|
|
||||||
+0xe60,0x021400a0,
|
|
||||||
+0xe64,0x281600a0,
|
|
||||||
+0xe6c,0x00002910,
|
|
||||||
+0xe70,0x31ed92fb,
|
|
||||||
+0xe74,0x361536fb,
|
|
||||||
+0xe78,0x361536fb,
|
|
||||||
+0xe7c,0x361536fb,
|
|
||||||
+0xe80,0x361536fb,
|
|
||||||
+0xe84,0x000d92fb,
|
|
||||||
+0xe88,0x000d92fb,
|
|
||||||
+0xe8c,0x31ed92fb,
|
|
||||||
+0xed0,0x31ed92fb,
|
|
||||||
+0xed4,0x31ed92fb,
|
|
||||||
+0xed8,0x000d92fb,
|
|
||||||
+0xedc,0x000d92fb,
|
|
||||||
+0xee0,0x000d92fb,
|
|
||||||
+0xee4,0x015e5448,
|
|
||||||
+0xee8,0x21555448,
|
|
||||||
+0x900,0x00000000,
|
|
||||||
+0x904,0x00000023,
|
|
||||||
+0x908,0x00000000,
|
|
||||||
+0x90c,0x03321333,
|
|
||||||
+0xa00,0x00d047c8,
|
|
||||||
+0xa04,0x80ff0008,
|
|
||||||
+0xa08,0x8ccd8300,
|
|
||||||
+0xa0c,0x2e62120f,
|
|
||||||
+0xa10,0x9500bb78,
|
|
||||||
+0xa14,0x11144028,
|
|
||||||
+0xa18,0x00881117,
|
|
||||||
+0xa1c,0x89140f00,
|
|
||||||
+0xa20,0x1a1b0000,
|
|
||||||
+0xa24,0x090e1317,
|
|
||||||
+0xa28,0x00000204,
|
|
||||||
+0xa2c,0x10d30000,
|
|
||||||
+0xc00,0x40071d40,
|
|
||||||
+0xc04,0x00a05633,
|
|
||||||
+0xc08,0x000000e4,
|
|
||||||
+0xc0c,0x6c6c6c6c,
|
|
||||||
+0xc10,0x08800000,
|
|
||||||
+0xc14,0x40000100,
|
|
||||||
+0xc18,0x08000000,
|
|
||||||
+0xc1c,0x40000100,
|
|
||||||
+0xc20,0x08000000,
|
|
||||||
+0xc24,0x40000100,
|
|
||||||
+0xc28,0x08000000,
|
|
||||||
+0xc2c,0x40000100,
|
|
||||||
+0xc30,0x6de9ac44,
|
|
||||||
+0xc34,0x469652cf,
|
|
||||||
+0xc38,0x49795994,
|
|
||||||
+0xc3c,0x0a979764,
|
|
||||||
+0xc40,0x1f7c403f,
|
|
||||||
+0xc44,0x000100b7,
|
|
||||||
+0xc48,0xec020000,
|
|
||||||
+0xc4c,0x007f037f,
|
|
||||||
+0xc50,0x69543420,
|
|
||||||
+0xc54,0x433c0094,
|
|
||||||
+0xc58,0x69543420,
|
|
||||||
+0xc5c,0x433c0094,
|
|
||||||
+0xc60,0x69543420,
|
|
||||||
+0xc64,0x433c0094,
|
|
||||||
+0xc68,0x69543420,
|
|
||||||
+0xc6c,0x433c0094,
|
|
||||||
+0xc70,0x2c7f000d,
|
|
||||||
+0xc74,0x0186155b,
|
|
||||||
+0xc78,0x0000001f,
|
|
||||||
+0xc7c,0x00b91612,
|
|
||||||
+0xc80,0x40000100,
|
|
||||||
+0xc84,0x20f60000,
|
|
||||||
+0xc88,0x20000080,
|
|
||||||
+0xc8c,0x20200000,
|
|
||||||
+0xc90,0x40000100,
|
|
||||||
+0xc94,0x00000000,
|
|
||||||
+0xc98,0x40000100,
|
|
||||||
+0xc9c,0x00000000,
|
|
||||||
+0xca0,0x00492492,
|
|
||||||
+0xca4,0x00000000,
|
|
||||||
+0xca8,0x00000000,
|
|
||||||
+0xcac,0x00000000,
|
|
||||||
+0xcb0,0x00000000,
|
|
||||||
+0xcb4,0x00000000,
|
|
||||||
+0xcb8,0x00000000,
|
|
||||||
+0xcbc,0x28000000,
|
|
||||||
+0xcc0,0x00000000,
|
|
||||||
+0xcc4,0x00000000,
|
|
||||||
+0xcc8,0x00000000,
|
|
||||||
+0xccc,0x00000000,
|
|
||||||
+0xcd0,0x00000000,
|
|
||||||
+0xcd4,0x00000000,
|
|
||||||
+0xcd8,0x64b22427,
|
|
||||||
+0xcdc,0x00766932,
|
|
||||||
+0xce0,0x00222222,
|
|
||||||
+0xce4,0x00000000,
|
|
||||||
+0xce8,0x37644302,
|
|
||||||
+0xcec,0x2f97d40c,
|
|
||||||
+0xd00,0x00000750,
|
|
||||||
+0xd04,0x00000403,
|
|
||||||
+0xd08,0x0000907f,
|
|
||||||
+0xd0c,0x00000001,
|
|
||||||
+0xd10,0xa0633333,
|
|
||||||
+0xd14,0x33333c63,
|
|
||||||
+0xd18,0x6a8f5b6b,
|
|
||||||
+0xd1c,0x00000000,
|
|
||||||
+0xd20,0x00000000,
|
|
||||||
+0xd24,0x00000000,
|
|
||||||
+0xd28,0x00000000,
|
|
||||||
+0xd2c,0xcc979975,
|
|
||||||
+0xd30,0x00000000,
|
|
||||||
+0xd34,0x00000000,
|
|
||||||
+0xd38,0x00000000,
|
|
||||||
+0xd3c,0x00027293,
|
|
||||||
+0xd40,0x00000000,
|
|
||||||
+0xd44,0x00000000,
|
|
||||||
+0xd48,0x00000000,
|
|
||||||
+0xd50,0x6437140a,
|
|
||||||
+0xd54,0x024dbd02,
|
|
||||||
+0xd58,0x00000000,
|
|
||||||
+0xd5c,0x30032064,
|
|
||||||
+0xd60,0x4653de68,
|
|
||||||
+0xd64,0x00518a3c,
|
|
||||||
+0xd68,0x00002101,
|
|
||||||
+0xf14,0x00000003,
|
|
||||||
+0xf4c,0x00000000,
|
|
||||||
+0xf00,0x00000300,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SUPHY_REG_1T2RArray[PHY_REG_1T2RArrayLength] = {
|
|
||||||
+0x0, };
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SUPHY_ChangeTo_1T1RArray[PHY_ChangeTo_1T1RArrayLength] = {
|
|
||||||
+0x844,0xffffffff,0x00010000,
|
|
||||||
+0x804,0x0000000f,0x00000001,
|
|
||||||
+0x824,0x00f0000f,0x00300004,
|
|
||||||
+0x82c,0x00f0000f,0x00100002,
|
|
||||||
+0x870,0x04000000,0x00000001,
|
|
||||||
+0x864,0x00000400,0x00000000,
|
|
||||||
+0x878,0x000f000f,0x00000002,
|
|
||||||
+0xe74,0x0f000000,0x00000002,
|
|
||||||
+0xe78,0x0f000000,0x00000002,
|
|
||||||
+0xe7c,0x0f000000,0x00000002,
|
|
||||||
+0xe80,0x0f000000,0x00000002,
|
|
||||||
+0x90c,0x000000ff,0x00000011,
|
|
||||||
+0xc04,0x000000ff,0x00000011,
|
|
||||||
+0xd04,0x0000000f,0x00000001,
|
|
||||||
+0x1f4,0xffff0000,0x00007777,
|
|
||||||
+0x234,0xf8000000,0x0000000a,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SUPHY_ChangeTo_1T2RArray[PHY_ChangeTo_1T2RArrayLength] = {
|
|
||||||
+0x804,0x0000000f,0x00000003,
|
|
||||||
+0x824,0x00f0000f,0x00300004,
|
|
||||||
+0x82c,0x00f0000f,0x00300002,
|
|
||||||
+0x870,0x04000000,0x00000001,
|
|
||||||
+0x864,0x00000400,0x00000000,
|
|
||||||
+0x878,0x000f000f,0x00000002,
|
|
||||||
+0xe74,0x0f000000,0x00000002,
|
|
||||||
+0xe78,0x0f000000,0x00000002,
|
|
||||||
+0xe7c,0x0f000000,0x00000002,
|
|
||||||
+0xe80,0x0f000000,0x00000002,
|
|
||||||
+0x90c,0x000000ff,0x00000011,
|
|
||||||
+0xc04,0x000000ff,0x00000033,
|
|
||||||
+0xd04,0x0000000f,0x00000003,
|
|
||||||
+0x1f4,0xffff0000,0x00007777,
|
|
||||||
+0x234,0xf8000000,0x0000000a,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SUPHY_ChangeTo_2T2RArray[PHY_ChangeTo_2T2RArrayLength] = {
|
|
||||||
+0x804,0x0000000f,0x00000003,
|
|
||||||
+0x824,0x00f0000f,0x00300004,
|
|
||||||
+0x82c,0x00f0000f,0x00300004,
|
|
||||||
+0x870,0x04000000,0x00000001,
|
|
||||||
+0x864,0x00000400,0x00000001,
|
|
||||||
+0x878,0x000f000f,0x00020002,
|
|
||||||
+0xe74,0x0f000000,0x00000006,
|
|
||||||
+0xe78,0x0f000000,0x00000006,
|
|
||||||
+0xe7c,0x0f000000,0x00000006,
|
|
||||||
+0xe80,0x0f000000,0x00000006,
|
|
||||||
+0x90c,0x000000ff,0x00000033,
|
|
||||||
+0xc04,0x000000ff,0x00000033,
|
|
||||||
+0xd04,0x0000000f,0x00000003,
|
|
||||||
+0x1f4,0xffff0000,0x0000ffff,
|
|
||||||
+0x234,0xf8000000,0x00000013,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SUPHY_REG_Array_PG[PHY_REG_Array_PGLength] = {
|
|
||||||
+0xe00,0xffffffff,0x06090909,
|
|
||||||
+0xe04,0xffffffff,0x00030406,
|
|
||||||
+0xe08,0x0000ff00,0x00000000,
|
|
||||||
+0xe10,0xffffffff,0x0a0c0d0e,
|
|
||||||
+0xe14,0xffffffff,0x04070809,
|
|
||||||
+0xe18,0xffffffff,0x0a0c0d0e,
|
|
||||||
+0xe1c,0xffffffff,0x04070809,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SURadioA_1T_Array[RadioA_1T_ArrayLength] = {
|
|
||||||
+0x000,0x00030159,
|
|
||||||
+0x001,0x00030250,
|
|
||||||
+0x002,0x00010000,
|
|
||||||
+0x010,0x0008000f,
|
|
||||||
+0x011,0x000231fc,
|
|
||||||
+0x010,0x000c000f,
|
|
||||||
+0x011,0x0003f9f8,
|
|
||||||
+0x010,0x0002000f,
|
|
||||||
+0x011,0x00020101,
|
|
||||||
+0x014,0x0001093e,
|
|
||||||
+0x014,0x0009093e,
|
|
||||||
+0x015,0x000198f4,
|
|
||||||
+0x017,0x000f6500,
|
|
||||||
+0x01a,0x00013056,
|
|
||||||
+0x01b,0x00060000,
|
|
||||||
+0x01c,0x00000300,
|
|
||||||
+0x01e,0x00031059,
|
|
||||||
+0x021,0x00054000,
|
|
||||||
+0x022,0x0000083c,
|
|
||||||
+0x023,0x00001558,
|
|
||||||
+0x024,0x00000060,
|
|
||||||
+0x025,0x00022583,
|
|
||||||
+0x026,0x0000f200,
|
|
||||||
+0x027,0x000eacf1,
|
|
||||||
+0x028,0x0009bd54,
|
|
||||||
+0x029,0x00004582,
|
|
||||||
+0x02a,0x00000001,
|
|
||||||
+0x02b,0x00021334,
|
|
||||||
+0x02a,0x00000000,
|
|
||||||
+0x02b,0x0000000a,
|
|
||||||
+0x02a,0x00000001,
|
|
||||||
+0x02b,0x00000808,
|
|
||||||
+0x02b,0x00053333,
|
|
||||||
+0x02c,0x0000000c,
|
|
||||||
+0x02a,0x00000002,
|
|
||||||
+0x02b,0x00000808,
|
|
||||||
+0x02b,0x0005b333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x00000003,
|
|
||||||
+0x02b,0x00000808,
|
|
||||||
+0x02b,0x00063333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x00000004,
|
|
||||||
+0x02b,0x00000808,
|
|
||||||
+0x02b,0x0006b333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x00000005,
|
|
||||||
+0x02b,0x00000709,
|
|
||||||
+0x02b,0x00053333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x00000006,
|
|
||||||
+0x02b,0x00000709,
|
|
||||||
+0x02b,0x0005b333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x00000007,
|
|
||||||
+0x02b,0x00000709,
|
|
||||||
+0x02b,0x00063333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x00000008,
|
|
||||||
+0x02b,0x00000709,
|
|
||||||
+0x02b,0x0006b333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x00000009,
|
|
||||||
+0x02b,0x0000060a,
|
|
||||||
+0x02b,0x00053333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x0000000a,
|
|
||||||
+0x02b,0x0000060a,
|
|
||||||
+0x02b,0x0005b333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x0000000b,
|
|
||||||
+0x02b,0x0000060a,
|
|
||||||
+0x02b,0x00063333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x0000000c,
|
|
||||||
+0x02b,0x0000060a,
|
|
||||||
+0x02b,0x0006b333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x0000000d,
|
|
||||||
+0x02b,0x0000050b,
|
|
||||||
+0x02b,0x00053333,
|
|
||||||
+0x02c,0x0000000d,
|
|
||||||
+0x02a,0x0000000e,
|
|
||||||
+0x02b,0x0000050b,
|
|
||||||
+0x02b,0x00066623,
|
|
||||||
+0x02c,0x0000001a,
|
|
||||||
+0x02a,0x000e4000,
|
|
||||||
+0x030,0x00020000,
|
|
||||||
+0x031,0x000b9631,
|
|
||||||
+0x032,0x0000130d,
|
|
||||||
+0x033,0x00000187,
|
|
||||||
+0x013,0x00019e6c,
|
|
||||||
+0x013,0x00015e94,
|
|
||||||
+0x000,0x00010159,
|
|
||||||
+0x018,0x0000f401,
|
|
||||||
+0x0fe,0x00000000,
|
|
||||||
+0x01e,0x0003105b,
|
|
||||||
+0x0fe,0x00000000,
|
|
||||||
+0x000,0x00030159,
|
|
||||||
+0x010,0x0004000f,
|
|
||||||
+0x011,0x000203f9,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SURadioB_Array[RadioB_ArrayLength] = {
|
|
||||||
+0x000,0x00030159,
|
|
||||||
+0x001,0x00001041,
|
|
||||||
+0x002,0x00011000,
|
|
||||||
+0x005,0x00080fc0,
|
|
||||||
+0x007,0x000fc803,
|
|
||||||
+0x013,0x00017cb0,
|
|
||||||
+0x013,0x00011cc0,
|
|
||||||
+0x013,0x0000dc60,
|
|
||||||
+0x013,0x00008c60,
|
|
||||||
+0x013,0x00004450,
|
|
||||||
+0x013,0x00000020,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SURadioA_to1T_Array[RadioA_to1T_ArrayLength] = {
|
|
||||||
+0x000,0x00000000,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SURadioA_to2T_Array[RadioA_to2T_ArrayLength] = {
|
|
||||||
+0x000,0x00000000,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SURadioB_GM_Array[RadioB_GM_ArrayLength] = {
|
|
||||||
+0x000,0x00030159,
|
|
||||||
+0x001,0x00001041,
|
|
||||||
+0x002,0x00011000,
|
|
||||||
+0x005,0x00080fc0,
|
|
||||||
+0x007,0x000fc803,
|
|
||||||
+0x013,0x0000bef0,
|
|
||||||
+0x013,0x00007e90,
|
|
||||||
+0x013,0x00003e30,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SUMAC_2T_Array[MAC_2T_ArrayLength] = {
|
|
||||||
+0x020,0x00000035,
|
|
||||||
+0x048,0x0000000e,
|
|
||||||
+0x049,0x000000f0,
|
|
||||||
+0x04a,0x00000077,
|
|
||||||
+0x04b,0x00000083,
|
|
||||||
+0x0b5,0x00000021,
|
|
||||||
+0x0dc,0x000000ff,
|
|
||||||
+0x0dd,0x000000ff,
|
|
||||||
+0x0de,0x000000ff,
|
|
||||||
+0x0df,0x000000ff,
|
|
||||||
+0x116,0x00000000,
|
|
||||||
+0x117,0x00000000,
|
|
||||||
+0x118,0x00000000,
|
|
||||||
+0x119,0x00000000,
|
|
||||||
+0x11a,0x00000000,
|
|
||||||
+0x11b,0x00000000,
|
|
||||||
+0x11c,0x00000000,
|
|
||||||
+0x11d,0x00000000,
|
|
||||||
+0x160,0x0000000b,
|
|
||||||
+0x161,0x0000000b,
|
|
||||||
+0x162,0x0000000b,
|
|
||||||
+0x163,0x0000000b,
|
|
||||||
+0x164,0x0000000b,
|
|
||||||
+0x165,0x0000000b,
|
|
||||||
+0x166,0x0000000b,
|
|
||||||
+0x167,0x0000000b,
|
|
||||||
+0x168,0x0000000b,
|
|
||||||
+0x169,0x0000000b,
|
|
||||||
+0x16a,0x0000000b,
|
|
||||||
+0x16b,0x0000000b,
|
|
||||||
+0x16c,0x0000000b,
|
|
||||||
+0x16d,0x0000000b,
|
|
||||||
+0x16e,0x0000000b,
|
|
||||||
+0x16f,0x0000000b,
|
|
||||||
+0x170,0x0000000b,
|
|
||||||
+0x171,0x0000000b,
|
|
||||||
+0x172,0x0000000b,
|
|
||||||
+0x173,0x0000000b,
|
|
||||||
+0x174,0x0000000b,
|
|
||||||
+0x175,0x0000000b,
|
|
||||||
+0x176,0x0000000b,
|
|
||||||
+0x177,0x0000000b,
|
|
||||||
+0x178,0x0000000b,
|
|
||||||
+0x179,0x0000000b,
|
|
||||||
+0x17a,0x0000000b,
|
|
||||||
+0x17b,0x0000000b,
|
|
||||||
+0x17c,0x0000000b,
|
|
||||||
+0x17d,0x0000000b,
|
|
||||||
+0x17e,0x0000000b,
|
|
||||||
+0x17f,0x0000000b,
|
|
||||||
+0x236,0x0000000c,
|
|
||||||
+0x503,0x00000022,
|
|
||||||
+0x560,0x00000009,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SUMACPHY_Array_PG[MACPHY_Array_PGLength] = {
|
|
||||||
+0x0, };
|
|
||||||
+
|
|
||||||
+u32 Rtl8192SUAGCTAB_Array[AGCTAB_ArrayLength] = {
|
|
||||||
+0xc78,0x7f000001,
|
|
||||||
+0xc78,0x7f010001,
|
|
||||||
+0xc78,0x7e020001,
|
|
||||||
+0xc78,0x7d030001,
|
|
||||||
+0xc78,0x7c040001,
|
|
||||||
+0xc78,0x7b050001,
|
|
||||||
+0xc78,0x7a060001,
|
|
||||||
+0xc78,0x79070001,
|
|
||||||
+0xc78,0x78080001,
|
|
||||||
+0xc78,0x77090001,
|
|
||||||
+0xc78,0x760a0001,
|
|
||||||
+0xc78,0x750b0001,
|
|
||||||
+0xc78,0x740c0001,
|
|
||||||
+0xc78,0x730d0001,
|
|
||||||
+0xc78,0x720e0001,
|
|
||||||
+0xc78,0x710f0001,
|
|
||||||
+0xc78,0x70100001,
|
|
||||||
+0xc78,0x6f110001,
|
|
||||||
+0xc78,0x6f120001,
|
|
||||||
+0xc78,0x6e130001,
|
|
||||||
+0xc78,0x6d140001,
|
|
||||||
+0xc78,0x6d150001,
|
|
||||||
+0xc78,0x6c160001,
|
|
||||||
+0xc78,0x6b170001,
|
|
||||||
+0xc78,0x6a180001,
|
|
||||||
+0xc78,0x6a190001,
|
|
||||||
+0xc78,0x691a0001,
|
|
||||||
+0xc78,0x681b0001,
|
|
||||||
+0xc78,0x671c0001,
|
|
||||||
+0xc78,0x661d0001,
|
|
||||||
+0xc78,0x651e0001,
|
|
||||||
+0xc78,0x641f0001,
|
|
||||||
+0xc78,0x63200001,
|
|
||||||
+0xc78,0x4c210001,
|
|
||||||
+0xc78,0x4b220001,
|
|
||||||
+0xc78,0x4a230001,
|
|
||||||
+0xc78,0x49240001,
|
|
||||||
+0xc78,0x48250001,
|
|
||||||
+0xc78,0x47260001,
|
|
||||||
+0xc78,0x46270001,
|
|
||||||
+0xc78,0x45280001,
|
|
||||||
+0xc78,0x44290001,
|
|
||||||
+0xc78,0x2c2a0001,
|
|
||||||
+0xc78,0x2b2b0001,
|
|
||||||
+0xc78,0x2a2c0001,
|
|
||||||
+0xc78,0x292d0001,
|
|
||||||
+0xc78,0x282e0001,
|
|
||||||
+0xc78,0x272f0001,
|
|
||||||
+0xc78,0x26300001,
|
|
||||||
+0xc78,0x25310001,
|
|
||||||
+0xc78,0x24320001,
|
|
||||||
+0xc78,0x23330001,
|
|
||||||
+0xc78,0x22340001,
|
|
||||||
+0xc78,0x09350001,
|
|
||||||
+0xc78,0x08360001,
|
|
||||||
+0xc78,0x07370001,
|
|
||||||
+0xc78,0x06380001,
|
|
||||||
+0xc78,0x05390001,
|
|
||||||
+0xc78,0x043a0001,
|
|
||||||
+0xc78,0x033b0001,
|
|
||||||
+0xc78,0x023c0001,
|
|
||||||
+0xc78,0x013d0001,
|
|
||||||
+0xc78,0x003e0001,
|
|
||||||
+0xc78,0x003f0001,
|
|
||||||
+0xc78,0x7f400001,
|
|
||||||
+0xc78,0x7f410001,
|
|
||||||
+0xc78,0x7e420001,
|
|
||||||
+0xc78,0x7d430001,
|
|
||||||
+0xc78,0x7c440001,
|
|
||||||
+0xc78,0x7b450001,
|
|
||||||
+0xc78,0x7a460001,
|
|
||||||
+0xc78,0x79470001,
|
|
||||||
+0xc78,0x78480001,
|
|
||||||
+0xc78,0x77490001,
|
|
||||||
+0xc78,0x764a0001,
|
|
||||||
+0xc78,0x754b0001,
|
|
||||||
+0xc78,0x744c0001,
|
|
||||||
+0xc78,0x734d0001,
|
|
||||||
+0xc78,0x724e0001,
|
|
||||||
+0xc78,0x714f0001,
|
|
||||||
+0xc78,0x70500001,
|
|
||||||
+0xc78,0x6f510001,
|
|
||||||
+0xc78,0x6f520001,
|
|
||||||
+0xc78,0x6e530001,
|
|
||||||
+0xc78,0x6d540001,
|
|
||||||
+0xc78,0x6d550001,
|
|
||||||
+0xc78,0x6c560001,
|
|
||||||
+0xc78,0x6b570001,
|
|
||||||
+0xc78,0x6a580001,
|
|
||||||
+0xc78,0x6a590001,
|
|
||||||
+0xc78,0x695a0001,
|
|
||||||
+0xc78,0x685b0001,
|
|
||||||
+0xc78,0x675c0001,
|
|
||||||
+0xc78,0x665d0001,
|
|
||||||
+0xc78,0x655e0001,
|
|
||||||
+0xc78,0x645f0001,
|
|
||||||
+0xc78,0x63600001,
|
|
||||||
+0xc78,0x4c610001,
|
|
||||||
+0xc78,0x4b620001,
|
|
||||||
+0xc78,0x4a630001,
|
|
||||||
+0xc78,0x49640001,
|
|
||||||
+0xc78,0x48650001,
|
|
||||||
+0xc78,0x47660001,
|
|
||||||
+0xc78,0x46670001,
|
|
||||||
+0xc78,0x45680001,
|
|
||||||
+0xc78,0x44690001,
|
|
||||||
+0xc78,0x2c6a0001,
|
|
||||||
+0xc78,0x2b6b0001,
|
|
||||||
+0xc78,0x2a6c0001,
|
|
||||||
+0xc78,0x296d0001,
|
|
||||||
+0xc78,0x286e0001,
|
|
||||||
+0xc78,0x276f0001,
|
|
||||||
+0xc78,0x26700001,
|
|
||||||
+0xc78,0x25710001,
|
|
||||||
+0xc78,0x24720001,
|
|
||||||
+0xc78,0x23730001,
|
|
||||||
+0xc78,0x22740001,
|
|
||||||
+0xc78,0x09750001,
|
|
||||||
+0xc78,0x08760001,
|
|
||||||
+0xc78,0x07770001,
|
|
||||||
+0xc78,0x06780001,
|
|
||||||
+0xc78,0x05790001,
|
|
||||||
+0xc78,0x047a0001,
|
|
||||||
+0xc78,0x037b0001,
|
|
||||||
+0xc78,0x027c0001,
|
|
||||||
+0xc78,0x017d0001,
|
|
||||||
+0xc78,0x007e0001,
|
|
||||||
+0xc78,0x007f0001,
|
|
||||||
+0xc78,0x3000001e,
|
|
||||||
+0xc78,0x3001001e,
|
|
||||||
+0xc78,0x3002001e,
|
|
||||||
+0xc78,0x3003001e,
|
|
||||||
+0xc78,0x3004001e,
|
|
||||||
+0xc78,0x3405001e,
|
|
||||||
+0xc78,0x3806001e,
|
|
||||||
+0xc78,0x3e07001e,
|
|
||||||
+0xc78,0x3e08001e,
|
|
||||||
+0xc78,0x4409001e,
|
|
||||||
+0xc78,0x460a001e,
|
|
||||||
+0xc78,0x480b001e,
|
|
||||||
+0xc78,0x480c001e,
|
|
||||||
+0xc78,0x4e0d001e,
|
|
||||||
+0xc78,0x560e001e,
|
|
||||||
+0xc78,0x5a0f001e,
|
|
||||||
+0xc78,0x5e10001e,
|
|
||||||
+0xc78,0x6211001e,
|
|
||||||
+0xc78,0x6c12001e,
|
|
||||||
+0xc78,0x7213001e,
|
|
||||||
+0xc78,0x7214001e,
|
|
||||||
+0xc78,0x7215001e,
|
|
||||||
+0xc78,0x7216001e,
|
|
||||||
+0xc78,0x7217001e,
|
|
||||||
+0xc78,0x7218001e,
|
|
||||||
+0xc78,0x7219001e,
|
|
||||||
+0xc78,0x721a001e,
|
|
||||||
+0xc78,0x721b001e,
|
|
||||||
+0xc78,0x721c001e,
|
|
||||||
+0xc78,0x721d001e,
|
|
||||||
+0xc78,0x721e001e,
|
|
||||||
+0xc78,0x721f001e,
|
|
||||||
+};
|
|
||||||
+
|
|
|
@ -1,570 +0,0 @@
|
||||||
From 7206e64fd7590c13f4d3038d9b2139366d3e3c07 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Date: Fri, 18 Jun 2010 01:37:19 +0100
|
|
||||||
Subject: [PATCH 1/2] rtl8192u_usb: Restore lookup tables in r819xU_firmware_img.c
|
|
||||||
|
|
||||||
The upstream version of this file contains a firmware image and
|
|
||||||
lookup tables for the driver. We deleted the whole file because
|
|
||||||
we didn't build the driver. But we now want to build the driver,
|
|
||||||
so restore the lookup tables.
|
|
||||||
---
|
|
||||||
drivers/staging/rtl8192u/r819xU_firmware_img.c | 547 ++++++++++++++++++++++++
|
|
||||||
1 files changed, 547 insertions(+), 0 deletions(-)
|
|
||||||
create mode 100644 drivers/staging/rtl8192u/r819xU_firmware_img.c
|
|
||||||
|
|
||||||
diff --git a/drivers/staging/rtl8192u/r819xU_firmware_img.c b/drivers/staging/rtl8192u/r819xU_firmware_img.c
|
|
||||||
new file mode 100644
|
|
||||||
index 0000000..df0f9d1
|
|
||||||
--- /dev/null
|
|
||||||
+++ b/drivers/staging/rtl8192u/r819xU_firmware_img.c
|
|
||||||
@@ -0,0 +1,547 @@
|
|
||||||
+/*Created on 2008/ 7/16, 5:31*/
|
|
||||||
+#include <linux/types.h>
|
|
||||||
+
|
|
||||||
+u32 Rtl8192UsbPHY_REGArray[] = {
|
|
||||||
+0x0, };
|
|
||||||
+
|
|
||||||
+u32 Rtl8192UsbPHY_REG_1T2RArray[] = {
|
|
||||||
+0x800,0x00000000,
|
|
||||||
+0x804,0x00000001,
|
|
||||||
+0x808,0x0000fc00,
|
|
||||||
+0x80c,0x0000001c,
|
|
||||||
+0x810,0x801010aa,
|
|
||||||
+0x814,0x008514d0,
|
|
||||||
+0x818,0x00000040,
|
|
||||||
+0x81c,0x00000000,
|
|
||||||
+0x820,0x00000004,
|
|
||||||
+0x824,0x00690000,
|
|
||||||
+0x828,0x00000004,
|
|
||||||
+0x82c,0x00e90000,
|
|
||||||
+0x830,0x00000004,
|
|
||||||
+0x834,0x00690000,
|
|
||||||
+0x838,0x00000004,
|
|
||||||
+0x83c,0x00e90000,
|
|
||||||
+0x840,0x00000000,
|
|
||||||
+0x844,0x00000000,
|
|
||||||
+0x848,0x00000000,
|
|
||||||
+0x84c,0x00000000,
|
|
||||||
+0x850,0x00000000,
|
|
||||||
+0x854,0x00000000,
|
|
||||||
+0x858,0x65a965a9,
|
|
||||||
+0x85c,0x65a965a9,
|
|
||||||
+0x860,0x001f0010,
|
|
||||||
+0x864,0x007f0010,
|
|
||||||
+0x868,0x001f0010,
|
|
||||||
+0x86c,0x007f0010,
|
|
||||||
+0x870,0x0f100f70,
|
|
||||||
+0x874,0x0f100f70,
|
|
||||||
+0x878,0x00000000,
|
|
||||||
+0x87c,0x00000000,
|
|
||||||
+0x880,0x6870e36c,
|
|
||||||
+0x884,0xe3573600,
|
|
||||||
+0x888,0x4260c340,
|
|
||||||
+0x88c,0x0000ff00,
|
|
||||||
+0x890,0x00000000,
|
|
||||||
+0x894,0xfffffffe,
|
|
||||||
+0x898,0x4c42382f,
|
|
||||||
+0x89c,0x00656056,
|
|
||||||
+0x8b0,0x00000000,
|
|
||||||
+0x8e0,0x00000000,
|
|
||||||
+0x8e4,0x00000000,
|
|
||||||
+0x900,0x00000000,
|
|
||||||
+0x904,0x00000023,
|
|
||||||
+0x908,0x00000000,
|
|
||||||
+0x90c,0x31121311,
|
|
||||||
+0xa00,0x00d0c7d8,
|
|
||||||
+0xa04,0x811f0008,
|
|
||||||
+0xa08,0x80cd8300,
|
|
||||||
+0xa0c,0x2e62740f,
|
|
||||||
+0xa10,0x95009b78,
|
|
||||||
+0xa14,0x11145008,
|
|
||||||
+0xa18,0x00881117,
|
|
||||||
+0xa1c,0x89140fa0,
|
|
||||||
+0xa20,0x1a1b0000,
|
|
||||||
+0xa24,0x090e1317,
|
|
||||||
+0xa28,0x00000204,
|
|
||||||
+0xa2c,0x00000000,
|
|
||||||
+0xc00,0x00000040,
|
|
||||||
+0xc04,0x00005433,
|
|
||||||
+0xc08,0x000000e4,
|
|
||||||
+0xc0c,0x6c6c6c6c,
|
|
||||||
+0xc10,0x08800000,
|
|
||||||
+0xc14,0x40000100,
|
|
||||||
+0xc18,0x08000000,
|
|
||||||
+0xc1c,0x40000100,
|
|
||||||
+0xc20,0x08000000,
|
|
||||||
+0xc24,0x40000100,
|
|
||||||
+0xc28,0x08000000,
|
|
||||||
+0xc2c,0x40000100,
|
|
||||||
+0xc30,0x6de9ac44,
|
|
||||||
+0xc34,0x465c52cd,
|
|
||||||
+0xc38,0x497f5994,
|
|
||||||
+0xc3c,0x0a969764,
|
|
||||||
+0xc40,0x1f7c403f,
|
|
||||||
+0xc44,0x000100b7,
|
|
||||||
+0xc48,0xec020000,
|
|
||||||
+0xc4c,0x00000300,
|
|
||||||
+0xc50,0x69543420,
|
|
||||||
+0xc54,0x433c0094,
|
|
||||||
+0xc58,0x69543420,
|
|
||||||
+0xc5c,0x433c0094,
|
|
||||||
+0xc60,0x69543420,
|
|
||||||
+0xc64,0x433c0094,
|
|
||||||
+0xc68,0x69543420,
|
|
||||||
+0xc6c,0x433c0094,
|
|
||||||
+0xc70,0x2c7f000d,
|
|
||||||
+0xc74,0x0186175b,
|
|
||||||
+0xc78,0x0000001f,
|
|
||||||
+0xc7c,0x00b91612,
|
|
||||||
+0xc80,0x40000100,
|
|
||||||
+0xc84,0x20000000,
|
|
||||||
+0xc88,0x40000100,
|
|
||||||
+0xc8c,0x20200000,
|
|
||||||
+0xc90,0x40000100,
|
|
||||||
+0xc94,0x00000000,
|
|
||||||
+0xc98,0x40000100,
|
|
||||||
+0xc9c,0x00000000,
|
|
||||||
+0xca0,0x00492492,
|
|
||||||
+0xca4,0x00000000,
|
|
||||||
+0xca8,0x00000000,
|
|
||||||
+0xcac,0x00000000,
|
|
||||||
+0xcb0,0x00000000,
|
|
||||||
+0xcb4,0x00000000,
|
|
||||||
+0xcb8,0x00000000,
|
|
||||||
+0xcbc,0x00492492,
|
|
||||||
+0xcc0,0x00000000,
|
|
||||||
+0xcc4,0x00000000,
|
|
||||||
+0xcc8,0x00000000,
|
|
||||||
+0xccc,0x00000000,
|
|
||||||
+0xcd0,0x00000000,
|
|
||||||
+0xcd4,0x00000000,
|
|
||||||
+0xcd8,0x64b22427,
|
|
||||||
+0xcdc,0x00766932,
|
|
||||||
+0xce0,0x00222222,
|
|
||||||
+0xd00,0x00000750,
|
|
||||||
+0xd04,0x00000403,
|
|
||||||
+0xd08,0x0000907f,
|
|
||||||
+0xd0c,0x00000001,
|
|
||||||
+0xd10,0xa0633333,
|
|
||||||
+0xd14,0x33333c63,
|
|
||||||
+0xd18,0x6a8f5b6b,
|
|
||||||
+0xd1c,0x00000000,
|
|
||||||
+0xd20,0x00000000,
|
|
||||||
+0xd24,0x00000000,
|
|
||||||
+0xd28,0x00000000,
|
|
||||||
+0xd2c,0xcc979975,
|
|
||||||
+0xd30,0x00000000,
|
|
||||||
+0xd34,0x00000000,
|
|
||||||
+0xd38,0x00000000,
|
|
||||||
+0xd3c,0x00027293,
|
|
||||||
+0xd40,0x00000000,
|
|
||||||
+0xd44,0x00000000,
|
|
||||||
+0xd48,0x00000000,
|
|
||||||
+0xd4c,0x00000000,
|
|
||||||
+0xd50,0x6437140a,
|
|
||||||
+0xd54,0x024dbd02,
|
|
||||||
+0xd58,0x00000000,
|
|
||||||
+0xd5c,0x04032064,
|
|
||||||
+0xe00,0x161a1a1a,
|
|
||||||
+0xe04,0x12121416,
|
|
||||||
+0xe08,0x00001800,
|
|
||||||
+0xe0c,0x00000000,
|
|
||||||
+0xe10,0x161a1a1a,
|
|
||||||
+0xe14,0x12121416,
|
|
||||||
+0xe18,0x161a1a1a,
|
|
||||||
+0xe1c,0x12121416,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192UsbRadioA_Array[] = {
|
|
||||||
+0x019,0x00000003,
|
|
||||||
+0x000,0x000000bf,
|
|
||||||
+0x001,0x00000ee0,
|
|
||||||
+0x002,0x0000004c,
|
|
||||||
+0x003,0x000007f1,
|
|
||||||
+0x004,0x00000975,
|
|
||||||
+0x005,0x00000c58,
|
|
||||||
+0x006,0x00000ae6,
|
|
||||||
+0x007,0x000000ca,
|
|
||||||
+0x008,0x00000e1c,
|
|
||||||
+0x009,0x000007f0,
|
|
||||||
+0x00a,0x000009d0,
|
|
||||||
+0x00b,0x000001ba,
|
|
||||||
+0x00c,0x00000240,
|
|
||||||
+0x00e,0x00000020,
|
|
||||||
+0x00f,0x00000990,
|
|
||||||
+0x012,0x00000806,
|
|
||||||
+0x014,0x000005ab,
|
|
||||||
+0x015,0x00000f80,
|
|
||||||
+0x016,0x00000020,
|
|
||||||
+0x017,0x00000597,
|
|
||||||
+0x018,0x0000050a,
|
|
||||||
+0x01a,0x00000f80,
|
|
||||||
+0x01b,0x00000f5e,
|
|
||||||
+0x01c,0x00000008,
|
|
||||||
+0x01d,0x00000607,
|
|
||||||
+0x01e,0x000006cc,
|
|
||||||
+0x01f,0x00000000,
|
|
||||||
+0x020,0x000001a5,
|
|
||||||
+0x01f,0x00000001,
|
|
||||||
+0x020,0x00000165,
|
|
||||||
+0x01f,0x00000002,
|
|
||||||
+0x020,0x000000c6,
|
|
||||||
+0x01f,0x00000003,
|
|
||||||
+0x020,0x00000086,
|
|
||||||
+0x01f,0x00000004,
|
|
||||||
+0x020,0x00000046,
|
|
||||||
+0x01f,0x00000005,
|
|
||||||
+0x020,0x000001e6,
|
|
||||||
+0x01f,0x00000006,
|
|
||||||
+0x020,0x000001a6,
|
|
||||||
+0x01f,0x00000007,
|
|
||||||
+0x020,0x00000166,
|
|
||||||
+0x01f,0x00000008,
|
|
||||||
+0x020,0x000000c7,
|
|
||||||
+0x01f,0x00000009,
|
|
||||||
+0x020,0x00000087,
|
|
||||||
+0x01f,0x0000000a,
|
|
||||||
+0x020,0x000000f7,
|
|
||||||
+0x01f,0x0000000b,
|
|
||||||
+0x020,0x000000d7,
|
|
||||||
+0x01f,0x0000000c,
|
|
||||||
+0x020,0x000000b7,
|
|
||||||
+0x01f,0x0000000d,
|
|
||||||
+0x020,0x00000097,
|
|
||||||
+0x01f,0x0000000e,
|
|
||||||
+0x020,0x00000077,
|
|
||||||
+0x01f,0x0000000f,
|
|
||||||
+0x020,0x00000057,
|
|
||||||
+0x01f,0x00000010,
|
|
||||||
+0x020,0x00000037,
|
|
||||||
+0x01f,0x00000011,
|
|
||||||
+0x020,0x000000fb,
|
|
||||||
+0x01f,0x00000012,
|
|
||||||
+0x020,0x000000db,
|
|
||||||
+0x01f,0x00000013,
|
|
||||||
+0x020,0x000000bb,
|
|
||||||
+0x01f,0x00000014,
|
|
||||||
+0x020,0x000000ff,
|
|
||||||
+0x01f,0x00000015,
|
|
||||||
+0x020,0x000000e3,
|
|
||||||
+0x01f,0x00000016,
|
|
||||||
+0x020,0x000000c3,
|
|
||||||
+0x01f,0x00000017,
|
|
||||||
+0x020,0x000000a3,
|
|
||||||
+0x01f,0x00000018,
|
|
||||||
+0x020,0x00000083,
|
|
||||||
+0x01f,0x00000019,
|
|
||||||
+0x020,0x00000063,
|
|
||||||
+0x01f,0x0000001a,
|
|
||||||
+0x020,0x00000043,
|
|
||||||
+0x01f,0x0000001b,
|
|
||||||
+0x020,0x00000023,
|
|
||||||
+0x01f,0x0000001c,
|
|
||||||
+0x020,0x00000003,
|
|
||||||
+0x01f,0x0000001d,
|
|
||||||
+0x020,0x000001e3,
|
|
||||||
+0x01f,0x0000001e,
|
|
||||||
+0x020,0x000001c3,
|
|
||||||
+0x01f,0x0000001f,
|
|
||||||
+0x020,0x000001a3,
|
|
||||||
+0x01f,0x00000020,
|
|
||||||
+0x020,0x00000183,
|
|
||||||
+0x01f,0x00000021,
|
|
||||||
+0x020,0x00000163,
|
|
||||||
+0x01f,0x00000022,
|
|
||||||
+0x020,0x00000143,
|
|
||||||
+0x01f,0x00000023,
|
|
||||||
+0x020,0x00000123,
|
|
||||||
+0x01f,0x00000024,
|
|
||||||
+0x020,0x00000103,
|
|
||||||
+0x023,0x00000203,
|
|
||||||
+0x024,0x00000200,
|
|
||||||
+0x00b,0x000001ba,
|
|
||||||
+0x02c,0x000003d7,
|
|
||||||
+0x02d,0x00000ff0,
|
|
||||||
+0x000,0x00000037,
|
|
||||||
+0x004,0x00000160,
|
|
||||||
+0x007,0x00000080,
|
|
||||||
+0x002,0x0000088d,
|
|
||||||
+0x0fe,0x00000000,
|
|
||||||
+0x0fe,0x00000000,
|
|
||||||
+0x016,0x00000200,
|
|
||||||
+0x016,0x00000380,
|
|
||||||
+0x016,0x00000020,
|
|
||||||
+0x016,0x000001a0,
|
|
||||||
+0x000,0x000000bf,
|
|
||||||
+0x00d,0x0000001f,
|
|
||||||
+0x00d,0x00000c9f,
|
|
||||||
+0x002,0x0000004d,
|
|
||||||
+0x000,0x00000cbf,
|
|
||||||
+0x004,0x00000975,
|
|
||||||
+0x007,0x00000700,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192UsbRadioB_Array[] = {
|
|
||||||
+0x019,0x00000003,
|
|
||||||
+0x000,0x000000bf,
|
|
||||||
+0x001,0x000006e0,
|
|
||||||
+0x002,0x0000004c,
|
|
||||||
+0x003,0x000007f1,
|
|
||||||
+0x004,0x00000975,
|
|
||||||
+0x005,0x00000c58,
|
|
||||||
+0x006,0x00000ae6,
|
|
||||||
+0x007,0x000000ca,
|
|
||||||
+0x008,0x00000e1c,
|
|
||||||
+0x000,0x000000b7,
|
|
||||||
+0x00a,0x00000850,
|
|
||||||
+0x000,0x000000bf,
|
|
||||||
+0x00b,0x000001ba,
|
|
||||||
+0x00c,0x00000240,
|
|
||||||
+0x00e,0x00000020,
|
|
||||||
+0x015,0x00000f80,
|
|
||||||
+0x016,0x00000020,
|
|
||||||
+0x017,0x00000597,
|
|
||||||
+0x018,0x0000050a,
|
|
||||||
+0x01a,0x00000e00,
|
|
||||||
+0x01b,0x00000f5e,
|
|
||||||
+0x01d,0x00000607,
|
|
||||||
+0x01e,0x000006cc,
|
|
||||||
+0x00b,0x000001ba,
|
|
||||||
+0x023,0x00000203,
|
|
||||||
+0x024,0x00000200,
|
|
||||||
+0x000,0x00000037,
|
|
||||||
+0x004,0x00000160,
|
|
||||||
+0x016,0x00000200,
|
|
||||||
+0x016,0x00000380,
|
|
||||||
+0x016,0x00000020,
|
|
||||||
+0x016,0x000001a0,
|
|
||||||
+0x00d,0x00000ccc,
|
|
||||||
+0x000,0x000000bf,
|
|
||||||
+0x002,0x0000004d,
|
|
||||||
+0x000,0x00000cbf,
|
|
||||||
+0x004,0x00000975,
|
|
||||||
+0x007,0x00000700,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192UsbRadioC_Array[] = {
|
|
||||||
+0x0, };
|
|
||||||
+
|
|
||||||
+u32 Rtl8192UsbRadioD_Array[] = {
|
|
||||||
+0x0, };
|
|
||||||
+
|
|
||||||
+u32 Rtl8192UsbMACPHY_Array[] = {
|
|
||||||
+0x03c,0xffff0000,0x00000f0f,
|
|
||||||
+0x340,0xffffffff,0x161a1a1a,
|
|
||||||
+0x344,0xffffffff,0x12121416,
|
|
||||||
+0x348,0x0000ffff,0x00001818,
|
|
||||||
+0x12c,0xffffffff,0x04000802,
|
|
||||||
+0x318,0x00000fff,0x00000100,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192UsbMACPHY_Array_PG[] = {
|
|
||||||
+0x03c,0xffff0000,0x00000f0f,
|
|
||||||
+0xe00,0xffffffff,0x06090909,
|
|
||||||
+0xe04,0xffffffff,0x00030306,
|
|
||||||
+0xe08,0x0000ff00,0x00000000,
|
|
||||||
+0xe10,0xffffffff,0x0a0c0d0f,
|
|
||||||
+0xe14,0xffffffff,0x06070809,
|
|
||||||
+0xe18,0xffffffff,0x0a0c0d0f,
|
|
||||||
+0xe1c,0xffffffff,0x06070809,
|
|
||||||
+0x12c,0xffffffff,0x04000802,
|
|
||||||
+0x318,0x00000fff,0x00000800,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+u32 Rtl8192UsbAGCTAB_Array[] = {
|
|
||||||
+0xc78,0x7d000001,
|
|
||||||
+0xc78,0x7d010001,
|
|
||||||
+0xc78,0x7d020001,
|
|
||||||
+0xc78,0x7d030001,
|
|
||||||
+0xc78,0x7d040001,
|
|
||||||
+0xc78,0x7d050001,
|
|
||||||
+0xc78,0x7c060001,
|
|
||||||
+0xc78,0x7b070001,
|
|
||||||
+0xc78,0x7a080001,
|
|
||||||
+0xc78,0x79090001,
|
|
||||||
+0xc78,0x780a0001,
|
|
||||||
+0xc78,0x770b0001,
|
|
||||||
+0xc78,0x760c0001,
|
|
||||||
+0xc78,0x750d0001,
|
|
||||||
+0xc78,0x740e0001,
|
|
||||||
+0xc78,0x730f0001,
|
|
||||||
+0xc78,0x72100001,
|
|
||||||
+0xc78,0x71110001,
|
|
||||||
+0xc78,0x70120001,
|
|
||||||
+0xc78,0x6f130001,
|
|
||||||
+0xc78,0x6e140001,
|
|
||||||
+0xc78,0x6d150001,
|
|
||||||
+0xc78,0x6c160001,
|
|
||||||
+0xc78,0x6b170001,
|
|
||||||
+0xc78,0x6a180001,
|
|
||||||
+0xc78,0x69190001,
|
|
||||||
+0xc78,0x681a0001,
|
|
||||||
+0xc78,0x671b0001,
|
|
||||||
+0xc78,0x661c0001,
|
|
||||||
+0xc78,0x651d0001,
|
|
||||||
+0xc78,0x641e0001,
|
|
||||||
+0xc78,0x491f0001,
|
|
||||||
+0xc78,0x48200001,
|
|
||||||
+0xc78,0x47210001,
|
|
||||||
+0xc78,0x46220001,
|
|
||||||
+0xc78,0x45230001,
|
|
||||||
+0xc78,0x44240001,
|
|
||||||
+0xc78,0x43250001,
|
|
||||||
+0xc78,0x28260001,
|
|
||||||
+0xc78,0x27270001,
|
|
||||||
+0xc78,0x26280001,
|
|
||||||
+0xc78,0x25290001,
|
|
||||||
+0xc78,0x242a0001,
|
|
||||||
+0xc78,0x232b0001,
|
|
||||||
+0xc78,0x222c0001,
|
|
||||||
+0xc78,0x212d0001,
|
|
||||||
+0xc78,0x202e0001,
|
|
||||||
+0xc78,0x0a2f0001,
|
|
||||||
+0xc78,0x08300001,
|
|
||||||
+0xc78,0x06310001,
|
|
||||||
+0xc78,0x05320001,
|
|
||||||
+0xc78,0x04330001,
|
|
||||||
+0xc78,0x03340001,
|
|
||||||
+0xc78,0x02350001,
|
|
||||||
+0xc78,0x01360001,
|
|
||||||
+0xc78,0x00370001,
|
|
||||||
+0xc78,0x00380001,
|
|
||||||
+0xc78,0x00390001,
|
|
||||||
+0xc78,0x003a0001,
|
|
||||||
+0xc78,0x003b0001,
|
|
||||||
+0xc78,0x003c0001,
|
|
||||||
+0xc78,0x003d0001,
|
|
||||||
+0xc78,0x003e0001,
|
|
||||||
+0xc78,0x003f0001,
|
|
||||||
+0xc78,0x7d400001,
|
|
||||||
+0xc78,0x7d410001,
|
|
||||||
+0xc78,0x7d420001,
|
|
||||||
+0xc78,0x7d430001,
|
|
||||||
+0xc78,0x7d440001,
|
|
||||||
+0xc78,0x7d450001,
|
|
||||||
+0xc78,0x7c460001,
|
|
||||||
+0xc78,0x7b470001,
|
|
||||||
+0xc78,0x7a480001,
|
|
||||||
+0xc78,0x79490001,
|
|
||||||
+0xc78,0x784a0001,
|
|
||||||
+0xc78,0x774b0001,
|
|
||||||
+0xc78,0x764c0001,
|
|
||||||
+0xc78,0x754d0001,
|
|
||||||
+0xc78,0x744e0001,
|
|
||||||
+0xc78,0x734f0001,
|
|
||||||
+0xc78,0x72500001,
|
|
||||||
+0xc78,0x71510001,
|
|
||||||
+0xc78,0x70520001,
|
|
||||||
+0xc78,0x6f530001,
|
|
||||||
+0xc78,0x6e540001,
|
|
||||||
+0xc78,0x6d550001,
|
|
||||||
+0xc78,0x6c560001,
|
|
||||||
+0xc78,0x6b570001,
|
|
||||||
+0xc78,0x6a580001,
|
|
||||||
+0xc78,0x69590001,
|
|
||||||
+0xc78,0x685a0001,
|
|
||||||
+0xc78,0x675b0001,
|
|
||||||
+0xc78,0x665c0001,
|
|
||||||
+0xc78,0x655d0001,
|
|
||||||
+0xc78,0x645e0001,
|
|
||||||
+0xc78,0x495f0001,
|
|
||||||
+0xc78,0x48600001,
|
|
||||||
+0xc78,0x47610001,
|
|
||||||
+0xc78,0x46620001,
|
|
||||||
+0xc78,0x45630001,
|
|
||||||
+0xc78,0x44640001,
|
|
||||||
+0xc78,0x43650001,
|
|
||||||
+0xc78,0x28660001,
|
|
||||||
+0xc78,0x27670001,
|
|
||||||
+0xc78,0x26680001,
|
|
||||||
+0xc78,0x25690001,
|
|
||||||
+0xc78,0x246a0001,
|
|
||||||
+0xc78,0x236b0001,
|
|
||||||
+0xc78,0x226c0001,
|
|
||||||
+0xc78,0x216d0001,
|
|
||||||
+0xc78,0x206e0001,
|
|
||||||
+0xc78,0x0a6f0001,
|
|
||||||
+0xc78,0x08700001,
|
|
||||||
+0xc78,0x06710001,
|
|
||||||
+0xc78,0x05720001,
|
|
||||||
+0xc78,0x04730001,
|
|
||||||
+0xc78,0x03740001,
|
|
||||||
+0xc78,0x02750001,
|
|
||||||
+0xc78,0x01760001,
|
|
||||||
+0xc78,0x00770001,
|
|
||||||
+0xc78,0x00780001,
|
|
||||||
+0xc78,0x00790001,
|
|
||||||
+0xc78,0x007a0001,
|
|
||||||
+0xc78,0x007b0001,
|
|
||||||
+0xc78,0x007c0001,
|
|
||||||
+0xc78,0x007d0001,
|
|
||||||
+0xc78,0x007e0001,
|
|
||||||
+0xc78,0x007f0001,
|
|
||||||
+0xc78,0x2e00001e,
|
|
||||||
+0xc78,0x2e01001e,
|
|
||||||
+0xc78,0x2e02001e,
|
|
||||||
+0xc78,0x2e03001e,
|
|
||||||
+0xc78,0x2e04001e,
|
|
||||||
+0xc78,0x2e05001e,
|
|
||||||
+0xc78,0x3006001e,
|
|
||||||
+0xc78,0x3407001e,
|
|
||||||
+0xc78,0x3908001e,
|
|
||||||
+0xc78,0x3c09001e,
|
|
||||||
+0xc78,0x3f0a001e,
|
|
||||||
+0xc78,0x420b001e,
|
|
||||||
+0xc78,0x440c001e,
|
|
||||||
+0xc78,0x450d001e,
|
|
||||||
+0xc78,0x460e001e,
|
|
||||||
+0xc78,0x460f001e,
|
|
||||||
+0xc78,0x4710001e,
|
|
||||||
+0xc78,0x4811001e,
|
|
||||||
+0xc78,0x4912001e,
|
|
||||||
+0xc78,0x4a13001e,
|
|
||||||
+0xc78,0x4b14001e,
|
|
||||||
+0xc78,0x4b15001e,
|
|
||||||
+0xc78,0x4c16001e,
|
|
||||||
+0xc78,0x4d17001e,
|
|
||||||
+0xc78,0x4e18001e,
|
|
||||||
+0xc78,0x4f19001e,
|
|
||||||
+0xc78,0x4f1a001e,
|
|
||||||
+0xc78,0x501b001e,
|
|
||||||
+0xc78,0x511c001e,
|
|
||||||
+0xc78,0x521d001e,
|
|
||||||
+0xc78,0x521e001e,
|
|
||||||
+0xc78,0x531f001e,
|
|
||||||
+0xc78,0x5320001e,
|
|
||||||
+0xc78,0x5421001e,
|
|
||||||
+0xc78,0x5522001e,
|
|
||||||
+0xc78,0x5523001e,
|
|
||||||
+0xc78,0x5624001e,
|
|
||||||
+0xc78,0x5725001e,
|
|
||||||
+0xc78,0x5726001e,
|
|
||||||
+0xc78,0x5827001e,
|
|
||||||
+0xc78,0x5828001e,
|
|
||||||
+0xc78,0x5929001e,
|
|
||||||
+0xc78,0x592a001e,
|
|
||||||
+0xc78,0x5a2b001e,
|
|
||||||
+0xc78,0x5b2c001e,
|
|
||||||
+0xc78,0x5c2d001e,
|
|
||||||
+0xc78,0x5c2e001e,
|
|
||||||
+0xc78,0x5d2f001e,
|
|
||||||
+0xc78,0x5e30001e,
|
|
||||||
+0xc78,0x5f31001e,
|
|
||||||
+0xc78,0x6032001e,
|
|
||||||
+0xc78,0x6033001e,
|
|
||||||
+0xc78,0x6134001e,
|
|
||||||
+0xc78,0x6235001e,
|
|
||||||
+0xc78,0x6336001e,
|
|
||||||
+0xc78,0x6437001e,
|
|
||||||
+0xc78,0x6438001e,
|
|
||||||
+0xc78,0x6539001e,
|
|
||||||
+0xc78,0x663a001e,
|
|
||||||
+0xc78,0x673b001e,
|
|
||||||
+0xc78,0x673c001e,
|
|
||||||
+0xc78,0x683d001e,
|
|
||||||
+0xc78,0x693e001e,
|
|
||||||
+0xc78,0x6a3f001e,
|
|
||||||
+};
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -6,11 +6,11 @@ index 44203ff..964bab1 100644
|
||||||
#include <asm/irq_regs.h>
|
#include <asm/irq_regs.h>
|
||||||
|
|
||||||
/* Whether we react on sysrq keys or just ignore them */
|
/* Whether we react on sysrq keys or just ignore them */
|
||||||
-int __read_mostly __sysrq_enabled = 1;
|
-static int __read_mostly sysrq_enabled = 1;
|
||||||
+int __read_mostly __sysrq_enabled = CONFIG_MAGIC_SYSRQ_DEFAULT_MASK;
|
+static int __read_mostly sysrq_enabled = CONFIG_MAGIC_SYSRQ_DEFAULT_MASK;
|
||||||
|
static bool __read_mostly sysrq_always_enabled;
|
||||||
static int __read_mostly sysrq_always_enabled;
|
|
||||||
|
|
||||||
|
static bool sysrq_on(void)
|
||||||
diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
|
diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
|
||||||
index 234ceb1..415a834 100644
|
index 234ceb1..415a834 100644
|
||||||
--- a/lib/Kconfig.debug
|
--- a/lib/Kconfig.debug
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
diff --git a/init/version.c b/init/version.c
|
|
||||||
index 9d17d70..ef8aa6e 100644
|
|
||||||
--- a/init/version.c
|
--- a/init/version.c
|
||||||
+++ b/init/version.c
|
+++ b/init/version.c
|
||||||
@@ -33,12 +33,31 @@ struct uts_namespace init_uts_ns = {
|
@@ -36,12 +36,31 @@ struct uts_namespace init_uts_ns = {
|
||||||
};
|
};
|
||||||
EXPORT_SYMBOL_GPL(init_uts_ns);
|
EXPORT_SYMBOL_GPL(init_uts_ns);
|
||||||
|
|
||||||
|
@ -37,20 +35,17 @@ index 9d17d70..ef8aa6e 100644
|
||||||
" (" LINUX_COMPILE_BY "@" LINUX_COMPILE_HOST ")"
|
" (" LINUX_COMPILE_BY "@" LINUX_COMPILE_HOST ")"
|
||||||
+#endif
|
+#endif
|
||||||
" (" LINUX_COMPILER ") %s\n";
|
" (" LINUX_COMPILER ") %s\n";
|
||||||
diff --git a/scripts/mkcompile_h b/scripts/mkcompile_h
|
|
||||||
index 82d0af4..d8e0d05 100755
|
|
||||||
--- a/scripts/mkcompile_h
|
--- a/scripts/mkcompile_h
|
||||||
+++ b/scripts/mkcompile_h
|
+++ b/scripts/mkcompile_h
|
||||||
@@ -47,19 +47,34 @@ UTS_TRUNCATE="sed -e s/\(.\{1,$UTS_LEN\}\).*/\1/"
|
@@ -64,18 +64,34 @@ UTS_TRUNCATE="sed -e s/\(.\{1,$UTS_LEN\}\).*/\1/"
|
||||||
echo \#define UTS_VERSION \"`echo $UTS_VERSION | $UTS_TRUNCATE`\"
|
echo \#define UTS_VERSION \"`echo $UTS_VERSION | $UTS_TRUNCATE`\"
|
||||||
|
|
||||||
echo \#define LINUX_COMPILE_TIME \"`date +%T`\"
|
echo \#define LINUX_COMPILE_TIME \"`date +%T`\"
|
||||||
- echo \#define LINUX_COMPILE_BY \"`whoami`\"
|
- echo \#define LINUX_COMPILE_BY \"`whoami`\"
|
||||||
- echo \#define LINUX_COMPILE_HOST \"`hostname | $UTS_TRUNCATE`\"
|
- echo \#define LINUX_COMPILE_HOST \"`hostname | $UTS_TRUNCATE`\"
|
||||||
|
|
||||||
- if [ -x /bin/dnsdomainname ]; then
|
- domain=`dnsdomainname 2> /dev/null`
|
||||||
- domain=`dnsdomainname 2> /dev/null`
|
- if [ -z "$domain" ]; then
|
||||||
- elif [ -x /bin/domainname ]; then
|
|
||||||
- domain=`domainname 2> /dev/null`
|
- domain=`domainname 2> /dev/null`
|
||||||
- fi
|
- fi
|
||||||
-
|
-
|
||||||
|
|
|
@ -1,163 +0,0 @@
|
||||||
From: Arnaud Patard <apatard@mandriva.com>
|
|
||||||
Date: Thu, 29 Apr 2010 11:58:44 +0200
|
|
||||||
Subject: [PATCH] RTC: rtc-cmos: Fix binary mode support
|
|
||||||
|
|
||||||
commit 3804a89bfb84fb8849c72e3bbafddaee539b3430 upstream.
|
|
||||||
|
|
||||||
As a follow-up to the thread about RTC support for some Loongson 2E/2F
|
|
||||||
boards, this patch tries to address the "REVISIT"/"FIXME" comments about
|
|
||||||
rtc binary mode handling and allow rtc to work with rtc in binary mode.
|
|
||||||
I've also raised the message about 24-h mode not supported to warning
|
|
||||||
otherwise, one may end up with no rtc without any message in the kernel
|
|
||||||
log.
|
|
||||||
|
|
||||||
Signed-off-by: Arnaud Patard <apatard@mandriva.com>
|
|
||||||
To: linux-mips@linux-mips.org
|
|
||||||
To: rtc-linux@googlegroups.com
|
|
||||||
Cc: david-b@pacbell.net
|
|
||||||
Cc: a.zummo@towertech.it
|
|
||||||
Cc: akpm@linux-foundation.org
|
|
||||||
Patchwork: http://patchwork.linux-mips.org/patch/1158/
|
|
||||||
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
|
|
||||||
---
|
|
||||||
drivers/rtc/rtc-cmos.c | 83 +++++++++++++++++++++++-------------------------
|
|
||||||
1 files changed, 40 insertions(+), 43 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/rtc/rtc-cmos.c b/drivers/rtc/rtc-cmos.c
|
|
||||||
index ece4dbd..96e8e70 100644
|
|
||||||
--- a/drivers/rtc/rtc-cmos.c
|
|
||||||
+++ b/drivers/rtc/rtc-cmos.c
|
|
||||||
@@ -238,31 +238,32 @@ static int cmos_read_alarm(struct device *dev, struct rtc_wkalrm *t)
|
|
||||||
rtc_control = CMOS_READ(RTC_CONTROL);
|
|
||||||
spin_unlock_irq(&rtc_lock);
|
|
||||||
|
|
||||||
- /* REVISIT this assumes PC style usage: always BCD */
|
|
||||||
-
|
|
||||||
- if (((unsigned)t->time.tm_sec) < 0x60)
|
|
||||||
- t->time.tm_sec = bcd2bin(t->time.tm_sec);
|
|
||||||
- else
|
|
||||||
- t->time.tm_sec = -1;
|
|
||||||
- if (((unsigned)t->time.tm_min) < 0x60)
|
|
||||||
- t->time.tm_min = bcd2bin(t->time.tm_min);
|
|
||||||
- else
|
|
||||||
- t->time.tm_min = -1;
|
|
||||||
- if (((unsigned)t->time.tm_hour) < 0x24)
|
|
||||||
- t->time.tm_hour = bcd2bin(t->time.tm_hour);
|
|
||||||
- else
|
|
||||||
- t->time.tm_hour = -1;
|
|
||||||
-
|
|
||||||
- if (cmos->day_alrm) {
|
|
||||||
- if (((unsigned)t->time.tm_mday) <= 0x31)
|
|
||||||
- t->time.tm_mday = bcd2bin(t->time.tm_mday);
|
|
||||||
+ if (!(rtc_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) {
|
|
||||||
+ if (((unsigned)t->time.tm_sec) < 0x60)
|
|
||||||
+ t->time.tm_sec = bcd2bin(t->time.tm_sec);
|
|
||||||
else
|
|
||||||
- t->time.tm_mday = -1;
|
|
||||||
- if (cmos->mon_alrm) {
|
|
||||||
- if (((unsigned)t->time.tm_mon) <= 0x12)
|
|
||||||
- t->time.tm_mon = bcd2bin(t->time.tm_mon) - 1;
|
|
||||||
+ t->time.tm_sec = -1;
|
|
||||||
+ if (((unsigned)t->time.tm_min) < 0x60)
|
|
||||||
+ t->time.tm_min = bcd2bin(t->time.tm_min);
|
|
||||||
+ else
|
|
||||||
+ t->time.tm_min = -1;
|
|
||||||
+ if (((unsigned)t->time.tm_hour) < 0x24)
|
|
||||||
+ t->time.tm_hour = bcd2bin(t->time.tm_hour);
|
|
||||||
+ else
|
|
||||||
+ t->time.tm_hour = -1;
|
|
||||||
+
|
|
||||||
+ if (cmos->day_alrm) {
|
|
||||||
+ if (((unsigned)t->time.tm_mday) <= 0x31)
|
|
||||||
+ t->time.tm_mday = bcd2bin(t->time.tm_mday);
|
|
||||||
else
|
|
||||||
- t->time.tm_mon = -1;
|
|
||||||
+ t->time.tm_mday = -1;
|
|
||||||
+
|
|
||||||
+ if (cmos->mon_alrm) {
|
|
||||||
+ if (((unsigned)t->time.tm_mon) <= 0x12)
|
|
||||||
+ t->time.tm_mon = bcd2bin(t->time.tm_mon)-1;
|
|
||||||
+ else
|
|
||||||
+ t->time.tm_mon = -1;
|
|
||||||
+ }
|
|
||||||
}
|
|
||||||
}
|
|
||||||
t->time.tm_year = -1;
|
|
||||||
@@ -322,29 +323,26 @@ static void cmos_irq_disable(struct cmos_rtc *cmos, unsigned char mask)
|
|
||||||
static int cmos_set_alarm(struct device *dev, struct rtc_wkalrm *t)
|
|
||||||
{
|
|
||||||
struct cmos_rtc *cmos = dev_get_drvdata(dev);
|
|
||||||
- unsigned char mon, mday, hrs, min, sec;
|
|
||||||
+ unsigned char mon, mday, hrs, min, sec, rtc_control;
|
|
||||||
|
|
||||||
if (!is_valid_irq(cmos->irq))
|
|
||||||
return -EIO;
|
|
||||||
|
|
||||||
- /* REVISIT this assumes PC style usage: always BCD */
|
|
||||||
-
|
|
||||||
- /* Writing 0xff means "don't care" or "match all". */
|
|
||||||
-
|
|
||||||
mon = t->time.tm_mon + 1;
|
|
||||||
- mon = (mon <= 12) ? bin2bcd(mon) : 0xff;
|
|
||||||
-
|
|
||||||
mday = t->time.tm_mday;
|
|
||||||
- mday = (mday >= 1 && mday <= 31) ? bin2bcd(mday) : 0xff;
|
|
||||||
-
|
|
||||||
hrs = t->time.tm_hour;
|
|
||||||
- hrs = (hrs < 24) ? bin2bcd(hrs) : 0xff;
|
|
||||||
-
|
|
||||||
min = t->time.tm_min;
|
|
||||||
- min = (min < 60) ? bin2bcd(min) : 0xff;
|
|
||||||
-
|
|
||||||
sec = t->time.tm_sec;
|
|
||||||
- sec = (sec < 60) ? bin2bcd(sec) : 0xff;
|
|
||||||
+
|
|
||||||
+ rtc_control = CMOS_READ(RTC_CONTROL);
|
|
||||||
+ if (!(rtc_control & RTC_DM_BINARY) || RTC_ALWAYS_BCD) {
|
|
||||||
+ /* Writing 0xff means "don't care" or "match all". */
|
|
||||||
+ mon = (mon <= 12) ? bin2bcd(mon) : 0xff;
|
|
||||||
+ mday = (mday >= 1 && mday <= 31) ? bin2bcd(mday) : 0xff;
|
|
||||||
+ hrs = (hrs < 24) ? bin2bcd(hrs) : 0xff;
|
|
||||||
+ min = (min < 60) ? bin2bcd(min) : 0xff;
|
|
||||||
+ sec = (sec < 60) ? bin2bcd(sec) : 0xff;
|
|
||||||
+ }
|
|
||||||
|
|
||||||
spin_lock_irq(&rtc_lock);
|
|
||||||
|
|
||||||
@@ -478,7 +476,7 @@ static int cmos_procfs(struct device *dev, struct seq_file *seq)
|
|
||||||
"update_IRQ\t: %s\n"
|
|
||||||
"HPET_emulated\t: %s\n"
|
|
||||||
// "square_wave\t: %s\n"
|
|
||||||
- // "BCD\t\t: %s\n"
|
|
||||||
+ "BCD\t\t: %s\n"
|
|
||||||
"DST_enable\t: %s\n"
|
|
||||||
"periodic_freq\t: %d\n"
|
|
||||||
"batt_status\t: %s\n",
|
|
||||||
@@ -486,7 +484,7 @@ static int cmos_procfs(struct device *dev, struct seq_file *seq)
|
|
||||||
(rtc_control & RTC_UIE) ? "yes" : "no",
|
|
||||||
is_hpet_enabled() ? "yes" : "no",
|
|
||||||
// (rtc_control & RTC_SQWE) ? "yes" : "no",
|
|
||||||
- // (rtc_control & RTC_DM_BINARY) ? "no" : "yes",
|
|
||||||
+ (rtc_control & RTC_DM_BINARY) ? "no" : "yes",
|
|
||||||
(rtc_control & RTC_DST_EN) ? "yes" : "no",
|
|
||||||
cmos->rtc->irq_freq,
|
|
||||||
(valid & RTC_VRT) ? "okay" : "dead");
|
|
||||||
@@ -751,12 +749,11 @@ cmos_do_probe(struct device *dev, struct resource *ports, int rtc_irq)
|
|
||||||
|
|
||||||
spin_unlock_irq(&rtc_lock);
|
|
||||||
|
|
||||||
- /* FIXME teach the alarm code how to handle binary mode;
|
|
||||||
+ /* FIXME:
|
|
||||||
* <asm-generic/rtc.h> doesn't know 12-hour mode either.
|
|
||||||
*/
|
|
||||||
- if (is_valid_irq(rtc_irq) &&
|
|
||||||
- (!(rtc_control & RTC_24H) || (rtc_control & (RTC_DM_BINARY)))) {
|
|
||||||
- dev_dbg(dev, "only 24-hr BCD mode supported\n");
|
|
||||||
+ if (is_valid_irq(rtc_irq) && !(rtc_control & RTC_24H)) {
|
|
||||||
+ dev_warn(dev, "only 24-hr supported\n");
|
|
||||||
retval = -ENXIO;
|
|
||||||
goto cleanup1;
|
|
||||||
}
|
|
||||||
--
|
|
||||||
1.7.1
|
|
||||||
|
|
|
@ -1,230 +0,0 @@
|
||||||
From 1e9da7da73886eaf63449e56ebf16cf7daa4a9e5 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Date: Mon, 17 Aug 2009 02:17:09 +0100
|
|
||||||
Subject: [PATCH 3/3] ib_ipath: use request_firmware() to load SD7220 firmware
|
|
||||||
|
|
||||||
---
|
|
||||||
drivers/infiniband/hw/ipath/Makefile | 7 ++--
|
|
||||||
drivers/infiniband/hw/ipath/ipath_7220.h | 7 ----
|
|
||||||
drivers/infiniband/hw/ipath/ipath_driver.c | 4 --
|
|
||||||
drivers/infiniband/hw/ipath/ipath_sd7220.c | 49 ++++++++++++++++++++++-----
|
|
||||||
4 files changed, 43 insertions(+), 24 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/infiniband/hw/ipath/Makefile b/drivers/infiniband/hw/ipath/Makefile
|
|
||||||
index 42d8d4c..fc892cf 100644
|
|
||||||
--- a/drivers/infiniband/hw/ipath/Makefile
|
|
||||||
+++ b/drivers/infiniband/hw/ipath/Makefile
|
|
||||||
@@ -29,10 +29,9 @@ ib_ipath-y := \
|
|
||||||
ipath_user_pages.o \
|
|
||||||
ipath_user_sdma.o \
|
|
||||||
ipath_verbs_mcast.o \
|
|
||||||
- ipath_verbs.o
|
|
||||||
-
|
|
||||||
-# IBA7220 depends on firmware to be removed
|
|
||||||
-ib_ipath-$(CONFIG_BROKEN) += ipath_iba7220.o ipath_sd7220.o
|
|
||||||
+ ipath_verbs.o \
|
|
||||||
+ ipath_iba7220.o \
|
|
||||||
+ ipath_sd7220.o
|
|
||||||
|
|
||||||
ib_ipath-$(CONFIG_HT_IRQ) += ipath_iba6110.o
|
|
||||||
ib_ipath-$(CONFIG_PCI_MSI) += ipath_iba6120.o
|
|
||||||
diff --git a/drivers/infiniband/hw/ipath/ipath_7220.h b/drivers/infiniband/hw/ipath/ipath_7220.h
|
|
||||||
index 74fa5cc..29a73e0 100644
|
|
||||||
--- a/drivers/infiniband/hw/ipath/ipath_7220.h
|
|
||||||
+++ b/drivers/infiniband/hw/ipath/ipath_7220.h
|
|
||||||
@@ -40,10 +40,6 @@
|
|
||||||
*/
|
|
||||||
int ipath_sd7220_presets(struct ipath_devdata *dd);
|
|
||||||
int ipath_sd7220_init(struct ipath_devdata *dd, int was_reset);
|
|
||||||
-int ipath_sd7220_prog_ld(struct ipath_devdata *dd, int sdnum, u8 *img,
|
|
||||||
- int len, int offset);
|
|
||||||
-int ipath_sd7220_prog_vfy(struct ipath_devdata *dd, int sdnum, const u8 *img,
|
|
||||||
- int len, int offset);
|
|
||||||
/*
|
|
||||||
* Below used for sdnum parameter, selecting one of the two sections
|
|
||||||
* used for PCIe, or the single SerDes used for IB, which is the
|
|
||||||
@@ -51,7 +47,4 @@ int ipath_sd7220_prog_vfy(struct ipath_devdata *dd, int sdnum, const u8 *img,
|
|
||||||
*/
|
|
||||||
#define IB_7220_SERDES 2
|
|
||||||
|
|
||||||
-int ipath_sd7220_ib_load(struct ipath_devdata *dd);
|
|
||||||
-int ipath_sd7220_ib_vfy(struct ipath_devdata *dd);
|
|
||||||
-
|
|
||||||
#endif /* _IPATH_7220_H */
|
|
||||||
diff --git a/drivers/infiniband/hw/ipath/ipath_driver.c b/drivers/infiniband/hw/ipath/ipath_driver.c
|
|
||||||
index 20407a0..04e88b6 100644
|
|
||||||
--- a/drivers/infiniband/hw/ipath/ipath_driver.c
|
|
||||||
+++ b/drivers/infiniband/hw/ipath/ipath_driver.c
|
|
||||||
@@ -140,9 +140,7 @@ static int __devinit ipath_init_one(struct pci_dev *,
|
|
||||||
static const struct pci_device_id ipath_pci_tbl[] = {
|
|
||||||
{ PCI_DEVICE(PCI_VENDOR_ID_PATHSCALE, PCI_DEVICE_ID_INFINIPATH_HT) },
|
|
||||||
{ PCI_DEVICE(PCI_VENDOR_ID_PATHSCALE, PCI_DEVICE_ID_INFINIPATH_PE800) },
|
|
||||||
-#ifdef CONFIG_BROKEN
|
|
||||||
{ PCI_DEVICE(PCI_VENDOR_ID_QLOGIC, PCI_DEVICE_ID_INFINIPATH_7220) },
|
|
||||||
-#endif
|
|
||||||
{ 0, }
|
|
||||||
};
|
|
||||||
|
|
||||||
@@ -537,7 +535,6 @@ static int __devinit ipath_init_one(struct pci_dev *pdev,
|
|
||||||
"CONFIG_PCI_MSI is not enabled\n", ent->device);
|
|
||||||
return -ENODEV;
|
|
||||||
#endif
|
|
||||||
-#ifdef CONFIG_BROKEN
|
|
||||||
case PCI_DEVICE_ID_INFINIPATH_7220:
|
|
||||||
#ifndef CONFIG_PCI_MSI
|
|
||||||
ipath_dbg("CONFIG_PCI_MSI is not enabled, "
|
|
||||||
@@ -545,7 +542,6 @@ static int __devinit ipath_init_one(struct pci_dev *pdev,
|
|
||||||
#endif
|
|
||||||
ipath_init_iba7220_funcs(dd);
|
|
||||||
break;
|
|
||||||
-#endif
|
|
||||||
default:
|
|
||||||
ipath_dev_err(dd, "Found unknown QLogic deviceid 0x%x, "
|
|
||||||
"failing\n", ent->device);
|
|
||||||
diff --git a/drivers/infiniband/hw/ipath/ipath_sd7220.c b/drivers/infiniband/hw/ipath/ipath_sd7220.c
|
|
||||||
index aa47eb5..df3735d 100644
|
|
||||||
--- a/drivers/infiniband/hw/ipath/ipath_sd7220.c
|
|
||||||
+++ b/drivers/infiniband/hw/ipath/ipath_sd7220.c
|
|
||||||
@@ -37,11 +37,15 @@
|
|
||||||
|
|
||||||
#include <linux/pci.h>
|
|
||||||
#include <linux/delay.h>
|
|
||||||
+#include <linux/firmware.h>
|
|
||||||
|
|
||||||
#include "ipath_kernel.h"
|
|
||||||
#include "ipath_registers.h"
|
|
||||||
#include "ipath_7220.h"
|
|
||||||
|
|
||||||
+#define SD7220_FW_NAME "qlogic/sd7220.fw"
|
|
||||||
+MODULE_FIRMWARE(SD7220_FW_NAME);
|
|
||||||
+
|
|
||||||
/*
|
|
||||||
* The IBSerDesMappTable is a memory that holds values to be stored in
|
|
||||||
* various SerDes registers by IBC. It is not part of the normal kregs
|
|
||||||
@@ -88,6 +92,11 @@ static int ipath_internal_presets(struct ipath_devdata *dd);
|
|
||||||
static int ipath_sd_trimself(struct ipath_devdata *dd, int val);
|
|
||||||
static int epb_access(struct ipath_devdata *dd, int sdnum, int claim);
|
|
||||||
|
|
||||||
+static int
|
|
||||||
+ipath_sd7220_ib_load(struct ipath_devdata *dd, const struct firmware *fw);
|
|
||||||
+static int
|
|
||||||
+ipath_sd7220_ib_vfy(struct ipath_devdata *dd, const struct firmware *fw);
|
|
||||||
+
|
|
||||||
void ipath_set_relock_poll(struct ipath_devdata *dd, int ibup);
|
|
||||||
|
|
||||||
/*
|
|
||||||
@@ -98,9 +107,10 @@ void ipath_set_relock_poll(struct ipath_devdata *dd, int ibup);
|
|
||||||
* ipath_sd7220_init() is no longer valid. Instead, we check for the
|
|
||||||
* actual uC code having been loaded.
|
|
||||||
*/
|
|
||||||
-static int ipath_ibsd_ucode_loaded(struct ipath_devdata *dd)
|
|
||||||
+static int
|
|
||||||
+ipath_ibsd_ucode_loaded(struct ipath_devdata *dd, const struct firmware *fw)
|
|
||||||
{
|
|
||||||
- if (!dd->serdes_first_init_done && (ipath_sd7220_ib_vfy(dd) > 0))
|
|
||||||
+ if (!dd->serdes_first_init_done && (ipath_sd7220_ib_vfy(dd, fw) > 0))
|
|
||||||
dd->serdes_first_init_done = 1;
|
|
||||||
return dd->serdes_first_init_done;
|
|
||||||
}
|
|
||||||
@@ -363,6 +373,7 @@ static void ipath_sd_trimdone_monitor(struct ipath_devdata *dd,
|
|
||||||
*/
|
|
||||||
int ipath_sd7220_init(struct ipath_devdata *dd, int was_reset)
|
|
||||||
{
|
|
||||||
+ const struct firmware *fw;
|
|
||||||
int ret = 1; /* default to failure */
|
|
||||||
int first_reset;
|
|
||||||
int val_stat;
|
|
||||||
@@ -373,8 +384,14 @@ int ipath_sd7220_init(struct ipath_devdata *dd, int was_reset)
|
|
||||||
ipath_sd_trimdone_monitor(dd, "Driver-reload");
|
|
||||||
}
|
|
||||||
|
|
||||||
+ ret = request_firmware(&fw, SD7220_FW_NAME, &dd->pcidev->dev);
|
|
||||||
+ if (ret) {
|
|
||||||
+ ipath_dev_err(dd, "Failed to load IB SERDES image\n");
|
|
||||||
+ goto done;
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
/* Substitute our deduced value for was_reset */
|
|
||||||
- ret = ipath_ibsd_ucode_loaded(dd);
|
|
||||||
+ ret = ipath_ibsd_ucode_loaded(dd, fw);
|
|
||||||
if (ret < 0) {
|
|
||||||
ret = 1;
|
|
||||||
goto done;
|
|
||||||
@@ -431,7 +448,7 @@ int ipath_sd7220_init(struct ipath_devdata *dd, int was_reset)
|
|
||||||
int vfy;
|
|
||||||
int trim_done;
|
|
||||||
ipath_dbg("SerDes uC was reset, reloading PRAM\n");
|
|
||||||
- ret = ipath_sd7220_ib_load(dd);
|
|
||||||
+ ret = ipath_sd7220_ib_load(dd, fw);
|
|
||||||
if (ret < 0) {
|
|
||||||
ipath_dev_err(dd, "Failed to load IB SERDES image\n");
|
|
||||||
ret = 1;
|
|
||||||
@@ -439,7 +456,7 @@ int ipath_sd7220_init(struct ipath_devdata *dd, int was_reset)
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Loaded image, try to verify */
|
|
||||||
- vfy = ipath_sd7220_ib_vfy(dd);
|
|
||||||
+ vfy = ipath_sd7220_ib_vfy(dd, fw);
|
|
||||||
if (vfy != ret) {
|
|
||||||
ipath_dev_err(dd, "SERDES PRAM VFY failed\n");
|
|
||||||
ret = 1;
|
|
||||||
@@ -500,6 +517,8 @@ int ipath_sd7220_init(struct ipath_devdata *dd, int was_reset)
|
|
||||||
done:
|
|
||||||
/* start relock timer regardless, but start at 1 second */
|
|
||||||
ipath_set_relock_poll(dd, -1);
|
|
||||||
+
|
|
||||||
+ release_firmware(fw);
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -836,8 +855,8 @@ static int ipath_sd7220_ram_xfer(struct ipath_devdata *dd, int sdnum, u32 loc,
|
|
||||||
|
|
||||||
#define PROG_CHUNK 64
|
|
||||||
|
|
||||||
-int ipath_sd7220_prog_ld(struct ipath_devdata *dd, int sdnum,
|
|
||||||
- u8 *img, int len, int offset)
|
|
||||||
+static int ipath_sd7220_prog_ld(struct ipath_devdata *dd, int sdnum,
|
|
||||||
+ const u8 *img, int len, int offset)
|
|
||||||
{
|
|
||||||
int cnt, sofar, req;
|
|
||||||
|
|
||||||
@@ -847,7 +866,7 @@ int ipath_sd7220_prog_ld(struct ipath_devdata *dd, int sdnum,
|
|
||||||
if (req > PROG_CHUNK)
|
|
||||||
req = PROG_CHUNK;
|
|
||||||
cnt = ipath_sd7220_ram_xfer(dd, sdnum, offset + sofar,
|
|
||||||
- img + sofar, req, 0);
|
|
||||||
+ (u8 *)img + sofar, req, 0);
|
|
||||||
if (cnt < req) {
|
|
||||||
sofar = -1;
|
|
||||||
break;
|
|
||||||
@@ -860,7 +879,7 @@ int ipath_sd7220_prog_ld(struct ipath_devdata *dd, int sdnum,
|
|
||||||
#define VFY_CHUNK 64
|
|
||||||
#define SD_PRAM_ERROR_LIMIT 42
|
|
||||||
|
|
||||||
-int ipath_sd7220_prog_vfy(struct ipath_devdata *dd, int sdnum,
|
|
||||||
+static int ipath_sd7220_prog_vfy(struct ipath_devdata *dd, int sdnum,
|
|
||||||
const u8 *img, int len, int offset)
|
|
||||||
{
|
|
||||||
int cnt, sofar, req, idx, errors;
|
|
||||||
@@ -888,6 +907,18 @@ int ipath_sd7220_prog_vfy(struct ipath_devdata *dd, int sdnum,
|
|
||||||
return errors ? -errors : sofar;
|
|
||||||
}
|
|
||||||
|
|
||||||
+static int
|
|
||||||
+ipath_sd7220_ib_load(struct ipath_devdata *dd, const struct firmware *fw)
|
|
||||||
+{
|
|
||||||
+ return ipath_sd7220_prog_ld(dd, IB_7220_SERDES, fw->data, fw->size, 0);
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
+static int
|
|
||||||
+ipath_sd7220_ib_vfy(struct ipath_devdata *dd, const struct firmware *fw)
|
|
||||||
+{
|
|
||||||
+ return ipath_sd7220_prog_vfy(dd, IB_7220_SERDES, fw->data, fw->size, 0);
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
/* IRQ not set up at this point in init, so we poll. */
|
|
||||||
#define IB_SERDES_TRIM_DONE (1ULL << 11)
|
|
||||||
#define TRIM_TMO (30)
|
|
||||||
--
|
|
||||||
1.6.3.3
|
|
||||||
|
|
|
@ -8,5 +8,5 @@
|
||||||
MODULE_DEVICE_TABLE(pci, pciidlist);
|
MODULE_DEVICE_TABLE(pci, pciidlist);
|
||||||
-#endif
|
-#endif
|
||||||
|
|
||||||
static int i915_drm_freeze(struct drm_device *dev)
|
#define INTEL_PCH_DEVICE_ID_MASK 0xff00
|
||||||
{
|
#define INTEL_PCH_CPT_DEVICE_ID_TYPE 0x1c00
|
||||||
|
|
178
debian/patches/features/all/ib_qib-use-request_firmware-to-load-SD7220-firmware.patch
vendored
Normal file
178
debian/patches/features/all/ib_qib-use-request_firmware-to-load-SD7220-firmware.patch
vendored
Normal file
|
@ -0,0 +1,178 @@
|
||||||
|
From: Ben Hutchings <ben@decadent.org.uk>
|
||||||
|
Date: Mon, 17 Aug 2009 02:17:09 +0100
|
||||||
|
Subject: [PATCH] ib_qib: use request_firmware() to load SD7220 firmware
|
||||||
|
|
||||||
|
|
||||||
|
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
||||||
|
---
|
||||||
|
--- a/drivers/infiniband/hw/qib/qib_7220.h
|
||||||
|
+++ b/drivers/infiniband/hw/qib/qib_7220.h
|
||||||
|
@@ -109,10 +109,6 @@ struct qib_chippport_specific {
|
||||||
|
*/
|
||||||
|
int qib_sd7220_presets(struct qib_devdata *dd);
|
||||||
|
int qib_sd7220_init(struct qib_devdata *dd);
|
||||||
|
-int qib_sd7220_prog_ld(struct qib_devdata *dd, int sdnum, u8 *img,
|
||||||
|
- int len, int offset);
|
||||||
|
-int qib_sd7220_prog_vfy(struct qib_devdata *dd, int sdnum, const u8 *img,
|
||||||
|
- int len, int offset);
|
||||||
|
void qib_sd7220_clr_ibpar(struct qib_devdata *);
|
||||||
|
/*
|
||||||
|
* Below used for sdnum parameter, selecting one of the two sections
|
||||||
|
@@ -121,9 +117,6 @@ void qib_sd7220_clr_ibpar(struct qib_devdata *);
|
||||||
|
*/
|
||||||
|
#define IB_7220_SERDES 2
|
||||||
|
|
||||||
|
-int qib_sd7220_ib_load(struct qib_devdata *dd);
|
||||||
|
-int qib_sd7220_ib_vfy(struct qib_devdata *dd);
|
||||||
|
-
|
||||||
|
static inline u32 qib_read_kreg32(const struct qib_devdata *dd,
|
||||||
|
const u16 regno)
|
||||||
|
{
|
||||||
|
--- a/drivers/infiniband/hw/qib/qib_sd7220.c
|
||||||
|
+++ b/drivers/infiniband/hw/qib/qib_sd7220.c
|
||||||
|
@@ -37,10 +37,14 @@
|
||||||
|
|
||||||
|
#include <linux/pci.h>
|
||||||
|
#include <linux/delay.h>
|
||||||
|
+#include <linux/firmware.h>
|
||||||
|
|
||||||
|
#include "qib.h"
|
||||||
|
#include "qib_7220.h"
|
||||||
|
|
||||||
|
+#define SD7220_FW_NAME "qlogic/sd7220.fw"
|
||||||
|
+MODULE_FIRMWARE(SD7220_FW_NAME);
|
||||||
|
+
|
||||||
|
/*
|
||||||
|
* Same as in qib_iba7220.c, but just the registers needed here.
|
||||||
|
* Could move whole set to qib_7220.h, but decided better to keep
|
||||||
|
@@ -74,6 +78,11 @@
|
||||||
|
#define PCIE_SERDES0 0
|
||||||
|
#define PCIE_SERDES1 1
|
||||||
|
|
||||||
|
+static int
|
||||||
|
+qib_sd7220_ib_load(struct qib_devdata *dd, const struct firmware *fw);
|
||||||
|
+static int
|
||||||
|
+qib_sd7220_ib_vfy(struct qib_devdata *dd, const struct firmware *fw);
|
||||||
|
+
|
||||||
|
/*
|
||||||
|
* The EPB requires addressing in a particular form. EPB_LOC() is intended
|
||||||
|
* to make #definitions a little more readable.
|
||||||
|
@@ -110,10 +119,12 @@ static int epb_access(struct qib_devdata *dd, int sdnum, int claim);
|
||||||
|
* state of the reset "pin", is no longer valid. Instead, we check for the
|
||||||
|
* actual uC code having been loaded.
|
||||||
|
*/
|
||||||
|
-static int qib_ibsd_ucode_loaded(struct qib_pportdata *ppd)
|
||||||
|
+static int
|
||||||
|
+qib_ibsd_ucode_loaded(struct qib_pportdata *ppd, const struct firmware *fw)
|
||||||
|
{
|
||||||
|
struct qib_devdata *dd = ppd->dd;
|
||||||
|
- if (!dd->cspec->serdes_first_init_done && (qib_sd7220_ib_vfy(dd) > 0))
|
||||||
|
+ if (!dd->cspec->serdes_first_init_done &&
|
||||||
|
+ (qib_sd7220_ib_vfy(dd, fw) > 0))
|
||||||
|
dd->cspec->serdes_first_init_done = 1;
|
||||||
|
return dd->cspec->serdes_first_init_done;
|
||||||
|
}
|
||||||
|
@@ -377,6 +388,7 @@ static void qib_sd_trimdone_monitor(struct qib_devdata *dd,
|
||||||
|
*/
|
||||||
|
int qib_sd7220_init(struct qib_devdata *dd)
|
||||||
|
{
|
||||||
|
+ const struct firmware *fw;
|
||||||
|
int ret = 1; /* default to failure */
|
||||||
|
int first_reset, was_reset;
|
||||||
|
|
||||||
|
@@ -387,8 +399,15 @@ int qib_sd7220_init(struct qib_devdata *dd)
|
||||||
|
qib_ibsd_reset(dd, 1);
|
||||||
|
qib_sd_trimdone_monitor(dd, "Driver-reload");
|
||||||
|
}
|
||||||
|
+
|
||||||
|
+ ret = request_firmware(&fw, SD7220_FW_NAME, &dd->pcidev->dev);
|
||||||
|
+ if (ret) {
|
||||||
|
+ qib_dev_err(dd, "Failed to load IB SERDES image\n");
|
||||||
|
+ goto done;
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
/* Substitute our deduced value for was_reset */
|
||||||
|
- ret = qib_ibsd_ucode_loaded(dd->pport);
|
||||||
|
+ ret = qib_ibsd_ucode_loaded(dd->pport, fw);
|
||||||
|
if (ret < 0)
|
||||||
|
goto bail;
|
||||||
|
|
||||||
|
@@ -437,13 +456,13 @@ int qib_sd7220_init(struct qib_devdata *dd)
|
||||||
|
int vfy;
|
||||||
|
int trim_done;
|
||||||
|
|
||||||
|
- ret = qib_sd7220_ib_load(dd);
|
||||||
|
+ ret = qib_sd7220_ib_load(dd, fw);
|
||||||
|
if (ret < 0) {
|
||||||
|
qib_dev_err(dd, "Failed to load IB SERDES image\n");
|
||||||
|
goto bail;
|
||||||
|
} else {
|
||||||
|
/* Loaded image, try to verify */
|
||||||
|
- vfy = qib_sd7220_ib_vfy(dd);
|
||||||
|
+ vfy = qib_sd7220_ib_vfy(dd, fw);
|
||||||
|
if (vfy != ret) {
|
||||||
|
qib_dev_err(dd, "SERDES PRAM VFY failed\n");
|
||||||
|
goto bail;
|
||||||
|
@@ -506,6 +525,8 @@ bail:
|
||||||
|
done:
|
||||||
|
/* start relock timer regardless, but start at 1 second */
|
||||||
|
set_7220_relock_poll(dd, -1);
|
||||||
|
+
|
||||||
|
+ release_firmware(fw);
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -829,8 +850,8 @@ static int qib_sd7220_ram_xfer(struct qib_devdata *dd, int sdnum, u32 loc,
|
||||||
|
|
||||||
|
#define PROG_CHUNK 64
|
||||||
|
|
||||||
|
-int qib_sd7220_prog_ld(struct qib_devdata *dd, int sdnum,
|
||||||
|
- u8 *img, int len, int offset)
|
||||||
|
+static int qib_sd7220_prog_ld(struct qib_devdata *dd, int sdnum,
|
||||||
|
+ const u8 *img, int len, int offset)
|
||||||
|
{
|
||||||
|
int cnt, sofar, req;
|
||||||
|
|
||||||
|
@@ -840,7 +861,7 @@ int qib_sd7220_prog_ld(struct qib_devdata *dd, int sdnum,
|
||||||
|
if (req > PROG_CHUNK)
|
||||||
|
req = PROG_CHUNK;
|
||||||
|
cnt = qib_sd7220_ram_xfer(dd, sdnum, offset + sofar,
|
||||||
|
- img + sofar, req, 0);
|
||||||
|
+ (u8 *)img + sofar, req, 0);
|
||||||
|
if (cnt < req) {
|
||||||
|
sofar = -1;
|
||||||
|
break;
|
||||||
|
@@ -853,8 +874,8 @@ int qib_sd7220_prog_ld(struct qib_devdata *dd, int sdnum,
|
||||||
|
#define VFY_CHUNK 64
|
||||||
|
#define SD_PRAM_ERROR_LIMIT 42
|
||||||
|
|
||||||
|
-int qib_sd7220_prog_vfy(struct qib_devdata *dd, int sdnum,
|
||||||
|
- const u8 *img, int len, int offset)
|
||||||
|
+static int qib_sd7220_prog_vfy(struct qib_devdata *dd, int sdnum,
|
||||||
|
+ const u8 *img, int len, int offset)
|
||||||
|
{
|
||||||
|
int cnt, sofar, req, idx, errors;
|
||||||
|
unsigned char readback[VFY_CHUNK];
|
||||||
|
@@ -881,16 +902,16 @@ int qib_sd7220_prog_vfy(struct qib_devdata *dd, int sdnum,
|
||||||
|
return errors ? -errors : sofar;
|
||||||
|
}
|
||||||
|
|
||||||
|
-int
|
||||||
|
-qib_sd7220_ib_load(struct qib_devdata *dd)
|
||||||
|
+static int
|
||||||
|
+qib_sd7220_ib_load(struct qib_devdata *dd, const struct firmware *fw)
|
||||||
|
{
|
||||||
|
- return -1;
|
||||||
|
+ return qib_sd7220_prog_ld(dd, IB_7220_SERDES, fw->data, fw->size, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
-int
|
||||||
|
-qib_sd7220_ib_vfy(struct qib_devdata *dd)
|
||||||
|
+static int
|
||||||
|
+qib_sd7220_ib_vfy(struct qib_devdata *dd, const struct firmware *fw)
|
||||||
|
{
|
||||||
|
- return -1;
|
||||||
|
+ return qib_sd7220_prog_vfy(dd, IB_7220_SERDES, fw->data, fw->size, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
|
@ -1,265 +0,0 @@
|
||||||
From: David Woodhouse <dwmw2@infradead.org>
|
|
||||||
Date: Fri, 02 Apr 2010 12:05:56 +0100
|
|
||||||
Subject: [PATCH 2/2] phylib: Add module table to all existing phy drivers
|
|
||||||
|
|
||||||
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
|
|
||||||
[bwh: Backport to 2.6.33 as suggested in follow-up by dwmw2]
|
|
||||||
---
|
|
||||||
drivers/net/phy/bcm63xx.c | 8 ++++++++
|
|
||||||
drivers/net/phy/broadcom.c | 16 ++++++++++++++++
|
|
||||||
drivers/net/phy/cicada.c | 8 ++++++++
|
|
||||||
drivers/net/phy/davicom.c | 9 +++++++++
|
|
||||||
drivers/net/phy/et1011c.c | 7 +++++++
|
|
||||||
drivers/net/phy/icplus.c | 7 +++++++
|
|
||||||
drivers/net/phy/lxt.c | 8 ++++++++
|
|
||||||
drivers/net/phy/marvell.c | 13 +++++++++++++
|
|
||||||
drivers/net/phy/national.c | 7 +++++++
|
|
||||||
drivers/net/phy/qsemi.c | 7 +++++++
|
|
||||||
drivers/net/phy/realtek.c | 7 +++++++
|
|
||||||
drivers/net/phy/smsc.c | 11 +++++++++++
|
|
||||||
drivers/net/phy/ste10Xp.c | 8 ++++++++
|
|
||||||
drivers/net/phy/vitesse.c | 8 ++++++++
|
|
||||||
14 files changed, 124 insertions(+), 0 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/net/phy/bcm63xx.c b/drivers/net/phy/bcm63xx.c
|
|
||||||
index 4fed95e..ac5e498 100644
|
|
||||||
--- a/drivers/net/phy/bcm63xx.c
|
|
||||||
+++ b/drivers/net/phy/bcm63xx.c
|
|
||||||
@@ -130,3 +130,11 @@ static void __exit bcm63xx_phy_exit(void)
|
|
||||||
|
|
||||||
module_init(bcm63xx_phy_init);
|
|
||||||
module_exit(bcm63xx_phy_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id bcm63xx_tbl[] = {
|
|
||||||
+ { 0x00406000, 0xfffffc00 },
|
|
||||||
+ { 0x002bdc00, 0xfffffc00 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, bcm64xx_tbl);
|
|
||||||
diff --git a/drivers/net/phy/broadcom.c b/drivers/net/phy/broadcom.c
|
|
||||||
index f482fc4..cecdbbd 100644
|
|
||||||
--- a/drivers/net/phy/broadcom.c
|
|
||||||
+++ b/drivers/net/phy/broadcom.c
|
|
||||||
@@ -908,3 +908,19 @@ static void __exit broadcom_exit(void)
|
|
||||||
|
|
||||||
module_init(broadcom_init);
|
|
||||||
module_exit(broadcom_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id broadcom_tbl[] = {
|
|
||||||
+ { 0x00206070, 0xfffffff0 },
|
|
||||||
+ { 0x002060e0, 0xfffffff0 },
|
|
||||||
+ { 0x002060c0, 0xfffffff0 },
|
|
||||||
+ { 0x002060b0, 0xfffffff0 },
|
|
||||||
+ { 0x0143bca0, 0xfffffff0 },
|
|
||||||
+ { 0x0143bcb0, 0xfffffff0 },
|
|
||||||
+ { PHY_ID_BCM50610, 0xfffffff0 },
|
|
||||||
+ { PHY_ID_BCM50610M, 0xfffffff0 },
|
|
||||||
+ { PHY_ID_BCM57780, 0xfffffff0 },
|
|
||||||
+ { 0x0143bc70, 0xfffffff0 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, broadcom_tbl);
|
|
||||||
diff --git a/drivers/net/phy/cicada.c b/drivers/net/phy/cicada.c
|
|
||||||
index a1bd599..efc608f 100644
|
|
||||||
--- a/drivers/net/phy/cicada.c
|
|
||||||
+++ b/drivers/net/phy/cicada.c
|
|
||||||
@@ -159,3 +159,11 @@ static void __exit cicada_exit(void)
|
|
||||||
|
|
||||||
module_init(cicada_init);
|
|
||||||
module_exit(cicada_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id cicada_tbl[] = {
|
|
||||||
+ { 0x000fc410, 0x000ffff0 },
|
|
||||||
+ { 0x000fc440, 0x000fffc0 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, cicada_tbl);
|
|
||||||
diff --git a/drivers/net/phy/davicom.c b/drivers/net/phy/davicom.c
|
|
||||||
index d926168..e02b18c 100644
|
|
||||||
--- a/drivers/net/phy/davicom.c
|
|
||||||
+++ b/drivers/net/phy/davicom.c
|
|
||||||
@@ -219,3 +219,12 @@ static void __exit davicom_exit(void)
|
|
||||||
|
|
||||||
module_init(davicom_init);
|
|
||||||
module_exit(davicom_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id davicom_tbl[] = {
|
|
||||||
+ { 0x0181b880, 0x0ffffff0 },
|
|
||||||
+ { 0x0181b8a0, 0x0ffffff0 },
|
|
||||||
+ { 0x00181b80, 0x0ffffff0 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, davicom_tbl);
|
|
||||||
diff --git a/drivers/net/phy/et1011c.c b/drivers/net/phy/et1011c.c
|
|
||||||
index b031fa2..500f0fd 100644
|
|
||||||
--- a/drivers/net/phy/et1011c.c
|
|
||||||
+++ b/drivers/net/phy/et1011c.c
|
|
||||||
@@ -111,3 +111,10 @@ static void __exit et1011c_exit(void)
|
|
||||||
|
|
||||||
module_init(et1011c_init);
|
|
||||||
module_exit(et1011c_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id et1011c_tbl[] = {
|
|
||||||
+ { 0x0282f014, 0xfffffff0 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, et1011c_tbl);
|
|
||||||
diff --git a/drivers/net/phy/icplus.c b/drivers/net/phy/icplus.c
|
|
||||||
index af3f1f2..e661e90 100644
|
|
||||||
--- a/drivers/net/phy/icplus.c
|
|
||||||
+++ b/drivers/net/phy/icplus.c
|
|
||||||
@@ -132,3 +132,10 @@ static void __exit ip175c_exit(void)
|
|
||||||
|
|
||||||
module_init(ip175c_init);
|
|
||||||
module_exit(ip175c_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id icplus_tbl[] = {
|
|
||||||
+ { 0x02430d80, 0x0ffffff0 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, icplus_tbl);
|
|
||||||
diff --git a/drivers/net/phy/lxt.c b/drivers/net/phy/lxt.c
|
|
||||||
index 4cf3324..1d94f1d 100644
|
|
||||||
--- a/drivers/net/phy/lxt.c
|
|
||||||
+++ b/drivers/net/phy/lxt.c
|
|
||||||
@@ -174,3 +174,11 @@ static void __exit lxt_exit(void)
|
|
||||||
|
|
||||||
module_init(lxt_init);
|
|
||||||
module_exit(lxt_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id lxt_tbl[] = {
|
|
||||||
+ { 0x78100000, 0xfffffff0 },
|
|
||||||
+ { 0x001378e0, 0xfffffff0 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, lxt_tbl);
|
|
||||||
diff --git a/drivers/net/phy/marvell.c b/drivers/net/phy/marvell.c
|
|
||||||
index 65ed385..c7e5b9f 100644
|
|
||||||
--- a/drivers/net/phy/marvell.c
|
|
||||||
+++ b/drivers/net/phy/marvell.c
|
|
||||||
@@ -649,3 +649,16 @@ static void __exit marvell_exit(void)
|
|
||||||
|
|
||||||
module_init(marvell_init);
|
|
||||||
module_exit(marvell_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id marvell_tbl[] = {
|
|
||||||
+ { 0x01410c60, 0xfffffff0 },
|
|
||||||
+ { 0x01410c90, 0xfffffff0 },
|
|
||||||
+ { 0x01410cc0, 0xfffffff0 },
|
|
||||||
+ { 0x01410e10, 0xfffffff0 },
|
|
||||||
+ { 0x01410cb0, 0xfffffff0 },
|
|
||||||
+ { 0x01410cd0, 0xfffffff0 },
|
|
||||||
+ { 0x01410e30, 0xfffffff0 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, marvell_tbl);
|
|
||||||
diff --git a/drivers/net/phy/national.c b/drivers/net/phy/national.c
|
|
||||||
index 6c636eb..729ab29 100644
|
|
||||||
--- a/drivers/net/phy/national.c
|
|
||||||
+++ b/drivers/net/phy/national.c
|
|
||||||
@@ -153,3 +153,10 @@ MODULE_LICENSE("GPL");
|
|
||||||
|
|
||||||
module_init(ns_init);
|
|
||||||
module_exit(ns_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id ns_tbl[] = {
|
|
||||||
+ { DP83865_PHY_ID, 0xfffffff0 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, ns_tbl);
|
|
||||||
diff --git a/drivers/net/phy/qsemi.c b/drivers/net/phy/qsemi.c
|
|
||||||
index 23062d0..3ec9610 100644
|
|
||||||
--- a/drivers/net/phy/qsemi.c
|
|
||||||
+++ b/drivers/net/phy/qsemi.c
|
|
||||||
@@ -138,3 +138,10 @@ static void __exit qs6612_exit(void)
|
|
||||||
|
|
||||||
module_init(qs6612_init);
|
|
||||||
module_exit(qs6612_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id qs6612_tbl[] = {
|
|
||||||
+ { 0x00181440, 0xfffffff0 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, qs6612_tbl);
|
|
||||||
diff --git a/drivers/net/phy/realtek.c b/drivers/net/phy/realtek.c
|
|
||||||
index a052a67..f567c0e 100644
|
|
||||||
--- a/drivers/net/phy/realtek.c
|
|
||||||
+++ b/drivers/net/phy/realtek.c
|
|
||||||
@@ -78,3 +78,10 @@ static void __exit realtek_exit(void)
|
|
||||||
|
|
||||||
module_init(realtek_init);
|
|
||||||
module_exit(realtek_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id realtek_tbl[] = {
|
|
||||||
+ { 0x001cc912, 0x001fffff },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, realtek_tbl);
|
|
||||||
diff --git a/drivers/net/phy/smsc.c b/drivers/net/phy/smsc.c
|
|
||||||
index ed2644a..78fa988 100644
|
|
||||||
--- a/drivers/net/phy/smsc.c
|
|
||||||
+++ b/drivers/net/phy/smsc.c
|
|
||||||
@@ -253,3 +253,14 @@ MODULE_LICENSE("GPL");
|
|
||||||
|
|
||||||
module_init(smsc_init);
|
|
||||||
module_exit(smsc_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id smsc_tbl[] = {
|
|
||||||
+ { 0x0007c0a0, 0xfffffff0 },
|
|
||||||
+ { 0x0007c0b0, 0xfffffff0 },
|
|
||||||
+ { 0x0007c0c0, 0xfffffff0 },
|
|
||||||
+ { 0x0007c0d0, 0xfffffff0 },
|
|
||||||
+ { 0x0007c0f0, 0xfffffff0 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, smsc_tbl);
|
|
||||||
diff --git a/drivers/net/phy/ste10Xp.c b/drivers/net/phy/ste10Xp.c
|
|
||||||
index 6bdb0d5..7229009 100644
|
|
||||||
--- a/drivers/net/phy/ste10Xp.c
|
|
||||||
+++ b/drivers/net/phy/ste10Xp.c
|
|
||||||
@@ -132,6 +132,14 @@ static void __exit ste10Xp_exit(void)
|
|
||||||
module_init(ste10Xp_init);
|
|
||||||
module_exit(ste10Xp_exit);
|
|
||||||
|
|
||||||
+static struct mdio_device_id ste10Xp_tbl[] = {
|
|
||||||
+ { STE101P_PHY_ID, 0xfffffff0 },
|
|
||||||
+ { STE100P_PHY_ID, 0xffffffff },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, ste10Xp_tbl);
|
|
||||||
+
|
|
||||||
MODULE_DESCRIPTION("STMicroelectronics STe10Xp PHY driver");
|
|
||||||
MODULE_AUTHOR("Giuseppe Cavallaro <peppe.cavallaro@st.com>");
|
|
||||||
MODULE_LICENSE("GPL");
|
|
||||||
diff --git a/drivers/net/phy/vitesse.c b/drivers/net/phy/vitesse.c
|
|
||||||
index dd3b244..45cce50 100644
|
|
||||||
--- a/drivers/net/phy/vitesse.c
|
|
||||||
+++ b/drivers/net/phy/vitesse.c
|
|
||||||
@@ -191,3 +191,11 @@ static void __exit vsc82xx_exit(void)
|
|
||||||
|
|
||||||
module_init(vsc82xx_init);
|
|
||||||
module_exit(vsc82xx_exit);
|
|
||||||
+
|
|
||||||
+static struct mdio_device_id vitesse_tbl[] = {
|
|
||||||
+ { PHY_ID_VSC8244, 0x000fffc0 },
|
|
||||||
+ { PHY_ID_VSC8221, 0x000ffff0 },
|
|
||||||
+ { }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+MODULE_DEVICE_TABLE(mdio, vitesse_tbl);
|
|
||||||
--
|
|
||||||
1.6.6.1
|
|
||||||
|
|
|
@ -1,147 +0,0 @@
|
||||||
From 8626d3b4328061f5b82b11ae1d6918a0c3602f42 Mon Sep 17 00:00:00 2001
|
|
||||||
From: David Woodhouse <dwmw2@infradead.org>
|
|
||||||
Date: Fri, 2 Apr 2010 01:05:27 +0000
|
|
||||||
Subject: [PATCH 1/2] phylib: Support phy module autoloading
|
|
||||||
|
|
||||||
We don't use the normal hotplug mechanism because it doesn't work. It will
|
|
||||||
load the module some time after the device appears, but that's not good
|
|
||||||
enough for us -- we need the driver loaded _immediately_ because otherwise
|
|
||||||
the NIC driver may just abort and then the phy 'device' goes away.
|
|
||||||
|
|
||||||
[bwh: s/phy/mdio/ in module alias, kerneldoc for struct mdio_device_id]
|
|
||||||
|
|
||||||
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
|
|
||||||
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
|
|
||||||
Acked-by: Andy Fleming <afleming@freescale.com>
|
|
||||||
Signed-off-by: David S. Miller <davem@davemloft.net>
|
|
||||||
---
|
|
||||||
drivers/net/phy/phy_device.c | 12 ++++++++++++
|
|
||||||
include/linux/mod_devicetable.h | 26 ++++++++++++++++++++++++++
|
|
||||||
include/linux/phy.h | 1 +
|
|
||||||
scripts/mod/file2alias.c | 26 ++++++++++++++++++++++++++
|
|
||||||
4 files changed, 65 insertions(+), 0 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/drivers/net/phy/phy_device.c b/drivers/net/phy/phy_device.c
|
|
||||||
index db17945..1a99bb2 100644
|
|
||||||
--- a/drivers/net/phy/phy_device.c
|
|
||||||
+++ b/drivers/net/phy/phy_device.c
|
|
||||||
@@ -149,6 +149,7 @@ EXPORT_SYMBOL(phy_scan_fixups);
|
|
||||||
struct phy_device* phy_device_create(struct mii_bus *bus, int addr, int phy_id)
|
|
||||||
{
|
|
||||||
struct phy_device *dev;
|
|
||||||
+
|
|
||||||
/* We allocate the device, and initialize the
|
|
||||||
* default values */
|
|
||||||
dev = kzalloc(sizeof(*dev), GFP_KERNEL);
|
|
||||||
@@ -179,6 +180,17 @@ struct phy_device* phy_device_create(struct mii_bus *bus, int addr, int phy_id)
|
|
||||||
mutex_init(&dev->lock);
|
|
||||||
INIT_DELAYED_WORK(&dev->state_queue, phy_state_machine);
|
|
||||||
|
|
||||||
+ /* Request the appropriate module unconditionally; don't
|
|
||||||
+ bother trying to do so only if it isn't already loaded,
|
|
||||||
+ because that gets complicated. A hotplug event would have
|
|
||||||
+ done an unconditional modprobe anyway.
|
|
||||||
+ We don't do normal hotplug because it won't work for MDIO
|
|
||||||
+ -- because it relies on the device staying around for long
|
|
||||||
+ enough for the driver to get loaded. With MDIO, the NIC
|
|
||||||
+ driver will get bored and give up as soon as it finds that
|
|
||||||
+ there's no driver _already_ loaded. */
|
|
||||||
+ request_module(MDIO_MODULE_PREFIX MDIO_ID_FMT, MDIO_ID_ARGS(phy_id));
|
|
||||||
+
|
|
||||||
return dev;
|
|
||||||
}
|
|
||||||
EXPORT_SYMBOL(phy_device_create);
|
|
||||||
diff --git a/include/linux/mod_devicetable.h b/include/linux/mod_devicetable.h
|
|
||||||
index f58e9d8..55f1f9c 100644
|
|
||||||
--- a/include/linux/mod_devicetable.h
|
|
||||||
+++ b/include/linux/mod_devicetable.h
|
|
||||||
@@ -474,4 +474,30 @@ struct platform_device_id {
|
|
||||||
__attribute__((aligned(sizeof(kernel_ulong_t))));
|
|
||||||
};
|
|
||||||
|
|
||||||
+#define MDIO_MODULE_PREFIX "mdio:"
|
|
||||||
+
|
|
||||||
+#define MDIO_ID_FMT "%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d%d"
|
|
||||||
+#define MDIO_ID_ARGS(_id) \
|
|
||||||
+ (_id)>>31, ((_id)>>30) & 1, ((_id)>>29) & 1, ((_id)>>28) & 1, \
|
|
||||||
+ ((_id)>>27) & 1, ((_id)>>26) & 1, ((_id)>>25) & 1, ((_id)>>24) & 1, \
|
|
||||||
+ ((_id)>>23) & 1, ((_id)>>22) & 1, ((_id)>>21) & 1, ((_id)>>20) & 1, \
|
|
||||||
+ ((_id)>>19) & 1, ((_id)>>18) & 1, ((_id)>>17) & 1, ((_id)>>16) & 1, \
|
|
||||||
+ ((_id)>>15) & 1, ((_id)>>14) & 1, ((_id)>>13) & 1, ((_id)>>12) & 1, \
|
|
||||||
+ ((_id)>>11) & 1, ((_id)>>10) & 1, ((_id)>>9) & 1, ((_id)>>8) & 1, \
|
|
||||||
+ ((_id)>>7) & 1, ((_id)>>6) & 1, ((_id)>>5) & 1, ((_id)>>4) & 1, \
|
|
||||||
+ ((_id)>>3) & 1, ((_id)>>2) & 1, ((_id)>>1) & 1, (_id) & 1
|
|
||||||
+
|
|
||||||
+/**
|
|
||||||
+ * struct mdio_device_id - identifies PHY devices on an MDIO/MII bus
|
|
||||||
+ * @phy_id: The result of
|
|
||||||
+ * (mdio_read(&MII_PHYSID1) << 16 | mdio_read(&PHYSID2)) & @phy_id_mask
|
|
||||||
+ * for this PHY type
|
|
||||||
+ * @phy_id_mask: Defines the significant bits of @phy_id. A value of 0
|
|
||||||
+ * is used to terminate an array of struct mdio_device_id.
|
|
||||||
+ */
|
|
||||||
+struct mdio_device_id {
|
|
||||||
+ __u32 phy_id;
|
|
||||||
+ __u32 phy_id_mask;
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
#endif /* LINUX_MOD_DEVICETABLE_H */
|
|
||||||
diff --git a/include/linux/phy.h b/include/linux/phy.h
|
|
||||||
index d9bce4b..987e111 100644
|
|
||||||
--- a/include/linux/phy.h
|
|
||||||
+++ b/include/linux/phy.h
|
|
||||||
@@ -24,6 +24,7 @@
|
|
||||||
#include <linux/mii.h>
|
|
||||||
#include <linux/timer.h>
|
|
||||||
#include <linux/workqueue.h>
|
|
||||||
+#include <linux/mod_devicetable.h>
|
|
||||||
|
|
||||||
#include <asm/atomic.h>
|
|
||||||
|
|
||||||
diff --git a/scripts/mod/file2alias.c b/scripts/mod/file2alias.c
|
|
||||||
index 220213e..36a60a8 100644
|
|
||||||
--- a/scripts/mod/file2alias.c
|
|
||||||
+++ b/scripts/mod/file2alias.c
|
|
||||||
@@ -796,6 +796,28 @@ static int do_platform_entry(const char *filename,
|
|
||||||
return 1;
|
|
||||||
}
|
|
||||||
|
|
||||||
+static int do_mdio_entry(const char *filename,
|
|
||||||
+ struct mdio_device_id *id, char *alias)
|
|
||||||
+{
|
|
||||||
+ int i;
|
|
||||||
+
|
|
||||||
+ alias += sprintf(alias, MDIO_MODULE_PREFIX);
|
|
||||||
+
|
|
||||||
+ for (i = 0; i < 32; i++) {
|
|
||||||
+ if (!((id->phy_id_mask >> (31-i)) & 1))
|
|
||||||
+ *(alias++) = '?';
|
|
||||||
+ else if ((id->phy_id >> (31-i)) & 1)
|
|
||||||
+ *(alias++) = '1';
|
|
||||||
+ else
|
|
||||||
+ *(alias++) = '0';
|
|
||||||
+ }
|
|
||||||
+
|
|
||||||
+ /* Terminate the string */
|
|
||||||
+ *alias = 0;
|
|
||||||
+
|
|
||||||
+ return 1;
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
/* Ignore any prefix, eg. some architectures prepend _ */
|
|
||||||
static inline int sym_is(const char *symbol, const char *name)
|
|
||||||
{
|
|
||||||
@@ -943,6 +965,10 @@ void handle_moddevtable(struct module *mod, struct elf_info *info,
|
|
||||||
do_table(symval, sym->st_size,
|
|
||||||
sizeof(struct platform_device_id), "platform",
|
|
||||||
do_platform_entry, mod);
|
|
||||||
+ else if (sym_is(symname, "__mod_mdio_device_table"))
|
|
||||||
+ do_table(symval, sym->st_size,
|
|
||||||
+ sizeof(struct mdio_device_id), "mdio",
|
|
||||||
+ do_mdio_entry, mod);
|
|
||||||
free(zeros);
|
|
||||||
}
|
|
||||||
|
|
||||||
--
|
|
||||||
1.7.0.3
|
|
||||||
|
|
|
@ -18,9 +18,9 @@ firmware loader.
|
||||||
--- a/drivers/net/r8169.c
|
--- a/drivers/net/r8169.c
|
||||||
+++ b/drivers/net/r8169.c
|
+++ b/drivers/net/r8169.c
|
||||||
@@ -23,6 +23,7 @@
|
@@ -23,6 +23,7 @@
|
||||||
#include <linux/tcp.h>
|
|
||||||
#include <linux/init.h>
|
#include <linux/init.h>
|
||||||
#include <linux/dma-mapping.h>
|
#include <linux/dma-mapping.h>
|
||||||
|
#include <linux/pm_runtime.h>
|
||||||
+#include <linux/firmware.h>
|
+#include <linux/firmware.h>
|
||||||
|
|
||||||
#include <asm/system.h>
|
#include <asm/system.h>
|
||||||
|
|
|
@ -3,10 +3,10 @@ Subject: [PATCH] speakup: integrate into kbuild
|
||||||
|
|
||||||
--- a/drivers/staging/Kconfig
|
--- a/drivers/staging/Kconfig
|
||||||
+++ b/drivers/staging/Kconfig
|
+++ b/drivers/staging/Kconfig
|
||||||
@@ -138,6 +138,8 @@
|
@@ -146,6 +146,8 @@
|
||||||
source "drivers/staging/dt3155/Kconfig"
|
source "drivers/staging/mrst-touchscreen/Kconfig"
|
||||||
|
|
||||||
source "drivers/staging/crystalhd/Kconfig"
|
source "drivers/staging/msm/Kconfig"
|
||||||
+
|
+
|
||||||
+source "drivers/staging/speakup/Kconfig"
|
+source "drivers/staging/speakup/Kconfig"
|
||||||
|
|
||||||
|
@ -14,10 +14,10 @@ Subject: [PATCH] speakup: integrate into kbuild
|
||||||
endif # STAGING
|
endif # STAGING
|
||||||
--- a/drivers/staging/Makefile
|
--- a/drivers/staging/Makefile
|
||||||
+++ b/drivers/staging/Makefile
|
+++ b/drivers/staging/Makefile
|
||||||
@@ -51,3 +51,4 @@
|
@@ -53,3 +53,4 @@
|
||||||
obj-$(CONFIG_FB_SM7XX) += sm7xx/
|
obj-$(CONFIG_FB_XGI) += xgifb/
|
||||||
obj-$(CONFIG_DT3155) += dt3155/
|
obj-$(CONFIG_TOUCHSCREEN_MRSTOUCH) += mrst-touchscreen/
|
||||||
obj-$(CONFIG_CRYSTALHD) += crystalhd/
|
obj-$(CONFIG_MSM_STAGING) += msm/
|
||||||
+obj-$(CONFIG_SPEAKUP) += speakup/
|
+obj-$(CONFIG_SPEAKUP) += speakup/
|
||||||
--- a/drivers/staging/speakup/Kbuild
|
--- a/drivers/staging/speakup/Kbuild
|
||||||
+++ b/drivers/staging/speakup/Kbuild
|
+++ b/drivers/staging/speakup/Kbuild
|
||||||
|
|
|
@ -1,42 +0,0 @@
|
||||||
--- a/arch/arm/Kconfig
|
|
||||||
+++ b/arch/arm/Kconfig
|
|
||||||
@@ -20,6 +20,7 @@
|
|
||||||
select HAVE_FUNCTION_TRACER if (!XIP_KERNEL)
|
|
||||||
select HAVE_GENERIC_DMA_COHERENT
|
|
||||||
select HAVE_KERNEL_GZIP
|
|
||||||
+ select HAVE_KERNEL_LZMA
|
|
||||||
select HAVE_KERNEL_LZO
|
|
||||||
select HAVE_PERF_EVENTS
|
|
||||||
select PERF_USE_VMALLOC
|
|
||||||
--- a/arch/arm/boot/compressed/Makefile
|
|
||||||
+++ b/arch/arm/boot/compressed/Makefile
|
|
||||||
@@ -64,6 +64,7 @@ endif
|
|
||||||
SEDFLAGS = s/TEXT_START/$(ZTEXTADDR)/;s/BSS_START/$(ZBSSADDR)/
|
|
||||||
|
|
||||||
suffix_$(CONFIG_KERNEL_GZIP) = gzip
|
|
||||||
+suffix_$(CONFIG_KERNEL_LZMA) = lzma
|
|
||||||
suffix_$(CONFIG_KERNEL_LZO) = lzo
|
|
||||||
|
|
||||||
targets := vmlinux vmlinux.lds \
|
|
||||||
--- a/arch/arm/boot/compressed/decompress.c 2010-05-18 14:20:38.000000000 +0000
|
|
||||||
+++ b/arch/arm/boot/compressed/decompress.c 2010-05-18 14:21:06.000000000 +0000
|
|
||||||
@@ -36,6 +36,10 @@
|
|
||||||
#include "../../../../lib/decompress_inflate.c"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
+#ifdef CONFIG_KERNEL_LZMA
|
|
||||||
+#include "../../../../lib/decompress_unlzma.c"
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
#ifdef CONFIG_KERNEL_LZO
|
|
||||||
#include "../../../../lib/decompress_unlzo.c"
|
|
||||||
#endif
|
|
||||||
--- /dev/null
|
|
||||||
+++ b/arch/arm/boot/compressed/piggy.lzma.S
|
|
||||||
@@ -0,0 +1,6 @@
|
|
||||||
+ .section .piggydata,#alloc
|
|
||||||
+ .globl input_data
|
|
||||||
+input_data:
|
|
||||||
+ .incbin "arch/arm/boot/compressed/piggy.lzma"
|
|
||||||
+ .globl input_data_end
|
|
||||||
+input_data_end:
|
|
|
@ -1,187 +0,0 @@
|
||||||
From: Siddarth Gore <gores@marvell.com>
|
|
||||||
Date: Mon, 22 Mar 2010 09:28:20 +0000 (-0700)
|
|
||||||
Subject: [ARM] Kirkwood: Marvell GuruPlug support
|
|
||||||
X-Git-Url: http://git.marvell.com/?p=orion.git;a=commitdiff_plain;h=d8f089d2ad35861c432618900fa08ca70c168d76
|
|
||||||
|
|
||||||
[ARM] Kirkwood: Marvell GuruPlug support
|
|
||||||
|
|
||||||
GuruPlug Standard: 1 Gb Ethernet, 2 USB 2.0
|
|
||||||
GuruPlug Plus: 2 Gb Ethernet, 2 USB 2.0, 1 eSATA, 1 uSD slot
|
|
||||||
|
|
||||||
References:
|
|
||||||
http://www.globalscaletechnologies.com/t-guruplugdetails.aspx
|
|
||||||
http://plugcomputer.org
|
|
||||||
|
|
||||||
This patch is for GuruPlug Plus, but it supports Standard version
|
|
||||||
as well.
|
|
||||||
|
|
||||||
Signed-off-by: Siddarth Gore <gores@marvell.com>
|
|
||||||
Signed-off-by: Nicolas Pitre <nico@marvell.com>
|
|
||||||
---
|
|
||||||
|
|
||||||
diff --git a/arch/arm/mach-kirkwood/Kconfig b/arch/arm/mach-kirkwood/Kconfig
|
|
||||||
index 17879a8..05a8552 100644
|
|
||||||
--- a/arch/arm/mach-kirkwood/Kconfig
|
|
||||||
+++ b/arch/arm/mach-kirkwood/Kconfig
|
|
||||||
@@ -38,6 +38,12 @@ config MACH_ESATA_SHEEVAPLUG
|
|
||||||
Say 'Y' here if you want your kernel to support the
|
|
||||||
Marvell eSATA SheevaPlug Reference Board.
|
|
||||||
|
|
||||||
+config MACH_GURUPLUG
|
|
||||||
+ bool "Marvell GuruPlug Reference Board"
|
|
||||||
+ help
|
|
||||||
+ Say 'Y' here if you want your kernel to support the
|
|
||||||
+ Marvell GuruPlug Reference Board.
|
|
||||||
+
|
|
||||||
config MACH_TS219
|
|
||||||
bool "QNAP TS-110, TS-119, TS-210, TS-219 and TS-219P Turbo NAS"
|
|
||||||
help
|
|
||||||
diff --git a/arch/arm/mach-kirkwood/Makefile b/arch/arm/mach-kirkwood/Makefile
|
|
||||||
index a5530e3..85b3a39 100644
|
|
||||||
--- a/arch/arm/mach-kirkwood/Makefile
|
|
||||||
+++ b/arch/arm/mach-kirkwood/Makefile
|
|
||||||
@@ -6,6 +6,7 @@ obj-$(CONFIG_MACH_RD88F6281) += rd88f6281-setup.o
|
|
||||||
obj-$(CONFIG_MACH_MV88F6281GTW_GE) += mv88f6281gtw_ge-setup.o
|
|
||||||
obj-$(CONFIG_MACH_SHEEVAPLUG) += sheevaplug-setup.o
|
|
||||||
obj-$(CONFIG_MACH_ESATA_SHEEVAPLUG) += sheevaplug-setup.o
|
|
||||||
+obj-$(CONFIG_MACH_GURUPLUG) += guruplug-setup.o
|
|
||||||
obj-$(CONFIG_MACH_TS219) += ts219-setup.o tsx1x-common.o
|
|
||||||
obj-$(CONFIG_MACH_TS41X) += ts41x-setup.o tsx1x-common.o
|
|
||||||
obj-$(CONFIG_MACH_OPENRD_BASE) += openrd_base-setup.o
|
|
||||||
diff --git a/arch/arm/mach-kirkwood/guruplug-setup.c b/arch/arm/mach-kirkwood/guruplug-setup.c
|
|
||||||
new file mode 100644
|
|
||||||
index 0000000..54d07c8
|
|
||||||
--- /dev/null
|
|
||||||
+++ b/arch/arm/mach-kirkwood/guruplug-setup.c
|
|
||||||
@@ -0,0 +1,131 @@
|
|
||||||
+/*
|
|
||||||
+ * arch/arm/mach-kirkwood/guruplug-setup.c
|
|
||||||
+ *
|
|
||||||
+ * Marvell GuruPlug Reference Board Setup
|
|
||||||
+ *
|
|
||||||
+ * This file is licensed under the terms of the GNU General Public
|
|
||||||
+ * License version 2. This program is licensed "as is" without any
|
|
||||||
+ * warranty of any kind, whether express or implied.
|
|
||||||
+ */
|
|
||||||
+
|
|
||||||
+#include <linux/kernel.h>
|
|
||||||
+#include <linux/init.h>
|
|
||||||
+#include <linux/platform_device.h>
|
|
||||||
+#include <linux/mtd/partitions.h>
|
|
||||||
+#include <linux/ata_platform.h>
|
|
||||||
+#include <linux/mv643xx_eth.h>
|
|
||||||
+#include <linux/gpio.h>
|
|
||||||
+#include <linux/leds.h>
|
|
||||||
+#include <asm/mach-types.h>
|
|
||||||
+#include <asm/mach/arch.h>
|
|
||||||
+#include <mach/kirkwood.h>
|
|
||||||
+#include <plat/mvsdio.h>
|
|
||||||
+#include "common.h"
|
|
||||||
+#include "mpp.h"
|
|
||||||
+
|
|
||||||
+static struct mtd_partition guruplug_nand_parts[] = {
|
|
||||||
+ {
|
|
||||||
+ .name = "u-boot",
|
|
||||||
+ .offset = 0,
|
|
||||||
+ .size = SZ_1M
|
|
||||||
+ }, {
|
|
||||||
+ .name = "uImage",
|
|
||||||
+ .offset = MTDPART_OFS_NXTBLK,
|
|
||||||
+ .size = SZ_4M
|
|
||||||
+ }, {
|
|
||||||
+ .name = "root",
|
|
||||||
+ .offset = MTDPART_OFS_NXTBLK,
|
|
||||||
+ .size = MTDPART_SIZ_FULL
|
|
||||||
+ },
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+static struct mv643xx_eth_platform_data guruplug_ge00_data = {
|
|
||||||
+ .phy_addr = MV643XX_ETH_PHY_ADDR(0),
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+static struct mv643xx_eth_platform_data guruplug_ge01_data = {
|
|
||||||
+ .phy_addr = MV643XX_ETH_PHY_ADDR(1),
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+static struct mv_sata_platform_data guruplug_sata_data = {
|
|
||||||
+ .n_ports = 1,
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+static struct mvsdio_platform_data guruplug_mvsdio_data = {
|
|
||||||
+ /* unfortunately the CD signal has not been connected */
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+static struct gpio_led guruplug_led_pins[] = {
|
|
||||||
+ {
|
|
||||||
+ .name = "guruplug:red:health",
|
|
||||||
+ .gpio = 46,
|
|
||||||
+ .active_low = 1,
|
|
||||||
+ },
|
|
||||||
+ {
|
|
||||||
+ .name = "guruplug:green:health",
|
|
||||||
+ .gpio = 47,
|
|
||||||
+ .active_low = 1,
|
|
||||||
+ },
|
|
||||||
+ {
|
|
||||||
+ .name = "guruplug:red:wmode",
|
|
||||||
+ .gpio = 48,
|
|
||||||
+ .active_low = 1,
|
|
||||||
+ },
|
|
||||||
+ {
|
|
||||||
+ .name = "guruplug:green:wmode",
|
|
||||||
+ .gpio = 49,
|
|
||||||
+ .active_low = 1,
|
|
||||||
+ },
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+static struct gpio_led_platform_data guruplug_led_data = {
|
|
||||||
+ .leds = guruplug_led_pins,
|
|
||||||
+ .num_leds = ARRAY_SIZE(guruplug_led_pins),
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+static struct platform_device guruplug_leds = {
|
|
||||||
+ .name = "leds-gpio",
|
|
||||||
+ .id = -1,
|
|
||||||
+ .dev = {
|
|
||||||
+ .platform_data = &guruplug_led_data,
|
|
||||||
+ }
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+static unsigned int guruplug_mpp_config[] __initdata = {
|
|
||||||
+ MPP46_GPIO, /* M_RLED */
|
|
||||||
+ MPP47_GPIO, /* M_GLED */
|
|
||||||
+ MPP48_GPIO, /* B_RLED */
|
|
||||||
+ MPP49_GPIO, /* B_GLED */
|
|
||||||
+ 0
|
|
||||||
+};
|
|
||||||
+
|
|
||||||
+static void __init guruplug_init(void)
|
|
||||||
+{
|
|
||||||
+ /*
|
|
||||||
+ * Basic setup. Needs to be called early.
|
|
||||||
+ */
|
|
||||||
+ kirkwood_init();
|
|
||||||
+ kirkwood_mpp_conf(guruplug_mpp_config);
|
|
||||||
+
|
|
||||||
+ kirkwood_uart0_init();
|
|
||||||
+ kirkwood_nand_init(ARRAY_AND_SIZE(guruplug_nand_parts), 25);
|
|
||||||
+
|
|
||||||
+ kirkwood_ehci_init();
|
|
||||||
+ kirkwood_ge00_init(&guruplug_ge00_data);
|
|
||||||
+ kirkwood_ge01_init(&guruplug_ge01_data);
|
|
||||||
+ kirkwood_sata_init(&guruplug_sata_data);
|
|
||||||
+ kirkwood_sdio_init(&guruplug_mvsdio_data);
|
|
||||||
+
|
|
||||||
+ platform_device_register(&guruplug_leds);
|
|
||||||
+}
|
|
||||||
+
|
|
||||||
+MACHINE_START(GURUPLUG, "Marvell GuruPlug Reference Board")
|
|
||||||
+ /* Maintainer: Siddarth Gore <gores@marvell.com> */
|
|
||||||
+ .phys_io = KIRKWOOD_REGS_PHYS_BASE,
|
|
||||||
+ .io_pg_offst = ((KIRKWOOD_REGS_VIRT_BASE) >> 18) & 0xfffc,
|
|
||||||
+ .boot_params = 0x00000100,
|
|
||||||
+ .init_machine = guruplug_init,
|
|
||||||
+ .map_io = kirkwood_map_io,
|
|
||||||
+ .init_irq = kirkwood_init_irq,
|
|
||||||
+ .timer = &kirkwood_timer,
|
|
||||||
+MACHINE_END
|
|
|
@ -1,29 +0,0 @@
|
||||||
Kirkwood: Export GPIO indicating jumper setting of JP1
|
|
||||||
|
|
||||||
Export GPIO 45 which is used to indicate the setting of the JP1
|
|
||||||
jumper. This is useful for userland tools, such as qcontrol, to
|
|
||||||
see whether the LCD or a serial console is connected.
|
|
||||||
|
|
||||||
Signed-off-by: Martin Michlmayr <tbm@cyrius.com>
|
|
||||||
[bwh: Adjust context for 2.6.34]
|
|
||||||
|
|
||||||
--- a/arch/arm/mach-kirkwood/ts41x-setup.c 2010-05-21 19:27:57.000000000 +0000
|
|
||||||
+++ b/arch/arm/mach-kirkwood/ts41x-setup.c 2010-05-21 19:28:34.000000000 +0000
|
|
||||||
@@ -32,6 +33,8 @@
|
|
||||||
#include "mpp.h"
|
|
||||||
#include "tsx1x-common.h"
|
|
||||||
|
|
||||||
+#define QNAP_TS41X_JUMPER_JP1 45
|
|
||||||
+
|
|
||||||
static struct i2c_board_info __initdata qnap_ts41x_i2c_rtc = {
|
|
||||||
I2C_BOARD_INFO("s35390a", 0x30),
|
|
||||||
};
|
|
||||||
@@ -230,6 +233,8 @@
|
|
||||||
|
|
||||||
pm_power_off = qnap_tsx1x_power_off;
|
|
||||||
|
|
||||||
+ if (gpio_request(QNAP_TS41X_JUMPER_JP1, "JP1") == 0)
|
|
||||||
+ gpio_export(QNAP_TS41X_JUMPER_JP1, 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
static int __init ts41x_pci_init(void)
|
|
|
@ -1,16 +0,0 @@
|
||||||
- debian/dfsg/drivers-staging-rtl8192su-disable.patch
|
|
||||||
+ bugfix/all/writeback-Update-dirty-flags-in-two-steps.patch
|
|
||||||
+ bugfix/all/writeback-ensure-WB_SYNC_NONE-writeback-with-sb-pinned-is-sync.patch
|
|
||||||
+ bugfix/all/writeback-fix-non-integrity-write-back.patch
|
|
||||||
+ features/all/RTC-rtc-cmos-Fix-binary-mode-support.patch
|
|
||||||
+ features/mips/MIPS-Loongson-Define-rtc-device-on-MC146818-systems.patch
|
|
||||||
+ debian/revert-removal-of-r8192sU_HWImg-c.patch
|
|
||||||
+ bugfix/ia64/hardcode-arch-script-output.patch
|
|
||||||
+ bugfix/all/mac80211-explicitly-disable-enable-QoS.patch
|
|
||||||
+ bugfix/all/iwlwifi-manage-QoS-by-mac-stack.patch
|
|
||||||
+ bugfix/all/ext4-Conditionally-define-compat-ioctl-numbers.patch
|
|
||||||
+ bugfix/all/ext4-Fix-compat-EXT4_IOC_ADD_GROUP.patch
|
|
||||||
+ features/arm/ts41x-export-jp1.patch
|
|
||||||
+ bugfix/parisc/clear-fp-exception-flag-on-SIGFPE.patch
|
|
||||||
+ bugfix/sh4/fix-sh_tmu.patch
|
|
||||||
+ features/all/revert-ipv4-Make-INET_LRO-a-bool-instead-of-tristate.patch
|
|
|
@ -1,6 +0,0 @@
|
||||||
+ bugfix/all/ipr-add-writeq-definition-if-needed.patch
|
|
||||||
+ bugfix/mips/mips-Set-io_map_base-for-several-PCI-bridges-lacking.patch
|
|
||||||
+ bugfix/all/Staging-rtl8192s_usb-Fix-device-ID-table.patch
|
|
||||||
+ debian/rtl8192u_usb-Restore-lookup-tables.patch
|
|
||||||
+ debian/dfsg/rtl8192u_usb-Remove-code-for-using-built-in-firmware.patch
|
|
||||||
+ bugfix/all/Staging-rtl8192u_usb-Add-LG-device-ID-043e-7a01.patch
|
|
|
@ -5,7 +5,7 @@
|
||||||
|
|
||||||
+ debian/piix-disable-redundant-devids.patch
|
+ debian/piix-disable-redundant-devids.patch
|
||||||
|
|
||||||
+ features/all/drivers-infiniband-hw-ipath-iba7220-use-request_firmware.patch
|
+ features/all/ib_qib-use-request_firmware-to-load-SD7220-firmware.patch
|
||||||
+ features/all/drivers-media-dvb-usb-af9005-request_firmware.patch
|
+ features/all/drivers-media-dvb-usb-af9005-request_firmware.patch
|
||||||
|
|
||||||
+ features/all/lgs8gxx-lgs8g75-request_firmware.patch
|
+ features/all/lgs8gxx-lgs8g75-request_firmware.patch
|
||||||
|
@ -28,13 +28,12 @@
|
||||||
# made manually
|
# made manually
|
||||||
+ features/all/speakup/slab-build-fix.patch
|
+ features/all/speakup/slab-build-fix.patch
|
||||||
|
|
||||||
#+ bugfix/ia64/hardcode-arch-script-output.patch
|
+ bugfix/ia64/hardcode-arch-script-output.patch
|
||||||
+ bugfix/mips/disable-advansys.patch
|
+ bugfix/mips/disable-advansys.patch
|
||||||
+ bugfix/arm/disable-scsi_acard.patch
|
+ bugfix/arm/disable-scsi_acard.patch
|
||||||
+ bugfix/mips/disable-werror.patch
|
+ bugfix/mips/disable-werror.patch
|
||||||
+ bugfix/powerpc/lpar-console.patch
|
+ bugfix/powerpc/lpar-console.patch
|
||||||
#+ bugfix/all/wireless-regulatory-default-EU.patch
|
#+ bugfix/all/wireless-regulatory-default-EU.patch
|
||||||
+ features/arm/compression-add-lzma.patch
|
|
||||||
|
|
||||||
+ features/all/i915-autoload-without-CONFIG_DRM_I915_KMS.patch
|
+ features/all/i915-autoload-without-CONFIG_DRM_I915_KMS.patch
|
||||||
|
|
||||||
|
@ -42,31 +41,11 @@
|
||||||
|
|
||||||
+ debian/arch-sh4-fix-uimage-build.patch
|
+ debian/arch-sh4-fix-uimage-build.patch
|
||||||
|
|
||||||
+ features/all/phylib-Support-phy-module-autoloading.patch
|
|
||||||
+ features/all/phylib-Add-module-table-to-all-existing-phy-drivers.patch
|
|
||||||
|
|
||||||
+ bugfix/x86/PCI-Disable-MSI-for-MCP55-on-P5N32-E-SLI.patch
|
|
||||||
+ bugfix/all/phylib-fix-typo-in-bcm6xx-PHY-driver-table.patch
|
|
||||||
+ bugfix/all/rndis_host-Poll-status-channel-before-control-channel.patch
|
|
||||||
+ bugfix/all/thinkpad-acpi-add-x100e.patch
|
|
||||||
+ bugfix/all/p54pci-prevent-stuck-rx-ring.patch
|
|
||||||
+ bugfix/all/p54pci-fix-serious-sparse-warning.patch
|
|
||||||
+ bugfix/all/p54pci-fix-regression.patch
|
|
||||||
+ bugfix/all/cifs-allow-null-nd-on-create.patch
|
|
||||||
+ bugfix/mips/mips-ide-flush-dcache.patch
|
+ bugfix/mips/mips-ide-flush-dcache.patch
|
||||||
|
#+ bugfix/all/thinkpad-acpi-fix-backlight.patch
|
||||||
+ features/arm/guruplug.patch
|
+ features/mips/MIPS-Loongson-Define-rtc-device-on-MC146818-systems.patch
|
||||||
+ bugfix/all/buffer-make-invalidate_bdev-drain-all-add-caches.patch
|
+ features/all/revert-ipv4-Make-INET_LRO-a-bool-instead-of-tristate.patch
|
||||||
+ bugfix/all/block-restart-partition-scan-after-resizing.patch
|
+ bugfix/all/ipr-add-writeq-definition-if-needed.patch
|
||||||
+ bugfix/all/block-ide-simplify-bdops-set_capacity-to-unlock_native_capacity.patch
|
+ bugfix/mips/mips-Set-io_map_base-for-several-PCI-bridges-lacking.patch
|
||||||
+ bugfix/all/SCSI-implement-sd_unlock_native_capacity.patch
|
+ bugfix/all/Staging-rtl8192s_usb-Fix-device-ID-table.patch
|
||||||
+ bugfix/all/libata-use-enlarged-capacity-after-late-HPA-unlock.patch
|
+ bugfix/all/Staging-rtl8192u_usb-Add-LG-device-ID-043e-7a01.patch
|
||||||
+ bugfix/all/libata-implement-on-demand-HPA-unlocking.patch
|
|
||||||
+ bugfix/all/V4L-DVB-budget-Select-correct-frontends.patch
|
|
||||||
+ bugfix/all/drm-edid-Fix-1024x768@85Hz.patch
|
|
||||||
+ bugfix/all/3c503-Fix-IRQ-probing.patch
|
|
||||||
+ bugfix/x86/sis-agp-Remove-SIS-760-handled-by-amd64-agp.patch
|
|
||||||
+ bugfix/x86/amd64-agp-Probe-unknown-AGP-devices-the-right-way.patch
|
|
||||||
+ bugfix/all/thinkpad-acpi-fix-backlight.patch
|
|
||||||
+ bugfix/all/linux-2.6-acpi-sleep-live-sci-live.patch
|
|
||||||
+ bugfix/all/fs-explicitly-pass-in-whether-sb-is-pinned-or-not.patch
|
|
||||||
|
|
|
@ -1,12 +1,9 @@
|
||||||
+ debian/dfsg/arch-powerpc-platforms-8xx-ucode-disable.patch
|
+ debian/dfsg/arch-powerpc-platforms-8xx-ucode-disable.patch
|
||||||
+ debian/dfsg/drivers-media-dvb-dvb-usb-af9005-disable.patch
|
+ debian/dfsg/drivers-media-dvb-dvb-usb-af9005-disable.patch
|
||||||
+ debian/dfsg/drivers-infiniband-hw-ipath-iba7220-disable.patch
|
+ debian/dfsg/ip_qib-sd7220-disable.patch
|
||||||
+ debian/dfsg/drivers-net-appletalk-cops.patch
|
+ debian/dfsg/drivers-net-appletalk-cops.patch
|
||||||
+ debian/dfsg/drivers-staging-otus-disable.patch
|
+ debian/dfsg/drivers-staging-otus-disable.patch
|
||||||
# Next patch can be removed for next upstream release/rc
|
+ debian/dfsg/rtl8192u_usb-Remove-built-in-firmware.patch
|
||||||
+ debian/dfsg/drivers-staging-rtl8192su-disable.patch
|
|
||||||
# Next patch should be added for next upstream release/rc
|
|
||||||
#+ debian/dfsg/rtl8192u_usb-Remove-built-in-firmware.patch
|
|
||||||
+ debian/dfsg/drivers-staging-wlags49_h2-disable.patch
|
+ debian/dfsg/drivers-staging-wlags49_h2-disable.patch
|
||||||
+ debian/dfsg/drivers-staging-wlags49_h25-disable.patch
|
+ debian/dfsg/drivers-staging-wlags49_h25-disable.patch
|
||||||
+ debian/dfsg/firmware-cleanup.patch
|
+ debian/dfsg/firmware-cleanup.patch
|
||||||
|
|
Loading…
Reference in New Issue