mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Bartlomiej Zolnierkiewicz <B.Zolnierkiewicz@elka.pw.edu.pl>
To: Alex Bennee <kernel-hacker@bennee.com>
Cc: Linux Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: Any guides for adding new IDE chipset drivers?
Date: Mon, 16 Feb 2004 18:39:57 +0100	[thread overview]
Message-ID: <200402161839.57342.bzolnier@elka.pw.edu.pl> (raw)
In-Reply-To: <1076951082.31859.60.camel@cambridge.braddahead.com>

On Monday 16 of February 2004 18:04, Alex Bennee wrote:
> Hi,
>
> We currently have implemented a simple (PIO) IDE interface on our
> embedded SH based board. The "driver" is just a simple call from
> ide_setup() that twiddles the various values in ide_hwifs to set the
> correct port addresses.

Most embedded people till now just _abused_ ide_init_default_hwifs() :-(.

> All this is all well and good and works fine. However I'm looking at
> adding DMA support to the driver to make better use of the hardware.
> I've been looking around the other arch IDE drivers (e.g. the ppc pmac
> driver) which seem to hook into the probe_for_hwifs() and then update
> the hwifs table itself. This makes me wonder am I initialising my driver
> the "correct" way.

No, it is not the "correct" way.

> As far as implementing the DMA features is concerned as far as I can
> tell I just need to code up routines for all the various
> hwifs[x].ide_dma* functions and be done with it. Am I missing anything?
>
> So my questions boil down to:
>
> Are there any guides for driver writers for what needs doing to add new
> IDE chipset drivers?

No, unfortunately.

> Is there a driver that can be held of as an example of good taste and
> the "right" way to implement a chipset driver?

Yep.  Please take a look at drivers/ide/arm/icside.c.
It is well written, quite simple and has DMA support.

If you have any questions/issues feel free to ask
on linux-ide@vger.kernel.org mailing list.

Cheers,
--bart


  reply	other threads:[~2004-02-16 17:34 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-02-16 17:04 Alex Bennee
2004-02-16 17:39 ` Bartlomiej Zolnierkiewicz [this message]
2004-02-17 14:27 Alex Bennee
2004-02-17 15:41 ` Randy.Dunlap
2004-02-17 19:10 ` Bartlomiej Zolnierkiewicz
2004-02-18 10:41   ` Alex Bennee

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=200402161839.57342.bzolnier@elka.pw.edu.pl \
    --to=b.zolnierkiewicz@elka.pw.edu.pl \
    --cc=kernel-hacker@bennee.com \
    --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®