Re: [PATCH v2 2/2] kconfig: allow use of relations other than (in)equality

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2015-01-16 16:44, Jan Beulich wrote:
> Over the years I found it desirable to be able to use all sorts of
> relations, not just (in)equality. And apparently I'm not the only one,
> as there's at least one example in the tree where the programmer
> assumed this would work (see DEBUG_UART_8250_WORD in
> arch/arm/Kconfig.debug). Another possibly use would e.g. be to fold the
> two SMP/NR_CPUS prompt into one: SMP could be promptless, simply
> depending on NR_CPUS > 1.

Nice.


> A (desirable) side effect of this change - resulting from numeric
> values now necessarily being compared as numbers rather than as
> strings - is that comparing hex values now works as expected: Other
> than int ones (which aren't allowed to have leading zeroes), zeroes
> following the 0x prefix made them compare unequal even if their values
> were equal.
> 
> Question: Should "<>" and/or "==" then perhaps also be permitted?

Maybe == for the similarity with C expressions, but certainly not <>.


> 
> Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
> ---
> v2: Drop stray debugging printf()s.
> ---
>  scripts/kconfig/expr.c              |  167 ++++++++++-
>  scripts/kconfig/expr.h              |    4 
>  scripts/kconfig/symbol.c            |    4 
>  scripts/kconfig/zconf.l             |    4 
>  scripts/kconfig/zconf.lex.c_shipped |  291 +++++++++++--------
>  scripts/kconfig/zconf.tab.c_shipped |  524 +++++++++++++++++++-----------------

Can you please split it into two patches, first patching the human
readable files and then the generated files?

Thanks,
Michal
--
To unsubscribe from this list: send the line "unsubscribe linux-kbuild" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux&nblp;USB Development]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite Secrets]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux