<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/arch, branch v4.1.5</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>avr32: handle NULL as a valid clock object</title>
<updated>2015-08-10T19:21:58+00:00</updated>
<author>
<name>Andy Shevchenko</name>
<email>andriy.shevchenko@linux.intel.com</email>
</author>
<published>2015-07-24T10:49:48+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=c9bb1d26fe5747a4dbea75fe37e6474f6abbcdad'/>
<id>c9bb1d26fe5747a4dbea75fe37e6474f6abbcdad</id>
<content type='text'>
commit 5c02a4206538da12c040b51778d310df84c6bf6c upstream.

Since NULL is used as valid clock object on optional clocks we have to handle
this case in avr32 implementation as well.

Fixes: e1824dfe0d8e (net: macb: Adjust tx_clk when link speed changes)
Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Acked-by: Hans-Christian Egtvedt &lt;egtvedt@samfundet.no&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 5c02a4206538da12c040b51778d310df84c6bf6c upstream.

Since NULL is used as valid clock object on optional clocks we have to handle
this case in avr32 implementation as well.

Fixes: e1824dfe0d8e (net: macb: Adjust tx_clk when link speed changes)
Signed-off-by: Andy Shevchenko &lt;andriy.shevchenko@linux.intel.com&gt;
Acked-by: Hans-Christian Egtvedt &lt;egtvedt@samfundet.no&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>perf/x86/intel/cqm: Return cached counter value from IRQ context</title>
<updated>2015-08-10T19:21:58+00:00</updated>
<author>
<name>Matt Fleming</name>
<email>matt.fleming@intel.com</email>
</author>
<published>2015-07-21T14:55:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=f919f7a4d004513372807cedc14fac43f0652c4c'/>
<id>f919f7a4d004513372807cedc14fac43f0652c4c</id>
<content type='text'>
commit 2c534c0da0a68418693e10ce1c4146e085f39518 upstream.

Peter reported the following potential crash which I was able to
reproduce with his test program,

[  148.765788] ------------[ cut here ]------------
[  148.765796] WARNING: CPU: 34 PID: 2840 at kernel/smp.c:417 smp_call_function_many+0xb6/0x260()
[  148.765797] Modules linked in:
[  148.765800] CPU: 34 PID: 2840 Comm: perf Not tainted 4.2.0-rc1+ #4
[  148.765803]  ffffffff81cdc398 ffff88085f105950 ffffffff818bdfd5 0000000000000007
[  148.765805]  0000000000000000 ffff88085f105990 ffffffff810e413a 0000000000000000
[  148.765807]  ffffffff82301080 0000000000000022 ffffffff8107f640 ffffffff8107f640
[  148.765809] Call Trace:
[  148.765810]  &lt;NMI&gt;  [&lt;ffffffff818bdfd5&gt;] dump_stack+0x45/0x57
[  148.765818]  [&lt;ffffffff810e413a&gt;] warn_slowpath_common+0x8a/0xc0
[  148.765822]  [&lt;ffffffff8107f640&gt;] ? intel_cqm_stable+0x60/0x60
[  148.765824]  [&lt;ffffffff8107f640&gt;] ? intel_cqm_stable+0x60/0x60
[  148.765825]  [&lt;ffffffff810e422a&gt;] warn_slowpath_null+0x1a/0x20
[  148.765827]  [&lt;ffffffff811613f6&gt;] smp_call_function_many+0xb6/0x260
[  148.765829]  [&lt;ffffffff8107f640&gt;] ? intel_cqm_stable+0x60/0x60
[  148.765831]  [&lt;ffffffff81161748&gt;] on_each_cpu_mask+0x28/0x60
[  148.765832]  [&lt;ffffffff8107f6ef&gt;] intel_cqm_event_count+0x7f/0xe0
[  148.765836]  [&lt;ffffffff811cdd35&gt;] perf_output_read+0x2a5/0x400
[  148.765839]  [&lt;ffffffff811d2e5a&gt;] perf_output_sample+0x31a/0x590
[  148.765840]  [&lt;ffffffff811d333d&gt;] ? perf_prepare_sample+0x26d/0x380
[  148.765841]  [&lt;ffffffff811d3497&gt;] perf_event_output+0x47/0x60
[  148.765843]  [&lt;ffffffff811d36c5&gt;] __perf_event_overflow+0x215/0x240
[  148.765844]  [&lt;ffffffff811d4124&gt;] perf_event_overflow+0x14/0x20
[  148.765847]  [&lt;ffffffff8107e7f4&gt;] intel_pmu_handle_irq+0x1d4/0x440
[  148.765849]  [&lt;ffffffff811d07a6&gt;] ? __perf_event_task_sched_in+0x36/0xa0
[  148.765853]  [&lt;ffffffff81219bad&gt;] ? vunmap_page_range+0x19d/0x2f0
[  148.765854]  [&lt;ffffffff81219d11&gt;] ? unmap_kernel_range_noflush+0x11/0x20
[  148.765859]  [&lt;ffffffff814ce6fe&gt;] ? ghes_copy_tofrom_phys+0x11e/0x2a0
[  148.765863]  [&lt;ffffffff8109e5db&gt;] ? native_apic_msr_write+0x2b/0x30
[  148.765865]  [&lt;ffffffff8109e44d&gt;] ? x2apic_send_IPI_self+0x1d/0x20
[  148.765869]  [&lt;ffffffff81065135&gt;] ? arch_irq_work_raise+0x35/0x40
[  148.765872]  [&lt;ffffffff811c8d86&gt;] ? irq_work_queue+0x66/0x80
[  148.765875]  [&lt;ffffffff81075306&gt;] perf_event_nmi_handler+0x26/0x40
[  148.765877]  [&lt;ffffffff81063ed9&gt;] nmi_handle+0x79/0x100
[  148.765879]  [&lt;ffffffff81064422&gt;] default_do_nmi+0x42/0x100
[  148.765880]  [&lt;ffffffff81064563&gt;] do_nmi+0x83/0xb0
[  148.765884]  [&lt;ffffffff818c7c0f&gt;] end_repeat_nmi+0x1e/0x2e
[  148.765886]  [&lt;ffffffff811d07a6&gt;] ? __perf_event_task_sched_in+0x36/0xa0
[  148.765888]  [&lt;ffffffff811d07a6&gt;] ? __perf_event_task_sched_in+0x36/0xa0
[  148.765890]  [&lt;ffffffff811d07a6&gt;] ? __perf_event_task_sched_in+0x36/0xa0
[  148.765891]  &lt;&lt;EOE&gt;&gt;  [&lt;ffffffff8110ab66&gt;] finish_task_switch+0x156/0x210
[  148.765898]  [&lt;ffffffff818c1671&gt;] __schedule+0x341/0x920
[  148.765899]  [&lt;ffffffff818c1c87&gt;] schedule+0x37/0x80
[  148.765903]  [&lt;ffffffff810ae1af&gt;] ? do_page_fault+0x2f/0x80
[  148.765905]  [&lt;ffffffff818c1f4a&gt;] schedule_user+0x1a/0x50
[  148.765907]  [&lt;ffffffff818c666c&gt;] retint_careful+0x14/0x32
[  148.765908] ---[ end trace e33ff2be78e14901 ]---

The CQM task events are not safe to be called from within interrupt
context because they require performing an IPI to read the counter value
on all sockets. And performing IPIs from within IRQ context is a
"no-no".

Make do with the last read counter value currently event in
event-&gt;count when we're invoked in this context.

Reported-by: Peter Zijlstra &lt;peterz@infradead.org&gt;
Signed-off-by: Matt Fleming &lt;matt.fleming@intel.com&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Vikas Shivappa &lt;vikas.shivappa@intel.com&gt;
Cc: Kanaka Juvva &lt;kanaka.d.juvva@intel.com&gt;
Cc: Will Auld &lt;will.auld@intel.com&gt;
Link: http://lkml.kernel.org/r/1437490509-15373-1-git-send-email-matt@codeblueprint.co.uk
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 2c534c0da0a68418693e10ce1c4146e085f39518 upstream.

Peter reported the following potential crash which I was able to
reproduce with his test program,

[  148.765788] ------------[ cut here ]------------
[  148.765796] WARNING: CPU: 34 PID: 2840 at kernel/smp.c:417 smp_call_function_many+0xb6/0x260()
[  148.765797] Modules linked in:
[  148.765800] CPU: 34 PID: 2840 Comm: perf Not tainted 4.2.0-rc1+ #4
[  148.765803]  ffffffff81cdc398 ffff88085f105950 ffffffff818bdfd5 0000000000000007
[  148.765805]  0000000000000000 ffff88085f105990 ffffffff810e413a 0000000000000000
[  148.765807]  ffffffff82301080 0000000000000022 ffffffff8107f640 ffffffff8107f640
[  148.765809] Call Trace:
[  148.765810]  &lt;NMI&gt;  [&lt;ffffffff818bdfd5&gt;] dump_stack+0x45/0x57
[  148.765818]  [&lt;ffffffff810e413a&gt;] warn_slowpath_common+0x8a/0xc0
[  148.765822]  [&lt;ffffffff8107f640&gt;] ? intel_cqm_stable+0x60/0x60
[  148.765824]  [&lt;ffffffff8107f640&gt;] ? intel_cqm_stable+0x60/0x60
[  148.765825]  [&lt;ffffffff810e422a&gt;] warn_slowpath_null+0x1a/0x20
[  148.765827]  [&lt;ffffffff811613f6&gt;] smp_call_function_many+0xb6/0x260
[  148.765829]  [&lt;ffffffff8107f640&gt;] ? intel_cqm_stable+0x60/0x60
[  148.765831]  [&lt;ffffffff81161748&gt;] on_each_cpu_mask+0x28/0x60
[  148.765832]  [&lt;ffffffff8107f6ef&gt;] intel_cqm_event_count+0x7f/0xe0
[  148.765836]  [&lt;ffffffff811cdd35&gt;] perf_output_read+0x2a5/0x400
[  148.765839]  [&lt;ffffffff811d2e5a&gt;] perf_output_sample+0x31a/0x590
[  148.765840]  [&lt;ffffffff811d333d&gt;] ? perf_prepare_sample+0x26d/0x380
[  148.765841]  [&lt;ffffffff811d3497&gt;] perf_event_output+0x47/0x60
[  148.765843]  [&lt;ffffffff811d36c5&gt;] __perf_event_overflow+0x215/0x240
[  148.765844]  [&lt;ffffffff811d4124&gt;] perf_event_overflow+0x14/0x20
[  148.765847]  [&lt;ffffffff8107e7f4&gt;] intel_pmu_handle_irq+0x1d4/0x440
[  148.765849]  [&lt;ffffffff811d07a6&gt;] ? __perf_event_task_sched_in+0x36/0xa0
[  148.765853]  [&lt;ffffffff81219bad&gt;] ? vunmap_page_range+0x19d/0x2f0
[  148.765854]  [&lt;ffffffff81219d11&gt;] ? unmap_kernel_range_noflush+0x11/0x20
[  148.765859]  [&lt;ffffffff814ce6fe&gt;] ? ghes_copy_tofrom_phys+0x11e/0x2a0
[  148.765863]  [&lt;ffffffff8109e5db&gt;] ? native_apic_msr_write+0x2b/0x30
[  148.765865]  [&lt;ffffffff8109e44d&gt;] ? x2apic_send_IPI_self+0x1d/0x20
[  148.765869]  [&lt;ffffffff81065135&gt;] ? arch_irq_work_raise+0x35/0x40
[  148.765872]  [&lt;ffffffff811c8d86&gt;] ? irq_work_queue+0x66/0x80
[  148.765875]  [&lt;ffffffff81075306&gt;] perf_event_nmi_handler+0x26/0x40
[  148.765877]  [&lt;ffffffff81063ed9&gt;] nmi_handle+0x79/0x100
[  148.765879]  [&lt;ffffffff81064422&gt;] default_do_nmi+0x42/0x100
[  148.765880]  [&lt;ffffffff81064563&gt;] do_nmi+0x83/0xb0
[  148.765884]  [&lt;ffffffff818c7c0f&gt;] end_repeat_nmi+0x1e/0x2e
[  148.765886]  [&lt;ffffffff811d07a6&gt;] ? __perf_event_task_sched_in+0x36/0xa0
[  148.765888]  [&lt;ffffffff811d07a6&gt;] ? __perf_event_task_sched_in+0x36/0xa0
[  148.765890]  [&lt;ffffffff811d07a6&gt;] ? __perf_event_task_sched_in+0x36/0xa0
[  148.765891]  &lt;&lt;EOE&gt;&gt;  [&lt;ffffffff8110ab66&gt;] finish_task_switch+0x156/0x210
[  148.765898]  [&lt;ffffffff818c1671&gt;] __schedule+0x341/0x920
[  148.765899]  [&lt;ffffffff818c1c87&gt;] schedule+0x37/0x80
[  148.765903]  [&lt;ffffffff810ae1af&gt;] ? do_page_fault+0x2f/0x80
[  148.765905]  [&lt;ffffffff818c1f4a&gt;] schedule_user+0x1a/0x50
[  148.765907]  [&lt;ffffffff818c666c&gt;] retint_careful+0x14/0x32
[  148.765908] ---[ end trace e33ff2be78e14901 ]---

The CQM task events are not safe to be called from within interrupt
context because they require performing an IPI to read the counter value
on all sockets. And performing IPIs from within IRQ context is a
"no-no".

Make do with the last read counter value currently event in
event-&gt;count when we're invoked in this context.

Reported-by: Peter Zijlstra &lt;peterz@infradead.org&gt;
Signed-off-by: Matt Fleming &lt;matt.fleming@intel.com&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Vikas Shivappa &lt;vikas.shivappa@intel.com&gt;
Cc: Kanaka Juvva &lt;kanaka.d.juvva@intel.com&gt;
Cc: Will Auld &lt;will.auld@intel.com&gt;
Link: http://lkml.kernel.org/r/1437490509-15373-1-git-send-email-matt@codeblueprint.co.uk
Signed-off-by: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>ARC: Make ARC bitops "safer" (add anti-optimization)</title>
<updated>2015-08-10T19:21:57+00:00</updated>
<author>
<name>Vineet Gupta</name>
<email>vgupta@synopsys.com</email>
</author>
<published>2015-07-03T05:56:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=26121b675728939c515594b2bb866756b7789c16'/>
<id>26121b675728939c515594b2bb866756b7789c16</id>
<content type='text'>
commit 80f420842ff42ad61f84584716d74ef635f13892 upstream.

ARCompact/ARCv2 ISA provide that any instructions which deals with
bitpos/count operand ASL, LSL, BSET, BCLR, BMSK .... will only consider
lower 5 bits. i.e. auto-clamp the pos to 0-31.

ARC Linux bitops exploited this fact by NOT explicitly masking out upper
bits for @nr operand in general, saving a bunch of AND/BMSK instructions
in generated code around bitops.

While this micro-optimization has worked well over years it is NOT safe
as shifting a number with a value, greater than native size is
"undefined" per "C" spec.

So as it turns outm EZChip ran into this eventually, in their massive
muti-core SMP build with 64 cpus. There was a test_bit() inside a loop
from 63 to 0 and gcc was weirdly optimizing away the first iteration
(so it was really adhering to standard by implementing undefined behaviour
vs. removing all the iterations which were phony i.e. (1 &lt;&lt; [63..32])

| for i = 63 to 0
|    X = ( 1 &lt;&lt; i )
|    if X == 0
|       continue

So fix the code to do the explicit masking at the expense of generating
additional instructions. Fortunately, this can be mitigated to a large
extent as gcc has SHIFT_COUNT_TRUNCATED which allows combiner to fold
masking into shift operation itself. It is currently not enabled in ARC
gcc backend, but could be done after a bit of testing.

Fixes STAR 9000866918 ("unsafe "undefined behavior" code in kernel")

Reported-by: Noam Camus &lt;noamc@ezchip.com&gt;
Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 80f420842ff42ad61f84584716d74ef635f13892 upstream.

ARCompact/ARCv2 ISA provide that any instructions which deals with
bitpos/count operand ASL, LSL, BSET, BCLR, BMSK .... will only consider
lower 5 bits. i.e. auto-clamp the pos to 0-31.

ARC Linux bitops exploited this fact by NOT explicitly masking out upper
bits for @nr operand in general, saving a bunch of AND/BMSK instructions
in generated code around bitops.

While this micro-optimization has worked well over years it is NOT safe
as shifting a number with a value, greater than native size is
"undefined" per "C" spec.

So as it turns outm EZChip ran into this eventually, in their massive
muti-core SMP build with 64 cpus. There was a test_bit() inside a loop
from 63 to 0 and gcc was weirdly optimizing away the first iteration
(so it was really adhering to standard by implementing undefined behaviour
vs. removing all the iterations which were phony i.e. (1 &lt;&lt; [63..32])

| for i = 63 to 0
|    X = ( 1 &lt;&lt; i )
|    if X == 0
|       continue

So fix the code to do the explicit masking at the expense of generating
additional instructions. Fortunately, this can be mitigated to a large
extent as gcc has SHIFT_COUNT_TRUNCATED which allows combiner to fold
masking into shift operation itself. It is currently not enabled in ARC
gcc backend, but could be done after a bit of testing.

Fixes STAR 9000866918 ("unsafe "undefined behavior" code in kernel")

Reported-by: Noam Camus &lt;noamc@ezchip.com&gt;
Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>ARC: Reduce bitops lines of code using macros</title>
<updated>2015-08-10T19:21:57+00:00</updated>
<author>
<name>Vineet Gupta</name>
<email>vgupta@synopsys.com</email>
</author>
<published>2015-03-31T17:08:21+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=3092e514c62477fa17401667d4ffb4921b14842c'/>
<id>3092e514c62477fa17401667d4ffb4921b14842c</id>
<content type='text'>
commit 04e2eee4b02edcafce96c9c37b31b1a3318291a4 upstream.

No semantical changes !

Acked-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 04e2eee4b02edcafce96c9c37b31b1a3318291a4 upstream.

No semantical changes !

Acked-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Signed-off-by: Vineet Gupta &lt;vgupta@synopsys.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>x86/efi: Use all 64 bit of efi_memmap in setup_e820()</title>
<updated>2015-08-10T19:21:57+00:00</updated>
<author>
<name>Dmitry Skorodumov</name>
<email>sdmitry@parallels.com</email>
</author>
<published>2015-07-28T14:38:32+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=e8647ec68feb66acd35b0f7fa3177bb47cc6a94e'/>
<id>e8647ec68feb66acd35b0f7fa3177bb47cc6a94e</id>
<content type='text'>
commit 7cc03e48965453b5df1cce5062c826189b04b960 upstream.

The efi_info structure stores low 32 bits of memory map
in efi_memmap and high 32 bits in efi_memmap_hi.

While constructing pointer in the setup_e820(), need
to take into account all 64 bit of the pointer.

It is because on 64bit machine the function
efi_get_memory_map() may return full 64bit pointer and before
the patch that pointer was truncated.

The issue is triggered on Parallles virtual machine and
fixed with this patch.

Signed-off-by: Dmitry Skorodumov &lt;sdmitry@parallels.com&gt;
Cc: Denis V. Lunev &lt;den@openvz.org&gt;
Signed-off-by: Matt Fleming &lt;matt.fleming@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 7cc03e48965453b5df1cce5062c826189b04b960 upstream.

The efi_info structure stores low 32 bits of memory map
in efi_memmap and high 32 bits in efi_memmap_hi.

While constructing pointer in the setup_e820(), need
to take into account all 64 bit of the pointer.

It is because on 64bit machine the function
efi_get_memory_map() may return full 64bit pointer and before
the patch that pointer was truncated.

The issue is triggered on Parallles virtual machine and
fixed with this patch.

Signed-off-by: Dmitry Skorodumov &lt;sdmitry@parallels.com&gt;
Cc: Denis V. Lunev &lt;den@openvz.org&gt;
Signed-off-by: Matt Fleming &lt;matt.fleming@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>efi: Check for NULL efi kernel parameters</title>
<updated>2015-08-10T19:21:57+00:00</updated>
<author>
<name>Ricardo Neri</name>
<email>ricardo.neri-calderon@linux.intel.com</email>
</author>
<published>2015-07-16T02:36:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=c54f557fa580989c304cc5c83528efa5a1819a85'/>
<id>c54f557fa580989c304cc5c83528efa5a1819a85</id>
<content type='text'>
commit 9115c7589b11349a1c3099758b4bded579ff69e0 upstream.

Even though it is documented how to specifiy efi parameters, it is
possible to cause a kernel panic due to a dereference of a NULL pointer when
parsing such parameters if "efi" alone is given:

PANIC: early exception 0e rip 10:ffffffff812fb361 error 0 cr2 0
[ 0.000000] CPU: 0 PID: 0 Comm: swapper Not tainted 4.2.0-rc1+ #450
[ 0.000000]  ffffffff81fe20a9 ffffffff81e03d50 ffffffff8184bb0f 00000000000003f8
[ 0.000000]  0000000000000000 ffffffff81e03e08 ffffffff81f371a1 64656c62616e6520
[ 0.000000]  0000000000000069 000000000000005f 0000000000000000 0000000000000000
[ 0.000000] Call Trace:
[ 0.000000]  [&lt;ffffffff8184bb0f&gt;] dump_stack+0x45/0x57
[ 0.000000]  [&lt;ffffffff81f371a1&gt;] early_idt_handler_common+0x81/0xae
[ 0.000000]  [&lt;ffffffff812fb361&gt;] ? parse_option_str+0x11/0x90
[ 0.000000]  [&lt;ffffffff81f4dd69&gt;] arch_parse_efi_cmdline+0x15/0x42
[ 0.000000]  [&lt;ffffffff81f376e1&gt;] do_early_param+0x50/0x8a
[ 0.000000]  [&lt;ffffffff8106b1b3&gt;] parse_args+0x1e3/0x400
[ 0.000000]  [&lt;ffffffff81f37a43&gt;] parse_early_options+0x24/0x28
[ 0.000000]  [&lt;ffffffff81f37691&gt;] ? loglevel+0x31/0x31
[ 0.000000]  [&lt;ffffffff81f37a78&gt;] parse_early_param+0x31/0x3d
[ 0.000000]  [&lt;ffffffff81f3ae98&gt;] setup_arch+0x2de/0xc08
[ 0.000000]  [&lt;ffffffff8109629a&gt;] ? vprintk_default+0x1a/0x20
[ 0.000000]  [&lt;ffffffff81f37b20&gt;] start_kernel+0x90/0x423
[ 0.000000]  [&lt;ffffffff81f37495&gt;] x86_64_start_reservations+0x2a/0x2c
[ 0.000000]  [&lt;ffffffff81f37582&gt;] x86_64_start_kernel+0xeb/0xef
[ 0.000000] RIP 0xffffffff81ba2efc

This panic is not reproducible with "efi=" as this will result in a non-NULL
zero-length string.

Thus, verify that the pointer to the parameter string is not NULL. This is
consistent with other parameter-parsing functions which check for NULL pointers.

Signed-off-by: Ricardo Neri &lt;ricardo.neri-calderon@linux.intel.com&gt;
Cc: Dave Young &lt;dyoung@redhat.com&gt;
Signed-off-by: Matt Fleming &lt;matt.fleming@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 9115c7589b11349a1c3099758b4bded579ff69e0 upstream.

Even though it is documented how to specifiy efi parameters, it is
possible to cause a kernel panic due to a dereference of a NULL pointer when
parsing such parameters if "efi" alone is given:

PANIC: early exception 0e rip 10:ffffffff812fb361 error 0 cr2 0
[ 0.000000] CPU: 0 PID: 0 Comm: swapper Not tainted 4.2.0-rc1+ #450
[ 0.000000]  ffffffff81fe20a9 ffffffff81e03d50 ffffffff8184bb0f 00000000000003f8
[ 0.000000]  0000000000000000 ffffffff81e03e08 ffffffff81f371a1 64656c62616e6520
[ 0.000000]  0000000000000069 000000000000005f 0000000000000000 0000000000000000
[ 0.000000] Call Trace:
[ 0.000000]  [&lt;ffffffff8184bb0f&gt;] dump_stack+0x45/0x57
[ 0.000000]  [&lt;ffffffff81f371a1&gt;] early_idt_handler_common+0x81/0xae
[ 0.000000]  [&lt;ffffffff812fb361&gt;] ? parse_option_str+0x11/0x90
[ 0.000000]  [&lt;ffffffff81f4dd69&gt;] arch_parse_efi_cmdline+0x15/0x42
[ 0.000000]  [&lt;ffffffff81f376e1&gt;] do_early_param+0x50/0x8a
[ 0.000000]  [&lt;ffffffff8106b1b3&gt;] parse_args+0x1e3/0x400
[ 0.000000]  [&lt;ffffffff81f37a43&gt;] parse_early_options+0x24/0x28
[ 0.000000]  [&lt;ffffffff81f37691&gt;] ? loglevel+0x31/0x31
[ 0.000000]  [&lt;ffffffff81f37a78&gt;] parse_early_param+0x31/0x3d
[ 0.000000]  [&lt;ffffffff81f3ae98&gt;] setup_arch+0x2de/0xc08
[ 0.000000]  [&lt;ffffffff8109629a&gt;] ? vprintk_default+0x1a/0x20
[ 0.000000]  [&lt;ffffffff81f37b20&gt;] start_kernel+0x90/0x423
[ 0.000000]  [&lt;ffffffff81f37495&gt;] x86_64_start_reservations+0x2a/0x2c
[ 0.000000]  [&lt;ffffffff81f37582&gt;] x86_64_start_kernel+0xeb/0xef
[ 0.000000] RIP 0xffffffff81ba2efc

This panic is not reproducible with "efi=" as this will result in a non-NULL
zero-length string.

Thus, verify that the pointer to the parameter string is not NULL. This is
consistent with other parameter-parsing functions which check for NULL pointers.

Signed-off-by: Ricardo Neri &lt;ricardo.neri-calderon@linux.intel.com&gt;
Cc: Dave Young &lt;dyoung@redhat.com&gt;
Signed-off-by: Matt Fleming &lt;matt.fleming@intel.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>arm64/efi: map the entire UEFI vendor string before reading it</title>
<updated>2015-08-10T19:21:57+00:00</updated>
<author>
<name>Ard Biesheuvel</name>
<email>ard.biesheuvel@linaro.org</email>
</author>
<published>2015-07-26T12:59:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=b3525bdf91087473d4490ab7acc31f59821cc04a'/>
<id>b3525bdf91087473d4490ab7acc31f59821cc04a</id>
<content type='text'>
commit f91b1feada0b6f0a4d33648155b3ded2c4e0707e upstream.

At boot, the UTF-16 UEFI vendor string is copied from the system
table into a char array with a size of 100 bytes. However, this
size of 100 bytes is also used for memremapping() the source,
which may not be sufficient if the vendor string exceeds 50
UTF-16 characters, and the placement of the vendor string inside
a 4 KB page happens to leave the end unmapped.

So use the correct '100 * sizeof(efi_char16_t)' for the size of
the mapping.

Signed-off-by: Ard Biesheuvel &lt;ard.biesheuvel@linaro.org&gt;
Fixes: f84d02755f5a ("arm64: add EFI runtime services")
Signed-off-by: Catalin Marinas &lt;catalin.marinas@arm.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit f91b1feada0b6f0a4d33648155b3ded2c4e0707e upstream.

At boot, the UTF-16 UEFI vendor string is copied from the system
table into a char array with a size of 100 bytes. However, this
size of 100 bytes is also used for memremapping() the source,
which may not be sufficient if the vendor string exceeds 50
UTF-16 characters, and the placement of the vendor string inside
a 4 KB page happens to leave the end unmapped.

So use the correct '100 * sizeof(efi_char16_t)' for the size of
the mapping.

Signed-off-by: Ard Biesheuvel &lt;ard.biesheuvel@linaro.org&gt;
Fixes: f84d02755f5a ("arm64: add EFI runtime services")
Signed-off-by: Catalin Marinas &lt;catalin.marinas@arm.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>x86/mm: Add parenthesis for TLB tracepoint size calculation</title>
<updated>2015-08-10T19:21:57+00:00</updated>
<author>
<name>Dave Hansen</name>
<email>dave.hansen@linux.intel.com</email>
</author>
<published>2015-07-20T23:01:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=5728ec989adce2f303000b84469750579f162c2d'/>
<id>5728ec989adce2f303000b84469750579f162c2d</id>
<content type='text'>
commit bbc03778b9954a2ec93baed63718e4df0192f130 upstream.

flush_tlb_info-&gt;flush_start/end are both normal virtual
addresses.  When calculating 'nr_pages' (only used for the
tracepoint), I neglected to put parenthesis in.

Thanks to David Koufaty for pointing this out.

Signed-off-by: Dave Hansen &lt;dave.hansen@linux.intel.com&gt;
Cc: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: dave@sr71.net
Link: http://lkml.kernel.org/r/20150720230153.9E834081@viggo.jf.intel.com
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit bbc03778b9954a2ec93baed63718e4df0192f130 upstream.

flush_tlb_info-&gt;flush_start/end are both normal virtual
addresses.  When calculating 'nr_pages' (only used for the
tracepoint), I neglected to put parenthesis in.

Thanks to David Koufaty for pointing this out.

Signed-off-by: Dave Hansen &lt;dave.hansen@linux.intel.com&gt;
Cc: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: dave@sr71.net
Link: http://lkml.kernel.org/r/20150720230153.9E834081@viggo.jf.intel.com
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>tile: use free_bootmem_late() for initrd</title>
<updated>2015-08-10T19:21:56+00:00</updated>
<author>
<name>Chris Metcalf</name>
<email>cmetcalf@ezchip.com</email>
</author>
<published>2015-07-23T18:11:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=bec2057fee79fe271a629c98feb2201faba4ff2c'/>
<id>bec2057fee79fe271a629c98feb2201faba4ff2c</id>
<content type='text'>
commit 3f81d2447b37ac697b3c600039f2c6b628c06e21 upstream.

We were previously using free_bootmem() and just getting lucky
that nothing too bad happened.

Signed-off-by: Chris Metcalf &lt;cmetcalf@ezchip.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit 3f81d2447b37ac697b3c600039f2c6b628c06e21 upstream.

We were previously using free_bootmem() and just getting lucky
that nothing too bad happened.

Signed-off-by: Chris Metcalf &lt;cmetcalf@ezchip.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
<entry>
<title>x86, perf: Fix static_key bug in load_mm_cr4()</title>
<updated>2015-08-10T19:21:54+00:00</updated>
<author>
<name>Peter Zijlstra</name>
<email>peterz@infradead.org</email>
</author>
<published>2015-07-09T17:23:38+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=68b9e67311ca10a0bdce6ab2939ca0ff3ebac91b'/>
<id>68b9e67311ca10a0bdce6ab2939ca0ff3ebac91b</id>
<content type='text'>
commit a833581e372a4adae2319d8dc379493edbc444e9 upstream.

Mikulas reported his K6-3 not booting. This is because the
static_key API confusion struck and bit Andy, this wants to be
static_key_false().

Reported-by: Mikulas Patocka &lt;mpatocka@redhat.com&gt;
Tested-by: Mikulas Patocka &lt;mpatocka@redhat.com&gt;
Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Cc: Andrea Arcangeli &lt;aarcange@redhat.com&gt;
Cc: Andy Lutomirski &lt;luto@amacapital.net&gt;
Cc: Arnaldo Carvalho de Melo &lt;acme@kernel.org&gt;
Cc: Borislav Petkov &lt;bp@alien8.de&gt;
Cc: Brian Gerst &lt;brgerst@gmail.com&gt;
Cc: Denys Vlasenko &lt;dvlasenk@redhat.com&gt;
Cc: H. Peter Anvin &lt;hpa@zytor.com&gt;
Cc: Kees Cook &lt;keescook@chromium.org&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Valdis Kletnieks &lt;Valdis.Kletnieks@vt.edu&gt;
Cc: Vince Weaver &lt;vince@deater.net&gt;
Cc: hillf.zj &lt;hillf.zj@alibaba-inc.com&gt;
Fixes: a66734297f78 ("perf/x86: Add /sys/devices/cpu/rdpmc=2 to allow rdpmc for all tasks")
Link: http://lkml.kernel.org/r/20150709172338.GC19282@twins.programming.kicks-ass.net
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
commit a833581e372a4adae2319d8dc379493edbc444e9 upstream.

Mikulas reported his K6-3 not booting. This is because the
static_key API confusion struck and bit Andy, this wants to be
static_key_false().

Reported-by: Mikulas Patocka &lt;mpatocka@redhat.com&gt;
Tested-by: Mikulas Patocka &lt;mpatocka@redhat.com&gt;
Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Cc: Andrea Arcangeli &lt;aarcange@redhat.com&gt;
Cc: Andy Lutomirski &lt;luto@amacapital.net&gt;
Cc: Arnaldo Carvalho de Melo &lt;acme@kernel.org&gt;
Cc: Borislav Petkov &lt;bp@alien8.de&gt;
Cc: Brian Gerst &lt;brgerst@gmail.com&gt;
Cc: Denys Vlasenko &lt;dvlasenk@redhat.com&gt;
Cc: H. Peter Anvin &lt;hpa@zytor.com&gt;
Cc: Kees Cook &lt;keescook@chromium.org&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Paul Mackerras &lt;paulus@samba.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Valdis Kletnieks &lt;Valdis.Kletnieks@vt.edu&gt;
Cc: Vince Weaver &lt;vince@deater.net&gt;
Cc: hillf.zj &lt;hillf.zj@alibaba-inc.com&gt;
Fixes: a66734297f78 ("perf/x86: Add /sys/devices/cpu/rdpmc=2 to allow rdpmc for all tasks")
Link: http://lkml.kernel.org/r/20150709172338.GC19282@twins.programming.kicks-ass.net
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</pre>
</div>
</content>
</entry>
</feed>
