Thread (4 messages) 4 messages, 2 authors, 2009-08-04

Re: Extremely slow IO with a PCMCIA CompactFlash adapter

From: Jack Byer <hidden>
Date: 2009-08-03 01:25:26
Also in: lkml

quoted hunk ↗ jump to hunk
Seems like there is also a bug in ali5451 sound driver..

This should help:

---
 sound/pci/ali5451/ali5451.c |   11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

Index: b/sound/pci/ali5451/ali5451.c
===================================================================
--- a/sound/pci/ali5451/ali5451.c
+++ b/sound/pci/ali5451/ali5451.c
@@ -314,8 +314,11 @@ static int snd_ali_codec_ready(struct sn
               res = snd_ali_5451_peek(codec,port);
               if (!(res & 0x8000))
                       return 0;
+               if (time_after_eq(end_time, jiffies))
+                       break;
               schedule_timeout_uninterruptible(1);
-       } while (time_after_eq(end_time, jiffies));
+       } while (1);
+
       snd_ali_5451_poke(codec, port, res & ~0x8000);
       snd_printdd("ali_codec_ready: codec is not ready.\n ");
       return -EIO;
@@ -327,15 +330,17 @@ static int snd_ali_stimer_ready(struct s
       unsigned long dwChk1,dwChk2;

       dwChk1 = snd_ali_5451_peek(codec, ALI_STIMER);
-       dwChk2 = snd_ali_5451_peek(codec, ALI_STIMER);

       end_time = jiffies + msecs_to_jiffies(250);
       do {
               dwChk2 = snd_ali_5451_peek(codec, ALI_STIMER);
               if (dwChk2 != dwChk1)
                       return 0;
+               if (time_after_eq(end_time, jiffies))
+                       break;
               schedule_timeout_uninterruptible(1);
-       } while (time_after_eq(end_time, jiffies));
+       } while (1);
+
       snd_printk(KERN_ERR "ali_stimer_read: stimer is not ready.\n");
       return -EIO;
 }

--
quoted
AC'97 1 does not respond - RESET
AC'97 1 access is not valid [0xffffffff], removing mixer.
ali mixer 1 creating error.
This was also present in the previous log (before libata's setup) so
there is some more general problem with the sound..

You may try this patch which keeps softmodem device alive instead of
disabling it (since it shares some hardware with the sound codec)..

---
 drivers/serial/8250_pci.c |   11 ++++++++---
 1 file changed, 8 insertions(+), 3 deletions(-)

Index: b/drivers/serial/8250_pci.c
===================================================================
--- a/drivers/serial/8250_pci.c
+++ b/drivers/serial/8250_pci.c
@@ -2222,7 +2222,7 @@ serial_pci_guess_board(struct pci_dev *d
            blacklist++) {
               if (dev->vendor == blacklist->vendor &&
                   dev->device == blacklist->device)
-                       return -ENODEV;
+                       return -EOPNOTSUPP;
       }

       num_iomem = num_port = 0;
@@ -2448,8 +2448,12 @@ pciserial_init_one(struct pci_dev *dev,
                * determine the parameters of this board.
                */
               rc = serial_pci_guess_board(dev, &tmp);
-               if (rc)
-                       goto disable;
+               if (rc) {
+                       if (rc == -EOPNOTSUPP)
+                               goto out;
+                       else
+                               goto disable;
+               }
       } else {
               /*
                * We matched an explicit entry.  If we are able to
@@ -2474,6 +2478,7 @@ pciserial_init_one(struct pci_dev *dev,
 disable:
       pci_disable_device(dev);
+ out:
       return rc;
 }

Those patches do not appear to have worked:

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help