* [RFC/PATCH] mtd: Hide CONFIG_MTD_BLKDEVS from the menu
@ 2013-12-13 13:58 Ezequiel Garcia
2013-12-20 0:47 ` Ezequiel Garcia
2014-01-05 8:46 ` Brian Norris
0 siblings, 2 replies; 8+ messages in thread
From: Ezequiel Garcia @ 2013-12-13 13:58 UTC (permalink / raw)
To: linux-mtd
Cc: Brian Norris, David Woodhouse, Ezequiel Garcia, Artem Bityutskiy
Make this option a hidden one and get a cleaner configuration.
This option just selects a common infrastructure for MTD-based devices
to expose a block interface. There is no point in allowing a separate
enable/disable.
Signed-off-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
---
drivers/mtd/Kconfig | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig
index 5fab4e6e..2a0ca2a 100644
--- a/drivers/mtd/Kconfig
+++ b/drivers/mtd/Kconfig
@@ -158,9 +158,7 @@ config MTD_BCM47XX_PARTS
comment "User Modules And Translation Layers"
config MTD_BLKDEVS
- tristate "Common interface to block layer for MTD 'translation layers'"
- depends on BLOCK
- default n
+ bool
config MTD_BLOCK
tristate "Caching block device access to MTD devices"
--
1.8.1.5
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [RFC/PATCH] mtd: Hide CONFIG_MTD_BLKDEVS from the menu
2013-12-13 13:58 [RFC/PATCH] mtd: Hide CONFIG_MTD_BLKDEVS from the menu Ezequiel Garcia
@ 2013-12-20 0:47 ` Ezequiel Garcia
2013-12-20 2:05 ` Brian Norris
2014-01-05 8:46 ` Brian Norris
1 sibling, 1 reply; 8+ messages in thread
From: Ezequiel Garcia @ 2013-12-20 0:47 UTC (permalink / raw)
To: linux-mtd; +Cc: Brian Norris, David Woodhouse, Artem Bityutskiy
On Fri, Dec 13, 2013 at 10:58:44AM -0300, Ezequiel Garcia wrote:
> Make this option a hidden one and get a cleaner configuration.
> This option just selects a common infrastructure for MTD-based devices
> to expose a block interface. There is no point in allowing a separate
> enable/disable.
>
> Signed-off-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
> ---
> drivers/mtd/Kconfig | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig
> index 5fab4e6e..2a0ca2a 100644
> --- a/drivers/mtd/Kconfig
> +++ b/drivers/mtd/Kconfig
> @@ -158,9 +158,7 @@ config MTD_BCM47XX_PARTS
> comment "User Modules And Translation Layers"
>
> config MTD_BLKDEVS
> - tristate "Common interface to block layer for MTD 'translation layers'"
> - depends on BLOCK
> - default n
> + bool
>
> config MTD_BLOCK
> tristate "Caching block device access to MTD devices"
> --
> 1.8.1.5
>
Any comments on this one?
--
Ezequiel García, Free Electrons
Embedded Linux, Kernel and Android Engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [RFC/PATCH] mtd: Hide CONFIG_MTD_BLKDEVS from the menu
2013-12-20 0:47 ` Ezequiel Garcia
@ 2013-12-20 2:05 ` Brian Norris
2013-12-20 18:17 ` Ezequiel Garcia
0 siblings, 1 reply; 8+ messages in thread
From: Brian Norris @ 2013-12-20 2:05 UTC (permalink / raw)
To: Ezequiel Garcia; +Cc: David Woodhouse, linux-mtd, Artem Bityutskiy
On Thu, Dec 19, 2013 at 09:47:13PM -0300, Ezequiel Garcia wrote:
> On Fri, Dec 13, 2013 at 10:58:44AM -0300, Ezequiel Garcia wrote:
> > Make this option a hidden one and get a cleaner configuration.
> > This option just selects a common infrastructure for MTD-based devices
> > to expose a block interface. There is no point in allowing a separate
> > enable/disable.
> >
> > Signed-off-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
> > ---
> > drivers/mtd/Kconfig | 4 +---
> > 1 file changed, 1 insertion(+), 3 deletions(-)
> >
> > diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig
> > index 5fab4e6e..2a0ca2a 100644
> > --- a/drivers/mtd/Kconfig
> > +++ b/drivers/mtd/Kconfig
> > @@ -158,9 +158,7 @@ config MTD_BCM47XX_PARTS
> > comment "User Modules And Translation Layers"
> >
> > config MTD_BLKDEVS
> > - tristate "Common interface to block layer for MTD 'translation layers'"
> > - depends on BLOCK
> > - default n
> > + bool
> >
> > config MTD_BLOCK
> > tristate "Caching block device access to MTD devices"
>
> Any comments on this one?
It looks OK to me. I might add a comment above MTD_BLKDEVS like I see in
some other similar Kconfig not-user-selectable options:
#
# MTD block device support is select'ed if needed
#
Brian
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [RFC/PATCH] mtd: Hide CONFIG_MTD_BLKDEVS from the menu
2013-12-20 2:05 ` Brian Norris
@ 2013-12-20 18:17 ` Ezequiel Garcia
2014-01-03 19:48 ` Brian Norris
0 siblings, 1 reply; 8+ messages in thread
From: Ezequiel Garcia @ 2013-12-20 18:17 UTC (permalink / raw)
To: Brian Norris; +Cc: linux-mtd, David Woodhouse, Artem Bityutskiy
On Thu, Dec 19, 2013 at 06:05:18PM -0800, Brian Norris wrote:
> On Thu, Dec 19, 2013 at 09:47:13PM -0300, Ezequiel Garcia wrote:
> > On Fri, Dec 13, 2013 at 10:58:44AM -0300, Ezequiel Garcia wrote:
> > > Make this option a hidden one and get a cleaner configuration.
> > > This option just selects a common infrastructure for MTD-based devices
> > > to expose a block interface. There is no point in allowing a separate
> > > enable/disable.
> > >
> > > Signed-off-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
> > > ---
> > > drivers/mtd/Kconfig | 4 +---
> > > 1 file changed, 1 insertion(+), 3 deletions(-)
> > >
> > > diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig
> > > index 5fab4e6e..2a0ca2a 100644
> > > --- a/drivers/mtd/Kconfig
> > > +++ b/drivers/mtd/Kconfig
> > > @@ -158,9 +158,7 @@ config MTD_BCM47XX_PARTS
> > > comment "User Modules And Translation Layers"
> > >
> > > config MTD_BLKDEVS
> > > - tristate "Common interface to block layer for MTD 'translation layers'"
> > > - depends on BLOCK
> > > - default n
> > > + bool
> > >
> > > config MTD_BLOCK
> > > tristate "Caching block device access to MTD devices"
> >
> > Any comments on this one?
>
> It looks OK to me. I might add a comment above MTD_BLKDEVS like I see in
> some other similar Kconfig not-user-selectable options:
>
> #
> # MTD block device support is select'ed if needed
> #
>
Fully agreed.
--
Ezequiel García, Free Electrons
Embedded Linux, Kernel and Android Engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [RFC/PATCH] mtd: Hide CONFIG_MTD_BLKDEVS from the menu
2013-12-20 18:17 ` Ezequiel Garcia
@ 2014-01-03 19:48 ` Brian Norris
0 siblings, 0 replies; 8+ messages in thread
From: Brian Norris @ 2014-01-03 19:48 UTC (permalink / raw)
To: Ezequiel Garcia; +Cc: linux-mtd, David Woodhouse, Artem Bityutskiy
On Fri, Dec 20, 2013 at 03:17:58PM -0300, Ezequiel Garcia wrote:
> On Thu, Dec 19, 2013 at 06:05:18PM -0800, Brian Norris wrote:
> > On Thu, Dec 19, 2013 at 09:47:13PM -0300, Ezequiel Garcia wrote:
> > > Any comments on this one?
> >
> > It looks OK to me. I might add a comment above MTD_BLKDEVS like I see in
> > some other similar Kconfig not-user-selectable options:
> >
> > #
> > # MTD block device support is select'ed if needed
> > #
> >
>
> Fully agreed.
Since I didn't receive a follow-up, I just added the comment and pushed
to l2-mtd.git. Diff pasted below.
Thanks,
Brian
diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig
index 5fab4e6e8301..cdaa4e512c97 100644
--- a/drivers/mtd/Kconfig
+++ b/drivers/mtd/Kconfig
@@ -157,10 +157,11 @@ config MTD_BCM47XX_PARTS
comment "User Modules And Translation Layers"
+#
+# MTD block device support is select'ed if needed
+#
config MTD_BLKDEVS
- tristate "Common interface to block layer for MTD 'translation layers'"
- depends on BLOCK
- default n
+ bool
config MTD_BLOCK
tristate "Caching block device access to MTD devices"
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [RFC/PATCH] mtd: Hide CONFIG_MTD_BLKDEVS from the menu
2013-12-13 13:58 [RFC/PATCH] mtd: Hide CONFIG_MTD_BLKDEVS from the menu Ezequiel Garcia
2013-12-20 0:47 ` Ezequiel Garcia
@ 2014-01-05 8:46 ` Brian Norris
2014-01-05 17:37 ` Ezequiel Garcia
1 sibling, 1 reply; 8+ messages in thread
From: Brian Norris @ 2014-01-05 8:46 UTC (permalink / raw)
To: Ezequiel Garcia; +Cc: David Woodhouse, linux-mtd, Artem Bityutskiy
Hi Ezequiel,
On Fri, Dec 13, 2013 at 10:58:44AM -0300, Ezequiel Garcia wrote:
> Make this option a hidden one and get a cleaner configuration.
> This option just selects a common infrastructure for MTD-based devices
> to expose a block interface. There is no point in allowing a separate
> enable/disable.
>
> Signed-off-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com>
> ---
> drivers/mtd/Kconfig | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig
> index 5fab4e6e..2a0ca2a 100644
> --- a/drivers/mtd/Kconfig
> +++ b/drivers/mtd/Kconfig
> @@ -158,9 +158,7 @@ config MTD_BCM47XX_PARTS
> comment "User Modules And Translation Layers"
>
> config MTD_BLKDEVS
> - tristate "Common interface to block layer for MTD 'translation layers'"
> - depends on BLOCK
> - default n
> + bool
>
> config MTD_BLOCK
> tristate "Caching block device access to MTD devices"
Hmm, I'm seeing some issues with this patch. I think it's problematic
that you are changing MTD_BLKDEVS from tristate to bool. We can't have
MTD_BLKDEVS built into the kernel while MTD itself is built as a module.
This manifests in linker errors in my all-module builds, with .config
like this (note that MTD_BLKDEVS gets "select"ed by MTD_SWAP, which
forces it to be built-in, not built as a module):
CONFIG_MTD=m
CONFIG_MTD_BLKDEVS=y
CONFIG_MTD_SWAP=m
[...]
Building modules, stage 2.
MODPOST 14 modules
ERROR: "deregister_mtd_blktrans" [drivers/mtd/mtdswap.ko] undefined!
ERROR: "register_mtd_blktrans" [drivers/mtd/mtdswap.ko] undefined!
ERROR: "add_mtd_blktrans_dev" [drivers/mtd/mtdswap.ko] undefined!
ERROR: "mtd_blktrans_cease_background" [drivers/mtd/mtdswap.ko] undefined!
ERROR: "del_mtd_blktrans_dev" [drivers/mtd/mtdswap.ko] undefined!
make[1]: *** [__modpost] Error 1
make: *** [modules] Error 2
I believe the correct solution would be the following additional diff:
diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig
index cdaa4e512c97..5ebcda39f554 100644
--- a/drivers/mtd/Kconfig
+++ b/drivers/mtd/Kconfig
@@ -161,7 +161,7 @@ comment "User Modules And Translation Layers"
# MTD block device support is select'ed if needed
#
config MTD_BLKDEVS
- bool
+ tristate
config MTD_BLOCK
tristate "Caching block device access to MTD devices"
--
I'll squash this into your patch if I don't hear any objections.
Brian
^ permalink raw reply related [flat|nested] 8+ messages in thread
* Re: [RFC/PATCH] mtd: Hide CONFIG_MTD_BLKDEVS from the menu
2014-01-05 8:46 ` Brian Norris
@ 2014-01-05 17:37 ` Ezequiel Garcia
2014-01-05 22:06 ` Brian Norris
0 siblings, 1 reply; 8+ messages in thread
From: Ezequiel Garcia @ 2014-01-05 17:37 UTC (permalink / raw)
To: Brian Norris; +Cc: David Woodhouse, linux-mtd, Artem Bityutskiy
On Sun, Jan 05, 2014 at 12:46:10AM -0800, Brian Norris wrote:
>
> Hmm, I'm seeing some issues with this patch. I think it's problematic
> that you are changing MTD_BLKDEVS from tristate to bool. We can't have
[..]
>
> I believe the correct solution would be the following additional diff:
>
> diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig
> index cdaa4e512c97..5ebcda39f554 100644
> --- a/drivers/mtd/Kconfig
> +++ b/drivers/mtd/Kconfig
> @@ -161,7 +161,7 @@ comment "User Modules And Translation Layers"
> # MTD block device support is select'ed if needed
> #
> config MTD_BLKDEVS
> - bool
> + tristate
>
> config MTD_BLOCK
> tristate "Caching block device access to MTD devices"
> --
>
> I'll squash this into your patch if I don't hear any objections.
>
The solution looks fine. Thanks for taking care of it.
--
Ezequiel García, Free Electrons
Embedded Linux, Kernel and Android Engineering
http://free-electrons.com
^ permalink raw reply [flat|nested] 8+ messages in thread
* Re: [RFC/PATCH] mtd: Hide CONFIG_MTD_BLKDEVS from the menu
2014-01-05 17:37 ` Ezequiel Garcia
@ 2014-01-05 22:06 ` Brian Norris
0 siblings, 0 replies; 8+ messages in thread
From: Brian Norris @ 2014-01-05 22:06 UTC (permalink / raw)
To: Ezequiel Garcia; +Cc: David Woodhouse, linux-mtd, Artem Bityutskiy
On Sun, Jan 05, 2014 at 02:37:57PM -0300, Ezequiel Garcia wrote:
> On Sun, Jan 05, 2014 at 12:46:10AM -0800, Brian Norris wrote:
> >
> > Hmm, I'm seeing some issues with this patch. I think it's problematic
> > that you are changing MTD_BLKDEVS from tristate to bool. We can't have
> [..]
> >
> > I believe the correct solution would be the following additional diff:
> >
> > diff --git a/drivers/mtd/Kconfig b/drivers/mtd/Kconfig
> > index cdaa4e512c97..5ebcda39f554 100644
> > --- a/drivers/mtd/Kconfig
> > +++ b/drivers/mtd/Kconfig
> > @@ -161,7 +161,7 @@ comment "User Modules And Translation Layers"
> > # MTD block device support is select'ed if needed
> > #
> > config MTD_BLKDEVS
> > - bool
> > + tristate
> >
> > config MTD_BLOCK
> > tristate "Caching block device access to MTD devices"
> > --
> >
> > I'll squash this into your patch if I don't hear any objections.
> >
>
> The solution looks fine. Thanks for taking care of it.
OK, squahsed and pushed to l2-mtd.git.
Brian
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2014-01-05 22:06 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-12-13 13:58 [RFC/PATCH] mtd: Hide CONFIG_MTD_BLKDEVS from the menu Ezequiel Garcia
2013-12-20 0:47 ` Ezequiel Garcia
2013-12-20 2:05 ` Brian Norris
2013-12-20 18:17 ` Ezequiel Garcia
2014-01-03 19:48 ` Brian Norris
2014-01-05 8:46 ` Brian Norris
2014-01-05 17:37 ` Ezequiel Garcia
2014-01-05 22:06 ` Brian Norris
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.