From: Joe Perches <joe@perches.com>
To: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
Andrew Morton <akpm@linux-foundation.org>,
Stephen Rothwell <sfr@canb.auug.org.au>,
linux-ide@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [git pull] IDE fixes
Date: Wed, 22 Apr 2009 12:06:47 -0700 [thread overview]
Message-ID: <1240427207.21848.81.camel@localhost> (raw)
In-Reply-To: <200904222048.15556.bzolnier@gmail.com>
On Wed, 2009-04-22 at 20:48 +0200, Bartlomiej Zolnierkiewicz wrote:
> diff --git a/drivers/ide/ide-cd.c b/drivers/ide/ide-cd.c
> index 3aec19d..3d4e099 100644
> --- a/drivers/ide/ide-cd.c
> +++ b/drivers/ide/ide-cd.c
> @@ -609,7 +609,7 @@ static ide_startstop_t cdrom_newpc_intr(ide_drive_t *drive)
> struct request *rq = hwif->rq;
> ide_expiry_t *expiry = NULL;
> int dma_error = 0, dma, thislen, uptodate = 0;
> - int write = (rq_data_dir(rq) == WRITE) ? 1 : 0, rc, nsectors;
> + int write = (rq_data_dir(rq) == WRITE) ? 1 : 0, rc = 0, nsectors;
> int sense = blk_sense_request(rq);
> unsigned int timeout;
> u16 len;
I think ide is the only subsystem to use the
initialization style of "?:," with additional
declarations.
Would it be better to use a more standard style?
maybe:
int dma_error = 0, dma, thislen, uptodate = 0, rc = 0, nsectors;
int write = ((rq_data_dir(rq) == WRITE) ? 1 : 0;
> diff --git a/drivers/ide/palm_bk3710.c b/drivers/ide/palm_bk3710.c
> index c7acca0..d1513b4 100644
> --- a/drivers/ide/palm_bk3710.c
> +++ b/drivers/ide/palm_bk3710.c
[]
> @@ -75,13 +67,19 @@ struct palm_bk3710_udmatiming {
>
> static unsigned ideclk_period; /* in nanoseconds */
>
> +struct palm_bk3710_udmatiming {
> + unsigned int rptime; /* tRP -- Ready to pause time (nsec) */
> + unsigned int cycletime; /* tCYCTYP2/2 -- avg Cycle Time (nsec) */
> + /* tENV is always a minimum of 20 nsec */
> +};
> +
> static const struct palm_bk3710_udmatiming palm_bk3710_udmatimings[6] = {
> - {160, 240}, /* UDMA Mode 0 */
> - {125, 160}, /* UDMA Mode 1 */
> - {100, 120}, /* UDMA Mode 2 */
> - {100, 90}, /* UDMA Mode 3 */
> - {100, 60}, /* UDMA Mode 4 */
> - {85, 40}, /* UDMA Mode 5 */
> + {160, 240 / 2,}, /* UDMA Mode 0 */
> + {125, 160 / 2,}, /* UDMA Mode 1 */
> + {100, 120 / 2,}, /* UDMA Mode 2 */
> + {100, 90 / 2,}, /* UDMA Mode 3 */
> + {100, 60 / 2,}, /* UDMA Mode 4 */
> + {85, 40 / 2,}, /* UDMA Mode 5 */
> };
>
> static void palm_bk3710_setudmamode(void __iomem *base, unsigned int dev,
Odd looking commas.
Maybe:
{.rptime = 160, .cycletime = 240 / 2 }, /* UDMA Mode 0 */
etc.
next prev parent reply other threads:[~2009-04-22 19:08 UTC|newest]
Thread overview: 58+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-22 18:48 [git pull] IDE fixes Bartlomiej Zolnierkiewicz
2009-04-22 19:06 ` Joe Perches [this message]
2009-04-22 19:22 ` Sam Ravnborg
2009-04-22 19:43 ` Bartlomiej Zolnierkiewicz
2009-04-22 19:55 ` Joe Perches
2009-04-22 21:41 ` Bartlomiej Zolnierkiewicz
2009-04-22 22:02 ` Ray Lee
2009-04-22 22:51 ` Bartlomiej Zolnierkiewicz
2009-04-22 22:58 ` Bartlomiej Zolnierkiewicz
-- strict thread matches above, loose matches on Subject: below --
2009-06-07 12:44 Bartlomiej Zolnierkiewicz
2009-06-07 14:21 ` Alan Cox
2009-06-07 14:32 ` Bartlomiej Zolnierkiewicz
2009-06-07 14:40 ` Alan Cox
2009-06-07 15:03 ` Bartlomiej Zolnierkiewicz
2009-06-07 15:11 ` Alan Cox
2009-06-07 14:38 ` James Bottomley
2009-06-07 14:57 ` Bartlomiej Zolnierkiewicz
2009-06-07 15:18 ` James Bottomley
2009-06-07 15:44 ` Bartlomiej Zolnierkiewicz
2009-06-07 16:08 ` James Bottomley
2009-06-07 17:47 ` Bartlomiej Zolnierkiewicz
2009-06-07 19:08 ` James Bottomley
2009-06-07 19:23 ` Bartlomiej Zolnierkiewicz
2009-06-07 20:07 ` Alan Cox
2009-06-07 20:39 ` James Bottomley
2009-06-07 21:08 ` Bartlomiej Zolnierkiewicz
2009-06-07 20:42 ` Bartlomiej Zolnierkiewicz
2009-06-07 16:54 ` Pekka Enberg
2009-06-07 17:55 ` Bartlomiej Zolnierkiewicz
2009-06-07 18:21 ` Pekka Enberg
2009-06-07 19:00 ` Bartlomiej Zolnierkiewicz
2009-06-07 19:09 ` Pekka Enberg
2009-06-07 19:25 ` Bartlomiej Zolnierkiewicz
2009-06-07 23:15 ` Linus Torvalds
2009-06-07 23:47 ` Bartlomiej Zolnierkiewicz
2009-06-07 23:57 ` Linus Torvalds
2009-06-08 0:54 ` Bartlomiej Zolnierkiewicz
2009-06-07 23:14 ` Linus Torvalds
2009-06-07 23:12 ` Linus Torvalds
2009-05-22 15:17 Bartlomiej Zolnierkiewicz
2009-05-16 19:16 Bartlomiej Zolnierkiewicz
2009-05-16 19:22 ` Borislav Petkov
2009-05-16 19:33 ` Bartlomiej Zolnierkiewicz
2009-04-18 16:09 Bartlomiej Zolnierkiewicz
2009-03-13 20:49 Bartlomiej Zolnierkiewicz
2009-03-05 15:30 Bartlomiej Zolnierkiewicz
2009-03-05 16:27 ` Bartlomiej Zolnierkiewicz
2009-02-25 19:54 Bartlomiej Zolnierkiewicz
2009-02-02 19:48 Bartlomiej Zolnierkiewicz
2009-01-19 12:50 Bartlomiej Zolnierkiewicz
2008-12-22 22:08 Bartlomiej Zolnierkiewicz
2008-12-08 16:55 Bartlomiej Zolnierkiewicz
2008-10-05 16:38 Bartlomiej Zolnierkiewicz
2008-09-27 17:47 Bartlomiej Zolnierkiewicz
2008-09-10 20:47 Bartlomiej Zolnierkiewicz
2008-09-02 18:24 Bartlomiej Zolnierkiewicz
2008-08-18 20:22 Bartlomiej Zolnierkiewicz
2008-07-08 17:38 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=1240427207.21848.81.camel@localhost \
--to=joe@perches.com \
--cc=akpm@linux-foundation.org \
--cc=bzolnier@gmail.com \
--cc=linux-ide@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=sfr@canb.auug.org.au \
--cc=torvalds@linux-foundation.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).