Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3 2/3] musb: sunxi: Remove custom babble handling
From: Bin Liu @ 2016-11-15 21:14 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20160923134058.26828-2-hdegoede@redhat.com>

On Fri, Sep 23, 2016 at 04:40:57PM +0300, Hans de Goede wrote:
> The musb core already handles babble interrupts, so the sunxi glue
> having its own custom handling is redundant.
> 
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>

Applied. Thanks.
-Bin.

> ---
> Changes in v2:
> -This is a new patch in v2 of this patch series
> Changes in v3:
> -Improve commit msg
> ---
>  drivers/usb/musb/sunxi.c | 10 ----------
>  1 file changed, 10 deletions(-)
> 
> diff --git a/drivers/usb/musb/sunxi.c b/drivers/usb/musb/sunxi.c
> index 1408245..82eba92 100644
> --- a/drivers/usb/musb/sunxi.c
> +++ b/drivers/usb/musb/sunxi.c
> @@ -186,16 +186,6 @@ static irqreturn_t sunxi_musb_interrupt(int irq, void *__hci)
>  	if (musb->int_usb)
>  		writeb(musb->int_usb, musb->mregs + SUNXI_MUSB_INTRUSB);
>  
> -	/*
> -	 * sunxi musb often signals babble on low / full speed device
> -	 * disconnect, without ever raising MUSB_INTR_DISCONNECT, since
> -	 * normally babble never happens treat it as disconnect.
> -	 */
> -	if ((musb->int_usb & MUSB_INTR_BABBLE) && is_host_active(musb)) {
> -		musb->int_usb &= ~MUSB_INTR_BABBLE;
> -		musb->int_usb |= MUSB_INTR_DISCONNECT;
> -	}
> -
>  	if ((musb->int_usb & MUSB_INTR_RESET) && !is_host_active(musb)) {
>  		/* ep0 FADDR must be 0 when (re)entering peripheral mode */
>  		musb_ep_select(musb->mregs, 0);
> -- 
> 2.9.3
> 

^ permalink raw reply

* [PATCH v3 3/3] musb: sunxi: Force session end on babble errors in host-mode
From: Bin Liu @ 2016-11-15 21:14 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20160923134058.26828-3-hdegoede@redhat.com>

On Fri, Sep 23, 2016 at 04:40:58PM +0300, Hans de Goede wrote:
> The sunxi musb has a bug where sometimes it will generate a babble
> error on device disconnect instead of a disconnect irq. When this
> happens the musb-controller switches from host mode to device mode
> (it clears MUSB_DEVCTL_SESSION and sets MUSB_DEVCTL_BDEVICE) and
> gets stuck in this state.
> 
> Clearing this requires reporting Vbus low for 200 or more ms, but
> on some devices Vbus is simply always high (host-only mode, no Vbus
> control).
> 
> This commit adds a sunxi_musb_recover() callback which makes
> sunxi_musb_work call phy_set_mode with the current mode, which
> will force end the current session.
> 
> This fixes the musb controller getting stuck in this state on systems
> without Vbus control; and also fixes the need to unplug the usb-b ->
> usb-a cable to get out of this state on systems with Vbus control.
> 
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>

Applied. Thanks.
-Bin.

> ---
> Changes in v2:
> -Use musb_platform_recover callback instead of using DYI code in the
>  interrupt handler
> -Call phy_set_mode with the current mode instead of adding a new custom
>  sunxi phy callback
> ---
>  drivers/usb/musb/sunxi.c | 15 +++++++++++++++
>  1 file changed, 15 insertions(+)
> 
> diff --git a/drivers/usb/musb/sunxi.c b/drivers/usb/musb/sunxi.c
> index 82eba92..d0be0ea 100644
> --- a/drivers/usb/musb/sunxi.c
> +++ b/drivers/usb/musb/sunxi.c
> @@ -380,6 +380,20 @@ static int sunxi_musb_set_mode(struct musb *musb, u8 mode)
>  	return 0;
>  }
>  
> +static int sunxi_musb_recover(struct musb *musb)
> +{
> +	struct sunxi_glue *glue = dev_get_drvdata(musb->controller->parent);
> +
> +	/*
> +	 * Schedule a phy_set_mode with the current glue->phy_mode value,
> +	 * this will force end the current session.
> +	 */
> +	set_bit(SUNXI_MUSB_FL_PHY_MODE_PEND, &glue->flags);
> +	schedule_work(&glue->work);
> +
> +	return 0;
> +}
> +
>  /*
>   * sunxi musb register layout
>   * 0x00 - 0x17	fifo regs, 1 long per fifo
> @@ -608,6 +622,7 @@ static const struct musb_platform_ops sunxi_musb_ops = {
>  	.dma_init	= sunxi_musb_dma_controller_create,
>  	.dma_exit	= sunxi_musb_dma_controller_destroy,
>  	.set_mode	= sunxi_musb_set_mode,
> +	.recover	= sunxi_musb_recover,
>  	.set_vbus	= sunxi_musb_set_vbus,
>  	.pre_root_reset_end = sunxi_musb_pre_root_reset_end,
>  	.post_root_reset_end = sunxi_musb_post_root_reset_end,
> -- 
> 2.9.3
> 

^ permalink raw reply

* Default atomic_pool_size value & changing it
From: Rafał Miłecki @ 2016-11-15 21:15 UTC (permalink / raw)
  To: linux-arm-kernel

Hi,

I've hit problem with allocating enough coherent DMA memory. Obviously
there is a limit of this memory as pointed by:
[ 0.283667] DMA: preallocated 256 KiB pool for atomic coherent allocations

In my case I was experimenting with a coherent memory used for DMA
descriptors. They are some small structs addressing SKBs and
controlling them:
struct bgmac_dma_desc {
        __le32 ctl0;
        __le32 ctl1;
        __le32 addr_low;
        __le32 addr_high;
} __packed;
Having 5-6 rings 512 entries each requires 48 KiB. There are devices
with 3 Ethernet bgmac devices and 2 wireless devices, 48 KiB * 5 gets
me dangerously close to the limit. I don't see this problem with
upstream default drivers yet, but it may become an issue at some
point.

Raspberry Pi was dealing a similar problem:
https://github.com/raspberrypi/linux/issues/170

Does it make any sense to increase default atomic_pool_size value?

I see there is init_dma_coherent_pool_size function but it seems to be
dead code (can we drop it?).
I can change that value using coherent_pool param, but is that sane to
put it in bootargs of upstream DTS files?
Any advise on this?

-- 
Rafa?

^ permalink raw reply

* [GIT PULL] sun4i-drm fixes for 4.9
From: Maxime Ripard @ 2016-11-15 21:18 UTC (permalink / raw)
  To: linux-arm-kernel

Hi David,

Please pull the following fixes for the 4.9 cycle.

Thanks!
Maxime

The following changes since commit 1001354ca34179f3db924eb66672442a173147dc:

  Linux 4.9-rc1 (2016-10-15 12:17:50 -0700)

are available in the git repository at:

  https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux.git tags/sunxi-drm-fixes-for-4.9

for you to fetch changes up to 4db069a2bf990e278ea57ff615dcaa89b85376bd:

  drm/sun4i: Propagate error to the caller (2016-11-07 16:09:35 +0100)

----------------------------------------------------------------
sun4i-drm fixes for 4.9

A few patches to fix our error handling and our panel / bridge calls.

----------------------------------------------------------------
Christophe JAILLET (2):
      drm/sun4i: Fix error handling
      drm/sun4i: Propagate error to the caller

Jonathan Liu (1):
      drm/sun4i: rgb: Enable panel after controller

Maxime Ripard (1):
      drm/sun4i: rgb: Remove the bridge enable/disable functions

 drivers/gpu/drm/sun4i/sun4i_drv.c |  4 ++--
 drivers/gpu/drm/sun4i/sun4i_rgb.c | 20 ++++++++------------
 2 files changed, 10 insertions(+), 14 deletions(-)

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20161115/d1cebdf5/attachment.sig>

^ permalink raw reply

* [PATCH v4 4/4] ARM: dts: da850: Add the usb otg device nodeg
From: Bin Liu @ 2016-11-15 21:19 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <0c94c5e0-9d2c-fff5-1213-2fb2adb20ab0@ti.com>

On Tue, Nov 15, 2016 at 04:16:02PM +0530, Sekhar Nori wrote:
> On Thursday 03 November 2016 09:29 PM, Alexandre Bailon wrote:
> > This adds the device tree node for the usb otg
> > controller present in the da850 family of SoC's.
> > This also enables the otg usb controller for the lcdk board.
> > 
> > Signed-off-by: Alexandre Bailon <abailon@baylibre.com>
> > ---
> >  arch/arm/boot/dts/da850-lcdk.dts |  8 ++++++++
> >  arch/arm/boot/dts/da850.dtsi     | 15 +++++++++++++++
> >  2 files changed, 23 insertions(+)
> > 
> > diff --git a/arch/arm/boot/dts/da850-lcdk.dts b/arch/arm/boot/dts/da850-lcdk.dts
> > index 7b8ab21..9f5040c 100644
> > --- a/arch/arm/boot/dts/da850-lcdk.dts
> > +++ b/arch/arm/boot/dts/da850-lcdk.dts
> > @@ -158,6 +158,14 @@
> >  	rx-num-evt = <32>;
> >  };
> >  
> > +&usb_phy {
> > +	status = "okay";
> > +	};
> 
> As mentioned by David already, this node needs to be removed. Please
> rebase this on top of latest linux-davinci/master when ready for merging
> (driver changes accepted).

Dropped this patch due to this comment.

Regards,
-Bin.

> 
> > +
> > +&usb0 {
> > +	status = "okay";
> > +};
> > +
> >  &aemif {
> >  	pinctrl-names = "default";
> >  	pinctrl-0 = <&nand_pins>;
> > diff --git a/arch/arm/boot/dts/da850.dtsi b/arch/arm/boot/dts/da850.dtsi
> > index f79e1b9..322a31a 100644
> > --- a/arch/arm/boot/dts/da850.dtsi
> > +++ b/arch/arm/boot/dts/da850.dtsi
> > @@ -372,6 +372,21 @@
> >  					>;
> >  			status = "disabled";
> >  		};
> > +		usb_phy: usb-phy {
> > +			compatible = "ti,da830-usb-phy";
> > +			#phy-cells = <1>;
> > +			status = "disabled";
> > +		};
> > +		usb0: usb at 200000 {
> > +			compatible = "ti,da830-musb";
> > +			reg = <0x200000 0x10000>;
> > +			interrupts = <58>;
> > +			interrupt-names = "mc";
> > +			dr_mode = "otg";
> > +			phys = <&usb_phy 0>;
> > +			phy-names = "usb-phy";
> > +			status = "disabled";
> > +		};
> 
> Can you separate out the soc specific changes from board changes? Please
> place the usb0 node above the mdio node. I am trying to get to a rough
> ordering based on reg property.
> 
> Thanks,
> Sekhar
> 

^ permalink raw reply

* [GIT PULL] sun4i-drm changes for 4.10
From: Maxime Ripard @ 2016-11-15 21:21 UTC (permalink / raw)
  To: linux-arm-kernel

Hi David,

Please pull the following changes for the next merge window.

Thanks!
Maxime

The following changes since commit 1001354ca34179f3db924eb66672442a173147dc:

  Linux 4.9-rc1 (2016-10-15 12:17:50 -0700)

are available in the git repository at:

  https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux.git tags/sunxi-drm-for-4.10

for you to fetch changes up to 47d7fbb32c57c8d1722a3e9bd21e501e80fd0741:

  drm/sun4i: Add a few formats (2016-11-02 19:37:37 +0100)

----------------------------------------------------------------
sun4i-drm changes for 4.10

Support for the Allwinner A31 SoC display engine using the sun4i-drm
driver.

----------------------------------------------------------------
Chen-Yu Tsai (4):
      drm/sun4i: sun6i-drc: Support DRC on A31 and A31s
      drm/sun4i: tcon: Move SoC specific quirks to a DT matched data structure
      drm/sun4i: Add compatible string for A31/A31s TCON (timing controller)
      drm/sun4i: Add compatible strings for A31/A31s display pipelines

Maxime Ripard (1):
      drm/sun4i: Add a few formats

 .../bindings/display/sunxi/sun4i-drm.txt           | 10 ++++-
 drivers/gpu/drm/sun4i/sun4i_backend.c              | 21 +++++++++++
 drivers/gpu/drm/sun4i/sun4i_drv.c                  |  5 +++
 drivers/gpu/drm/sun4i/sun4i_layer.c                |  6 +++
 drivers/gpu/drm/sun4i/sun4i_tcon.c                 | 43 ++++++++++++++--------
 drivers/gpu/drm/sun4i/sun4i_tcon.h                 | 11 ++++--
 drivers/gpu/drm/sun4i/sun6i_drc.c                  |  2 +
 7 files changed, 78 insertions(+), 20 deletions(-)

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20161115/70c09aa6/attachment.sig>

^ permalink raw reply

* [GIT PULL 1/5] non-urgent omap fixes for v4.10
From: Tony Lindgren @ 2016-11-15 21:22 UTC (permalink / raw)
  To: linux-arm-kernel

The following changes since commit 1001354ca34179f3db924eb66672442a173147dc:

  Linux 4.9-rc1 (2016-10-15 12:17:50 -0700)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap tags/omap-for-v4.10/fixes-not-urgent-signed

for you to fetch changes up to 5c02b01d234f8410010c952069d3fb9ec5d9124a:

  ARM: OMAP2+: pm-debug: Use seq_putc() in two functions (2016-11-09 15:33:33 -0700)

----------------------------------------------------------------
Non-urgent fixes for omaps for v4.10 merge window:

- Fix mismatched interrupt numbers for tps65217, these are not yet
  used

- Remove unused omapdss_early_init_of()

- Use seq_putc() for pm-debug.c

----------------------------------------------------------------
Laurent Pinchart (1):
      ARM: OMAP2+: Remove the omapdss_early_init_of() function

Markus Elfring (1):
      ARM: OMAP2+: pm-debug: Use seq_putc() in two functions

Milo Kim (1):
      mfd: tps65217: Fix mismatched interrupt number

 arch/arm/mach-omap2/board-generic.c |  2 --
 arch/arm/mach-omap2/common.h        |  1 -
 arch/arm/mach-omap2/display.c       |  5 -----
 arch/arm/mach-omap2/pm-debug.c      |  5 ++---
 include/linux/mfd/tps65217.h        | 11 +++++------
 5 files changed, 7 insertions(+), 17 deletions(-)

^ permalink raw reply

* [GIT PULL 2/5] omap soc changes for v4.10
From: Tony Lindgren @ 2016-11-15 21:22 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <pull-1479236877-351747>

The following changes since commit 1001354ca34179f3db924eb66672442a173147dc:

  Linux 4.9-rc1 (2016-10-15 12:17:50 -0700)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap tags/omap-for-v4.10/soc-signed

for you to fetch changes up to 2bb6375f5c03cc5bf510402b646c1a23046b3f12:

  Merge branch 'omap-for-v4.10/cpuidle-v2' into omap-for-v4.10/soc (2016-11-14 15:58:18 -0800)

----------------------------------------------------------------
SoC changes for omaps for v4.10 merge window:

- Add hwmod interconnect target wrapper module data for crypto
  accelerators for am3xxx, am43xx and dra7

- Add support for dra71x family of SoCs

- PM fixes for omap4/5 needed for omap5 cpuidle

----------------------------------------------------------------
Joel Fernandes (4):
      ARM: DRA7: hwmod: Add data for DES IP
      ARM: DRA7: hwmod: Add data for AES IP
      ARM: DRA7: hwmod: Add data for RNG IP
      ARM: OMAP: DRA7xx: Make L4SEC clock domain SWSUP only

Lokesh Vutla (4):
      ARM: DRA7: hwmod: Add data for SHA IP
      ARM: AM43xx: hwmod: Add data for DES
      ARM: AMx3xx: hwmod: Add data for RNG
      ARM: OMAP2+: board-generic: add support for DRA71x family

Nishanth Menon (1):
      ARM: DRA7: hwmod: Do not register RTC on DRA71

Santosh Shilimkar (1):
      ARM: OMAP5: Add basic cpuidle MPU CSWR support

Tony Lindgren (4):
      ARM: OMAP5: Fix build for PM code
      ARM: OMAP5: Fix mpuss_early_init
      ARM: OMAP4+: Fix bad fallthrough for cpuidle
      Merge branch 'omap-for-v4.10/cpuidle-v2' into omap-for-v4.10/soc

 .../devicetree/bindings/arm/omap/omap.txt          |   6 +
 arch/arm/mach-omap2/Makefile                       |   2 +-
 arch/arm/mach-omap2/board-generic.c                |   1 +
 arch/arm/mach-omap2/clockdomains7xx_data.c         |   2 +-
 arch/arm/mach-omap2/common.h                       |  38 ++++-
 arch/arm/mach-omap2/cpuidle44xx.c                  |  80 ++++++++-
 arch/arm/mach-omap2/io.c                           |   3 +-
 arch/arm/mach-omap2/omap-mpuss-lowpower.c          |  37 +++--
 arch/arm/mach-omap2/omap4-sar-layout.h             |   2 +
 .../mach-omap2/omap_hwmod_33xx_43xx_common_data.h  |   2 +
 .../omap_hwmod_33xx_43xx_interconnect_data.c       |   8 +
 .../mach-omap2/omap_hwmod_33xx_43xx_ipblock_data.c |  29 ++++
 arch/arm/mach-omap2/omap_hwmod_33xx_data.c         |  35 ----
 arch/arm/mach-omap2/omap_hwmod_43xx_data.c         |  34 ++++
 arch/arm/mach-omap2/omap_hwmod_7xx_data.c          | 182 ++++++++++++++++++++-
 arch/arm/mach-omap2/pm44xx.c                       |   2 +-
 arch/arm/mach-omap2/prcm43xx.h                     |   2 +
 17 files changed, 405 insertions(+), 60 deletions(-)

^ permalink raw reply

* [GIT PULL 3/5] omap device tree changes for v4.10
From: Tony Lindgren @ 2016-11-15 21:22 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <pull-1479236877-351747>

The following changes since commit 1001354ca34179f3db924eb66672442a173147dc:

  Linux 4.9-rc1 (2016-10-15 12:17:50 -0700)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap tags/omap-for-v4.10/dt-signed

for you to fetch changes up to 7e2f8c0ae670327cbe0348ad2f3df7d9a55a8e5d:

  ARM: dts: Add minimal support for motorola droid 4 xt894 (2016-11-15 10:28:49 -0800)

----------------------------------------------------------------
Device tree changes for omaps for v4.10 merge window:

- A series of patches to configure tps65217 PMIC interrupts for
  power button, charger and usb and use them on am335x

- Configure EEPROM, LEDs and USR1 button for omap5 boards

- Add tscadc DMA properites for am33xx and am4372

- Configure baltos-ir5221 both musb channels to host mode

- Configure internal and external RTC clocks for am335x boards

- Don't reset gpio3 block on baltos

- Remove pinmux for dra72-evm for erratum i869, fix the regulators
  and seprate out tps65917 support

- Add dra718-evm support

- Add minimal droid 4 xt894 support

----------------------------------------------------------------
H. Nikolaus Schaller (3):
      ARM: dts: omap5 uevm: add EEPROM
      ARM: dts: omap5 uevm: add LEDs
      ARM: dts: omap5 uevm: add USR1 button

Keerthy (3):
      ARM: dts: AM335X-bone-common: Add the internal and external clock nodes for rtc
      ARM: dts: AM335X-evm: Add the internal and external clock nodes for rtc
      ARM: dts: AM335X-evmsk: Add the internal and external clock nodes for rtc

Lokesh Vutla (3):
      ARM: dts: dra72-evm: Remove pinmux configurations for erratum i869
      ARM: dts: dra72-evm: Fix modelling of regulators
      ARM: dts: dra72: Add separate dtsi for tps65917

Milo Kim (7):
      ARM: dts: tps65217: Specify the interrupt controller
      ARM: dts: tps65217: Add the charger device
      ARM: dts: tps65217: Add the power button device
      ARM: dts: am335x: Support the PMIC interrupt
      dt-bindings: mfd: Provide human readable defines for TPS65217 interrupts
      ARM: dts: am335x: Add the charger interrupt
      ARM: dts: am335x: Add the power button interrupt

Mugunthan V N (2):
      ARM: dts: am33xx: add DMA properties for tscadc
      ARM: dts: am4372: add DMA properties for tscadc

Nishanth Menon (1):
      ARM: dts: Add support for dra718-evm

Tony Lindgren (1):
      ARM: dts: Add minimal support for motorola droid 4 xt894

Yegor Yefremov (2):
      ARM: dts: am335x-baltos-ir5221: use both musb channels in host mode
      ARM: dts: am335x-baltos: don't reset gpio3 block

 arch/arm/boot/dts/Makefile                 |   4 +-
 arch/arm/boot/dts/am335x-baltos-ir5221.dts |   2 +-
 arch/arm/boot/dts/am335x-baltos.dtsi       |   4 +
 arch/arm/boot/dts/am335x-bone-common.dtsi  |  22 ++
 arch/arm/boot/dts/am335x-evm.dts           |   5 +
 arch/arm/boot/dts/am335x-evmsk.dts         |   5 +
 arch/arm/boot/dts/am33xx.dtsi              |   4 +
 arch/arm/boot/dts/am4372.dtsi              |   2 +
 arch/arm/boot/dts/dra71-evm.dts            | 230 +++++++++++++++++++
 arch/arm/boot/dts/dra72-evm-common.dtsi    | 348 ++++-------------------------
 arch/arm/boot/dts/dra72-evm-revc.dts       |  21 +-
 arch/arm/boot/dts/dra72-evm-tps65917.dtsi  | 134 +++++++++++
 arch/arm/boot/dts/dra72-evm.dts            |  14 +-
 arch/arm/boot/dts/omap4-droid4-xt894.dts   | 188 ++++++++++++++++
 arch/arm/boot/dts/omap5-uevm.dts           |  92 ++++++++
 arch/arm/boot/dts/tps65217.dtsi            |  12 +
 include/dt-bindings/mfd/tps65217.h         |  26 +++
 17 files changed, 787 insertions(+), 326 deletions(-)
 create mode 100644 arch/arm/boot/dts/dra71-evm.dts
 create mode 100644 arch/arm/boot/dts/dra72-evm-tps65917.dtsi
 create mode 100644 arch/arm/boot/dts/omap4-droid4-xt894.dts
 create mode 100644 include/dt-bindings/mfd/tps65217.h

^ permalink raw reply

* [GIT PULL 4/5] drop unused omap platform_data for v4.10
From: Tony Lindgren @ 2016-11-15 21:22 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <pull-1479236877-351747>

The following changes since commit 1001354ca34179f3db924eb66672442a173147dc:

  Linux 4.9-rc1 (2016-10-15 12:17:50 -0700)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap tags/omap-for-v4.10/legacy-signed

for you to fetch changes up to 19944b3a4a30163656b26e9d2ca659657113ac3e:

  ARM: OMAP2+: Drop legacy sdram timings (2016-11-10 16:07:32 -0700)

----------------------------------------------------------------
Legacy platform_data removal for omaps for v4.10 merge window.
We've dropped the last legacy boot board-*.c files for mach-omap2
for v4.9 so now we can start removing the unused platform_data.

All of the below has been unused since v4.9 merge window:

- Drop legacy pmic init code

- Apply seq_puts() fixes for legacy mux code, then drop it

- Drop legacy serial init

- Drop legacy i2c init

- Drop legacy PM init

- Drop legacy twl4030 platform init

- Drop legacy USB host init

- Drop legacy muxing for tusb6010, n8x0 is still using it's
  platform init via pdata-quirks.c

- Drop legacy musb init

- Drop hwmod related legacy mux code

- Drop legacy hwmod data for omap3

- Drop legacy smsc911x and smc91x init

- Drop legacy board flash init

- Drop legacy ads7846 init

- Drop legacy sdram timings

----------------------------------------------------------------
Javier Martinez Canillas (2):
      ARM: OMAP2+: Remove legacy smsc911x and smc91x GPMC support
      ARM: OMAP2+: Remove legacy board-flash.c

Markus Elfring (2):
      ARM: OMAP2+: mux: Replace three seq_printf() calls by seq_puts()
      ARM: OMAP2+: mux: Use seq_putc() in omap_mux_dbg_signal_show()

Nicolae Rosia (5):
      ARM: OMAP4: kill omap4_pmic_init and omap4_pmic_get_config
      ARM: OMAP3: kill omap3_pmic_get_config and twl_{get,set}_voltage
      ARM: OMAP3: kill omap3_pmic_init
      ARM: OMAP2: kill omap2_pmic_init
      ARM: OMAP: kill omap_pmic_init

Tony Lindgren (12):
      ARM: OMAP2+: Remove legacy serial.c
      ARM: OMAP2+: Remove legacy i2c.c platform init code
      ARM: OMAP2+: Remove legacy PM init
      ARM: OMAP2+: Remove legacy twl4030 platform init code
      ARM: OMAP2+: Remove legacy usb-host.c platform init code
      ARM: OMAP2+: Remove legacy muxing for usb-tusb6010.c
      ARM: OMAP2+: Remove legacy usb-musb.c platform init code
      ARM: OMAP2+: Remove legacy hwmod mux code
      ARM: OMAP2+: Remove legacy mux code
      ARM: OMAP2+: Remove legacy data from hwmod for omap3
      ARM: OMAP2+: Drop legacy ads7846 init
      ARM: OMAP2+: Drop legacy sdram timings

 arch/arm/mach-omap1/Kconfig                        |   26 +
 arch/arm/mach-omap1/i2c.c                          |   83 +
 arch/arm/mach-omap2/Makefile                       |   16 +-
 arch/arm/mach-omap2/board-flash.c                  |  242 ---
 arch/arm/mach-omap2/board-flash.h                  |   56 -
 arch/arm/mach-omap2/common-board-devices.c         |  102 -
 arch/arm/mach-omap2/common-board-devices.h         |    8 -
 arch/arm/mach-omap2/common.h                       |    9 -
 arch/arm/mach-omap2/devices.c                      |    1 -
 arch/arm/mach-omap2/dss-common.c                   |   37 -
 arch/arm/mach-omap2/dss-common.h                   |   13 -
 arch/arm/mach-omap2/gpmc-smsc911x.c                |  100 -
 arch/arm/mach-omap2/gpmc-smsc911x.h                |   35 -
 arch/arm/mach-omap2/hsmmc.c                        |   88 -
 arch/arm/mach-omap2/i2c.c                          |   97 -
 arch/arm/mach-omap2/io.c                           |    1 -
 arch/arm/mach-omap2/msdi.c                         |    1 -
 arch/arm/mach-omap2/mux.c                          | 1153 -----------
 arch/arm/mach-omap2/mux.h                          |  352 ----
 arch/arm/mach-omap2/mux34xx.c                      | 2061 --------------------
 arch/arm/mach-omap2/mux34xx.h                      |  402 ----
 arch/arm/mach-omap2/omap_hwmod.c                   |  107 +-
 .../omap_hwmod_2xxx_3xxx_interconnect_data.c       |  149 +-
 .../mach-omap2/omap_hwmod_2xxx_3xxx_ipblock_data.c |  201 +-
 .../mach-omap2/omap_hwmod_2xxx_interconnect_data.c |    4 -
 arch/arm/mach-omap2/omap_hwmod_2xxx_ipblock_data.c |    1 -
 arch/arm/mach-omap2/omap_hwmod_3xxx_data.c         |  787 +-------
 arch/arm/mach-omap2/omap_hwmod_common_data.h       |   15 -
 arch/arm/mach-omap2/pdata-quirks.c                 |    1 -
 arch/arm/mach-omap2/pm.c                           |   66 +-
 arch/arm/mach-omap2/sdram-hynix-h8mbx00u0mer-0em.h |   51 -
 arch/arm/mach-omap2/sdram-micron-mt46h32m32lf-6.h  |   55 -
 arch/arm/mach-omap2/sdram-nokia.c                  |  299 ---
 arch/arm/mach-omap2/sdram-nokia.h                  |   12 -
 arch/arm/mach-omap2/sdram-numonyx-m65kxxxxam.h     |   51 -
 .../mach-omap2/sdram-qimonda-hyb18m512160af-6.h    |   54 -
 arch/arm/mach-omap2/serial.c                       |  332 ----
 arch/arm/mach-omap2/twl-common.c                   |  564 ------
 arch/arm/mach-omap2/twl-common.h                   |   66 -
 arch/arm/mach-omap2/usb-host.c                     |  496 -----
 arch/arm/mach-omap2/usb-musb.c                     |  106 -
 arch/arm/mach-omap2/usb-tusb6010.c                 |   21 -
 arch/arm/plat-omap/Kconfig                         |   26 -
 arch/arm/plat-omap/Makefile                        |    3 -
 arch/arm/plat-omap/i2c.c                           |  116 --
 45 files changed, 160 insertions(+), 8306 deletions(-)
 delete mode 100644 arch/arm/mach-omap2/board-flash.c
 delete mode 100644 arch/arm/mach-omap2/board-flash.h
 delete mode 100644 arch/arm/mach-omap2/common-board-devices.c
 delete mode 100644 arch/arm/mach-omap2/dss-common.c
 delete mode 100644 arch/arm/mach-omap2/dss-common.h
 delete mode 100644 arch/arm/mach-omap2/gpmc-smsc911x.c
 delete mode 100644 arch/arm/mach-omap2/gpmc-smsc911x.h
 delete mode 100644 arch/arm/mach-omap2/mux.c
 delete mode 100644 arch/arm/mach-omap2/mux.h
 delete mode 100644 arch/arm/mach-omap2/mux34xx.c
 delete mode 100644 arch/arm/mach-omap2/mux34xx.h
 delete mode 100644 arch/arm/mach-omap2/sdram-hynix-h8mbx00u0mer-0em.h
 delete mode 100644 arch/arm/mach-omap2/sdram-micron-mt46h32m32lf-6.h
 delete mode 100644 arch/arm/mach-omap2/sdram-nokia.c
 delete mode 100644 arch/arm/mach-omap2/sdram-nokia.h
 delete mode 100644 arch/arm/mach-omap2/sdram-numonyx-m65kxxxxam.h
 delete mode 100644 arch/arm/mach-omap2/sdram-qimonda-hyb18m512160af-6.h
 delete mode 100644 arch/arm/mach-omap2/serial.c
 delete mode 100644 arch/arm/mach-omap2/twl-common.c
 delete mode 100644 arch/arm/mach-omap2/twl-common.h
 delete mode 100644 arch/arm/mach-omap2/usb-host.c
 delete mode 100644 arch/arm/mach-omap2/usb-musb.c
 delete mode 100644 arch/arm/plat-omap/i2c.c

^ permalink raw reply

* [GIT PULL 5/5] omap defconfig changes for v4.10
From: Tony Lindgren @ 2016-11-15 21:22 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <pull-1479236877-351747>

The following changes since commit 1001354ca34179f3db924eb66672442a173147dc:

  Linux 4.9-rc1 (2016-10-15 12:17:50 -0700)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap tags/omap-for-v4.10/defconfig-signed

for you to fetch changes up to 9c106e4efab2ec96daebb7bdd0bb61602fd52e7a:

  ARM: omap2plus_defconfig: Run make savedefconfig to save some space (2016-11-15 11:01:24 -0800)

----------------------------------------------------------------
Defconfig changes for omaps for v4.10 merge window:

- Enable tsc2004 touchscreen as a loadable module

- Enable REGULATOR_GPIO, dra71-evm needs this for MMC voltage

- Enable LP873x PMICs for dra71x-evm

- Run make savedefconfig to save some space and make it
  easier to generate minimal patches against it

----------------------------------------------------------------
Adam Ford (1):
      ARM: omap2plus_defconfig: Enable TOUCHSCREEN_TSC2004

Lokesh Vutla (2):
      ARM: omap2plus_defconfig: Enable REGULATOR_GPIO
      ARM: omap2plus_defconfig: Enable LP873X support

Tony Lindgren (1):
      ARM: omap2plus_defconfig: Run make savedefconfig to save some space

 arch/arm/configs/omap2plus_defconfig | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

^ permalink raw reply

* [GIT PULL] Allwinner clock fixes for 4.9
From: Maxime Ripard @ 2016-11-15 21:23 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Mike, Stephen,

Please pull the following fixes for the 4.9 cycle

Thanks!
Maxime

The following changes since commit 1001354ca34179f3db924eb66672442a173147dc:

  Linux 4.9-rc1 (2016-10-15 12:17:50 -0700)

are available in the git repository at:

  https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux.git tags/sunxi-clk-fixes-for-4.9

for you to fetch changes up to ac95330b96376550ae7a533d1396272d675adfa2:

  clk: sunxi: Fix M factor computation for APB1 (2016-11-04 08:49:46 +0100)

----------------------------------------------------------------
Allwinner clock fixes for 4.9

Two fixes, one for the old clock code, one for the new implementation.

----------------------------------------------------------------
Chen-Yu Tsai (1):
      clk: sunxi-ng: sun6i-a31: Force AHB1 clock to use PLL6 as parent

St?phan Rafin (1):
      clk: sunxi: Fix M factor computation for APB1

 drivers/clk/sunxi-ng/ccu-sun6i-a31.c | 12 ++++++++++++
 drivers/clk/sunxi/clk-sunxi.c        |  2 +-
 2 files changed, 13 insertions(+), 1 deletion(-)

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20161115/edb7507a/attachment.sig>

^ permalink raw reply

* [GIT PULL] Allwinner clock changes for 4.10
From: Maxime Ripard @ 2016-11-15 21:26 UTC (permalink / raw)
  To: linux-arm-kernel

Hi Mike, Stephen,

Please pull the following patches for the next merge window.

Thanks!
Maxime

The following changes since commit 1001354ca34179f3db924eb66672442a173147dc:

  Linux 4.9-rc1 (2016-10-15 12:17:50 -0700)

are available in the git repository at:

  https://git.kernel.org/pub/scm/linux/kernel/git/mripard/linux.git sunxi-clk-for-4.10

for you to fetch changes up to 0f6f9302b819ca352cfd4f42c18ec08d521f9cae:

  clk: sunxi-ng: sun8i-h3: Set CLK_SET_RATE_PARENT for audio module clocks (2016-11-11 21:47:41 +0100)

----------------------------------------------------------------
Allwinner clock changes for 4.10

The usual patches from us, but most notably the introduction of the A64
clocks unit.

----------------------------------------------------------------
Chen-Yu Tsai (2):
      clk: sunxi-ng: sun8i-a23: Set CLK_SET_RATE_PARENT for audio module clocks
      clk: sunxi-ng: sun8i-h3: Set CLK_SET_RATE_PARENT for audio module clocks

Julia Lawall (1):
      clk: sunxi: mod0: improve function-level documentation

Maxime Ripard (6):
      clk: sunxi-ng: Rename the internal structures
      clk: sunxi-ng: Remove the use of rational computations
      clk: sunxi-ng: Finish to convert to structures for arguments
      clk: sunxi-ng: Add minimums for all the relevant structures and clocks
      clk: sunxi-ng: Implement minimum for multipliers
      clk: sunxi-ng: Add A64 clocks

 .../devicetree/bindings/clock/sunxi-ccu.txt        |   1 +
 drivers/clk/sunxi-ng/Kconfig                       |  14 +-
 drivers/clk/sunxi-ng/Makefile                      |   1 +
 drivers/clk/sunxi-ng/ccu-sun50i-a64.c              | 915 +++++++++++++++++++++
 drivers/clk/sunxi-ng/ccu-sun50i-a64.h              |  72 ++
 drivers/clk/sunxi-ng/ccu-sun8i-a23.c               |   6 +-
 drivers/clk/sunxi-ng/ccu-sun8i-h3.c                |  10 +-
 drivers/clk/sunxi-ng/ccu_div.h                     |   6 +-
 drivers/clk/sunxi-ng/ccu_frac.c                    |  12 +-
 drivers/clk/sunxi-ng/ccu_frac.h                    |  14 +-
 drivers/clk/sunxi-ng/ccu_mp.h                      |   4 +-
 drivers/clk/sunxi-ng/ccu_mult.c                    |  33 +-
 drivers/clk/sunxi-ng/ccu_mult.h                    |  17 +-
 drivers/clk/sunxi-ng/ccu_nk.c                      |  43 +-
 drivers/clk/sunxi-ng/ccu_nk.h                      |   4 +-
 drivers/clk/sunxi-ng/ccu_nkm.c                     |  45 +-
 drivers/clk/sunxi-ng/ccu_nkm.h                     |   6 +-
 drivers/clk/sunxi-ng/ccu_nkmp.c                    |  55 +-
 drivers/clk/sunxi-ng/ccu_nkmp.h                    |   8 +-
 drivers/clk/sunxi-ng/ccu_nm.c                      |  58 +-
 drivers/clk/sunxi-ng/ccu_nm.h                      |   6 +-
 drivers/clk/sunxi/clk-mod0.c                       |   2 +-
 include/dt-bindings/clock/sun50i-a64-ccu.h         | 134 +++
 include/dt-bindings/reset/sun50i-a64-ccu.h         |  98 +++
 24 files changed, 1434 insertions(+), 130 deletions(-)
 create mode 100644 drivers/clk/sunxi-ng/ccu-sun50i-a64.c
 create mode 100644 drivers/clk/sunxi-ng/ccu-sun50i-a64.h
 create mode 100644 include/dt-bindings/clock/sun50i-a64-ccu.h
 create mode 100644 include/dt-bindings/reset/sun50i-a64-ccu.h

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20161115/2e76f92b/attachment-0001.sig>

^ permalink raw reply

* [PATCH v2] staging: vc04_services: rework ioctl code path
From: Michael Zoran @ 2016-11-15 21:27 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20161115095520.GA18059@kroah.com>

On Tue, 2016-11-15 at 10:55 +0100, Greg KH wrote:
> On Thu, Nov 10, 2016 at 10:15:31PM -0800, Michael Zoran wrote:
> > VCHIQ/vc04_services has a userland device interface
> > that includes ioctls. The current ioctl implementation
> > is a single monolithic function over 1,000+ lines
> > that handles 17 different ioctls through a complex
> > maze of switch and if statements.
> > 
> > The change reimplements that code path by breaking
> > up the code into smaller, easier to maintain functions
> > and uses a dispatch table to invoke the correct function.
> > 
> > Testing:
> > 
> > 1. vchiq_test -f 10 and vchiq_test -p 1 were run from a native
> > 64-bit OS(debian sid).
> > 
> > 2. vchiq_test -f 10 and vchiq_test -p 1 where run from a 32-bit
> > chroot install from the same OS.
> > 
> > Both test cases pass.
> > 
> > This is V2 of this patch.??Changes include:
> > 
> > 1. More code has been moved to the dispatch routine.
> > The dispatch routine is now responsible for copying the top-level
> > data into and out of kernel space by using the data encoded in
> > the ioctl command number.
> > 
> > 2. The number of parameters have been reduced for the handling
> > functions by giving a different prototype to ioctls that pass
> > no arguments.
> > 
> > 3. Macros in linux/compat.h are now used for compatibility data
> > structures.
> > 
> > Signed-off-by: Michael Zoran <mzoran@crowfest.net>
> > ---
> > ?.../vc04_services/interface/vchiq_arm/vchiq_arm.c??| 1733
> > +++++++++++++-------
> > ?.../interface/vchiq_arm/vchiq_ioctl.h??????????????|???96 ++
> > ?2 files changed, 1200 insertions(+), 629 deletions(-)
> 
> This is a rough patch to review, can you break this up into a patch
> series that moves each ioctl to a separate function as needed?
> 
> thanks,
> 
> greg k-h

I'll see what I can do, but since this is getting closer to the
holidays I'm planing to spend less time on this. Perhaps someone else
may be interested in cleaning up the ioctl path?

Since the old code uses obsolete kernel features, it's going to take
some work to fix without adding any checkpatch.pl warnings.

^ permalink raw reply

* specifying order of /dev/mmcblk devices via device-tree?
From: Russell King - ARM Linux @ 2016-11-15 21:35 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <CAJ+vNU38XQBHt709S_z6Quvce6wcqLzRHFuN_bVZ_0eARa3=fw@mail.gmail.com>

On Tue, Nov 15, 2016 at 12:27:53PM -0800, Tim Harvey wrote:
> On Mon, Nov 14, 2016 at 11:08 AM, Russell King - ARM Linux
> <linux@armlinux.org.uk> wrote:
> > So, someone merged a patch which makes mmcblk devices follow the
> > host controller numbering.
> >
> > Now my cubox-i fails to boot correctly because the SD card in the
> > _only_ SD card slot now gets called "mmcblk1" and not "mmcblk0".
> >
> > USDHC1 is wired to the on-microsom WiFi, and never has anything
> > remotely near a SD card or eMMC present.  So, this change is
> > confusing on these platforms.
> >
> > Moreover, this is _going_ to break SolidRun distros if people upgrade
> > their kernels.
> >
> > It may be appropriate for eMMC, but it's not appropriate everywhere.
> >
> > This is a user visible _regression_ in 4.9-rc.  Whoever did this,
> > please revert whatever change caused this, and next time limit it
> > to only eMMC.
> >
> > Thanks.
> 
> I see the same thing on newer kernels, which is why I asked the
> question. I didn't expect (or even want honestly) a non mmcblk0 boot
> device and was looking for a way to control that via dt. Now I'm
> understanding that to avoid this kind of bootloader/kernel dependence
> issue I should be using UUID's to identify the boot device.
> 
> >From my testing it looks like the change your looking for occurred
> some time ago and is somewhere between 4.5 and 4.6 and not a 4.9
> regression specifically.

That depends how you look at it.  Yes, there's a change in 4.5 to 4.6
which ties the block device number to the host device index, but that's
really only part of the story here.

4.8 definitely identifies the SD card in iMX6 usdhc2 as "mmcblk0".
4.9-rc identifies the SD card as "mmcblk1".  This makes it a 4.9 change
of behaviour - there can be no argument about that.

Now, digging further into this today, it appears that:

v4.8: usdhc2 was probed first, and is given mmc0.
      usdhc1 is probed second, and is given mmc1.

v4.9-rc: usdhc1 is probed first, and is given mmc0.
         usdhc2 is probed second, and is given mmc1.

I haven't yet been able to figure out why there's been this change
of probe order.  There's no change that I can see in the iMX6 DT
files that would account for this.

-- 
RMK's Patch system: http://www.armlinux.org.uk/developer/patches/
FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up
according to speedtest.net.

^ permalink raw reply

* Default atomic_pool_size value & changing it
From: Russell King - ARM Linux @ 2016-11-15 21:37 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <CACna6ryHrkhxF-HKDB-+if=7XC9D=89oTEVyR9PJWpYAWnoVzw@mail.gmail.com>

On Tue, Nov 15, 2016 at 10:15:51PM +0100, Rafa? Mi?ecki wrote:
> I've hit problem with allocating enough coherent DMA memory. Obviously
> there is a limit of this memory as pointed by:
> [ 0.283667] DMA: preallocated 256 KiB pool for atomic coherent allocations

This is for _atomic_ coherent allocations, not for normal coherent
allocations.  Normal coherent allocations come from the CMA memory.
Make sure you have CMA enabled, and you have enough of it.

Boot with cma=xxxMB with xxx set appropriately.

-- 
RMK's Patch system: http://www.armlinux.org.uk/developer/patches/
FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up
according to speedtest.net.

^ permalink raw reply

* specifying order of /dev/mmcblk devices via device-tree?
From: Tim Harvey @ 2016-11-15 21:39 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20161115213510.GY1041@n2100.armlinux.org.uk>

On Tue, Nov 15, 2016 at 1:35 PM, Russell King - ARM Linux
<linux@armlinux.org.uk> wrote:
> On Tue, Nov 15, 2016 at 12:27:53PM -0800, Tim Harvey wrote:
>> On Mon, Nov 14, 2016 at 11:08 AM, Russell King - ARM Linux
>> <linux@armlinux.org.uk> wrote:
>> > So, someone merged a patch which makes mmcblk devices follow the
>> > host controller numbering.
>> >
>> > Now my cubox-i fails to boot correctly because the SD card in the
>> > _only_ SD card slot now gets called "mmcblk1" and not "mmcblk0".
>> >
>> > USDHC1 is wired to the on-microsom WiFi, and never has anything
>> > remotely near a SD card or eMMC present.  So, this change is
>> > confusing on these platforms.
>> >
>> > Moreover, this is _going_ to break SolidRun distros if people upgrade
>> > their kernels.
>> >
>> > It may be appropriate for eMMC, but it's not appropriate everywhere.
>> >
>> > This is a user visible _regression_ in 4.9-rc.  Whoever did this,
>> > please revert whatever change caused this, and next time limit it
>> > to only eMMC.
>> >
>> > Thanks.
>>
>> I see the same thing on newer kernels, which is why I asked the
>> question. I didn't expect (or even want honestly) a non mmcblk0 boot
>> device and was looking for a way to control that via dt. Now I'm
>> understanding that to avoid this kind of bootloader/kernel dependence
>> issue I should be using UUID's to identify the boot device.
>>
>> >From my testing it looks like the change your looking for occurred
>> some time ago and is somewhere between 4.5 and 4.6 and not a 4.9
>> regression specifically.
>
> That depends how you look at it.  Yes, there's a change in 4.5 to 4.6
> which ties the block device number to the host device index, but that's
> really only part of the story here.
>
> 4.8 definitely identifies the SD card in iMX6 usdhc2 as "mmcblk0".
> 4.9-rc identifies the SD card as "mmcblk1".  This makes it a 4.9 change
> of behaviour - there can be no argument about that.
>
> Now, digging further into this today, it appears that:
>
> v4.8: usdhc2 was probed first, and is given mmc0.
>       usdhc1 is probed second, and is given mmc1.
>
> v4.9-rc: usdhc1 is probed first, and is given mmc0.
>          usdhc2 is probed second, and is given mmc1.
>
> I haven't yet been able to figure out why there's been this change
> of probe order.  There's no change that I can see in the iMX6 DT
> files that would account for this.
>

I bisected it and the commit your looking for is
9aaf3437aa72ed5370bf32c99580a3fa2c330e3d

Tim

^ permalink raw reply

* Default atomic_pool_size value & changing it
From: Rafał Miłecki @ 2016-11-15 21:43 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20161115213706.GZ1041@n2100.armlinux.org.uk>

On 15 November 2016 at 22:37, Russell King - ARM Linux
<linux@armlinux.org.uk> wrote:
> On Tue, Nov 15, 2016 at 10:15:51PM +0100, Rafa? Mi?ecki wrote:
>> I've hit problem with allocating enough coherent DMA memory. Obviously
>> there is a limit of this memory as pointed by:
>> [ 0.283667] DMA: preallocated 256 KiB pool for atomic coherent allocations
>
> This is for _atomic_ coherent allocations, not for normal coherent
> allocations.  Normal coherent allocations come from the CMA memory.
> Make sure you have CMA enabled, and you have enough of it.
>
> Boot with cma=xxxMB with xxx set appropriately.

Oh, that definitely sounds like worth trying
# CONFIG_CMA is not set
thanks for pointing it to me!

-- 
Rafa?

^ permalink raw reply

* specifying order of /dev/mmcblk devices via device-tree?
From: Russell King - ARM Linux @ 2016-11-15 22:10 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <CAJ+vNU2t5f=HQ94_GW-cry7DV3FsR9Vx-ck_E-eNuDk5vd-eaw@mail.gmail.com>

On Tue, Nov 15, 2016 at 01:39:42PM -0800, Tim Harvey wrote:
> On Tue, Nov 15, 2016 at 1:35 PM, Russell King - ARM Linux
> <linux@armlinux.org.uk> wrote:
> > On Tue, Nov 15, 2016 at 12:27:53PM -0800, Tim Harvey wrote:
> >> On Mon, Nov 14, 2016 at 11:08 AM, Russell King - ARM Linux
> >> <linux@armlinux.org.uk> wrote:
> >> > So, someone merged a patch which makes mmcblk devices follow the
> >> > host controller numbering.
> >> >
> >> > Now my cubox-i fails to boot correctly because the SD card in the
> >> > _only_ SD card slot now gets called "mmcblk1" and not "mmcblk0".
> >> >
> >> > USDHC1 is wired to the on-microsom WiFi, and never has anything
> >> > remotely near a SD card or eMMC present.  So, this change is
> >> > confusing on these platforms.
> >> >
> >> > Moreover, this is _going_ to break SolidRun distros if people upgrade
> >> > their kernels.
> >> >
> >> > It may be appropriate for eMMC, but it's not appropriate everywhere.
> >> >
> >> > This is a user visible _regression_ in 4.9-rc.  Whoever did this,
> >> > please revert whatever change caused this, and next time limit it
> >> > to only eMMC.
> >> >
> >> > Thanks.
> >>
> >> I see the same thing on newer kernels, which is why I asked the
> >> question. I didn't expect (or even want honestly) a non mmcblk0 boot
> >> device and was looking for a way to control that via dt. Now I'm
> >> understanding that to avoid this kind of bootloader/kernel dependence
> >> issue I should be using UUID's to identify the boot device.
> >>
> >> >From my testing it looks like the change your looking for occurred
> >> some time ago and is somewhere between 4.5 and 4.6 and not a 4.9
> >> regression specifically.
> >
> > That depends how you look at it.  Yes, there's a change in 4.5 to 4.6
> > which ties the block device number to the host device index, but that's
> > really only part of the story here.
> >
> > 4.8 definitely identifies the SD card in iMX6 usdhc2 as "mmcblk0".
> > 4.9-rc identifies the SD card as "mmcblk1".  This makes it a 4.9 change
> > of behaviour - there can be no argument about that.
> >
> > Now, digging further into this today, it appears that:
> >
> > v4.8: usdhc2 was probed first, and is given mmc0.
> >       usdhc1 is probed second, and is given mmc1.
> >
> > v4.9-rc: usdhc1 is probed first, and is given mmc0.
> >          usdhc2 is probed second, and is given mmc1.
> >
> > I haven't yet been able to figure out why there's been this change
> > of probe order.  There's no change that I can see in the iMX6 DT
> > files that would account for this.
> >
> 
> I bisected it and the commit your looking for is
> 9aaf3437aa72ed5370bf32c99580a3fa2c330e3d

No it's not.

Let me try and put it plainer:

* Commit 9aaf3437aa72ed5370bf32c99580a3fa2c330e3d ties the mmc block
  device number (mmcblkN) to the mmc host interface number (mmcN).
  This change happened between 4.5 and 4.6.

* The change I'm seeing happened between 4.8 and 4.9-rc.  I'm not
  seeing a change of behaviour between 4.5 and 4.6.

* The change I'm seeing changes the order of the physical device
  associated with the hosts named mmc0 and mmc1 in the kernel.

* Because physical devices associated with the mmc0 and mmc1 hosts
  swap over, the mmcblkN number changes due to the commit you point
  out.

* So, the change that I'm seeing between 4.8 and 4.9-rc is not caused
  by commit 9aaf3437aa72ed5370bf32c99580a3fa2c330e3d, but by something
  else changing the order in which the two usdhc physical hardware
  blocks get probed.

Does this make it clearer?

-- 
RMK's Patch system: http://www.armlinux.org.uk/developer/patches/
FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up
according to speedtest.net.

^ permalink raw reply

* [PATCH 01/10] ASoC: sunxi: Add bindings for A23/A33/H3 codec's analog path controls
From: Rob Herring @ 2016-11-15 22:22 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20161112064648.26779-2-wens@csie.org>

On Sat, Nov 12, 2016 at 02:46:39PM +0800, Chen-Yu Tsai wrote:
> The internal codec on A23/A33/H3 is split into 2 parts. The
> analog path controls are routed through an embedded custom register
> bus accessed through the PRCM block.
> 
> The SoCs share a common set of inputs, outputs, and audio paths.
> The following table lists the differences.
> 
>     ----------------------------------------
>     | Feature \ SoC |  A23  |  A33  |  H3  |
>     ----------------------------------------
>     | Headphone     |   v   |   v   |      |
>     ----------------------------------------
>     | Line Out      |       |       |  v   |
>     ----------------------------------------
>     | Phone In/Out  |   v   |   v   |      |
>     ----------------------------------------
> 
> Add a binding for this hardware.
> 
> Signed-off-by: Chen-Yu Tsai <wens@csie.org>
> ---
>  .../devicetree/bindings/sound/sun8i-codec-analog.txt     | 16 ++++++++++++++++
>  1 file changed, 16 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/sound/sun8i-codec-analog.txt

Acked-by: Rob Herring <robh@kernel.org> 

^ permalink raw reply

* [PATCH 04/10] ASoC: sun4i-codec: Add support for A23 codec
From: Rob Herring @ 2016-11-15 22:23 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20161112064648.26779-5-wens@csie.org>

On Sat, Nov 12, 2016 at 02:46:42PM +0800, Chen-Yu Tsai wrote:
> The codec in the A23 is similar to the one found on the A31. One key
> difference is the analog path controls are routed through the PRCM
> block. This is supported by the sun8i-codec-analog driver, and tied
> into this codec driver with the audio card's aux_dev.
> 
> In addition, the A23 does not have LINEOUT, and it does not support
> headset jack detection or buttons.
> 
> Signed-off-by: Chen-Yu Tsai <wens@csie.org>
> ---
>  .../devicetree/bindings/sound/sun4i-codec.txt      |  11 ++-

Acked-by: Rob Herring <robh@kernel.org> 

>  sound/soc/sunxi/sun4i-codec.c                      | 108 +++++++++++++++++++++
>  2 files changed, 117 insertions(+), 2 deletions(-)

^ permalink raw reply

* [PATCH 08/10] ASoC: sun4i-codec: Add support for H3 codec
From: Rob Herring @ 2016-11-15 22:23 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20161112064648.26779-9-wens@csie.org>

On Sat, Nov 12, 2016 at 02:46:46PM +0800, Chen-Yu Tsai wrote:
> The codec on the H3 is similar to the one found on the A31. One key
> difference is the analog path controls are routed through the PRCM
> block. This is supported by the sun8i-codec-analog driver, and tied
> into this codec driver with the audio card's aux_dev.
> 
> In addition, the H3 has no HP (headphone) and HBIAS support, and no
> MIC3 input. The FIFO related registers are slightly rearranged.
> 
> Signed-off-by: Chen-Yu Tsai <wens@csie.org>
> ---
>  .../devicetree/bindings/sound/sun4i-codec.txt      |  3 +

Acked-by: Rob Herring <robh@kernel.org> 

>  sound/soc/sunxi/sun4i-codec.c                      | 71 ++++++++++++++++++++++
>  2 files changed, 74 insertions(+)

^ permalink raw reply

* [PATCH v2 0/3] Rockchip: generalize GRF setup
From: Heiko Stuebner @ 2016-11-15 22:38 UTC (permalink / raw)
  To: linux-arm-kernel

The General register files contain a big bunch of settings for various
components. Things like the automatic sdmmc/jtag switch may even affect
us in a bad way, while that property (and possibly others) are not even
part of the dw_mmc controller itself.

And while the rk3288 could still carry adaptions to these defaults
in its mach files, this is no longer possible on the arm64 socs, while
things like the jtag-switch from above still can affect us there.

changes in v2:
- address comments from Doug Anderson
- drop platform device, as we actual probing may happen at some
  unspecified later time during boot
- add reviews / acks received in v1

Heiko Stuebner (3):
  dt-bindings: add used but undocumented rockchip grf compatible values
  soc: rockchip: add driver handling grf setup
  ARM: rockchip: drop rk3288 jtag/mmc switch handling

 .../devicetree/bindings/soc/rockchip/grf.txt       |   4 +
 arch/arm/mach-rockchip/rockchip.c                  |  12 --
 drivers/soc/rockchip/Kconfig                       |  10 ++
 drivers/soc/rockchip/Makefile                      |   1 +
 drivers/soc/rockchip/grf.c                         | 134 +++++++++++++++++++++
 5 files changed, 149 insertions(+), 12 deletions(-)
 create mode 100644 drivers/soc/rockchip/grf.c

-- 
2.10.2

^ permalink raw reply

* [PATCH v2 1/3] dt-bindings: add used but undocumented rockchip grf compatible values
From: Heiko Stuebner @ 2016-11-15 22:38 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20161115223900.30728-1-heiko@sntech.de>

There are some more General Register Files used in devicetree files
already, but as of now undocumented in the binding document, fix that.

Signed-off-by: Heiko Stuebner <heiko@sntech.de>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Acked-by: Rob Herring <robh@kernel.org>
Reviewed-by: Shawn Lin <shawn.lin@rock-chips.com>
---
 Documentation/devicetree/bindings/soc/rockchip/grf.txt | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/Documentation/devicetree/bindings/soc/rockchip/grf.txt b/Documentation/devicetree/bindings/soc/rockchip/grf.txt
index 013e71a..c6e62cb 100644
--- a/Documentation/devicetree/bindings/soc/rockchip/grf.txt
+++ b/Documentation/devicetree/bindings/soc/rockchip/grf.txt
@@ -5,11 +5,13 @@ is composed of many registers for system control.
 
 From RK3368 SoCs, the GRF is divided into two sections,
 - GRF, used for general non-secure system,
+- SGRF, used for general secure system,
 - PMUGRF, used for always on system
 
 Required Properties:
 
 - compatible: GRF should be one of the followings
+   - "rockchip,rk3036-grf", "syscon": for rk3036
    - "rockchip,rk3066-grf", "syscon": for rk3066
    - "rockchip,rk3188-grf", "syscon": for rk3188
    - "rockchip,rk3228-grf", "syscon": for rk3228
@@ -19,6 +21,8 @@ Required Properties:
 - compatible: PMUGRF should be one of the followings
    - "rockchip,rk3368-pmugrf", "syscon": for rk3368
    - "rockchip,rk3399-pmugrf", "syscon": for rk3399
+- compatible: SGRF should be one of the following
+   - "rockchip,rk3288-sgrf", "syscon": for rk3288
 - reg: physical base address of the controller and length of memory mapped
   region.
 
-- 
2.10.2

^ permalink raw reply related

* [PATCH v2 2/3] soc: rockchip: add driver handling grf setup
From: Heiko Stuebner @ 2016-11-15 22:38 UTC (permalink / raw)
  To: linux-arm-kernel
In-Reply-To: <20161115223900.30728-1-heiko@sntech.de>

The General Register Files are an area of registers containing a lot
of single-bit settings for numerous components as well full components
like usbphy control. Therefore all used components are accessed
via the syscon provided by the grf nodes or from the sub-devices
created through the simple-mfd created from the grf node.

Some settings are not used by anything but will need to be set up
according to expectations on the kernel side.

Best example is the force_jtag setting, which defaults to on and
results in the soc switching the pin-outputs between jtag and sdmmc
automatically depending on the card-detect status. This conflicts
heavily with how the dw_mmc driver expects to do its work and also
with the clock-controller, which has most likely deactivated the
jtag clock due to it being unused.

So far the handling of this setting was living in the mach-rockchip
code for the arm32-based rk3288 but that of course doesn't work
for arm64 socs and would also look ugly for further arm32 socs.

Also always disabling this setting is quite specific to linux and
its subsystems, other operating systems might prefer other settings,
so that the bootloader cannot really set a sane default for all.

So introduce a top-level driver for the grf that handles these
settings that need to be a certain way but nobody cares about.

Other needed settings might surface in the future and can then
be added here, but only as a last option. Ideally general GRF
settings should be handled in the driver needing them.

Signed-off-by: Heiko Stuebner <heiko@sntech.de>
---
 drivers/soc/rockchip/Kconfig  |  10 ++++
 drivers/soc/rockchip/Makefile |   1 +
 drivers/soc/rockchip/grf.c    | 134 ++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 145 insertions(+)
 create mode 100644 drivers/soc/rockchip/grf.c

diff --git a/drivers/soc/rockchip/Kconfig b/drivers/soc/rockchip/Kconfig
index 7140ff8..20da55d 100644
--- a/drivers/soc/rockchip/Kconfig
+++ b/drivers/soc/rockchip/Kconfig
@@ -3,6 +3,16 @@ if ARCH_ROCKCHIP || COMPILE_TEST
 #
 # Rockchip Soc drivers
 #
+
+config ROCKCHIP_GRF
+	bool
+	default y
+	help
+	  The General Register Files are a central component providing
+	  special additional settings registers for a lot of soc-components.
+	  In a lot of cases there also need to be default settings initialized
+	  to make some of them conform to expectations of the kernel.
+
 config ROCKCHIP_PM_DOMAINS
         bool "Rockchip generic power domain"
         depends on PM
diff --git a/drivers/soc/rockchip/Makefile b/drivers/soc/rockchip/Makefile
index 3d73d06..c851fa0 100644
--- a/drivers/soc/rockchip/Makefile
+++ b/drivers/soc/rockchip/Makefile
@@ -1,4 +1,5 @@
 #
 # Rockchip Soc drivers
 #
+obj-$(CONFIG_ROCKCHIP_GRF) += grf.o
 obj-$(CONFIG_ROCKCHIP_PM_DOMAINS) += pm_domains.o
diff --git a/drivers/soc/rockchip/grf.c b/drivers/soc/rockchip/grf.c
new file mode 100644
index 0000000..0c85476a
--- /dev/null
+++ b/drivers/soc/rockchip/grf.c
@@ -0,0 +1,134 @@
+/*
+ * Rockchip Generic Register Files setup
+ *
+ * Copyright (c) 2016 Heiko Stuebner <heiko@sntech.de>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ */
+
+#include <linux/err.h>
+#include <linux/regmap.h>
+#include <linux/mfd/syscon.h>
+#include <linux/of_device.h>
+#include <linux/platform_device.h>
+#include <linux/regmap.h>
+
+#define HIWORD_UPDATE(val, mask, shift) \
+		((val) << (shift) | (mask) << ((shift) + 16))
+
+struct rockchip_grf_value {
+	const char *desc;
+	u32 reg;
+	u32 val;
+};
+
+struct rockchip_grf_info {
+	const struct rockchip_grf_value *values;
+	int num_values;
+};
+
+#define RK3036_GRF_SOC_CON0		0x140
+
+static const struct rockchip_grf_value rk3036_defaults[] __initconst = {
+	/*
+	 * Disable auto jtag/sdmmc switching that causes issues with the
+	 * clock-framework and the mmc controllers making them unreliable.
+	 */
+	{ "jtag switching", RK3036_GRF_SOC_CON0, HIWORD_UPDATE(0, 1, 11) },
+};
+
+static const struct rockchip_grf_info rk3036_grf __initconst = {
+	.values = rk3036_defaults,
+	.num_values = ARRAY_SIZE(rk3036_defaults),
+};
+
+#define RK3288_GRF_SOC_CON0		0x244
+
+static const struct rockchip_grf_value rk3288_defaults[] __initconst = {
+	{ "jtag switching", RK3288_GRF_SOC_CON0, HIWORD_UPDATE(0, 1, 12) },
+};
+
+static const struct rockchip_grf_info rk3288_grf __initconst = {
+	.values = rk3288_defaults,
+	.num_values = ARRAY_SIZE(rk3288_defaults),
+};
+
+#define RK3368_GRF_SOC_CON15		0x43c
+
+static const struct rockchip_grf_value rk3368_defaults[] __initconst = {
+	{ "jtag switching", RK3368_GRF_SOC_CON15, HIWORD_UPDATE(0, 1, 13) },
+};
+
+static const struct rockchip_grf_info rk3368_grf __initconst = {
+	.values = rk3368_defaults,
+	.num_values = ARRAY_SIZE(rk3368_defaults),
+};
+
+#define RK3399_GRF_SOC_CON7		0xe21c
+
+static const struct rockchip_grf_value rk3399_defaults[] __initconst = {
+	{ "jtag switching", RK3399_GRF_SOC_CON7, HIWORD_UPDATE(0, 1, 12) },
+};
+
+static const struct rockchip_grf_info rk3399_grf __initconst = {
+	.values = rk3399_defaults,
+	.num_values = ARRAY_SIZE(rk3399_defaults),
+};
+
+static const struct of_device_id rockchip_grf_dt_match[] __initconst = {
+	{
+		.compatible = "rockchip,rk3036-grf",
+		.data = (void *)&rk3036_grf,
+	}, {
+		.compatible = "rockchip,rk3288-grf",
+		.data = (void *)&rk3288_grf,
+	}, {
+		.compatible = "rockchip,rk3368-grf",
+		.data = (void *)&rk3368_grf,
+	}, {
+		.compatible = "rockchip,rk3399-grf",
+		.data = (void *)&rk3399_grf,
+	},
+	{ /* sentinel */ },
+};
+
+static int __init rockchip_grf_init(void)
+{
+	const struct rockchip_grf_info *grf_info;
+	const struct of_device_id *match;
+	struct device_node *np;
+	struct regmap *grf;
+	int ret, i;
+
+	np = of_find_matching_node_and_match(NULL, rockchip_grf_dt_match, &match);
+	if (!np)
+		return -ENODEV;
+	if (!match || !match->data) {
+		pr_err("%s: missing grf data\n", __func__);
+		return -EINVAL;
+	}
+
+	grf_info = match->data;
+
+	grf = syscon_node_to_regmap(np);
+	if (IS_ERR(grf)) {
+		pr_err("%s: could not get grf syscon\n", __func__);
+		return PTR_ERR(grf);
+	}
+
+	for (i = 0; i < grf_info->num_values; i++) {
+		const struct rockchip_grf_value *val = &grf_info->values[i];
+
+		pr_debug("%s: adjusting %s in %#6x to %#10x\n", __func__,
+			val->desc, val->reg, val->val);
+		ret = regmap_write(grf, val->reg, val->val);
+		if (ret < 0)
+			pr_err("%s: write to %#6x failed with %d\n",
+			       __func__, val->reg, ret);
+	}
+
+	return 0;
+}
+postcore_initcall(rockchip_grf_init);
-- 
2.10.2

^ permalink raw reply related


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox