2014-10-15 15:25:29

by Aristeu Rozanski

[permalink] [raw]
Subject: [PATCH] tiny: reverse logic for DISABLE_DEV_COREDUMP

It's desirable for allnconfig and tinyconfig targets to result in the
least amount of code possible. DISABLE_DEV_COREDUMP exists as a way to
switch off DEV_COREDUMP regardless if any drivers select
WANT_DEV_COREDUMP.

This patch renames the option to ENABLE_DEV_COREDUMP and setting it to
'n' (as in allnconfig or tinyconfig) will effectively disable device
coredump.

Cc: Greg Kroah-Hartman <[email protected]>
Cc: Josh Triplett <[email protected]>
Reviewed-by: Josh Triplett <[email protected]>
Signed-off-by: Aristeu Rozanski <[email protected]>

diff --git a/drivers/base/Kconfig b/drivers/base/Kconfig
index 134f763..63a5702 100644
--- a/drivers/base/Kconfig
+++ b/drivers/base/Kconfig
@@ -171,20 +171,23 @@ config WANT_DEV_COREDUMP
Drivers should "select" this option if they desire to use the
device coredump mechanism.

-config DISABLE_DEV_COREDUMP
- bool "Disable device coredump" if EXPERT
+config ENABLE_DEV_COREDUMP
+ bool "Enable device coredump" if EXPERT
+ default y
help
- Disable the device coredump mechanism despite drivers wanting to
- use it; this allows for more sensitive systems or systems that
- don't want to ever access the information to not have the code,
- nor keep any data.
+ This option controls if the device coredump mechanism is available or
+ not; if disabled, the mechanism will be omitted even if drivers that
+ can use it are enabled.
+ Say 'N' for more sensitive systems or systems that don't want
+ to ever access the information to not have the code, nor keep any
+ data.

- If unsure, say N.
+ If unsure, say Y.

config DEV_COREDUMP
bool
default y if WANT_DEV_COREDUMP
- depends on !DISABLE_DEV_COREDUMP
+ depends on ENABLE_DEV_COREDUMP

config DEBUG_DRIVER
bool "Driver Core verbose debug messages"


2014-10-15 23:15:51

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH] tiny: reverse logic for DISABLE_DEV_COREDUMP

On Wed, Oct 15, 2014 at 11:25:23AM -0400, Aristeu Rozanski wrote:
> It's desirable for allnconfig and tinyconfig targets to result in the
> least amount of code possible. DISABLE_DEV_COREDUMP exists as a way to
> switch off DEV_COREDUMP regardless if any drivers select
> WANT_DEV_COREDUMP.
>
> This patch renames the option to ENABLE_DEV_COREDUMP and setting it to
> 'n' (as in allnconfig or tinyconfig) will effectively disable device
> coredump.
>
> Cc: Greg Kroah-Hartman <[email protected]>
> Cc: Josh Triplett <[email protected]>
> Reviewed-by: Josh Triplett <[email protected]>
> Signed-off-by: Aristeu Rozanski <[email protected]>

Any reason you didn't cc: the author of this feature / Kconfig option
about this change you are proposing?

Please resend it with the maintainer of this code in the distribution
list.

greg k-h

2014-10-16 03:52:09

by Josh Triplett

[permalink] [raw]
Subject: Re: [PATCH] tiny: reverse logic for DISABLE_DEV_COREDUMP

On Thu, Oct 16, 2014 at 01:14:46AM +0200, Greg Kroah-Hartman wrote:
> On Wed, Oct 15, 2014 at 11:25:23AM -0400, Aristeu Rozanski wrote:
> > It's desirable for allnconfig and tinyconfig targets to result in the
> > least amount of code possible. DISABLE_DEV_COREDUMP exists as a way to
> > switch off DEV_COREDUMP regardless if any drivers select
> > WANT_DEV_COREDUMP.
> >
> > This patch renames the option to ENABLE_DEV_COREDUMP and setting it to
> > 'n' (as in allnconfig or tinyconfig) will effectively disable device
> > coredump.
> >
> > Cc: Greg Kroah-Hartman <[email protected]>
> > Cc: Josh Triplett <[email protected]>
> > Reviewed-by: Josh Triplett <[email protected]>
> > Signed-off-by: Aristeu Rozanski <[email protected]>
>
> Any reason you didn't cc: the author of this feature / Kconfig option
> about this change you are proposing?

Likely my fault; I'd suggested using get_maintainer.pl, which does not
show that for this patch:

~/src/linux$ scripts/get_maintainer.pl < /tmp/patch
Greg Kroah-Hartman <[email protected]> (supporter:DRIVER CORE, KOBJ...)
[email protected] (open list)

2014-10-16 10:24:14

by Josh Triplett

[permalink] [raw]
Subject: Re: [PATCH] tiny: reverse logic for DISABLE_DEV_COREDUMP

On Thu, Oct 16, 2014 at 12:18:43PM +0200, Greg Kroah-Hartman wrote:
> On Thu, Oct 16, 2014 at 05:51:58AM +0200, Josh Triplett wrote:
> > On Thu, Oct 16, 2014 at 01:14:46AM +0200, Greg Kroah-Hartman wrote:
> > > On Wed, Oct 15, 2014 at 11:25:23AM -0400, Aristeu Rozanski wrote:
> > > > It's desirable for allnconfig and tinyconfig targets to result in the
> > > > least amount of code possible. DISABLE_DEV_COREDUMP exists as a way to
> > > > switch off DEV_COREDUMP regardless if any drivers select
> > > > WANT_DEV_COREDUMP.
> > > >
> > > > This patch renames the option to ENABLE_DEV_COREDUMP and setting it to
> > > > 'n' (as in allnconfig or tinyconfig) will effectively disable device
> > > > coredump.
> > > >
> > > > Cc: Greg Kroah-Hartman <[email protected]>
> > > > Cc: Josh Triplett <[email protected]>
> > > > Reviewed-by: Josh Triplett <[email protected]>
> > > > Signed-off-by: Aristeu Rozanski <[email protected]>
> > >
> > > Any reason you didn't cc: the author of this feature / Kconfig option
> > > about this change you are proposing?
> >
> > Likely my fault; I'd suggested using get_maintainer.pl, which does not
> > show that for this patch:
> >
> > ~/src/linux$ scripts/get_maintainer.pl < /tmp/patch
> > Greg Kroah-Hartman <[email protected]> (supporter:DRIVER CORE, KOBJ...)
> > [email protected] (open list)
>
> Yes, as that's just the Kconfig file, but at least let the person who
> wrote that entry a chance to review it, that's just "being nice" :)

I agree; I'm just saying blame me rather than Aristeu. :)

- Josh Triplett

2014-10-16 10:33:50

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH] tiny: reverse logic for DISABLE_DEV_COREDUMP

On Thu, Oct 16, 2014 at 05:51:58AM +0200, Josh Triplett wrote:
> On Thu, Oct 16, 2014 at 01:14:46AM +0200, Greg Kroah-Hartman wrote:
> > On Wed, Oct 15, 2014 at 11:25:23AM -0400, Aristeu Rozanski wrote:
> > > It's desirable for allnconfig and tinyconfig targets to result in the
> > > least amount of code possible. DISABLE_DEV_COREDUMP exists as a way to
> > > switch off DEV_COREDUMP regardless if any drivers select
> > > WANT_DEV_COREDUMP.
> > >
> > > This patch renames the option to ENABLE_DEV_COREDUMP and setting it to
> > > 'n' (as in allnconfig or tinyconfig) will effectively disable device
> > > coredump.
> > >
> > > Cc: Greg Kroah-Hartman <[email protected]>
> > > Cc: Josh Triplett <[email protected]>
> > > Reviewed-by: Josh Triplett <[email protected]>
> > > Signed-off-by: Aristeu Rozanski <[email protected]>
> >
> > Any reason you didn't cc: the author of this feature / Kconfig option
> > about this change you are proposing?
>
> Likely my fault; I'd suggested using get_maintainer.pl, which does not
> show that for this patch:
>
> ~/src/linux$ scripts/get_maintainer.pl < /tmp/patch
> Greg Kroah-Hartman <[email protected]> (supporter:DRIVER CORE, KOBJ...)
> [email protected] (open list)

Yes, as that's just the Kconfig file, but at least let the person who
wrote that entry a chance to review it, that's just "being nice" :)

thanks,

greg k-h

2014-10-16 13:02:40

by Aristeu Rozanski

[permalink] [raw]
Subject: Re: [PATCH] tiny: reverse logic for DISABLE_DEV_COREDUMP

On Thu, Oct 16, 2014 at 12:24:05PM +0200, Josh Triplett wrote:
> I agree; I'm just saying blame me rather than Aristeu. :)

Thanks Josh, but I should have used my brain and realized it's just the
Kconfig. Will resubmit it shortly.

--
Aristeu