From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
To: linux-ide@vger.kernel.org
Subject: [PATCH] pdc202xx_new: check ide_config_drive_speed() return value
Date: Thu, 26 Jul 2007 21:56:57 +0200 [thread overview]
Message-ID: <200707262156.57562.bzolnier@gmail.com> (raw)
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
---
drivers/ide/pci/pdc202xx_new.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
Index: b/drivers/ide/pci/pdc202xx_new.c
===================================================================
--- a/drivers/ide/pci/pdc202xx_new.c
+++ b/drivers/ide/pci/pdc202xx_new.c
@@ -150,13 +150,13 @@ static int pdcnew_tune_chipset(ide_drive
{
ide_hwif_t *hwif = HWIF(drive);
u8 adj = (drive->dn & 1) ? 0x08 : 0x00;
- int err;
/*
* Issue SETFEATURES_XFER to the drive first. PDC202xx hardware will
* automatically set the timing registers based on 100 MHz PLL output.
*/
- err = ide_config_drive_speed(drive, speed);
+ if (ide_config_drive_speed(drive, speed))
+ return 1;
/*
* As we set up the PLL to output 133 MHz for UltraDMA/133 capable
@@ -212,7 +212,7 @@ static int pdcnew_tune_chipset(ide_drive
set_indexed_reg(hwif, 0x10 + adj, tmp & 0x7f);
}
- return err;
+ return 0;
}
static void pdcnew_set_pio_mode(ide_drive_t *drive, const u8 pio)
next reply other threads:[~2007-07-26 20:00 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-07-26 19:56 Bartlomiej Zolnierkiewicz [this message]
2007-07-26 20:20 ` [PATCH] pdc202xx_new: check ide_config_drive_speed() return value Sergei Shtylyov
2007-07-28 21:57 ` Bartlomiej Zolnierkiewicz
2007-07-29 10:34 ` Sergei Shtylyov
2007-07-29 10:37 ` Sergei Shtylyov
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=200707262156.57562.bzolnier@gmail.com \
--to=bzolnier@gmail.com \
--cc=linux-ide@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).