LKML Archive on
help / color / mirror / Atom feed
From: "H. Nikolaus Schaller" <>
To: Ulf Hansson <>
Cc: Jerome Pouiller <>,
	Avri Altman <>,
	Shawn Lin <>,
	Linus Walleij <>,
	Bean Huo <>,,
	linux-kernel <>,
	Discussions about the Letux Kernel 
	<>,, Tony Lindgren <>,
	Linux-OMAP <>
Subject: Re: [RFC] mmc: core: transplant ti,wl1251 quirks from to be retired omap_hsmmc
Date: Wed, 27 Oct 2021 19:00:42 +0200	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

Hi Ulf,

> Am 26.10.2021 um 20:08 schrieb H. Nikolaus Schaller <>:
> Hi Uf,
>> As a matter of fact, the similar problem that you are looking to
>> address (applying card quirks based on DT compatibility strings), is
>> partly being taken care of in another series [1], being discussed
>> right now. I think the solution for the ti,wl1251 should be based upon
>> that too. Please have a look and see if you can play with that!?
> That is interesting.
> Yes, maybe it can be the basis. At least for finding the chip and driver.

I have done a first experiment.

It seems as if the series [1] does the opposite of what we need... It just
skips entries in struct mmc_fixup if the DT does *not* match.

This new match is not even tried in the wl1251 case since card->cis.vendor
and card->cis.device are not properly initialized when mmc_fixup_device() is called.
(in the upstream code the init_card function sets these and also sets MMC_QUIRK_NONSTD_SDIO
to early abort before sdio_read_cccr, sdio_read_common_cis, and mmc_fixup_device).

What I don't get from the code is how cis.vendor or cis.device can be
initialized from device tree for a specific device. As far as I see it can
only be checked for and some quirks can be set from a table if vendor and
device read from the CIS registers do match. 

Instead, we want to match DT and define some values for an otherwise unknown
device (i.e. we can't match by vendor or other methods) to help to initialize
the interface. So in mmc_fixup_device it is too late and we need something
running earlier, based purely on device tree information...

BR and thanks,

> [1]
> [RFC PATCH 0/2] mmc: allow to rely on the DT to apply quirks

  reply	other threads:[~2021-10-27 17:01 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-06 11:25 H. Nikolaus Schaller
2021-10-26 17:12 ` Ulf Hansson
2021-10-26 18:08   ` H. Nikolaus Schaller
2021-10-27 17:00     ` H. Nikolaus Schaller [this message]
2021-10-27 21:31       ` Ulf Hansson
2021-10-28  7:08         ` H. Nikolaus Schaller
2021-10-28  8:59           ` Jérôme Pouiller
2021-10-28  9:31             ` Ulf Hansson
2021-10-28  9:40             ` H. Nikolaus Schaller
2021-10-28  9:43               ` H. Nikolaus Schaller
2021-10-28  9:51                 ` Ulf Hansson
2021-10-28  9:55               ` Jérôme Pouiller
2021-10-28 10:07                 ` H. Nikolaus Schaller
2021-11-01  9:12                   ` H. Nikolaus Schaller

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:

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \ \ \ \ \ \ \ \ \ \ \ \ \ \ \
    --subject='Re: [RFC] mmc: core: transplant ti,wl1251 quirks from to be retired omap_hsmmc' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

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).