All of lore.kernel.org
 help / color / mirror / Atom feed
From: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
To: Russell King - ARM Linux <linux@armlinux.org.uk>
Cc: Sergei Shtylyov <sergei.shtylyov@cogentembedded.com>,
	Sekhar Nori <nsekhar@ti.com>, Arnd Bergmann <arnd@arndb.de>,
	Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>,
	Kevin Hilman <khilman@baylibre.com>,
	linux-kernel@vger.kernel.org, linux-ide@vger.kernel.org,
	Olof Johansson <olof@lixom.net>,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [RESEND PATCH] arm: assabet_defconfig: disable IDE subsystem
Date: Thu, 09 Mar 2017 15:52:11 +0100	[thread overview]
Message-ID: <2925309.c9ir13Bff9@amdc3058> (raw)
In-Reply-To: <3285453.g1rFzTv5DW@amdc3058>

On Thursday, March 09, 2017 03:42:49 PM Bartlomiej Zolnierkiewicz wrote:

> > Yes, it's very obscure - but what it comes down to is the silly way the
> > "ISA" IO is handled on the platform (which depends whether it's an 8-bit
> > or 16-bit ISA-style peripheral.)  The old IDE CS driver _could_ be bent
> > to work via a patch like this:
> > 
> > ARM: EBSA110: Enable 16-bit IO type for ide-iops
> > 
> > diff --git a/arch/arm/Makefile b/arch/arm/Makefile
> > index 047a20780fc1..2eb501d6b5fe 100644
> > --- a/arch/arm/Makefile
> > +++ b/arch/arm/Makefile
> > @@ -217,7 +217,8 @@ ifeq ($(CONFIG_ARCH_EBSA110),y)
> >  # This is what happens if you forget the IOCS16 line.
> >  # PCMCIA cards stop working.
> >  CFLAGS_3c589_cs.o :=-DISA_SIXTEEN_BIT_PERIPHERAL
> > -export CFLAGS_3c589_cs.o
> > +CFLAGS_ide-io-std.o :=-DISA_SIXTEEN_BIT_PERIPHERAL
> > +export CFLAGS_3c589_cs.o CFLAGS_ide-io-std.o
> >  endif
> 
> As I've already explained in the past, the proper fix for the problem
> (for both old IDE and libata) is to define custom transport ops in
> ide-cs.c/ata_pcmcia.c and use them on affected platforms.
> 
> >  # The byte offset of the kernel image in RAM from the start of RAM.
> > 
> > but the PATA driver is much harder.
> 
> There are a lot examples of using your own transport operations in
> existing code (i.e. pata_octeon_cf.c or drivers/ata/sata_rcar.c).

Basically it should come down to copypasting all transport ops
from libata-sff.c and replacing all ioread8()/iowrite8() with
__inb16()__outb16(). Then you need to add detection of EBSA1100
which should also be as simple as using machine_is_ebsa110() in
the proper place.

If you ever get to running current upstream on your EBSA110
I can provide you with the draft patch doing this.

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics


WARNING: multiple messages have this Message-ID (diff)
From: b.zolnierkie@samsung.com (Bartlomiej Zolnierkiewicz)
To: linux-arm-kernel@lists.infradead.org
Subject: [RESEND PATCH] arm: assabet_defconfig: disable IDE subsystem
Date: Thu, 09 Mar 2017 15:52:11 +0100	[thread overview]
Message-ID: <2925309.c9ir13Bff9@amdc3058> (raw)
In-Reply-To: <3285453.g1rFzTv5DW@amdc3058>

On Thursday, March 09, 2017 03:42:49 PM Bartlomiej Zolnierkiewicz wrote:

> > Yes, it's very obscure - but what it comes down to is the silly way the
> > "ISA" IO is handled on the platform (which depends whether it's an 8-bit
> > or 16-bit ISA-style peripheral.)  The old IDE CS driver _could_ be bent
> > to work via a patch like this:
> > 
> > ARM: EBSA110: Enable 16-bit IO type for ide-iops
> > 
> > diff --git a/arch/arm/Makefile b/arch/arm/Makefile
> > index 047a20780fc1..2eb501d6b5fe 100644
> > --- a/arch/arm/Makefile
> > +++ b/arch/arm/Makefile
> > @@ -217,7 +217,8 @@ ifeq ($(CONFIG_ARCH_EBSA110),y)
> >  # This is what happens if you forget the IOCS16 line.
> >  # PCMCIA cards stop working.
> >  CFLAGS_3c589_cs.o :=-DISA_SIXTEEN_BIT_PERIPHERAL
> > -export CFLAGS_3c589_cs.o
> > +CFLAGS_ide-io-std.o :=-DISA_SIXTEEN_BIT_PERIPHERAL
> > +export CFLAGS_3c589_cs.o CFLAGS_ide-io-std.o
> >  endif
> 
> As I've already explained in the past, the proper fix for the problem
> (for both old IDE and libata) is to define custom transport ops in
> ide-cs.c/ata_pcmcia.c and use them on affected platforms.
> 
> >  # The byte offset of the kernel image in RAM from the start of RAM.
> > 
> > but the PATA driver is much harder.
> 
> There are a lot examples of using your own transport operations in
> existing code (i.e. pata_octeon_cf.c or drivers/ata/sata_rcar.c).

Basically it should come down to copypasting all transport ops
from libata-sff.c and replacing all ioread8()/iowrite8() with
__inb16()__outb16(). Then you need to add detection of EBSA1100
which should also be as simple as using machine_is_ebsa110() in
the proper place.

If you ever get to running current upstream on your EBSA110
I can provide you with the draft patch doing this.

Best regards,
--
Bartlomiej Zolnierkiewicz
Samsung R&D Institute Poland
Samsung Electronics

  parent reply	other threads:[~2017-03-09 14:52 UTC|newest]

Thread overview: 106+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-08 15:24 [RESEND PATCH] arm: assabet_defconfig: disable IDE subsystem Bartlomiej Zolnierkiewicz
2016-07-08 15:24 ` Bartlomiej Zolnierkiewicz
2016-07-08 15:24 ` [RESEND PATCH] arm: badge4_defconfig: " Bartlomiej Zolnierkiewicz
2016-07-08 15:24   ` Bartlomiej Zolnierkiewicz
2016-07-08 15:24   ` Bartlomiej Zolnierkiewicz
2016-07-08 15:24 ` [RESEND PATCH] arm: cerfcube_defconfig: " Bartlomiej Zolnierkiewicz
2016-07-08 15:24   ` Bartlomiej Zolnierkiewicz
2016-07-08 15:24 ` [RESEND PATCH] arm: colibri_pxa270_defconfig: " Bartlomiej Zolnierkiewicz
2016-07-08 15:24   ` Bartlomiej Zolnierkiewicz
2016-07-16  9:01   ` Robert Jarzmik
2016-07-16  9:01     ` Robert Jarzmik
2016-07-08 15:24 ` [RESEND PATCH] arm: lart_defconfig: " Bartlomiej Zolnierkiewicz
2016-07-08 15:24   ` Bartlomiej Zolnierkiewicz
2016-07-08 15:24 ` [RESEND PATCH] arm: lpda270_defconfig: " Bartlomiej Zolnierkiewicz
2016-07-08 15:24   ` Bartlomiej Zolnierkiewicz
2016-07-08 15:24 ` [PATCH v2] arm: mainstone_defconfig: " Bartlomiej Zolnierkiewicz
2016-07-08 15:24   ` Bartlomiej Zolnierkiewicz
2016-07-08 15:24   ` Bartlomiej Zolnierkiewicz
2016-07-08 15:24 ` [RESEND PATCH] arm: pxa255-idp_defconfig: " Bartlomiej Zolnierkiewicz
2016-07-08 15:24   ` Bartlomiej Zolnierkiewicz
2016-07-08 15:24 ` [RESEND PATCH] arm: shannon_defconfig: " Bartlomiej Zolnierkiewicz
2016-07-08 15:24   ` Bartlomiej Zolnierkiewicz
2016-07-08 15:24 ` [RESEND PATCH] arm: trizeps4_defconfig: " Bartlomiej Zolnierkiewicz
2016-07-08 15:24   ` Bartlomiej Zolnierkiewicz
2016-07-08 20:23 ` [RESEND PATCH] arm: assabet_defconfig: " Arnd Bergmann
2016-07-08 20:23   ` Arnd Bergmann
2016-07-08 20:23   ` Arnd Bergmann
2016-07-13 10:59   ` Bartlomiej Zolnierkiewicz
2016-07-13 10:59     ` Bartlomiej Zolnierkiewicz
2016-07-13 14:37     ` Arnd Bergmann
2016-07-13 14:37       ` Arnd Bergmann
2016-07-13 14:37       ` Arnd Bergmann
2016-07-13 17:45       ` Russell King - ARM Linux
2016-07-13 17:45         ` Russell King - ARM Linux
2016-07-14  9:59         ` Bartlomiej Zolnierkiewicz
2016-07-14  9:59           ` Bartlomiej Zolnierkiewicz
2016-07-15 15:15       ` Kevin Hilman
2016-07-15 15:15         ` Kevin Hilman
2016-07-15 15:15         ` Kevin Hilman
2016-07-18 14:45         ` Sekhar Nori
2016-07-18 14:45           ` Sekhar Nori
2016-07-18 14:45           ` Sekhar Nori
2016-12-12 12:45           ` Bartlomiej Zolnierkiewicz
2016-12-12 12:45             ` Bartlomiej Zolnierkiewicz
2016-12-12 12:45             ` Bartlomiej Zolnierkiewicz
2016-12-12 13:54             ` Sekhar Nori
2016-12-12 13:54               ` Sekhar Nori
2016-12-12 13:54               ` Sekhar Nori
2017-03-07 17:51               ` Bartlomiej Zolnierkiewicz
2017-03-07 17:51                 ` Bartlomiej Zolnierkiewicz
2017-03-07 17:51                 ` Bartlomiej Zolnierkiewicz
2017-03-08 15:00                 ` Sekhar Nori
2017-03-08 15:00                   ` Sekhar Nori
2017-03-08 15:00                   ` Sekhar Nori
2017-03-09  8:39                   ` Sekhar Nori
2017-03-09  8:39                     ` Sekhar Nori
2017-03-09  8:39                     ` Sekhar Nori
2017-03-09  9:25                     ` Sergei Shtylyov
2017-03-09  9:25                       ` Sergei Shtylyov
2017-03-09 12:20                       ` Sekhar Nori
2017-03-09 12:20                         ` Sekhar Nori
2017-03-09 12:20                         ` Sekhar Nori
2017-03-09 12:24                         ` Sergei Shtylyov
2017-03-09 12:24                           ` Sergei Shtylyov
2017-03-09 13:57                           ` Russell King - ARM Linux
2017-03-09 13:57                             ` Russell King - ARM Linux
2017-03-09 13:57                             ` Russell King - ARM Linux
     [not found]                             ` <CGME20170309144256epcas1p25b4c18f7ced857f71e2f8c53ce7b2345@epcas1p2.samsung.com>
2017-03-09 14:42                               ` Bartlomiej Zolnierkiewicz
2017-03-09 14:42                                 ` Bartlomiej Zolnierkiewicz
2017-03-09 14:42                                 ` Bartlomiej Zolnierkiewicz
2017-03-09 14:51                                 ` Russell King - ARM Linux
2017-03-09 14:51                                   ` Russell King - ARM Linux
     [not found]                                   ` <CGME20170309145745epcas5p331cf5418a586b8d435a508626cbf7af9@epcas5p3.samsung.com>
2017-03-09 14:57                                     ` Bartlomiej Zolnierkiewicz
2017-03-09 14:57                                       ` Bartlomiej Zolnierkiewicz
2017-03-09 15:08                                       ` Russell King - ARM Linux
2017-03-09 15:08                                         ` Russell King - ARM Linux
     [not found]                                         ` <CGME20170309154131epcas5p1f9c668855ee33c1634d4491d8664848b@epcas5p1.samsung.com>
2017-03-09 15:41                                           ` Bartlomiej Zolnierkiewicz
2017-03-09 15:41                                             ` Bartlomiej Zolnierkiewicz
2017-03-09 15:41                                             ` Bartlomiej Zolnierkiewicz
     [not found]                                 ` <CGME20170309145219epcas5p38b1af654dd0a4b04bd02a488051c065f@epcas5p3.samsung.com>
2017-03-09 14:52                                   ` Bartlomiej Zolnierkiewicz [this message]
2017-03-09 14:52                                     ` Bartlomiej Zolnierkiewicz
2017-03-09 16:22                           ` Sergei Shtylyov
2017-03-09 16:22                             ` Sergei Shtylyov
2017-03-09 16:22                             ` Sergei Shtylyov
     [not found]                           ` <CGME20170310171153epcas5p259bf9353fd1194dd131350fc59c3423a@epcas5p2.samsung.com>
2017-03-10 17:11                             ` Bartlomiej Zolnierkiewicz
2017-03-10 17:11                               ` Bartlomiej Zolnierkiewicz
     [not found]                       ` <CGME20170309122125epcas5p415b1f2266f68d5b999d2eb4ced94e9f3@epcas5p4.samsung.com>
2017-03-09 12:21                         ` Bartlomiej Zolnierkiewicz
2017-03-09 12:21                           ` Bartlomiej Zolnierkiewicz
     [not found]                     ` <CGME20170309114756epcas5p3761bce85d5a8e3a095cb3a876c484ea6@epcas5p3.samsung.com>
2017-03-09 11:47                       ` Bartlomiej Zolnierkiewicz
2017-03-09 11:47                         ` Bartlomiej Zolnierkiewicz
2017-03-09 11:57                         ` Sekhar Nori
2017-03-09 11:57                           ` Sekhar Nori
2017-03-09 11:57                           ` Sekhar Nori
     [not found]                           ` <CGME20170309121425epcas1p119ed8e5e27e3f7d8bfc71d0173cd301b@epcas1p1.samsung.com>
2017-03-09 12:14                             ` Bartlomiej Zolnierkiewicz
2017-03-09 12:14                               ` Bartlomiej Zolnierkiewicz
2016-10-26 17:01       ` Bartlomiej Zolnierkiewicz
2016-10-26 17:01         ` Bartlomiej Zolnierkiewicz
2016-10-31 15:46         ` Russell King - ARM Linux
2016-10-31 15:46           ` Russell King - ARM Linux
2016-10-31 18:14           ` Bartlomiej Zolnierkiewicz
2016-10-31 18:14             ` Bartlomiej Zolnierkiewicz
2016-10-31 18:14             ` Bartlomiej Zolnierkiewicz
2016-10-31 18:24             ` Bartlomiej Zolnierkiewicz
2016-10-31 18:24               ` Bartlomiej Zolnierkiewicz
2016-11-25 22:22               ` Arnd Bergmann
2016-11-25 22:22                 ` Arnd Bergmann

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=2925309.c9ir13Bff9@amdc3058 \
    --to=b.zolnierkie@samsung.com \
    --cc=arnd@arndb.de \
    --cc=dbaryshkov@gmail.com \
    --cc=khilman@baylibre.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=nsekhar@ti.com \
    --cc=olof@lixom.net \
    --cc=sergei.shtylyov@cogentembedded.com \
    /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.