diff mbox series

[U-Boot,PATCHv3,2/4] dm: MIGRATION: Add migration plan for DM_USB

Message ID 1543533674-8688-2-git-send-email-trini@konsulko.com
State Accepted
Commit 109d8bf3ac7b9bb04f3c46bb540eb2bb865f3dd7
Delegated to: Tom Rini
Headers show
Series [U-Boot,PATCHv3,1/4] dm: MIGRATION: Add migration plan for DM_MMC | expand

Commit Message

Tom Rini Nov. 29, 2018, 11:21 p.m. UTC
As much of the USB system has been migrated to DM now, formalize a
deadline for migration.

Reviewed-by: Marek Vasut <marex@denx.de>
Reviewed-by: Simon Glass <sjg@chromium.org>
Signed-off-by: Tom Rini <trini@konsulko.com>
---
Changes in v3:
- Ensure CONFIG_USB is set.
Changes in v2:
- Note that failure to migration may lead to removal.
---
 Makefile                       | 10 ++++++++++
 doc/driver-model/MIGRATION.txt | 10 ++++++++++
 2 files changed, 20 insertions(+)

Comments

Tom Rini Dec. 4, 2018, 4:49 a.m. UTC | #1
On Thu, Nov 29, 2018 at 06:21:12PM -0500, Tom Rini wrote:

> As much of the USB system has been migrated to DM now, formalize a
> deadline for migration.
> 
> Reviewed-by: Marek Vasut <marex@denx.de>
> Reviewed-by: Simon Glass <sjg@chromium.org>
> Signed-off-by: Tom Rini <trini@konsulko.com>

Applied to u-boot/master, thanks!
Stefan Roese Dec. 5, 2018, 7:14 a.m. UTC | #2
Hi Tom,

On 04.12.18 05:49, Tom Rini wrote:
> On Thu, Nov 29, 2018 at 06:21:12PM -0500, Tom Rini wrote:
> 
>> As much of the USB system has been migrated to DM now, formalize a
>> deadline for migration.
>>
>> Reviewed-by: Marek Vasut <marex@denx.de>
>> Reviewed-by: Simon Glass <sjg@chromium.org>
>> Signed-off-by: Tom Rini <trini@konsulko.com>
> 
> Applied to u-boot/master, thanks!

Just a quick note on this, since I just tested compiling current
mainline on MVEBU "theadorable_debug". Here I get:

===================== WARNING ======================
This board does not use CONFIG_DM_USB. Please update
the board to use CONFIG_DM_USB before the v2019.07 release.
Failure to update by the deadline may result in board removal.
See doc/driver-model/MIGRATION.txt for more info.
====================================================
===================== WARNING ======================
This board does not use CONFIG_DM_SCSI. Please update
the storage controller to use CONFIG_DM_SCSI before the v2019.07 release.
Failure to update by the deadline may result in board removal.
See doc/driver-model/MIGRATION.txt for more info.
====================================================

The DM_SCSI warning seems to be okay, because of the not converted
ATA driver sata_mv.c (the controller is unfortunately not AHCI
compatible). I hope to find some time shortly to work on this.

But the board definitely uses DM_USB:

$ gg DM_USB configs/theadorable_debug_defconfig
configs/theadorable_debug_defconfig:CONFIG_DM_USB=y

So the DM_USB warning seems to be wrong here.

Thanks,
Stefan
Tom Rini Dec. 5, 2018, 12:23 p.m. UTC | #3
On Wed, Dec 05, 2018 at 08:14:14AM +0100, Stefan Roese wrote:
> Hi Tom,
> 
> On 04.12.18 05:49, Tom Rini wrote:
> >On Thu, Nov 29, 2018 at 06:21:12PM -0500, Tom Rini wrote:
> >
> >>As much of the USB system has been migrated to DM now, formalize a
> >>deadline for migration.
> >>
> >>Reviewed-by: Marek Vasut <marex@denx.de>
> >>Reviewed-by: Simon Glass <sjg@chromium.org>
> >>Signed-off-by: Tom Rini <trini@konsulko.com>
> >
> >Applied to u-boot/master, thanks!
> 
> Just a quick note on this, since I just tested compiling current
> mainline on MVEBU "theadorable_debug". Here I get:
> 
> ===================== WARNING ======================
> This board does not use CONFIG_DM_USB. Please update
> the board to use CONFIG_DM_USB before the v2019.07 release.
> Failure to update by the deadline may result in board removal.
> See doc/driver-model/MIGRATION.txt for more info.
> ====================================================
> ===================== WARNING ======================
> This board does not use CONFIG_DM_SCSI. Please update
> the storage controller to use CONFIG_DM_SCSI before the v2019.07 release.
> Failure to update by the deadline may result in board removal.
> See doc/driver-model/MIGRATION.txt for more info.
> ====================================================
> 
> The DM_SCSI warning seems to be okay, because of the not converted
> ATA driver sata_mv.c (the controller is unfortunately not AHCI
> compatible). I hope to find some time shortly to work on this.
> 
> But the board definitely uses DM_USB:
> 
> $ gg DM_USB configs/theadorable_debug_defconfig
> configs/theadorable_debug_defconfig:CONFIG_DM_USB=y
> 
> So the DM_USB warning seems to be wrong here.

I think you're "stuck" here because you can't turn on CONFIG_BLK to
silence the CONFIG_DM_USB warning without then breaking sata_mv.c.  The
CONFIG_DM_USB migration isn't complete until you're also using
CONFIG_BLK.
Chris Packham Dec. 7, 2018, 12:05 a.m. UTC | #4
On Thu, Dec 6, 2018 at 1:23 AM Tom Rini <trini@konsulko.com> wrote:
>
> On Wed, Dec 05, 2018 at 08:14:14AM +0100, Stefan Roese wrote:
> > Hi Tom,
> >
> > On 04.12.18 05:49, Tom Rini wrote:
> > >On Thu, Nov 29, 2018 at 06:21:12PM -0500, Tom Rini wrote:
> > >
> > >>As much of the USB system has been migrated to DM now, formalize a
> > >>deadline for migration.
> > >>
> > >>Reviewed-by: Marek Vasut <marex@denx.de>
> > >>Reviewed-by: Simon Glass <sjg@chromium.org>
> > >>Signed-off-by: Tom Rini <trini@konsulko.com>
> > >
> > >Applied to u-boot/master, thanks!
> >
> > Just a quick note on this, since I just tested compiling current
> > mainline on MVEBU "theadorable_debug". Here I get:
> >
> > ===================== WARNING ======================
> > This board does not use CONFIG_DM_USB. Please update
> > the board to use CONFIG_DM_USB before the v2019.07 release.
> > Failure to update by the deadline may result in board removal.
> > See doc/driver-model/MIGRATION.txt for more info.
> > ====================================================
> > ===================== WARNING ======================
> > This board does not use CONFIG_DM_SCSI. Please update
> > the storage controller to use CONFIG_DM_SCSI before the v2019.07 release.
> > Failure to update by the deadline may result in board removal.
> > See doc/driver-model/MIGRATION.txt for more info.
> > ====================================================
> >
> > The DM_SCSI warning seems to be okay, because of the not converted
> > ATA driver sata_mv.c (the controller is unfortunately not AHCI
> > compatible). I hope to find some time shortly to work on this.
> >
> > But the board definitely uses DM_USB:
> >
> > $ gg DM_USB configs/theadorable_debug_defconfig
> > configs/theadorable_debug_defconfig:CONFIG_DM_USB=y
> >
> > So the DM_USB warning seems to be wrong here.
>
> I think you're "stuck" here because you can't turn on CONFIG_BLK to
> silence the CONFIG_DM_USB warning without then breaking sata_mv.c.  The
> CONFIG_DM_USB migration isn't complete until you're also using
> CONFIG_BLK.

On a related note. I'm looking at adding a new board and have
CONFIG_DM_USB and CONFIG_USB_STORAGE enabled but I trip over the same
warning. This board doesn't enable SATA so I'm not trapped like the
theadorable boards but enabling CONFIG_BLK just to silence the warning
seems a bit wrong. Am I missing something?
Tom Rini Dec. 7, 2018, 1:19 a.m. UTC | #5
On Fri, Dec 07, 2018 at 01:05:24PM +1300, Chris Packham wrote:
> On Thu, Dec 6, 2018 at 1:23 AM Tom Rini <trini@konsulko.com> wrote:
> >
> > On Wed, Dec 05, 2018 at 08:14:14AM +0100, Stefan Roese wrote:
> > > Hi Tom,
> > >
> > > On 04.12.18 05:49, Tom Rini wrote:
> > > >On Thu, Nov 29, 2018 at 06:21:12PM -0500, Tom Rini wrote:
> > > >
> > > >>As much of the USB system has been migrated to DM now, formalize a
> > > >>deadline for migration.
> > > >>
> > > >>Reviewed-by: Marek Vasut <marex@denx.de>
> > > >>Reviewed-by: Simon Glass <sjg@chromium.org>
> > > >>Signed-off-by: Tom Rini <trini@konsulko.com>
> > > >
> > > >Applied to u-boot/master, thanks!
> > >
> > > Just a quick note on this, since I just tested compiling current
> > > mainline on MVEBU "theadorable_debug". Here I get:
> > >
> > > ===================== WARNING ======================
> > > This board does not use CONFIG_DM_USB. Please update
> > > the board to use CONFIG_DM_USB before the v2019.07 release.
> > > Failure to update by the deadline may result in board removal.
> > > See doc/driver-model/MIGRATION.txt for more info.
> > > ====================================================
> > > ===================== WARNING ======================
> > > This board does not use CONFIG_DM_SCSI. Please update
> > > the storage controller to use CONFIG_DM_SCSI before the v2019.07 release.
> > > Failure to update by the deadline may result in board removal.
> > > See doc/driver-model/MIGRATION.txt for more info.
> > > ====================================================
> > >
> > > The DM_SCSI warning seems to be okay, because of the not converted
> > > ATA driver sata_mv.c (the controller is unfortunately not AHCI
> > > compatible). I hope to find some time shortly to work on this.
> > >
> > > But the board definitely uses DM_USB:
> > >
> > > $ gg DM_USB configs/theadorable_debug_defconfig
> > > configs/theadorable_debug_defconfig:CONFIG_DM_USB=y
> > >
> > > So the DM_USB warning seems to be wrong here.
> >
> > I think you're "stuck" here because you can't turn on CONFIG_BLK to
> > silence the CONFIG_DM_USB warning without then breaking sata_mv.c.  The
> > CONFIG_DM_USB migration isn't complete until you're also using
> > CONFIG_BLK.
> 
> On a related note. I'm looking at adding a new board and have
> CONFIG_DM_USB and CONFIG_USB_STORAGE enabled but I trip over the same
> warning. This board doesn't enable SATA so I'm not trapped like the
> theadorable boards but enabling CONFIG_BLK just to silence the warning
> seems a bit wrong. Am I missing something?

No, enabling CONFIG_BLK is what's needed.  We can't select/depend on it
in all cases that we would like yet but enabling it enables other
functionality.
diff mbox series

Patch

diff --git a/Makefile b/Makefile
index 53046e763e0b..373939ddad94 100644
--- a/Makefile
+++ b/Makefile
@@ -930,6 +930,16 @@  ifneq ($(CONFIG_DM_MMC)$(CONFIG_OF_CONTROL)$(CONFIG_BLK),yyy)
 	@echo "===================================================="
 endif
 endif
+ifeq ($(CONFIG_USB),y)
+ifneq ($(CONFIG_DM_USB)$(CONFIG_OF_CONTROL)$(CONFIG_BLK),yyy)
+	@echo "===================== WARNING ======================"
+	@echo "This board does not use CONFIG_DM_USB. Please update"
+	@echo "the board to use CONFIG_DM_USB before the v2019.07 release."
+	@echo "Failure to update by the deadline may result in board removal."
+	@echo "See doc/driver-model/MIGRATION.txt for more info."
+	@echo "===================================================="
+endif
+endif
 	@# Check that this build does not use CONFIG options that we do not
 	@# know about unless they are in Kconfig. All the existing CONFIG
 	@# options are whitelisted, so new ones should not be added.
diff --git a/doc/driver-model/MIGRATION.txt b/doc/driver-model/MIGRATION.txt
index 71c26571828a..0b763f72a453 100644
--- a/doc/driver-model/MIGRATION.txt
+++ b/doc/driver-model/MIGRATION.txt
@@ -15,6 +15,16 @@  The subsystem itself has been converted and maintainers should submit patches
 switching over to using CONFIG_DM_MMC and other base driver model options in
 time for inclusion in the 2019.04 rerelease.
 
+CONFIG_DM_USB
+-------------
+
+Status: In progress
+Deadline: 2019.07
+
+The subsystem itself has been converted along with many of the host controller
+and maintainers should submit patches switching over to using CONFIG_DM_USB and
+other base driver model options in time for inclusion in the 2019.07 rerelease.
+
 CONFIG_BLK
 ----------