linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: Linus Walleij <linus.walleij@linaro.org>
To: Corentin Labbe <clabbe.montjoie@gmail.com>
Cc: Hans Ulli Kroll <ulli.kroll@googlemail.com>,
	 Linux ARM <linux-arm-kernel@lists.infradead.org>,
	 linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: gemini: sl3516: Mainlining of NS 2502
Date: Thu, 6 May 2021 01:56:28 +0200	[thread overview]
Message-ID: <CACRpkdaGAiK57LE8vkEBjCGwb+HRWBzWS_C86xdNa8N51G+1PA@mail.gmail.com> (raw)
In-Reply-To: <YJLxTgVflotKs5Oe@Red>

Hi Corentin,

I will check the patches you posted too, sorry for being a bit busy
with some merge window and stuff.

On Wed, May 5, 2021 at 9:26 PM Corentin Labbe <clabbe.montjoie@gmail.com> wrote:

> It seems that USB is still a bit buggy, device are detected only if plugged before boot.

Yeah :/ I don't know that driver very well, only that others use it too
so there might be some people who can help. I haven't mainlined
that patch because there is something that seems wrong about it
but I'm not a USB guy.

> I hit a problem on the NS2502, sata drives does not work well:
(...)
> It seems a problem soon after driver probe (qc timeout and HPA error).
> Any idea ?
>
> The SATA works well on my other board (SSI1328)
> having one or two disk does not change the behavour.

Could be the SATA muxing, this thing in your device tree:

sata: sata@46000000 {
    cortina,gemini-ata-muxmode = <0>;
    cortina,gemini-enable-sata-bridge;
    status = "okay";
};

cortina,gemini-ata-muxmode should be 3 for two harddisks
I think.

If that is correct then check if DMA is broken like on SQ201,
see drivers/ata/pata_ftide010.c and here:

/* This device has broken DMA, only PIO works */
if (of_machine_is_compatible("itian,sq201")) {
    pi->mwdma_mask = 0;
    pi->udma_mask = 0;
}

This had to be explicitly disabled for SQ201 to work and
I guess it must be broken electronics design (too long
leads, interference...) so try to put the compatible for your
board in there and see if the drive starts working. You should
be able to check the source code of the vendor tree to
see if they also turned off DMA, if they did then that is
a certain sign it has the same bug so you should make a
patch for it. Maybe it should rather be some "disable-dma"
flag in the DT node, the above is a bit ugly but works.

Yours,
Linus Walleij

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2021-05-05 23:58 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-05 18:39 gemini: sl3516: Mainlining of NS 2502 Corentin Labbe
2021-04-05 20:36 ` Andrew Lunn
2021-04-06  9:06   ` Corentin Labbe
2021-04-06  8:15 ` Linus Walleij
2021-04-06 12:05   ` Corentin Labbe
2021-04-07  9:34     ` Linus Walleij
2021-05-05 19:26       ` Corentin Labbe
2021-05-05 23:56         ` Linus Walleij [this message]
2021-05-06  9:02           ` Daniel Palmer
2021-05-12 20:14           ` Corentin Labbe

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=CACRpkdaGAiK57LE8vkEBjCGwb+HRWBzWS_C86xdNa8N51G+1PA@mail.gmail.com \
    --to=linus.walleij@linaro.org \
    --cc=clabbe.montjoie@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ulli.kroll@googlemail.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).