<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/scripts/kconfig, branch linux-4.16.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.</subtitle>
<id>https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-4.16.y</id>
<link rel='self' href='https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-4.16.y'/>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/'/>
<updated>2018-06-11T20:48:14Z</updated>
<entry>
<title>kconfig: Avoid format overflow warning from GCC 8.1</title>
<updated>2018-06-11T20:48:14Z</updated>
<author>
<name>Nathan Chancellor</name>
<email>natechancellor@gmail.com</email>
</author>
<published>2018-06-02T16:02:09Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=2d89dd3c4f2553135d781bdd78dd7106d2d92954'/>
<id>urn:sha1:2d89dd3c4f2553135d781bdd78dd7106d2d92954</id>
<content type='text'>
commit 2ae89c7a82ea9d81a19b4fc2df23bef4b112f24e upstream.

In file included from scripts/kconfig/zconf.tab.c:2485:
scripts/kconfig/confdata.c: In function ‘conf_write’:
scripts/kconfig/confdata.c:773:22: warning: ‘%s’ directive writing likely 7 or more bytes into a region of size between 1 and 4097 [-Wformat-overflow=]
  sprintf(newname, "%s%s", dirname, basename);
                      ^~
scripts/kconfig/confdata.c:773:19: note: assuming directive output of 7 bytes
  sprintf(newname, "%s%s", dirname, basename);
                   ^~~~~~
scripts/kconfig/confdata.c:773:2: note: ‘sprintf’ output 1 or more bytes (assuming 4104) into a destination of size 4097
  sprintf(newname, "%s%s", dirname, basename);
  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
scripts/kconfig/confdata.c:776:23: warning: ‘.tmpconfig.’ directive writing 11 bytes into a region of size between 1 and 4097 [-Wformat-overflow=]
   sprintf(tmpname, "%s.tmpconfig.%d", dirname, (int)getpid());
                       ^~~~~~~~~~~
scripts/kconfig/confdata.c:776:3: note: ‘sprintf’ output between 13 and 4119 bytes into a destination of size 4097
   sprintf(tmpname, "%s.tmpconfig.%d", dirname, (int)getpid());
   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Increase the size of tmpname and newname to make GCC happy.

Signed-off-by: Nathan Chancellor &lt;natechancellor@gmail.com&gt;
Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>kconfig: fix line number in recursive inclusion error message</title>
<updated>2018-03-02T15:44:47Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>yamada.masahiro@socionext.com</email>
</author>
<published>2018-03-02T07:05:12Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=5ae6fcc4bb82bd05996cc685b8786c586637e56d'/>
<id>urn:sha1:5ae6fcc4bb82bd05996cc685b8786c586637e56d</id>
<content type='text'>
When recursive inclusion is detected, the line number of the last
'included from:' is wrong.

[Test Case]

Kconfig:
  --------&gt;8--------
  source "Kconfig2"
  --------&gt;8--------

Kconfig2:
  --------&gt;8--------
  source "Kconfig3"
  --------&gt;8--------

Kconfig3:
  --------&gt;8--------
  source "Kconfig"
  --------&gt;8--------

[Result]

  $ make allyesconfig
  scripts/kconfig/conf  --allyesconfig Kconfig
  Kconfig:1: recursive inclusion detected. Inclusion path:
    current file : 'Kconfig'
    included from: 'Kconfig3:1'
    included from: 'Kconfig2:1'
    included from: 'Kconfig:3'
  scripts/kconfig/Makefile:89: recipe for target 'allyesconfig' failed
  make[1]: *** [allyesconfig] Error 1
  Makefile:512: recipe for target 'allyesconfig' failed
  make: *** [allyesconfig] Error 2

where we expect

    current file : 'Kconfig'
    included from: 'Kconfig3:1'
    included from: 'Kconfig2:1'
    included from: 'Kconfig:1'

The 'iter-&gt;lineno+1' in the second fpinrtf() should be 'iter-&gt;lineno-1'.
I refactored the code to merge the two fprintf() calls.

Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
Reviewed-by: Ulf Magnusson &lt;ulfalizer@gmail.com&gt;
</content>
</entry>
<entry>
<title>kconfig: Update ncurses package names for menuconfig</title>
<updated>2018-03-02T00:20:57Z</updated>
<author>
<name>Arvind Prasanna</name>
<email>arvindprasanna@gmail.com</email>
</author>
<published>2018-02-28T21:32:19Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=1a90ce36c6eff6fe989eabf0516beb12fc59e067'/>
<id>urn:sha1:1a90ce36c6eff6fe989eabf0516beb12fc59e067</id>
<content type='text'>
The package name is ncurses-devel for Redhat based distros
and libncurses-dev for Debian based distros.

Signed-off-by: Arvind Prasanna &lt;arvindprasanna@gmail.com&gt;
Acked-by: Randy Dunlap &lt;rdunlap@infradead.org&gt;
Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
</content>
</entry>
<entry>
<title>kconfig: Don't leak choice names during parsing</title>
<updated>2018-03-02T00:20:55Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>yamada.masahiro@socionext.com</email>
</author>
<published>2018-02-20T11:40:29Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=bf0bbdcf1003220b7ca9a6aa00a84e27e94287e8'/>
<id>urn:sha1:bf0bbdcf1003220b7ca9a6aa00a84e27e94287e8</id>
<content type='text'>
The named choice is not used in the kernel tree, but if it were used,
it would not be freed.

The intention of the named choice can be seen in the log of
commit 5a1aa8a1aff6 ("kconfig: add named choice group").

Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
Reviewed-by: Ulf Magnusson &lt;ulfalizer@gmail.com&gt;
</content>
</entry>
<entry>
<title>kconfig: set SYMBOL_AUTO to the symbol marked with defconfig_list</title>
<updated>2018-03-02T00:20:44Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>yamada.masahiro@socionext.com</email>
</author>
<published>2018-02-16T18:38:32Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=f4bc1eefc1608e9a7d40f5fdfc3acd560ba6f477'/>
<id>urn:sha1:f4bc1eefc1608e9a7d40f5fdfc3acd560ba6f477</id>
<content type='text'>
The 'defconfig_list' is a weird attribute.  If the '.config' is
missing, conf_read_simple() iterates over all visible defaults,
then it uses the first one for which fopen() succeeds.

config DEFCONFIG_LIST
	string
	depends on !UML
	option defconfig_list
	default "/lib/modules/$UNAME_RELEASE/.config"
	default "/etc/kernel-config"
	default "/boot/config-$UNAME_RELEASE"
	default "$ARCH_DEFCONFIG"
	default "arch/$ARCH/defconfig"

However, like other symbols, the first visible default is always
written out to the .config file.  This might be different from what
has been actually used.

For example, on my machine, the third one "/boot/config-$UNAME_RELEASE"
is opened, like follows:

  $ rm .config
  $ make oldconfig 2&gt;/dev/null
  scripts/kconfig/conf  --oldconfig Kconfig
  #
  # using defaults found in /boot/config-4.4.0-112-generic
  #
  *
  * Restart config...
  *
  *
  * IRQ subsystem
  *
  Expose irq internals in debugfs (GENERIC_IRQ_DEBUGFS) [N/y/?] (NEW)

However, the resulted .config file contains the first one since it is
visible:

  $ grep CONFIG_DEFCONFIG_LIST .config
  CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config"

In order to stop confusing people, prevent this CONFIG option from
being written to the .config file.

Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
Reviewed-by: Ulf Magnusson &lt;ulfalizer@gmail.com&gt;
</content>
</entry>
<entry>
<title>kconfig: add xstrdup() helper</title>
<updated>2018-03-01T15:26:47Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>yamada.masahiro@socionext.com</email>
</author>
<published>2018-02-16T18:38:31Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=cd81fc82b93fa408c30e08f59e5ef8caaa91d1d2'/>
<id>urn:sha1:cd81fc82b93fa408c30e08f59e5ef8caaa91d1d2</id>
<content type='text'>
We already have xmalloc(), xcalloc(), and xrealloc(().  Add xstrdup()
as well to save tedious error handling.

Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
</content>
</entry>
<entry>
<title>kconfig: remove const qualifier from sym_expand_string_value()</title>
<updated>2018-02-10T02:31:49Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>yamada.masahiro@socionext.com</email>
</author>
<published>2018-02-08T16:19:08Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=523ca58b7db2e30e3c185a7927dd80a30c1bc743'/>
<id>urn:sha1:523ca58b7db2e30e3c185a7927dd80a30c1bc743</id>
<content type='text'>
This function returns realloc'ed memory, so the returned pointer
must be passed to free() when done.  So, 'const' qualifier is odd.
It is allowed to modify the expanded string.

Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
</content>
</entry>
<entry>
<title>kconfig: add xrealloc() helper</title>
<updated>2018-02-10T02:26:04Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>yamada.masahiro@socionext.com</email>
</author>
<published>2018-02-08T16:19:07Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=d717f24d8c68081caae2374cf5ea6c4e62c490fc'/>
<id>urn:sha1:d717f24d8c68081caae2374cf5ea6c4e62c490fc</id>
<content type='text'>
We already have xmalloc(), xcalloc().  Add xrealloc() as well
to save tedious error handling.

Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
</content>
</entry>
<entry>
<title>kconfig: send error messages to stderr</title>
<updated>2018-02-08T19:10:10Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>yamada.masahiro@socionext.com</email>
</author>
<published>2018-02-06T00:34:41Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=9e3e10c725360b9d07018cfcd5b7b6b7d325fae5'/>
<id>urn:sha1:9e3e10c725360b9d07018cfcd5b7b6b7d325fae5</id>
<content type='text'>
These messages should be directed to stderr.

Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
Reviewed-by: Ulf Magnusson &lt;ulfalizer@gmail.com&gt;
</content>
</entry>
<entry>
<title>kconfig: echo stdin to stdout if either is redirected</title>
<updated>2018-02-08T19:10:10Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>yamada.masahiro@socionext.com</email>
</author>
<published>2018-02-08T05:56:40Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=f3ff6fb5db68bcd460e9880d5fb4902520dd645b'/>
<id>urn:sha1:f3ff6fb5db68bcd460e9880d5fb4902520dd645b</id>
<content type='text'>
If stdio is not tty, conf_askvalue() puts additional new line to
prevent prompts from being concatenated into a single line.  This
care is missing in conf_choice(), so a 'choice' prompt and the next
prompt are shown in the same line.

Move the code into xfgets() to cater to all cases.  To improve this
more, let's echo stdin to stdout.  This clarifies what keys were
input from stdio and the stdout looks like as if it were from tty.

I removed the isatty(2) check since stderr is unrelated here.

Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
Reviewed-by: Ulf Magnusson &lt;ulfalizer@gmail.com&gt;
</content>
</entry>
</feed>
