mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl>
To: Marc Singer <elf@buici.com>, Jeff Garzik <jgarzik@pobox.com>
Cc: linux-ide@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [RFC][DOC] writing IDE driver guidelines
Date: Sun, 16 May 2004 21:34:30 +0200	[thread overview]
Message-ID: <200405162134.30564.bzolnier@elka.pw.edu.pl> (raw)
In-Reply-To: <20040516010008.GC23743@buici.com>

On Sunday 16 of May 2004 03:00, Marc Singer wrote:
> On Sat, May 15, 2004 at 06:23:04PM -0400, Jeff Garzik wrote:
> > Bartlomiej Zolnierkiewicz wrote:
> > >On Saturday 15 of May 2004 19:34, Jeff Garzik wrote:
> > >>On Sat, May 15, 2004 at 07:23:50PM +0200, Bartlomiej Zolnierkiewicz wrote:
> > >>>- host drivers should request/release IO resource
> > >>> themelves and set hwif->mmio to 2
> > >>
> > >>Don't you mean, hwif->mmio==2 for MMIO hardware?
> > >
> > >It is was historically for MMIO, now it means that driver
> > >handles IO resource itself (per comment in <linux/ide.h>).
> >
> > Maybe then create a constant HOST_IO_RESOURCES (value==2) to make that
> > more obvious?
>
> Please allow me to advocate for the naive.
>
> While I do not in favor of lengthy commented discourses within the
> code for all of the usual reasons, I do believe that interface
> documentation is always welcome.  It encourages everyone to learn and
> follow the rules.  It allows the subsystem maintainer to establish a
> boundary so that accessing lower-level structures are left alone.
>
> I'm not talking about a HOWTO as we know it.  Let's look at this mmio
> flag.  How about writing this at a very minimum.
>
>   	int mmio; /* 0: iommio; <insert appropriate direction */
> 		  /* 2: custom; driver must reserve & release system resources */

I think this is good for ide.h

> Certainly, I'd rather see something along the lines of a full
> description.
>
> 	int mmio;
> 	    /* This field controls whether or not the driver blah,
> 	       blah.  If the driver needs to reserve system resources,
> 	       e.g. ports of memory, set the value to 2 and blah, blah. */

and this is good for documentation file.

> It isn't much, but it goes a long way.

Thanks.


  reply	other threads:[~2004-05-16 19:32 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-05-15 17:23 Bartlomiej Zolnierkiewicz
2004-05-15 17:34 ` Jeff Garzik
2004-05-15 17:58   ` Bartlomiej Zolnierkiewicz
2004-05-15 18:13     ` Bartlomiej Zolnierkiewicz
2004-05-15 22:23     ` Jeff Garzik
2004-05-16  1:00       ` Marc Singer
2004-05-16 19:34         ` Bartlomiej Zolnierkiewicz [this message]
2004-05-16 19:26       ` Bartlomiej Zolnierkiewicz
2004-05-16  0:51     ` Marc Singer
2004-05-16 19:33       ` 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=200405162134.30564.bzolnier@elka.pw.edu.pl \
    --to=b.zolnierkiewicz@elka.pw.edu.pl \
    --cc=elf@buici.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

all inboxes | Powered by JetHome®