public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Jesse Barnes <jbarnes@engr.sgi.com>
To: davidm@hpl.hp.com
Cc: linux-pci@atrey.karlin.mff.cuni.cz, linux-ia64@vger.kernel.org,
	linux-kernel@vger.kernel.org, willy@debian.org
Subject: Re: [PATCH] add legacy I/O port & memory APIs to /proc/bus/pci
Date: Thu, 16 Dec 2004 10:56:12 -0800	[thread overview]
Message-ID: <200412161056.13019.jbarnes@engr.sgi.com> (raw)
In-Reply-To: <16833.55270.601527.754270@napali.hpl.hp.com>

On Thursday, December 16, 2004 10:45 am, David Mosberger wrote:
> >>>>> On Thu, 16 Dec 2004 08:50:19 -0800, Jesse Barnes
> >>>>> <jbarnes@engr.sgi.com> said:
>
>   Jesse> +int ia64_pci_legacy_read(struct pci_dev *dev, u16 port, u32 *val,
> u8 size) Jesse> +{
>   Jesse> + int ret = 0;
>   Jesse>         :
>   Jesse> + case 1:
>   Jesse> +  addr = (unsigned long *)paddr;
>   Jesse> +  *val = (u8)(*(volatile u8 *)(addr));
>   Jesse> +  break;
>   Jesse> + case 2:
>   Jesse> +  addr = (unsigned long *)paddr;
>   Jesse> +  *val = (u16)(*(volatile u16 *)(addr));
>   Jesse> +  break;
>   Jesse>          :
>   Jesse> +}
>
>   Jesse> +int ia64_pci_legacy_write(struct pci_dev *dev, u16 port, u32 val,
> u8 size) Jesse> +{
>   Jesse> + switch (size) {
>   Jesse> + case 1:
>   Jesse> +  addr = (unsigned long *)paddr;
>   Jesse> +  *(volatile u8 *)(addr) = (u8)(val);
>   Jesse> +  break;
>   Jesse> + case 2:
>   Jesse> +  addr = (unsigned long *)paddr;
>   Jesse> +  *(volatile u16 *)(addr) = (u16)(val);
>   Jesse> +  break;
>   Jesse>           :
>   Jesse> + }
>
> No offense, but what's up with this castamania?

Leftovers from other code.  I don't actually use this stuff on sn2, someone 
with a DIG test box will have to verify it (willy pointed out that I should 
probably just be using the appropriate inX our outX routine here instead, 
which makes sense).

Jesse

  reply	other threads:[~2004-12-16 18:58 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-16 16:50 [PATCH] add legacy I/O port & memory APIs to /proc/bus/pci Jesse Barnes
2004-12-16 16:39 ` Randy.Dunlap
2004-12-16 17:07   ` Jesse Barnes
2004-12-16 17:55   ` Doug Maxey
2004-12-16 16:56 ` Christoph Hellwig
2004-12-16 17:04   ` Jesse Barnes
2004-12-16 17:37 ` Bjorn Helgaas
2004-12-16 17:42   ` Jesse Barnes
2004-12-16 18:45 ` David Mosberger
2004-12-16 18:56   ` Jesse Barnes [this message]
2004-12-16 19:07     ` Jesse Barnes
2004-12-16 19:11       ` David Mosberger
2004-12-16 19:13         ` Jesse Barnes

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=200412161056.13019.jbarnes@engr.sgi.com \
    --to=jbarnes@engr.sgi.com \
    --cc=davidm@hpl.hp.com \
    --cc=linux-ia64@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@atrey.karlin.mff.cuni.cz \
    --cc=willy@debian.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