<feed xmlns='http://www.w3.org/2005/Atom'>
<title>BMC/Intel-BMC/linux.git/arch/s390/kernel/setup.c, branch dev-4.10</title>
<subtitle>Intel OpenBMC Linux kernel source tree (mirror)</subtitle>
<id>https://git.radix-linux.su/BMC/Intel-BMC/linux.git/atom?h=dev-4.10</id>
<link rel='self' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/atom?h=dev-4.10'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/'/>
<updated>2017-03-15T02:20:08+00:00</updated>
<entry>
<title>s390: use correct input data address for setup_randomness</title>
<updated>2017-03-15T02:20:08+00:00</updated>
<author>
<name>Heiko Carstens</name>
<email>heiko.carstens@de.ibm.com</email>
</author>
<published>2017-02-05T22:03:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=c9ac3e943deba05e17db732044e6ec44a29e0b7b'/>
<id>urn:sha1:c9ac3e943deba05e17db732044e6ec44a29e0b7b</id>
<content type='text'>
commit 4920e3cf77347d7d7373552d4839e8d832321313 upstream.

The current implementation of setup_randomness uses the stack address
and therefore the pointer to the SYSIB 3.2.2 block as input data
address. Furthermore the length of the input data is the number of
virtual-machine description blocks which is typically one.

This means that typically a single zero byte is fed to
add_device_randomness.

Fix both of these and use the address of the first virtual machine
description block as input data address and also use the correct
length.

Fixes: bcfcbb6bae64 ("s390: add system information as device randomness")
Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>s390: make setup_randomness work</title>
<updated>2017-03-15T02:20:07+00:00</updated>
<author>
<name>Heiko Carstens</name>
<email>heiko.carstens@de.ibm.com</email>
</author>
<published>2017-02-04T10:40:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=0075504d83cefe2da69e1776956867ac368c4c3f'/>
<id>urn:sha1:0075504d83cefe2da69e1776956867ac368c4c3f</id>
<content type='text'>
commit da8fd820f389a0e29080b14c61bf5cf1d8ef5ca1 upstream.

Commit bcfcbb6bae64 ("s390: add system information as device
randomness") intended to add some virtual machine specific information
to the randomness pool.

Unfortunately it uses the page allocator before it is ready to use. In
result the page allocator always returns NULL and the setup_randomness
function never adds anything to the randomness pool.

To fix this use memblock_alloc and memblock_free instead.

Fixes: bcfcbb6bae64 ("s390: add system information as device randomness")
Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>s390/setup: reword printk messages</title>
<updated>2016-12-14T15:33:40+00:00</updated>
<author>
<name>Martin Schwidefsky</name>
<email>schwidefsky@de.ibm.com</email>
</author>
<published>2016-12-13T15:19:11+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=6d7b2ee9d56af3d17d88b0f43b7dc14ee38161b7'/>
<id>urn:sha1:6d7b2ee9d56af3d17d88b0f43b7dc14ee38161b7</id>
<content type='text'>
Two of the messages introduced by the memblock conversion are reworded.

Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/numa: establish cpu to node mapping early</title>
<updated>2016-12-07T06:23:25+00:00</updated>
<author>
<name>Heiko Carstens</name>
<email>heiko.carstens@de.ibm.com</email>
</author>
<published>2016-12-03T08:50:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=8c9105802235c28b03359d779cbd0557b7b66e70'/>
<id>urn:sha1:8c9105802235c28b03359d779cbd0557b7b66e70</id>
<content type='text'>
Initialize the cpu topology and therefore also the cpu to node mapping
much earlier. Fixes this warning and subsequent crashes when using the
fake numa emulation mode on s390:

WARNING: CPU: 0 PID: 1 at include/linux/cpumask.h:121 select_task_rq+0xe6/0x1a8
CPU: 0 PID: 1 Comm: swapper/0 Not tainted 4.6.0-rc6-00001-ge9d867a67fd0-dirty #28
task: 00000001dd270008 ti: 00000001eccb4000 task.ti: 00000001eccb4000
Krnl PSW : 0404c00180000000 0000000000176c56 (select_task_rq+0xe6/0x1a8)
           R:0 T:1 IO:0 EX:0 Key:0 M:1 W:0 P:0 AS:3 CC:0 PM:0 RI:0 EA:3
Call Trace:
([&lt;0000000000176c30&gt;] select_task_rq+0xc0/0x1a8)
([&lt;0000000000177d64&gt;] try_to_wake_up+0x2e4/0x478)
([&lt;000000000015d46c&gt;] create_worker+0x174/0x1c0)
([&lt;0000000000161a98&gt;] alloc_unbound_pwq+0x360/0x438)
([&lt;0000000000162550&gt;] apply_wqattrs_prepare+0x200/0x2a0)
([&lt;000000000016266a&gt;] apply_workqueue_attrs_locked+0x7a/0xb0)
([&lt;0000000000162af0&gt;] apply_workqueue_attrs+0x50/0x78)
([&lt;000000000016441c&gt;] __alloc_workqueue_key+0x304/0x520)
([&lt;0000000000ee3706&gt;] default_bdi_init+0x3e/0x70)
([&lt;0000000000100270&gt;] do_one_initcall+0x140/0x1d8)
([&lt;0000000000ec9da8&gt;] kernel_init_freeable+0x220/0x2d8)
([&lt;0000000000984a7a&gt;] kernel_init+0x2a/0x150)
([&lt;00000000009913fa&gt;] kernel_thread_starter+0x6/0xc)
([&lt;00000000009913f4&gt;] kernel_thread_starter+0x0/0xc)

Reviewed-by: Michael Holzheu &lt;holzheu@linux.vnet.ibm.com&gt;
Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/smp: initialize cpu_present_mask in setup_arch</title>
<updated>2016-12-07T06:23:07+00:00</updated>
<author>
<name>Heiko Carstens</name>
<email>heiko.carstens@de.ibm.com</email>
</author>
<published>2016-12-03T08:48:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=af51160ebd3cc1c8bf0d37a48f13ac0dbe8a6e5f'/>
<id>urn:sha1:af51160ebd3cc1c8bf0d37a48f13ac0dbe8a6e5f</id>
<content type='text'>
In order to be able to setup the cpu to node mappings early it is a
prerequisite to know which cpus are present. Therefore cpus must be
detected much earlier than before.

For sclp based cpu detection this requires yet another early sclp
call, since the system is not ready to use the regular interrupt and
memory allocations.

Reviewed-by: Michael Holzheu &lt;holzheu@linux.vnet.ibm.com&gt;
Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/setup: fix memblock usage</title>
<updated>2016-12-02T06:36:24+00:00</updated>
<author>
<name>Heiko Carstens</name>
<email>heiko.carstens@de.ibm.com</email>
</author>
<published>2016-12-01T11:20:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=db7ad63624b370100077aa0a849d54fbeabd432b'/>
<id>urn:sha1:db7ad63624b370100077aa0a849d54fbeabd432b</id>
<content type='text'>
When converting from bootmem to memblock I missed a subtle difference:
the memblock_alloc() functions return uninitialized memory, while the
memblock_virt_alloc() functions return zeroed memory.

This led to quite random early boot crashes.

Therefore use the correct version everywhere now.
Hopefully.

Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390/kexec: use node 0 when re-adding crash kernel memory</title>
<updated>2016-12-02T06:36:17+00:00</updated>
<author>
<name>Heiko Carstens</name>
<email>heiko.carstens@de.ibm.com</email>
</author>
<published>2016-11-28T10:40:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=9f88eb4df728aebcd2ddd154d99f1d75b428b897'/>
<id>urn:sha1:9f88eb4df728aebcd2ddd154d99f1d75b428b897</id>
<content type='text'>
When re-adding crash kernel memory within setup_resources() the
function memblock_add() is used. That function will add memory by
default to node "MAX_NUMNODES" instead of node 0, like the memory
detection code does. In case of !NUMA this will trigger this warning
when the kernel generates the vmemmap:

Usage of MAX_NUMNODES is deprecated. Use NUMA_NO_NODE instead
WARNING: CPU: 0 PID: 0 at mm/memblock.c:1261 memblock_virt_alloc_internal+0x76/0x220
CPU: 0 PID: 0 Comm: swapper Not tainted 4.9.0-rc6 #16
Call Trace:
 [&lt;0000000000d0b2e8&gt;] memblock_virt_alloc_try_nid+0x88/0xc8
 [&lt;000000000083c8ea&gt;] __earlyonly_bootmem_alloc.constprop.1+0x42/0x50
 [&lt;000000000083e7f4&gt;] vmemmap_populate+0x1ac/0x1e0
 [&lt;0000000000840136&gt;] sparse_mem_map_populate+0x46/0x68
 [&lt;0000000000d0c59c&gt;] sparse_init+0x184/0x238
 [&lt;0000000000cf45f6&gt;] paging_init+0xbe/0xf8
 [&lt;0000000000cf1d4a&gt;] setup_arch+0xa02/0xae0
 [&lt;0000000000ced75a&gt;] start_kernel+0x72/0x450
 [&lt;0000000000100020&gt;] _stext+0x20/0x80

If NUMA is selected numa_setup_memory() will fix the node assignments
before the vmemmap will be populated; so this warning will only appear
if NUMA is not selected.

To fix this simply use memblock_add_node() and re-add crash kernel
memory explicitly to node 0.

Reported-and-tested-by: Christian Borntraeger &lt;borntraeger@de.ibm.com&gt;
Fixes: 4e042af463f8 ("s390/kexec: fix crash on resize of reserved memory")
Cc: &lt;stable@vger.kernel.org&gt; # v4.8+
Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390: convert remaining bootmem allocations to memblock</title>
<updated>2016-11-29T06:52:55+00:00</updated>
<author>
<name>Heiko Carstens</name>
<email>heiko.carstens@de.ibm.com</email>
</author>
<published>2016-10-18T11:35:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=9e427365af736be864b1cef737b26c516b832144'/>
<id>urn:sha1:9e427365af736be864b1cef737b26c516b832144</id>
<content type='text'>
Get rid of all remaining alloc_bootmem calls and use memblock_alloc
instead everywhere.  This way we get rid of the inconsistent mixture
of alloc_bootmem and memblock_alloc usages.

Two of the alloc_bootmem_low calls within arch/s390/kernel/setup.c are
replaced with memblock_alloc calls that don't enforce that the
allocated memory is below 2GB. This restriction was never necessary.

Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390: add cma support</title>
<updated>2016-11-23T15:02:23+00:00</updated>
<author>
<name>Heiko Carstens</name>
<email>heiko.carstens@de.ibm.com</email>
</author>
<published>2016-11-14T12:57:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=e1231b0e487caea77d3dffeb737cb25bd3595c5b'/>
<id>urn:sha1:e1231b0e487caea77d3dffeb737cb25bd3595c5b</id>
<content type='text'>
In order to make the cma infrastructure usable we need to add a small
architecture backend which calls dma_contiguous_reserve.
Otherwise we would end up with the cma allocator enabled, but no pool
where memory can be allocated from.

Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
<entry>
<title>s390: move thread_info into task_struct</title>
<updated>2016-11-11T15:37:41+00:00</updated>
<author>
<name>Heiko Carstens</name>
<email>heiko.carstens@de.ibm.com</email>
</author>
<published>2016-11-08T10:08:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/BMC/Intel-BMC/linux.git/commit/?id=d5c352cdd022d2c304c6ab19d100631356f2198c'/>
<id>urn:sha1:d5c352cdd022d2c304c6ab19d100631356f2198c</id>
<content type='text'>
This is the s390 variant of commit 15f4eae70d36 ("x86: Move
thread_info into task_struct").

Signed-off-by: Heiko Carstens &lt;heiko.carstens@de.ibm.com&gt;
Signed-off-by: Martin Schwidefsky &lt;schwidefsky@de.ibm.com&gt;
</content>
</entry>
</feed>
