[PATCH] xfree86: remove user-configured AllowEmptyInput

Dan Nicholson dbn.lists at gmail.com
Tue Nov 9 06:34:13 PST 2010


On Mon, Nov 8, 2010 at 9:34 PM, Peter Hutterer <peter.hutterer at who-t.net> wrote:
> An estimated 100% (rounded down to the nearest percent) of those who have
> this in their configuration don't actually know what this option does.
> Protect the users from themselves.
>
> IIRC, AEI on was useful for some time between 1.4 and 1.5 and never since.
>
> Signed-off-by: Peter Hutterer <peter.hutterer at who-t.net>

I'm also seeing this in config/x11-input.fdi, which is probably not helping:

    You will probably want to add the following option to the ServerFlags of
    your xorg.conf:

        Option "AllowEmptyInput" "True"

Can you remove that part, too?

> ---
>  hw/xfree86/common/xf86Config.c       |    3 ---
>  hw/xfree86/doc/man/xorg.conf.man.pre |    9 ---------
>  2 files changed, 0 insertions(+), 12 deletions(-)
>
> diff --git a/hw/xfree86/common/xf86Config.c b/hw/xfree86/common/xf86Config.c
> index e3b2831..59a1429 100644
> --- a/hw/xfree86/common/xf86Config.c
> +++ b/hw/xfree86/common/xf86Config.c
> @@ -742,8 +742,6 @@ static OptionInfoRec FlagOptions[] = {
>        {0}, FALSE },
>   { FLAG_AIGLX,                        "AIGLX",                        OPTV_BOOLEAN,
>        {0}, FALSE },
> -  { FLAG_ALLOW_EMPTY_INPUT,     "AllowEmptyInput",              OPTV_BOOLEAN,
> -        {0}, FALSE },
>   { FLAG_IGNORE_ABI,           "IgnoreABI",                    OPTV_BOOLEAN,
>        {0}, FALSE },
>   { FLAG_USE_DEFAULT_FONT_PATH,  "UseDefaultFontPath",         OPTV_BOOLEAN,
> @@ -956,7 +954,6 @@ configServerFlags(XF86ConfFlagsPtr flagsconf, XF86OptionPtr layoutopts)
>
>     /* AllowEmptyInput is automatically true if we're hotplugging */
>     xf86Info.allowEmptyInput = (xf86Info.autoAddDevices && xf86Info.autoEnableDevices);
> -    xf86GetOptValBool(FlagOptions, FLAG_ALLOW_EMPTY_INPUT, &xf86Info.allowEmptyInput);
>
>     /* AEI on? Then we're not using kbd, so use the evdev rules set. */
>  #if defined(linux)

Later in this file I'm seeing some warnings about use of AEI:

   1441         xf86Msg(X_INFO, "Hotplugging is disabled and no input
devices were configured.\n"
   1442                         "\tTry disabling AllowEmptyInput.\n");

That's probably not useful if the option doesn't exist anymore.

   2356                 if (!warned)
   2357                 {
   2358                     xf86Msg(X_WARNING, "AllowEmptyInput is on,
devices using "
   2359                             "drivers 'kbd', 'mouse' or
'vmmouse' will be disabled.\n");
   2360                     warned = TRUE;
   2361                 }

Not sure how to handle that since checkInput can still act on
xf86Info.allowEmptyInput = (xf86Info.autoAddDevices &&
xf86Info.autoEnableDevices). AllowEmptyInput the option is not on, but
the equivalent action is. Maybe it should say "Hotplugging is enabled"
or something.

It might be nice in a future patch to get rid of allowEmptyInput and
just query autoAddDevices && autoEnableDevices in the one spot it's
needed (checkInput).

--
Dan


More information about the xorg-devel mailing list