From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
To: Jeff Garzik <jgarzik@pobox.com>
Cc: linux-ide@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: [PATCH] pata_ali: cleanup ali_set_piomode()
Date: Thu, 13 Oct 2011 13:09:25 +0200 [thread overview]
Message-ID: <201110131309.26032.bzolnier@gmail.com> (raw)
From: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Subject: [PATCH] pata_ali: cleanup ali_set_piomode()
Merge ali_fifo_control() calls.
This changes behavior but there shouldn't be any problems with it.
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
---
earlier references:
https://lkml.org/lkml/2010/1/18/258
drivers/ata/pata_ali.c | 7 ++-----
1 file changed, 2 insertions(+), 5 deletions(-)
Index: b/drivers/ata/pata_ali.c
===================================================================
--- a/drivers/ata/pata_ali.c
+++ b/drivers/ata/pata_ali.c
@@ -222,12 +222,9 @@ static void ali_set_piomode(struct ata_p
}
/* PIO FIFO is only permitted on ATA disk */
- if (adev->class != ATA_DEV_ATA)
- ali_fifo_control(ap, adev, 0x00);
- ali_program_modes(ap, adev, &t, 0);
- if (adev->class == ATA_DEV_ATA)
- ali_fifo_control(ap, adev, 0x05);
+ ali_fifo_control(ap, adev, (adev->class == ATA_DEV_ATA) ? 0x05 : 0x00);
+ ali_program_modes(ap, adev, &t, 0);
}
/**
next reply other threads:[~2011-10-13 11:09 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-10-13 11:09 Bartlomiej Zolnierkiewicz [this message]
2011-10-13 12:53 ` [PATCH] pata_ali: cleanup ali_set_piomode() Alan Cox
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=201110131309.26032.bzolnier@gmail.com \
--to=bzolnier@gmail.com \
--cc=jgarzik@pobox.com \
--cc=linux-ide@vger.kernel.org \
--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).