From: Andrei Martynov <andrei.martynov@web.de>
To: linux-ide@vger.kernel.org
Subject: IN_BYTE and OUT_BYTE replacement
Date: Thu, 9 Jul 2009 14:28:30 +0200 [thread overview]
Message-ID: <327262546.20090709142830@web.de> (raw)
Hi,
there were specific i/o macros IN_BYTE and OUT_BYTE in 2.4 kernel to
access IDE registers, but seems they are gone in 2.6 kernel and
replaced by ioread8 / iowrite8 that are used everywhere and not in
libata only. In my case original code for 2.4 kernel wrote specific
value to undocumented chipset register on *every* r/w access to *any*
IDE register.
#define OUT_BYTE(b,p) { outb(b,p); outb(255, JASPER_IDE_BASE + 0xe0); }
static inline byte jasper_ide_in_byte(int p)
{
byte b;
b = (byte)inb(p);
outb(255, JASPER_IDE_BASE + 0xe0);
return b;
}
#define IN_BYTE(p) jasper_ide_in_byte(p)
Is there any way to reproduce this behavior in libata other than
redefining ioread8/iowrite8?
--
Best regards,
Andrei mailto:andrei.martynov@web.de
next reply other threads:[~2009-07-09 12:28 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-07-09 12:28 Andrei Martynov [this message]
2009-07-09 12:46 ` IN_BYTE and OUT_BYTE replacement 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=327262546.20090709142830@web.de \
--to=andrei.martynov@web.de \
--cc=linux-ide@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.