diff mbox

[U-Boot,6/6] sunxi: Enable second sdcard slot found on some boards

Message ID 1412348759-4599-7-git-send-email-hdegoede@redhat.com
State Superseded
Delegated to: Ian Campbell
Headers show

Commit Message

Hans de Goede Oct. 3, 2014, 3:05 p.m. UTC
Enable the second sdcard slot found on some boards. Note that we do not
set CONFIG_MMC_SUNXI_SLOT_EXTRA for the SPL, as having it there is not useful,

Except for on the Mele-M3 where the second sdcard is an eMMC, from which the
device can also boot, and there we want to have both in the SPL, so that
a single u-boot binary can both from both. So for the M3 we do prefix the
defconfig setting with the special "+S:" syntax so that it applies to the
SPL too.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
---
 configs/A10s-OLinuXino-M_defconfig    | 3 +++
 configs/A20-OLinuXino_MICRO_defconfig | 3 +++
 configs/Mele_M3_defconfig             | 2 ++
 3 files changed, 8 insertions(+)

Comments

Ian Campbell Oct. 4, 2014, 8:38 a.m. UTC | #1
On Fri, 2014-10-03 at 17:05 +0200, Hans de Goede wrote:
> diff --git a/configs/Mele_M3_defconfig b/configs/Mele_M3_defconfig
> index 645b236..50979e2 100644
> --- a/configs/Mele_M3_defconfig
> +++ b/configs/Mele_M3_defconfig
> @@ -1,5 +1,7 @@
>  CONFIG_SPL=y
>  CONFIG_SYS_EXTRA_OPTIONS="MELE_M3,AXP209_POWER,SUNXI_GMAC,USB_EHCI"
>  CONFIG_FDTFILE="sun7i-a20-m3.dtb"
> ++S:CONFIG_MMC_SUNXI_SLOT_EXTRA=2

This one is +S (regular+SPL) while the other two are just S (regular
only). Is that deliberate?

Ian.
Ian Campbell Oct. 4, 2014, 8:39 a.m. UTC | #2
On Sat, 2014-10-04 at 09:38 +0100, Ian Campbell wrote:
> On Fri, 2014-10-03 at 17:05 +0200, Hans de Goede wrote:
> > diff --git a/configs/Mele_M3_defconfig b/configs/Mele_M3_defconfig
> > index 645b236..50979e2 100644
> > --- a/configs/Mele_M3_defconfig
> > +++ b/configs/Mele_M3_defconfig
> > @@ -1,5 +1,7 @@
> >  CONFIG_SPL=y
> >  CONFIG_SYS_EXTRA_OPTIONS="MELE_M3,AXP209_POWER,SUNXI_GMAC,USB_EHCI"
> >  CONFIG_FDTFILE="sun7i-a20-m3.dtb"
> > ++S:CONFIG_MMC_SUNXI_SLOT_EXTRA=2
> 
> This one is +S (regular+SPL) while the other two are just S (regular
> only). Is that deliberate?

Sorry, I should have read the commit message more carefully as you
explained it quite clearly there!

This patch looks good, except insofar as some of my comments on earlier
patches could result in it looking completely different, sorry about
that!

Ian.
Hans de Goede Oct. 6, 2014, 8:37 a.m. UTC | #3
Hi,

On 10/04/2014 10:39 AM, Ian Campbell wrote:
> On Sat, 2014-10-04 at 09:38 +0100, Ian Campbell wrote:
>> On Fri, 2014-10-03 at 17:05 +0200, Hans de Goede wrote:
>>> diff --git a/configs/Mele_M3_defconfig b/configs/Mele_M3_defconfig
>>> index 645b236..50979e2 100644
>>> --- a/configs/Mele_M3_defconfig
>>> +++ b/configs/Mele_M3_defconfig
>>> @@ -1,5 +1,7 @@
>>>  CONFIG_SPL=y
>>>  CONFIG_SYS_EXTRA_OPTIONS="MELE_M3,AXP209_POWER,SUNXI_GMAC,USB_EHCI"
>>>  CONFIG_FDTFILE="sun7i-a20-m3.dtb"
>>> ++S:CONFIG_MMC_SUNXI_SLOT_EXTRA=2
>>
>> This one is +S (regular+SPL) while the other two are just S (regular
>> only). Is that deliberate?
> 
> Sorry, I should have read the commit message more carefully as you
> explained it quite clearly there!
> 
> This patch looks good, except insofar as some of my comments on earlier
> patches could result in it looking completely different, sorry about
> that!

Heh, no worries. I'll try to do a v2 today addressing all your concerns.

Regards,

Hans
diff mbox

Patch

diff --git a/configs/A10s-OLinuXino-M_defconfig b/configs/A10s-OLinuXino-M_defconfig
index a578c06..f1b2d3b 100644
--- a/configs/A10s-OLinuXino-M_defconfig
+++ b/configs/A10s-OLinuXino-M_defconfig
@@ -1,5 +1,8 @@ 
 CONFIG_SPL=y
 CONFIG_SYS_EXTRA_OPTIONS="A10S_OLINUXINO_M,AXP152_POWER,SUNXI_EMAC,USB_EHCI,SUNXI_USB_VBUS0_GPIO=SUNXI_GPB(10)"
 CONFIG_FDTFILE="sun5i-a10s-olinuxino-micro.dtb"
+CONFIG_MMC_SUNXI_SLOT_EXTRA=1
++S:CONFIG_MMC0_CD_PIN=193
++S:CONFIG_MMC1_CD_PIN=205
 +S:CONFIG_ARM=y
 +S:CONFIG_TARGET_SUN5I=y
diff --git a/configs/A20-OLinuXino_MICRO_defconfig b/configs/A20-OLinuXino_MICRO_defconfig
index 20a947c..17756f5 100644
--- a/configs/A20-OLinuXino_MICRO_defconfig
+++ b/configs/A20-OLinuXino_MICRO_defconfig
@@ -1,5 +1,8 @@ 
 CONFIG_SPL=y
 CONFIG_SYS_EXTRA_OPTIONS="A20_OLINUXINO_M,AXP209_POWER,SUNXI_GMAC,AHCI,SATAPWR=SUNXI_GPB(8),USB_EHCI"
 CONFIG_FDTFILE="sun7i-a20-olinuxino-micro.dtb"
+CONFIG_MMC_SUNXI_SLOT_EXTRA=3
++S:CONFIG_MMC0_CD_PIN=225
++S:CONFIG_MMC3_CD_PIN=235
 +S:CONFIG_ARM=y
 +S:CONFIG_TARGET_SUN7I=y
diff --git a/configs/Mele_M3_defconfig b/configs/Mele_M3_defconfig
index 645b236..50979e2 100644
--- a/configs/Mele_M3_defconfig
+++ b/configs/Mele_M3_defconfig
@@ -1,5 +1,7 @@ 
 CONFIG_SPL=y
 CONFIG_SYS_EXTRA_OPTIONS="MELE_M3,AXP209_POWER,SUNXI_GMAC,USB_EHCI"
 CONFIG_FDTFILE="sun7i-a20-m3.dtb"
++S:CONFIG_MMC_SUNXI_SLOT_EXTRA=2
++S:CONFIG_MMC0_CD_PIN=225
 +S:CONFIG_ARM=y
 +S:CONFIG_TARGET_SUN7I=y