public inbox for linux-m68k@lists.linux-m68k.org
 help / color / mirror / Atom feed
From: Paolo Pisati <p.pisati@gmail.com>
To: linux-m68k <linux-m68k@vger.kernel.org>
Subject: [PATCH 0/1] [RFC][NOT WORKING] amiga: pcmcia: inb()/inw() on GAYLE_IO space
Date: Sat, 26 Oct 2024 17:42:32 +0200	[thread overview]
Message-ID: <20241026154233.351261-1-p.pisati@gmail.com> (raw)

Hi there,

attached is a driver for the pcmcia side of C='s gayle - it's a WIP, as such
there are many dev_dbg()/pr_err()/pr_dbg() scattered around, you've been warned.

It recognize all pcmcia cards i tried (IOW gayle's attribute space is read and
parsed correctly), socket's interrupt work (IOW you can plug & unplug cards),
but *it seems* any I/O read operation return bogus data (e.g. 0xff or 0xfff).

Here's a dmesg dealing with with a 3Com 3c589 ethernet card:
http://dpaste.com//84TPTPLNV - notice the "hw_addr ff:ff:ff:ff:ff:ff" or
"exiting interrupt, status ffff".

AFAIK inb()/inw() already add the GAYLE_IO offset (
AG_ISA_IO_B and AG_ISA_IO_W in arch/m68k/include/asm/io_mm.h), and i didn't know
if i could read directly (without an ioremap() first), so i tried both cases:

1) ioreamp() sock->phys_io, and subtract the GAYLE_IO offset (see
sock->socket.io_offset).

or 

2) set Amiga base IO port to 0x0 and patch
drivers/pcmcia/rsrc_mgr.c::static_find_io() (see https://dpaste.com//B75LTFF3V)

In both case the 3c589_cs driver request an I/O aperture at 0x0300, large
0x0010, receives it, but all read operations return 0xff or 0xffff.

Any idea? Any guess is welcome since i'm running out of ideas ATM.

Paolo Pisati (1):
  pcmcia: gayle: initial support

 arch/m68k/amiga/pcmcia.c          |   5 +
 arch/m68k/amiga/platform.c        |  29 +++
 arch/m68k/include/asm/amipcmcia.h |  11 ++
 drivers/pcmcia/Kconfig            |   8 +
 drivers/pcmcia/Makefile           |   1 +
 drivers/pcmcia/gayle.c            | 307 ++++++++++++++++++++++++++++++
 6 files changed, 361 insertions(+)
 create mode 100644 drivers/pcmcia/gayle.c

-- 
2.34.1


             reply	other threads:[~2024-10-26 15:42 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-26 15:42 Paolo Pisati [this message]
2024-10-26 15:42 ` [PATCH 1/1] pcmcia: gayle: initial support Paolo Pisati
2024-11-02  2:02 ` [PATCH 0/1] [RFC][NOT WORKING] amiga: pcmcia: inb()/inw() on GAYLE_IO space Michael Schmitz
2024-11-02 10:12   ` Paolo Pisati

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=20241026154233.351261-1-p.pisati@gmail.com \
    --to=p.pisati@gmail.com \
    --cc=linux-m68k@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