linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
To: linux-ide@vger.kernel.org
Cc: linuxppc-dev@ozlabs.org,
	Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>,
	Benjamin Herrenschmidt <benh@kernel.crashing.org>,
	linux-kernel@vger.kernel.org
Subject: [PATCH 1/7] ide-pmac: bugfix for media-bay support rework
Date: Fri, 13 Jun 2008 01:12:24 +0200	[thread overview]
Message-ID: <20080612231224.18335.91182.sendpatchset@localhost.localdomain> (raw)

Fix bug introduced by:

commit 2dde7861afa23cd59db83515cb0b810b92b220aa
Author: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Date:   Fri Apr 18 00:46:23 2008 +0200

    ide: rework PowerMac media-bay support (take 2)
...

[ Yeah, I suck. ]

bay->cd_index shouldn't be changed if IDE devices are not present
or retry operations won't happen.

Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
---
first three patches are meant for 2.6.26, the rest for 2.6.27

drivers/macintosh/mediabay.c |    3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Index: b/drivers/macintosh/mediabay.c
===================================================================
--- a/drivers/macintosh/mediabay.c
+++ b/drivers/macintosh/mediabay.c
@@ -556,7 +556,8 @@ static void media_bay_step(int i)
 				printk("mediabay %d, registering IDE...\n", i);
 				pmu_suspend();
 				ide_port_scan(bay->cd_port);
-				bay->cd_index = bay->cd_port->index;
+				if (bay->cd_port->present)
+					bay->cd_index = bay->cd_port->index;
 				pmu_resume();
 			}
 			if (bay->cd_index == -1) {

             reply	other threads:[~2008-06-12 23:10 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-12 23:12 Bartlomiej Zolnierkiewicz [this message]
2008-06-12 23:12 ` [PATCH 2/7] ide-pmac: add ->cable_detect method Bartlomiej Zolnierkiewicz
2008-06-12 23:12 ` [PATCH 3/7] ide-pmac: remove bogus comment about pmac_ide_setup_device() Bartlomiej Zolnierkiewicz
2008-06-12 23:12 ` [PATCH 4/7] ide-pmac: media-bay support fixes Bartlomiej Zolnierkiewicz
2008-06-12 23:13 ` [PATCH 5/7] ide-pmac: store pmif instead of hwif in ->driver_data Bartlomiej Zolnierkiewicz
2008-06-12 23:13 ` [PATCH 6/7] ide-pmac: add ->init_dev method Bartlomiej Zolnierkiewicz
2008-06-12 23:13 ` [PATCH 7/7] ide-pmac: move ide_find_port() call to pmac_ide_setup_device() Bartlomiej Zolnierkiewicz

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=20080612231224.18335.91182.sendpatchset@localhost.localdomain \
    --to=bzolnier@gmail.com \
    --cc=benh@kernel.crashing.org \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@ozlabs.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).