Commit 995cda62 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
Pull MMC updates from Ulf Hansson:
 "MMC core:
   - Convert drivers to use the ->remove_new() callback
   - Propagate the removable attribute for the card's device

  MMC host:
   - Convert drivers to use the ->remove_new() callback
   - atmel-mci: Convert to gpio descriptors and cleanup the code
   - davinci: Make SDIO irq truly optional
   - renesas_sdhi: Register irqs before registering controller
   - sdhci: Simplify the sdhci_pltfm_* interface a bit
   - sdhci-esdhc-imx: Improve support for the 1.8V errata
   - sdhci-of-at91: Add support for the microchip sam9x7 variant
   - sdhci-of-dwcmshc: Add support for runtime PM
   - sdhci-pci-o2micro: Add support for the new Bayhub GG8 variant
   - sdhci-sprd: Add support for SD high-speed mode tuning
   - uniphier-sd: Register irqs before registering controller"

* tag 'mmc-v6.6' of git://git.kernel.org/pub/scm/linux/kernel/git/ulfh/mmc: (108 commits)
  mmc: atmel-mci: Move card detect gpio polarity quirk to gpiolib
  mmc: atmel-mci: move atmel MCI header file
  mmc: atmel-mci: Convert to gpio descriptors
  mmc: sdhci-sprd: Add SD HS mode online tuning
  mmc: core: Add host specific tuning support for SD HS mode
  mmc: sdhci-of-dwcmshc: Add runtime PM operations
  mmc: sdhci-of-dwcmshc: Add error handling in dwcmshc_resume
  mmc: sdhci-esdhc-imx: improve ESDHC_FLAG_ERR010450
  mmc: sdhci-pltfm: Rename sdhci_pltfm_register()
  mmc: sdhci-pltfm: Remove sdhci_pltfm_unregister()
  mmc: sdhci-st: Use sdhci_pltfm_remove()
  mmc: sdhci-pxav2: Use sdhci_pltfm_remove()
  mmc: sdhci-of-sparx5: Use sdhci_pltfm_remove()
  mmc: sdhci-of-hlwd: Use sdhci_pltfm_remove()
  mmc: sdhci-of-esdhc: Use sdhci_pltfm_remove()
  mmc: sdhci-of-at91: Use sdhci_pltfm_remove()
  mmc: sdhci-of-arasan: Use sdhci_pltfm_remove()
  mmc: sdhci-iproc: Use sdhci_pltfm_remove()
  mmc: sdhci_f_sdh30: Use sdhci_pltfm_remove()
  mmc: sdhci-dove: Use sdhci_pltfm_remove()
  ...
parents 3b6bf5b1 98ac9e4f
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -160,6 +160,12 @@ properties:
    description:
      The MIO bank number in which the command and data lines are configured.

  iommus:
    maxItems: 1

  power-domains:
    maxItems: 1

dependencies:
  '#clock-cells': [ clock-output-names ]

+1 −1
Original line number Diff line number Diff line
@@ -269,7 +269,7 @@ properties:
  post-power-on-delay-ms:
    description:
      It was invented for MMC pwrseq-simple which could be referred to
      mmc-pwrseq-simple.txt. But now it\'s reused as a tunable delay
      mmc-pwrseq-simple.yaml. But now it\'s reused as a tunable delay
      waiting for I/O signalling and card power supply to be stable,
      regardless of whether pwrseq-simple is used. Default to 10ms if
      no available.
+0 −10
Original line number Diff line number Diff line
@@ -91,16 +91,6 @@ properties:
      should switch dat1 pin to GPIO mode.
    maxItems: 1

  assigned-clocks:
    description:
      PLL of the source clock.
    maxItems: 1

  assigned-clock-parents:
    description:
      parent of source clock, used for HS400 mode to get 400Mhz source clock.
    maxItems: 1

  hs400-ds-delay:
    $ref: /schemas/types.yaml#/definitions/uint32
    description:
+3 −1
Original line number Diff line number Diff line
@@ -5,11 +5,13 @@ Documentation/devicetree/bindings/mmc/mmc.txt and the properties used by the
sdhci-of-at91 driver.

Required properties:
- compatible:		Must be "atmel,sama5d2-sdhci" or "microchip,sam9x60-sdhci".
- compatible:		Must be "atmel,sama5d2-sdhci" or "microchip,sam9x60-sdhci"
			or "microchip,sam9x7-sdhci", "microchip,sam9x60-sdhci".
- clocks:		Phandlers to the clocks.
- clock-names:		Must be "hclock", "multclk", "baseclk" for
			"atmel,sama5d2-sdhci".
			Must be "hclock", "multclk" for "microchip,sam9x60-sdhci".
			Must be "hclock", "multclk" for "microchip,sam9x7-sdhci".

Optional properties:
- assigned-clocks:	The same with "multclk".
+18 −2
Original line number Diff line number Diff line
@@ -209,6 +209,8 @@ static void of_gpio_set_polarity_by_property(const struct device_node *np,
					     const char *propname,
					     enum of_gpio_flags *flags)
{
	const struct device_node *np_compat = np;
	const struct device_node *np_propname = np;
	static const struct {
		const char *compatible;
		const char *gpio_propname;
@@ -252,15 +254,29 @@ static void of_gpio_set_polarity_by_property(const struct device_node *np,
#if IS_ENABLED(CONFIG_REGULATOR_GPIO)
		{ "regulator-gpio",    "enable-gpio",  "enable-active-high" },
		{ "regulator-gpio",    "enable-gpios", "enable-active-high" },
#endif
#if IS_ENABLED(CONFIG_MMC_ATMELMCI)
		{ "atmel,hsmci",       "cd-gpios",     "cd-inverted" },
#endif
	};
	unsigned int i;
	bool active_high;

#if IS_ENABLED(CONFIG_MMC_ATMELMCI)
	/*
	 * The Atmel HSMCI has compatible property in the parent node and
	 * gpio property in a child node
	 */
	if (of_device_is_compatible(np->parent, "atmel,hsmci")) {
		np_compat = np->parent;
		np_propname = np;
	}
#endif

	for (i = 0; i < ARRAY_SIZE(gpios); i++) {
		if (of_device_is_compatible(np, gpios[i].compatible) &&
		if (of_device_is_compatible(np_compat, gpios[i].compatible) &&
		    !strcmp(propname, gpios[i].gpio_propname)) {
			active_high = of_property_read_bool(np,
			active_high = of_property_read_bool(np_propname,
						gpios[i].polarity_propname);
			of_gpio_quirk_polarity(np, active_high, flags);
			break;
Loading