[kernel] r12306 - in dists/sid/linux-2.6/debian: . config/m68k patches/bugfix/m68k/2.6.26 patches/series
Stephen Marenka
smarenka at alioth.debian.org
Mon Oct 13 23:44:53 UTC 2008
Author: smarenka
Date: Mon Oct 13 23:44:52 2008
New Revision: 12306
Log:
update m68k patches
Added:
dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/atari-atari_keyb_init-operator-precedence.diff
dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/atari-ethernec-IRQF_SHARED.diff
dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/atari-ethernec-fixes.diff
dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/mac-esp-fix-for-quadras-with-two-esp-chips.diff
Modified:
dists/sid/linux-2.6/debian/changelog
dists/sid/linux-2.6/debian/config/m68k/config.mac
dists/sid/linux-2.6/debian/patches/series/1-extra
Modified: dists/sid/linux-2.6/debian/changelog
==============================================================================
--- dists/sid/linux-2.6/debian/changelog (original)
+++ dists/sid/linux-2.6/debian/changelog Mon Oct 13 23:44:52 2008
@@ -79,6 +79,14 @@
(closes: #500472)
* [openvz] unset NF_CONNTRACK_IPV6 for now until abi bump.
+ [ Stephen R. Marenka ]
+ * [m68k] add patches to fix atari ethernec per Michael Schmitz:
+ atari-ethernec-IRQF_SHARED.diff and atari-ethernec-fixes.diff.
+ * [m68k] add mac-esp-fix-for-quadras-with-two-esp-chips.diff to fix macs
+ with dual scsi busses and a problem with xorg, per Finn Thain.
+ * [m68k] add atari-atari_keyb_init-operator-precedence.diff per
+ Michael Schmitz.
+
-- Bastian Blank <waldi at debian.org> Thu, 09 Oct 2008 15:14:50 +0200
linux-2.6 (2.6.26-8) unstable; urgency=medium
Modified: dists/sid/linux-2.6/debian/config/m68k/config.mac
==============================================================================
--- dists/sid/linux-2.6/debian/config/m68k/config.mac (original)
+++ dists/sid/linux-2.6/debian/config/m68k/config.mac Mon Oct 13 23:44:52 2008
@@ -78,7 +78,7 @@
CONFIG_ADB_MACII=y
# CONFIG_ADB_MACIISI is not set
CONFIG_ADB_IOP=y # switched on for the benefit of IIfx, Q900, Q950
-CONFIG_ADB_PMU68K=y
+CONFIG_ADB_PMU68K=y
CONFIG_ADB_CUDA=y
CONFIG_INPUT_ADBHID=y
CONFIG_MAC_EMUMOUSEBTN=y
Added: dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/atari-atari_keyb_init-operator-precedence.diff
==============================================================================
--- (empty file)
+++ dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/atari-atari_keyb_init-operator-precedence.diff Mon Oct 13 23:44:52 2008
@@ -0,0 +1,42 @@
+Subject: [PATCH] m68k: atari_keyb_init operator precedence fix
+
+From: Michael Schmitz <schmitz at biophys.uni-duesseldorf.de>
+
+Fix operator precedence bug in atari_keyb_init, which caused a failure on CT60
+
+Signed-off-by: Michael Schmitz <schmitz at debian.org>
+Signed-off-by: Geert Uytterhoeven <geert at linux-m68k.org>
+---
+ arch/m68k/atari/atakeyb.c | 9 ++++++---
+ 1 file changed, 6 insertions(+), 3 deletions(-)
+
+--- a/arch/m68k/atari/atakeyb.c
++++ b/arch/m68k/atari/atakeyb.c
+@@ -580,13 +580,15 @@ int atari_keyb_init(void)
+ do {
+ /* reset IKBD ACIA */
+ acia.key_ctrl = ACIA_RESET |
+- (atari_switches & ATARI_SWITCH_IKBD) ? ACIA_RHTID : 0;
++ ((atari_switches & ATARI_SWITCH_IKBD) ?
++ ACIA_RHTID : 0);
+ (void)acia.key_ctrl;
+ (void)acia.key_data;
+
+ /* reset MIDI ACIA */
+ acia.mid_ctrl = ACIA_RESET |
+- (atari_switches & ATARI_SWITCH_MIDI) ? ACIA_RHTID : 0;
++ ((atari_switches & ATARI_SWITCH_MIDI) ?
++ ACIA_RHTID : 0);
+ (void)acia.mid_ctrl;
+ (void)acia.mid_data;
+
+@@ -599,7 +601,8 @@ int atari_keyb_init(void)
+ ACIA_RHTID : ACIA_RLTID);
+
+ acia.mid_ctrl = ACIA_DIV16 | ACIA_D8N1S |
+- (atari_switches & ATARI_SWITCH_MIDI) ? ACIA_RHTID : 0;
++ ((atari_switches & ATARI_SWITCH_MIDI) ?
++ ACIA_RHTID : 0);
+
+ /* make sure the interrupt line is up */
+ } while ((mfp.par_dt_reg & 0x10) == 0);
Added: dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/atari-ethernec-IRQF_SHARED.diff
==============================================================================
--- (empty file)
+++ dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/atari-ethernec-IRQF_SHARED.diff Mon Oct 13 23:44:52 2008
@@ -0,0 +1,18 @@
+
+Must have missed Michael's original patch that contains this change...
+---
+ drivers/net/atari_ethernec.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+--- a/drivers/net/atari_ethernec.c
++++ b/drivers/net/atari_ethernec.c
+@@ -618,7 +618,8 @@ static int __init ne_probe1(struct net_d
+ /* start timer D, div = 1:100 */
+ mfp.tim_ct_cd = (mfp.tim_ct_cd & 0xf0) | 0x6;
+ }
+- ret = request_irq(dev->irq, ei_interrupt, 0, name, dev);
++ /* Must make this shared in case other timer ints are needed */
++ ret = request_irq(dev->irq, ei_interrupt, IRQF_SHARED, name, dev);
+ if (ret) {
+ printk(" unable to get IRQ %d (errno=%d), polling instead.\n",
+ dev->irq, ret);
Added: dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/atari-ethernec-fixes.diff
==============================================================================
--- (empty file)
+++ dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/atari-ethernec-fixes.diff Mon Oct 13 23:44:52 2008
@@ -0,0 +1,64 @@
+From: Michael Schmitz <schmitz at debian.org>
+
+Use wrapper around ei_interrupt to prevent delivery of (timer!) interrupts
+before card is opened.
+
+Limit IO addresses to 0x300 (this is hardwired on the bus adapter anyway, and
+the card needs to be programmed to use that IO in some way before the adapter
+can work).
+
+Preset io=0x300 for module use.
+
+Signed-off-by: Michael Schmitz <schmitz at debian.org>
+
+ drivers/net/atari_ethernec.c | 16 ++++++++++++----
+ 1 file changed, 12 insertions(+), 4 deletions(-)
+---
+
+--- a/drivers/net/atari_ethernec.c
++++ b/drivers/net/atari_ethernec.c
+@@ -124,7 +124,7 @@ static const char version2[] =
+ /* A zero-terminated list of I/O addresses to be probed at boot. */
+ #ifndef MODULE
+ static unsigned int netcard_portlist[] __initdata = {
+- 0x300, 0x280, 0x320, 0x340, 0x360, 0x380, 0
++ 0x300, 0
+ };
+ #endif
+
+@@ -227,6 +227,14 @@ static struct delayed_work tqueue;
+
+ static struct net_device *poll_dev = NULL;
+
++irqreturn_t atari_ei_interrupt(int irq, void *dev_id)
++{
++ struct net_device *dev = dev_id;
++ if (netif_running(dev))
++ return ei_interrupt(dev->irq, dev);
++ return IRQ_NONE;
++}
++
+ static void atari_ethernec_int(struct work_struct *work)
+ {
+ struct net_device *dev = poll_dev;
+@@ -619,7 +627,7 @@ static int __init ne_probe1(struct net_d
+ mfp.tim_ct_cd = (mfp.tim_ct_cd & 0xf0) | 0x6;
+ }
+ /* Must make this shared in case other timer ints are needed */
+- ret = request_irq(dev->irq, ei_interrupt, IRQF_SHARED, name, dev);
++ ret = request_irq(dev->irq, atari_ei_interrupt, IRQF_SHARED, name, dev);
+ if (ret) {
+ printk(" unable to get IRQ %d (errno=%d), polling instead.\n",
+ dev->irq, ret);
+@@ -941,9 +949,9 @@ retry:
+
+
+ #ifdef MODULE
+-#define MAX_NE_CARDS 4 /* Max number of NE cards per module */
++#define MAX_NE_CARDS 1 /* Max number of NE cards per module */
+ static struct net_device *dev_ne[MAX_NE_CARDS];
+-static int io[MAX_NE_CARDS];
++static int io[MAX_NE_CARDS] = { 0x300 };
+ static int irq[MAX_NE_CARDS];
+ static int bad[MAX_NE_CARDS]; /* 0xbad = bad sig or no reset ack */
+
Added: dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/mac-esp-fix-for-quadras-with-two-esp-chips.diff
==============================================================================
--- (empty file)
+++ dists/sid/linux-2.6/debian/patches/bugfix/m68k/2.6.26/mac-esp-fix-for-quadras-with-two-esp-chips.diff Mon Oct 13 23:44:52 2008
@@ -0,0 +1,157 @@
+From fthain at telegraphics.com.au Thu Oct 9 16:29:35 2008
+Date: Fri, 10 Oct 2008 01:23:52 +1100 (EST)
+From: Finn Thain <fthain at telegraphics.com.au>
+To: Geert Uytterhoeven <geert at linux-m68k.org>
+Cc: linux-m68k at vger.kernel.org
+Subject: [PATCH] mac_esp: fix for quadras with two esp chips
+
+
+On the Quadra 900 and 950 there are two ESP chips sharing one IRQ. Because
+the shared IRQ is edge-triggered, we must make sure that an IRQ transition
+from one chip doesn't go unnoticed when the shared IRQ is already active
+due to the other. This patch prevents interrupts getting lost so that both
+SCSI busses may be used simultaneously.
+
+Signed-off-by: Finn Thain <fthain at telegraphics.com.au>
+
+---
+ drivers/scsi/mac_esp.c | 83 ++++++++++++++++++++++++++++++++++---------------
+ 1 file changed, 59 insertions(+), 24 deletions(-)
+
+--- a/drivers/scsi/mac_esp.c
++++ b/drivers/scsi/mac_esp.c
+@@ -53,7 +53,8 @@ struct mac_esp_priv {
+ void __iomem *pdma_io;
+ int error;
+ };
+-static struct platform_device *internal_esp, *external_esp;
++static struct platform_device *internal_pdev, *external_pdev;
++static struct esp *esp_chips[2];
+
+ #define MAC_ESP_GET_PRIV(esp) ((struct mac_esp_priv *) \
+ platform_get_drvdata((struct platform_device *) \
+@@ -443,6 +444,32 @@ static u32 mac_esp_dma_length_limit(stru
+ return dma_len > 0xFFFF ? 0xFFFF : dma_len;
+ }
+
++static irqreturn_t mac_scsi_esp_intr(int irq, void *dev_id)
++{
++ int got_intr;
++
++ /*
++ * This is an edge triggered IRQ, so we have to be careful to
++ * avoid missing a transition when it is shared by two ESP devices.
++ */
++
++ do {
++ got_intr = 0;
++ if (esp_chips[0] &&
++ (mac_esp_read8(esp_chips[0], ESP_STATUS) & ESP_STAT_INTR)) {
++ (void)scsi_esp_intr(irq, esp_chips[0]);
++ got_intr = 1;
++ }
++ if (esp_chips[1] &&
++ (mac_esp_read8(esp_chips[1], ESP_STATUS) & ESP_STAT_INTR)) {
++ (void)scsi_esp_intr(irq, esp_chips[1]);
++ got_intr = 1;
++ }
++ } while (got_intr);
++
++ return IRQ_HANDLED;
++}
++
+ static struct esp_driver_ops mac_esp_ops = {
+ .esp_write8 = mac_esp_write8,
+ .esp_read8 = mac_esp_read8,
+@@ -557,10 +584,16 @@ static int __devinit esp_mac_probe(struc
+ }
+
+ host->irq = IRQ_MAC_SCSI;
+- err = request_irq(host->irq, scsi_esp_intr, IRQF_SHARED, "Mac ESP",
+- esp);
+- if (err < 0)
+- goto fail_free_priv;
++ esp_chips[dev->id] = esp;
++ mb();
++ if (esp_chips[!dev->id] == NULL) {
++ err = request_irq(host->irq, mac_scsi_esp_intr, 0,
++ "Mac ESP", NULL);
++ if (err < 0) {
++ esp_chips[dev->id] = NULL;
++ goto fail_free_priv;
++ }
++ }
+
+ err = scsi_esp_register(esp, &dev->dev);
+ if (err)
+@@ -569,7 +602,8 @@ static int __devinit esp_mac_probe(struc
+ return 0;
+
+ fail_free_irq:
+- free_irq(host->irq, esp);
++ if (esp_chips[!dev->id] == NULL)
++ free_irq(host->irq, esp);
+ fail_free_priv:
+ kfree(mep);
+ fail_free_command_block:
+@@ -588,7 +622,9 @@ static int __devexit esp_mac_remove(stru
+
+ scsi_esp_unregister(esp);
+
+- free_irq(irq, esp);
++ esp_chips[dev->id] = NULL;
++ if (!(esp_chips[0] || esp_chips[1]))
++ free_irq(irq, NULL);
+
+ kfree(mep);
+
+@@ -615,19 +651,18 @@ static int __init mac_esp_init(void)
+ if (err)
+ return err;
+
+- internal_esp = platform_device_alloc(DRV_MODULE_NAME, 0);
+- if (internal_esp && platform_device_add(internal_esp)) {
+- platform_device_put(internal_esp);
+- internal_esp = NULL;
++ internal_pdev = platform_device_alloc(DRV_MODULE_NAME, 0);
++ if (internal_pdev && platform_device_add(internal_pdev)) {
++ platform_device_put(internal_pdev);
++ internal_pdev = NULL;
+ }
+-
+- external_esp = platform_device_alloc(DRV_MODULE_NAME, 1);
+- if (external_esp && platform_device_add(external_esp)) {
+- platform_device_put(external_esp);
+- external_esp = NULL;
++ external_pdev = platform_device_alloc(DRV_MODULE_NAME, 1);
++ if (external_pdev && platform_device_add(external_pdev)) {
++ platform_device_put(external_pdev);
++ external_pdev = NULL;
+ }
+
+- if (internal_esp || external_esp) {
++ if (internal_pdev || external_pdev) {
+ return 0;
+ } else {
+ platform_driver_unregister(&esp_mac_driver);
+@@ -639,13 +674,13 @@ static void __exit mac_esp_exit(void)
+ {
+ platform_driver_unregister(&esp_mac_driver);
+
+- if (internal_esp) {
+- platform_device_unregister(internal_esp);
+- internal_esp = NULL;
+- }
+- if (external_esp) {
+- platform_device_unregister(external_esp);
+- external_esp = NULL;
++ if (internal_pdev) {
++ platform_device_unregister(internal_pdev);
++ internal_pdev = NULL;
++ }
++ if (external_pdev) {
++ platform_device_unregister(external_pdev);
++ external_pdev = NULL;
+ }
+ }
+
Modified: dists/sid/linux-2.6/debian/patches/series/1-extra
==============================================================================
--- dists/sid/linux-2.6/debian/patches/series/1-extra (original)
+++ dists/sid/linux-2.6/debian/patches/series/1-extra Mon Oct 13 23:44:52 2008
@@ -2,7 +2,7 @@
# m68k patches
-# updated 2008/07/17 srm notes based on
+# updated 2008/10/13 srm notes based on
# http://www.kernel.org/pub/linux/kernel/people/geert/linux-m68k-patches-2.6.26/series
# Source: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git
@@ -38,6 +38,7 @@
+ bugfix/m68k/2.6.26/m68k-sun3-eliminate-NULL-test-and-memset-after-alloc_bootmem.diff arch=m68k
+ bugfix/m68k/2.6.26/dio-use-dio_match_device.diff arch=m68k
+ bugfix/m68k/2.6.26/m68k-initrd-fix.diff arch=m68k
++ bugfix/m68k/2.6.26/atari-atari_keyb_init-operator-precedence.diff arch=m68k
# --- pending ---
+ bugfix/m68k/2.6.26/m68k-replace-linux-68k-by-linux-m68k.diff arch=m68k
@@ -55,6 +56,9 @@
+ bugfix/m68k/2.6.26/478-serial.diff arch=m68k
+ bugfix/m68k/2.6.26/atari-rom-isa.diff arch=m68k
+ bugfix/m68k/2.6.26/atari-ethernec.diff arch=m68k
+# following two added per mschmitz
++ bugfix/m68k/2.6.26/atari-ethernec-IRQF_SHARED.diff arch=m68k
++ bugfix/m68k/2.6.26/atari-ethernec-fixes.diff arch=m68k
+ bugfix/m68k/2.6.26/atari-aranym.diff arch=m68k
+ bugfix/m68k/2.6.26/atari-ethernat.diff arch=m68k
+ bugfix/m68k/2.6.26/atari-ethernat-is-broken.diff arch=m68k
@@ -81,5 +85,10 @@
# srm: fixes video for ramdisk booting
# this is a preliminary patch by Michael Schmitz
+ bugfix/m68k/2.6.26/m68k-atari-stram.diff arch=m68k
+
+# fix udev vs. nfcon bug
+ bugfix/m68k/2.6.26/atari-aranym-nf-wrappers.diff arch=m68k
+# fix dual scsi busses and a problem with xorg (per fthain)
++ bugfix/m68k/2.6.26/mac-esp-fix-for-quadras-with-two-esp-chips.diff arch=m68k
+
More information about the Kernel-svn-changes
mailing list