linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: norbert_wolff@t-online.de (Norbert Wolff)
To: linux-kernel@vger.kernel.org
Cc: alan@lxorguk.ukuu.org.uk
Subject: PROBLEM: linux-2.5.65-ac3 does not boot whith IDE-drivers
Date: Mon, 24 Mar 2003 11:08:24 +0000	[thread overview]
Message-ID: <20030324110824.1b419814.norbert_wolff@t-online.de> (raw)
In-Reply-To: <3E7E3248.7070307@portrix.net>

Hi !

I tried linux-2.5.65-ac3 with ide-disk and ide-scsi drivers both built in
the Kernel.
Two ide-disks attached to ide0, two CDROMS attached to ide1.
Im using the sis5513-PCI-IDE-Driver, but configuring it out makes no difference.

The System hangs while booting with last messages
	ide0 at 0x1f0-0x1f7,0x3f6 on irq 14
	ide1 at 0x170-0x177,0x376 on irq 15

It seems that all Drives went twice in the driver-list, so ata_attach
gets called twice for them, which leads to the hang.

Dirty Hack that works for me below.

Regards,

	Norbert


--- drivers/ide/ide.c.orig	2003-03-24 10:52:40.000000000 +0000
+++ drivers/ide/ide.c	2003-03-24 10:57:52.000000000 +0000
@@ -1423,6 +1423,14 @@
 {
 	struct list_head *p;
 	spin_lock(&drivers_lock);
+#define _DEBUG 1
+#ifdef _DEBUG
+	printk("ata_attach called for %s\n", drive->name);
+#endif
+	if (drive->already_attached) {
+		printk ("ata_attach: already attached for %s !\n", drive->name);
+		return 0;
+	}
 	list_for_each(p, &drivers) {
 		ide_driver_t *driver = list_entry(p, ide_driver_t, drivers);
 		if (!try_module_get(driver->owner))
@@ -1431,12 +1439,14 @@
 		if (driver->attach(drive) == 0) {
 			module_put(driver->owner);
 			drive->gendev.driver = &driver->gen_driver;
+			drive->already_attached = 1;
 			return 0;
 		}
 		spin_lock(&drivers_lock);
 		module_put(driver->owner);
 	}
 	drive->gendev.driver = &idedefault_driver.gen_driver;
+	drive->already_attached = 1;
 	spin_unlock(&drivers_lock);
 	if(idedefault_driver.attach(drive) != 0)
 		panic("ide: default attach failed");
--- include/linux/ide.h.orig	2003-03-24 11:01:41.000000000 +0000
+++ include/linux/ide.h	2003-03-24 11:02:33.000000000 +0000
@@ -791,6 +791,7 @@
 	int		forced_lun;	/* if hdxlun was given at boot */
 	int		lun;		/* logical unit */
 	int		crc_count;	/* crc counter to reduce drive speed */
+	int     already_attached;  /* Dirty Hack ... */
 	struct list_head list;
 	struct device	gendev;
 	struct gendisk *disk;

  reply	other threads:[~2003-03-24  9:57 UTC|newest]

Thread overview: 31+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-03-22 14:03 2.5.65-ac2 -- hda/ide trouble on ICH4 Dominik Brodowski
2003-03-22 16:35 ` Alan Cox
2003-03-22 16:25   ` Dominik Brodowski
2003-03-22 17:42     ` Alan Cox
2003-03-22 16:39       ` Jan Dittmer
2003-03-23  1:03       ` Dominik Brodowski
2003-03-23 15:47         ` Alan Cox
2003-03-23 14:59           ` Dominik Brodowski
2003-03-23 18:41             ` Alan Cox
2003-03-23 18:15               ` Dominik Brodowski
2003-03-23 18:25                 ` ide: indeed, using list_for_each_entry_safe removes endless looping / hang [Was: Re: 2.5.65-ac2 -- hda/ide trouble on ICH4] Dominik Brodowski
2003-03-23 22:16                   ` Jan Dittmer
2003-03-24 11:08                     ` Norbert Wolff [this message]
2003-03-24 13:54                       ` PROBLEM: linux-2.5.65-ac3 does not boot whith IDE-drivers Alan Cox
2003-03-24  9:55                   ` ide: indeed, using list_for_each_entry_safe removes endless looping / hang [Was: Re: 2.5.65-ac2 -- hda/ide trouble on ICH4] Alexander Atanasov
2003-03-24 13:59                     ` Alan Cox
2003-03-24 16:01                       ` Alexander Atanasov
2003-03-24 17:40                         ` Alan Cox
2003-03-24 17:24                           ` Alexander Atanasov
2003-03-25  4:16                             ` Andre Hedrick
2003-03-25 13:59                               ` Alan Cox
2003-03-25 20:05                             ` Bartlomiej Zolnierkiewicz
2003-03-25 20:24                               ` Bartlomiej Zolnierkiewicz
2003-04-03  7:00                           ` PATCH:ide_do_reset() fix for 2.5.66 rain.wang
2003-04-03  7:16                             ` Jens Axboe
2003-04-03  8:36                               ` PATCH RFC :ide_do_reset() " rain.wang
2003-04-10  3:37                                 ` [rfc][patch]: fix handler race in HDIO_DRIVE_RESET path for 2.5.67-ac1 rain.wang
2003-03-22 22:03     ` [PATCH] Re: 2.5.65-ac2 -- hda/ide trouble on ICH4 Bartlomiej Zolnierkiewicz
2003-03-22 23:27       ` Alan Cox
2003-03-22 22:33         ` Bartlomiej Zolnierkiewicz
2003-03-23  9:11       ` Dominik Brodowski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20030324110824.1b419814.norbert_wolff@t-online.de \
    --to=norbert_wolff@t-online.de \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).