diff mbox

[U-Boot,2/2] sunxi: Enable MMC new mode for A83T

Message ID 20170823100342.26148-2-maxime.ripard@free-electrons.com
State Accepted
Delegated to: Jagannadha Sutradharudu Teki
Headers show

Commit Message

Maxime Ripard Aug. 23, 2017, 10:03 a.m. UTC
The eMMC controller for the A83T uses the new operating mode. Enable it.

Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
---
 arch/arm/mach-sunxi/Kconfig | 1 +
 1 file changed, 1 insertion(+)

Comments

Jagan Teki Aug. 26, 2017, 6:41 a.m. UTC | #1
On Wed, Aug 23, 2017 at 3:33 PM, Maxime Ripard
<maxime.ripard@free-electrons.com> wrote:
> The eMMC controller for the A83T uses the new operating mode. Enable it.
>
> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
> ---

Reviewed-by: Jagan Teki <jagan@openedev.com>

thanks!
Maxime Ripard Aug. 28, 2017, 6:59 a.m. UTC | #2
Hi Jagan,

On Sat, Aug 26, 2017 at 12:11:23PM +0530, Jagan Teki wrote:
> On Wed, Aug 23, 2017 at 3:33 PM, Maxime Ripard
> <maxime.ripard@free-electrons.com> wrote:
> > The eMMC controller for the A83T uses the new operating mode. Enable it.
> >
> > Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
> 
> Reviewed-by: Jagan Teki <jagan@openedev.com>

I think both these patches should be merged in the upcoming
release. It's a fix for a usecase that already exists (we already
enable the eMMC on A83T), and it's unusable on some boards without it.

Maxime
Jagan Teki Aug. 28, 2017, 8:05 a.m. UTC | #3
On Mon, Aug 28, 2017 at 12:29 PM, Maxime Ripard
<maxime.ripard@free-electrons.com> wrote:
> Hi Jagan,
>
> On Sat, Aug 26, 2017 at 12:11:23PM +0530, Jagan Teki wrote:
>> On Wed, Aug 23, 2017 at 3:33 PM, Maxime Ripard
>> <maxime.ripard@free-electrons.com> wrote:
>> > The eMMC controller for the A83T uses the new operating mode. Enable it.
>> >
>> > Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
>>
>> Reviewed-by: Jagan Teki <jagan@openedev.com>
>
> I think both these patches should be merged in the upcoming
> release. It's a fix for a usecase that already exists (we already
> enable the eMMC on A83T), and it's unusable on some boards without it.

But none of A83T boards were not enable eMMC yet? even sun8i-a83t.dtsi
still need to add node. May be we can wait once all add?

# grep -R 83T configs/
configs/Sinovoip_BPI_M3_defconfig:CONFIG_MACH_SUN8I_A83T=y
configs/h8_homlet_v2_defconfig:CONFIG_MACH_SUN8I_A83T=y
configs/Cubietruck_plus_defconfig:CONFIG_MACH_SUN8I_A83T=y

thanks!
Chen-Yu Tsai Aug. 28, 2017, 8:12 a.m. UTC | #4
On Mon, Aug 28, 2017 at 4:05 PM, Jagan Teki <jagannadh.teki@gmail.com> wrote:
> On Mon, Aug 28, 2017 at 12:29 PM, Maxime Ripard
> <maxime.ripard@free-electrons.com> wrote:
>> Hi Jagan,
>>
>> On Sat, Aug 26, 2017 at 12:11:23PM +0530, Jagan Teki wrote:
>>> On Wed, Aug 23, 2017 at 3:33 PM, Maxime Ripard
>>> <maxime.ripard@free-electrons.com> wrote:
>>> > The eMMC controller for the A83T uses the new operating mode. Enable it.
>>> >
>>> > Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
>>>
>>> Reviewed-by: Jagan Teki <jagan@openedev.com>
>>
>> I think both these patches should be merged in the upcoming
>> release. It's a fix for a usecase that already exists (we already
>> enable the eMMC on A83T), and it's unusable on some boards without it.
>
> But none of A83T boards were not enable eMMC yet? even sun8i-a83t.dtsi
> still need to add node. May be we can wait once all add?

The sunxi-mmc driver does not use the device tree.

One only needs to set CONFIG_MMC_SUNXI_SLOT_EXTRA=2 to use the eMMC.
And yes, eMMC is broken on some boards unless the new timing mode is
used.

ChenYu

> # grep -R 83T configs/
> configs/Sinovoip_BPI_M3_defconfig:CONFIG_MACH_SUN8I_A83T=y
> configs/h8_homlet_v2_defconfig:CONFIG_MACH_SUN8I_A83T=y
> configs/Cubietruck_plus_defconfig:CONFIG_MACH_SUN8I_A83T=y
Maxime Ripard Aug. 28, 2017, 8:45 a.m. UTC | #5
On Mon, Aug 28, 2017 at 04:12:15PM +0800, Chen-Yu Tsai wrote:
> On Mon, Aug 28, 2017 at 4:05 PM, Jagan Teki <jagannadh.teki@gmail.com> wrote:
> > On Mon, Aug 28, 2017 at 12:29 PM, Maxime Ripard
> > <maxime.ripard@free-electrons.com> wrote:
> >> Hi Jagan,
> >>
> >> On Sat, Aug 26, 2017 at 12:11:23PM +0530, Jagan Teki wrote:
> >>> On Wed, Aug 23, 2017 at 3:33 PM, Maxime Ripard
> >>> <maxime.ripard@free-electrons.com> wrote:
> >>> > The eMMC controller for the A83T uses the new operating mode. Enable it.
> >>> >
> >>> > Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
> >>>
> >>> Reviewed-by: Jagan Teki <jagan@openedev.com>
> >>
> >> I think both these patches should be merged in the upcoming
> >> release. It's a fix for a usecase that already exists (we already
> >> enable the eMMC on A83T), and it's unusable on some boards without it.
> >
> > But none of A83T boards were not enable eMMC yet? even sun8i-a83t.dtsi
> > still need to add node. May be we can wait once all add?
> 
> The sunxi-mmc driver does not use the device tree.
> 
> One only needs to set CONFIG_MMC_SUNXI_SLOT_EXTRA=2 to use the eMMC.
> And yes, eMMC is broken on some boards unless the new timing mode is
> used.

And the support is broken until "mmc: sunxi: fix legacy MMC
initialisation" in my other serie is applied.

Maxime
Jagan Teki Aug. 28, 2017, 9 a.m. UTC | #6
On Mon, Aug 28, 2017 at 2:15 PM, Maxime Ripard
<maxime.ripard@free-electrons.com> wrote:
> On Mon, Aug 28, 2017 at 04:12:15PM +0800, Chen-Yu Tsai wrote:
>> On Mon, Aug 28, 2017 at 4:05 PM, Jagan Teki <jagannadh.teki@gmail.com> wrote:
>> > On Mon, Aug 28, 2017 at 12:29 PM, Maxime Ripard
>> > <maxime.ripard@free-electrons.com> wrote:
>> >> Hi Jagan,
>> >>
>> >> On Sat, Aug 26, 2017 at 12:11:23PM +0530, Jagan Teki wrote:
>> >>> On Wed, Aug 23, 2017 at 3:33 PM, Maxime Ripard
>> >>> <maxime.ripard@free-electrons.com> wrote:
>> >>> > The eMMC controller for the A83T uses the new operating mode. Enable it.
>> >>> >
>> >>> > Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
>> >>>
>> >>> Reviewed-by: Jagan Teki <jagan@openedev.com>
>> >>
>> >> I think both these patches should be merged in the upcoming
>> >> release. It's a fix for a usecase that already exists (we already
>> >> enable the eMMC on A83T), and it's unusable on some boards without it.
>> >
>> > But none of A83T boards were not enable eMMC yet? even sun8i-a83t.dtsi
>> > still need to add node. May be we can wait once all add?
>>
>> The sunxi-mmc driver does not use the device tree.
>>
>> One only needs to set CONFIG_MMC_SUNXI_SLOT_EXTRA=2 to use the eMMC.
>> And yes, eMMC is broken on some boards unless the new timing mode is
>> used.
>
> And the support is broken until "mmc: sunxi: fix legacy MMC
> initialisation" in my other serie is applied.

With these patches, eMMC detected BPI-M3. But none of A83T boards have
CONFIG_MMC_SUNXI_SLOT_EXTRA=2 So it's better to take this once boards
added.

thanks!
Maxime Ripard Aug. 28, 2017, 9:10 a.m. UTC | #7
On Mon, Aug 28, 2017 at 02:30:23PM +0530, Jagan Teki wrote:
> On Mon, Aug 28, 2017 at 2:15 PM, Maxime Ripard
> <maxime.ripard@free-electrons.com> wrote:
> > On Mon, Aug 28, 2017 at 04:12:15PM +0800, Chen-Yu Tsai wrote:
> >> On Mon, Aug 28, 2017 at 4:05 PM, Jagan Teki <jagannadh.teki@gmail.com> wrote:
> >> > On Mon, Aug 28, 2017 at 12:29 PM, Maxime Ripard
> >> > <maxime.ripard@free-electrons.com> wrote:
> >> >> Hi Jagan,
> >> >>
> >> >> On Sat, Aug 26, 2017 at 12:11:23PM +0530, Jagan Teki wrote:
> >> >>> On Wed, Aug 23, 2017 at 3:33 PM, Maxime Ripard
> >> >>> <maxime.ripard@free-electrons.com> wrote:
> >> >>> > The eMMC controller for the A83T uses the new operating mode. Enable it.
> >> >>> >
> >> >>> > Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
> >> >>>
> >> >>> Reviewed-by: Jagan Teki <jagan@openedev.com>
> >> >>
> >> >> I think both these patches should be merged in the upcoming
> >> >> release. It's a fix for a usecase that already exists (we already
> >> >> enable the eMMC on A83T), and it's unusable on some boards without it.
> >> >
> >> > But none of A83T boards were not enable eMMC yet? even sun8i-a83t.dtsi
> >> > still need to add node. May be we can wait once all add?
> >>
> >> The sunxi-mmc driver does not use the device tree.
> >>
> >> One only needs to set CONFIG_MMC_SUNXI_SLOT_EXTRA=2 to use the eMMC.
> >> And yes, eMMC is broken on some boards unless the new timing mode is
> >> used.
> >
> > And the support is broken until "mmc: sunxi: fix legacy MMC
> > initialisation" in my other serie is applied.
> 
> With these patches, eMMC detected BPI-M3. But none of A83T boards have
> CONFIG_MMC_SUNXI_SLOT_EXTRA=2 So it's better to take this once boards
> added.

That argument doesn't really stand, any user is able to modify the
configuration themself, and experience that breakage.

The fact that this is not enabled by default just make it less
exposed, but it's still a bug that can be encountered today in a
real-life situation.

Maxime
Jagan Teki Aug. 28, 2017, 9:14 a.m. UTC | #8
On Mon, Aug 28, 2017 at 2:40 PM, Maxime Ripard
<maxime.ripard@free-electrons.com> wrote:
> On Mon, Aug 28, 2017 at 02:30:23PM +0530, Jagan Teki wrote:
>> On Mon, Aug 28, 2017 at 2:15 PM, Maxime Ripard
>> <maxime.ripard@free-electrons.com> wrote:
>> > On Mon, Aug 28, 2017 at 04:12:15PM +0800, Chen-Yu Tsai wrote:
>> >> On Mon, Aug 28, 2017 at 4:05 PM, Jagan Teki <jagannadh.teki@gmail.com> wrote:
>> >> > On Mon, Aug 28, 2017 at 12:29 PM, Maxime Ripard
>> >> > <maxime.ripard@free-electrons.com> wrote:
>> >> >> Hi Jagan,
>> >> >>
>> >> >> On Sat, Aug 26, 2017 at 12:11:23PM +0530, Jagan Teki wrote:
>> >> >>> On Wed, Aug 23, 2017 at 3:33 PM, Maxime Ripard
>> >> >>> <maxime.ripard@free-electrons.com> wrote:
>> >> >>> > The eMMC controller for the A83T uses the new operating mode. Enable it.
>> >> >>> >
>> >> >>> > Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
>> >> >>>
>> >> >>> Reviewed-by: Jagan Teki <jagan@openedev.com>
>> >> >>
>> >> >> I think both these patches should be merged in the upcoming
>> >> >> release. It's a fix for a usecase that already exists (we already
>> >> >> enable the eMMC on A83T), and it's unusable on some boards without it.
>> >> >
>> >> > But none of A83T boards were not enable eMMC yet? even sun8i-a83t.dtsi
>> >> > still need to add node. May be we can wait once all add?
>> >>
>> >> The sunxi-mmc driver does not use the device tree.
>> >>
>> >> One only needs to set CONFIG_MMC_SUNXI_SLOT_EXTRA=2 to use the eMMC.
>> >> And yes, eMMC is broken on some boards unless the new timing mode is
>> >> used.
>> >
>> > And the support is broken until "mmc: sunxi: fix legacy MMC
>> > initialisation" in my other serie is applied.
>>
>> With these patches, eMMC detected BPI-M3. But none of A83T boards have
>> CONFIG_MMC_SUNXI_SLOT_EXTRA=2 So it's better to take this once boards
>> added.
>
> That argument doesn't really stand, any user is able to modify the
> configuration themself, and experience that breakage.
>
> The fact that this is not enabled by default just make it less
> exposed, but it's still a bug that can be encountered today in a
> real-life situation.

OK, will apply these 3 for the release.

thanks!
Jagan Teki Aug. 28, 2017, 5:16 p.m. UTC | #9
On Wed, Aug 23, 2017 at 3:33 PM, Maxime Ripard
<maxime.ripard@free-electrons.com> wrote:
> The eMMC controller for the A83T uses the new operating mode. Enable it.
>
> Signed-off-by: Maxime Ripard <maxime.ripard@free-electrons.com>
> ---

Applied to u-boot-sunxi/master

thanks!
diff mbox

Patch

diff --git a/arch/arm/mach-sunxi/Kconfig b/arch/arm/mach-sunxi/Kconfig
index 94412bac0c1d..8d56d591d97a 100644
--- a/arch/arm/mach-sunxi/Kconfig
+++ b/arch/arm/mach-sunxi/Kconfig
@@ -127,6 +127,7 @@  config MACH_SUN8I_A83T
 	bool "sun8i (Allwinner A83T)"
 	select CPU_V7
 	select SUNXI_GEN_SUN6I
+	select MMC_SUNXI_HAS_NEW_MODE
 	select SUPPORT_SPL
 
 config MACH_SUN8I_H3