<feed xmlns='http://www.w3.org/2005/Atom'>
<title>user/sven/linux.git, branch v4.8.13</title>
<subtitle>Linux Kernel
</subtitle>
<id>https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v4.8.13</id>
<link rel='self' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/atom?h=v4.8.13'/>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/'/>
<updated>2016-12-08T06:16:36Z</updated>
<entry>
<title>Linux 4.8.13</title>
<updated>2016-12-08T06:16:36Z</updated>
<author>
<name>Greg Kroah-Hartman</name>
<email>gregkh@linuxfoundation.org</email>
</author>
<published>2016-12-08T06:16:36Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=55d64c0b3c15cb5fb4d5a5bdebde9522e4ed52ff'/>
<id>urn:sha1:55d64c0b3c15cb5fb4d5a5bdebde9522e4ed52ff</id>
<content type='text'>
</content>
</entry>
<entry>
<title>arm64: suspend: Reconfigure PSTATE after resume from idle</title>
<updated>2016-12-08T06:16:20Z</updated>
<author>
<name>James Morse</name>
<email>james.morse@arm.com</email>
</author>
<published>2016-10-18T10:27:48Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=a4edb1a2b04597df75558d9fa6dbab7b28254895'/>
<id>urn:sha1:a4edb1a2b04597df75558d9fa6dbab7b28254895</id>
<content type='text'>
commit d08544127d9fb4505635e3cb6871fd50a42947bd upstream.

The suspend/resume path in kernel/sleep.S, as used by cpu-idle, does not
save/restore PSTATE. As a result of this cpufeatures that were detected
and have bits in PSTATE get lost when we resume from idle.

UAO gets set appropriately on the next context switch. PAN will be
re-enabled next time we return from user-space, but on a preemptible
kernel we may run work accessing user space before this point.

Add code to re-enable theses two features in __cpu_suspend_exit().
We re-use uao_thread_switch() passing current.

Signed-off-by: James Morse &lt;james.morse@arm.com&gt;
Cc: Lorenzo Pieralisi &lt;lorenzo.pieralisi@arm.com&gt;
Signed-off-by: Will Deacon &lt;will.deacon@arm.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>arm64: mm: Set PSTATE.PAN from the cpu_enable_pan() call</title>
<updated>2016-12-08T06:16:20Z</updated>
<author>
<name>James Morse</name>
<email>james.morse@arm.com</email>
</author>
<published>2016-10-18T10:27:47Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=6353400d91305273452dbe0d26a1dfd3c975ae91'/>
<id>urn:sha1:6353400d91305273452dbe0d26a1dfd3c975ae91</id>
<content type='text'>
commit 7209c868600bd8926e37c10b9aae83124ccc1dd8 upstream.

Commit 338d4f49d6f7 ("arm64: kernel: Add support for Privileged Access
Never") enabled PAN by enabling the 'SPAN' feature-bit in SCTLR_EL1.
This means the PSTATE.PAN bit won't be set until the next return to the
kernel from userspace. On a preemptible kernel we may schedule work that
accesses userspace on a CPU before it has done this.

Now that cpufeature enable() calls are scheduled via stop_machine(), we
can set PSTATE.PAN from the cpu_enable_pan() call.

Add WARN_ON_ONCE(in_interrupt()) to check the PSTATE value we updated
is not immediately discarded.

Reported-by: Tony Thompson &lt;anthony.thompson@arm.com&gt;
Reported-by: Vladimir Murzin &lt;vladimir.murzin@arm.com&gt;
Signed-off-by: James Morse &lt;james.morse@arm.com&gt;
[will: fixed typo in comment]
Signed-off-by: Will Deacon &lt;will.deacon@arm.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>arm64: cpufeature: Schedule enable() calls instead of calling them via IPI</title>
<updated>2016-12-08T06:16:20Z</updated>
<author>
<name>James Morse</name>
<email>james.morse@arm.com</email>
</author>
<published>2016-10-18T10:27:46Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=b49b1ae6d341f2a0940413338d3c2351c27a7537'/>
<id>urn:sha1:b49b1ae6d341f2a0940413338d3c2351c27a7537</id>
<content type='text'>
commit 2a6dcb2b5f3e21592ca8dfa198dcce7bec09b020 upstream.

The enable() call for a cpufeature/errata is called using on_each_cpu().
This issues a cross-call IPI to get the work done. Implicitly, this
stashes the running PSTATE in SPSR when the CPU receives the IPI, and
restores it when we return. This means an enable() call can never modify
PSTATE.

To allow PAN to do this, change the on_each_cpu() call to use
stop_machine(). This schedules the work on each CPU which allows
us to modify PSTATE.

This involves changing the protype of all the enable() functions.

enable_cpu_capabilities() is called during boot and enables the feature
on all online CPUs. This path now uses stop_machine(). CPU features for
hotplug'd CPUs are enabled by verify_local_cpu_features() which only
acts on the local CPU, and can already modify the running PSTATE as it
is called from secondary_start_kernel().

Reported-by: Tony Thompson &lt;anthony.thompson@arm.com&gt;
Reported-by: Vladimir Murzin &lt;vladimir.murzin@arm.com&gt;
Signed-off-by: James Morse &lt;james.morse@arm.com&gt;
Cc: Suzuki K Poulose &lt;suzuki.poulose@arm.com&gt;
Signed-off-by: Will Deacon &lt;will.deacon@arm.com&gt;
[Removed enable() hunks for A53 workaround]
Signed-off-by: James Morse &lt;james.morse@arm.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>batman-adv: Detect missing primaryif during tp_send as error</title>
<updated>2016-12-08T06:16:20Z</updated>
<author>
<name>Sven Eckelmann</name>
<email>sven@narfation.org</email>
</author>
<published>2016-10-29T07:18:43Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=e4e77deda20081cdd9b5217dc41b6d00356bf15f'/>
<id>urn:sha1:e4e77deda20081cdd9b5217dc41b6d00356bf15f</id>
<content type='text'>
commit e13258f38e927b61cdb5f4ad25309450d3b127d1 upstream.

The throughput meter detects different situations as problems for the
current test. It stops the test after these and reports it to userspace.
This also has to be done when the primary interface disappeared during the
test.

Fixes: 33a3bb4a3345 ("batman-adv: throughput meter implementation")
Reported-by: Joe Perches &lt;joe@perches.com&gt;
Signed-off-by: Sven Eckelmann &lt;sven@narfation.org&gt;
Signed-off-by: Simon Wunderlich &lt;sw@simonwunderlich.de&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>clk: sunxi: Fix M factor computation for APB1</title>
<updated>2016-12-08T06:16:20Z</updated>
<author>
<name>Stéphan Rafin</name>
<email>stephan@soliotek.com</email>
</author>
<published>2016-11-03T23:53:56Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=f106de5604ddb831df2a1a8f7e4b564a74514d66'/>
<id>urn:sha1:f106de5604ddb831df2a1a8f7e4b564a74514d66</id>
<content type='text'>
commit ac95330b96376550ae7a533d1396272d675adfa2 upstream.

commit cfa636886033 ("clk: sunxi: factors: Consolidate get_factors
parameters into a struct") introduced a regression for m factor
computation in sun4i_get_apb1_factors function.

The old code reassigned the "parent_rate" parameter to the targeted
divisor value and was buggy for the returned frequency but not for the
computed factors. Now, returned frequency is good but m factor is
incorrectly computed (its max value 31 is always set resulting in a
significantly slower frequency than the requested one...)

This patch simply restores the original proper computation for m while
keeping the good changes for returned rate.

Fixes: cfa636886033 ("clk: sunxi: factors: Consolidate get_factors parameters into a struct")
Signed-off-by: Stéphan Rafin &lt;stephan@soliotek.com&gt;
Signed-off-by: Maxime Ripard &lt;maxime.ripard@free-electrons.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>perf/x86: Restore TASK_SIZE check on frame pointer</title>
<updated>2016-12-08T06:16:20Z</updated>
<author>
<name>Johannes Weiner</name>
<email>hannes@cmpxchg.org</email>
</author>
<published>2016-11-22T09:57:42Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=9e2d9e95094a9326b140ac8bd173f3dc07a26c12'/>
<id>urn:sha1:9e2d9e95094a9326b140ac8bd173f3dc07a26c12</id>
<content type='text'>
commit ae31fe51a3cceaa0cabdb3058f69669ecb47f12e upstream.

The following commit:

  75925e1ad7f5 ("perf/x86: Optimize stack walk user accesses")

... switched from copy_from_user_nmi() to __copy_from_user_nmi() with a manual
access_ok() check.

Unfortunately, copy_from_user_nmi() does an explicit check against TASK_SIZE,
whereas the access_ok() uses whatever the current address limit of the task is.

We are getting NMIs when __probe_kernel_read() has switched to KERNEL_DS, and
then see vmalloc faults when we access what looks like pointers into vmalloc
space:

  [] WARNING: CPU: 3 PID: 3685731 at arch/x86/mm/fault.c:435 vmalloc_fault+0x289/0x290
  [] CPU: 3 PID: 3685731 Comm: sh Tainted: G        W       4.6.0-5_fbk1_223_gdbf0f40 #1
  [] Call Trace:
  []  &lt;NMI&gt;  [&lt;ffffffff814717d1&gt;] dump_stack+0x4d/0x6c
  []  [&lt;ffffffff81076e43&gt;] __warn+0xd3/0xf0
  []  [&lt;ffffffff81076f2d&gt;] warn_slowpath_null+0x1d/0x20
  []  [&lt;ffffffff8104a899&gt;] vmalloc_fault+0x289/0x290
  []  [&lt;ffffffff8104b5a0&gt;] __do_page_fault+0x330/0x490
  []  [&lt;ffffffff8104b70c&gt;] do_page_fault+0xc/0x10
  []  [&lt;ffffffff81794e82&gt;] page_fault+0x22/0x30
  []  [&lt;ffffffff81006280&gt;] ? perf_callchain_user+0x100/0x2a0
  []  [&lt;ffffffff8115124f&gt;] get_perf_callchain+0x17f/0x190
  []  [&lt;ffffffff811512c7&gt;] perf_callchain+0x67/0x80
  []  [&lt;ffffffff8114e750&gt;] perf_prepare_sample+0x2a0/0x370
  []  [&lt;ffffffff8114e840&gt;] perf_event_output+0x20/0x60
  []  [&lt;ffffffff8114aee7&gt;] ? perf_event_update_userpage+0xc7/0x130
  []  [&lt;ffffffff8114ea01&gt;] __perf_event_overflow+0x181/0x1d0
  []  [&lt;ffffffff8114f484&gt;] perf_event_overflow+0x14/0x20
  []  [&lt;ffffffff8100a6e3&gt;] intel_pmu_handle_irq+0x1d3/0x490
  []  [&lt;ffffffff8147daf7&gt;] ? copy_user_enhanced_fast_string+0x7/0x10
  []  [&lt;ffffffff81197191&gt;] ? vunmap_page_range+0x1a1/0x2f0
  []  [&lt;ffffffff811972f1&gt;] ? unmap_kernel_range_noflush+0x11/0x20
  []  [&lt;ffffffff814f2056&gt;] ? ghes_copy_tofrom_phys+0x116/0x1f0
  []  [&lt;ffffffff81040d1d&gt;] ? x2apic_send_IPI_self+0x1d/0x20
  []  [&lt;ffffffff8100411d&gt;] perf_event_nmi_handler+0x2d/0x50
  []  [&lt;ffffffff8101ea31&gt;] nmi_handle+0x61/0x110
  []  [&lt;ffffffff8101ef94&gt;] default_do_nmi+0x44/0x110
  []  [&lt;ffffffff8101f13b&gt;] do_nmi+0xdb/0x150
  []  [&lt;ffffffff81795187&gt;] end_repeat_nmi+0x1a/0x1e
  []  [&lt;ffffffff8147daf7&gt;] ? copy_user_enhanced_fast_string+0x7/0x10
  []  [&lt;ffffffff8147daf7&gt;] ? copy_user_enhanced_fast_string+0x7/0x10
  []  [&lt;ffffffff8147daf7&gt;] ? copy_user_enhanced_fast_string+0x7/0x10
  []  &lt;&lt;EOE&gt;&gt;  &lt;IRQ&gt;  [&lt;ffffffff8115d05e&gt;] ? __probe_kernel_read+0x3e/0xa0

Fix this by moving the valid_user_frame() check to before the uaccess
that loads the return address and the pointer to the next frame.

Signed-off-by: Johannes Weiner &lt;hannes@cmpxchg.org&gt;
Signed-off-by: Peter Zijlstra (Intel) &lt;peterz@infradead.org&gt;
Cc: Alexander Shishkin &lt;alexander.shishkin@linux.intel.com&gt;
Cc: Arnaldo Carvalho de Melo &lt;acme@redhat.com&gt;
Cc: Jiri Olsa &lt;jolsa@redhat.com&gt;
Cc: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
Cc: Peter Zijlstra &lt;peterz@infradead.org&gt;
Cc: Stephane Eranian &lt;eranian@google.com&gt;
Cc: Thomas Gleixner &lt;tglx@linutronix.de&gt;
Cc: Vince Weaver &lt;vincent.weaver@maine.edu&gt;
Cc: linux-kernel@vger.kernel.org
Fixes: 75925e1ad7f5 ("perf/x86: Optimize stack walk user accesses")
Signed-off-by: Ingo Molnar &lt;mingo@kernel.org&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>drm/mediatek: fix null pointer dereference</title>
<updated>2016-12-08T06:16:20Z</updated>
<author>
<name>Matthias Brugger</name>
<email>matthias.bgg@gmail.com</email>
</author>
<published>2016-11-18T10:06:10Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=ab34b429a01f608488016ce207ab7dda1fcdcfe3'/>
<id>urn:sha1:ab34b429a01f608488016ce207ab7dda1fcdcfe3</id>
<content type='text'>
commit 5ad45307d990020b25a8f7486178b6e033790f70 upstream.

The probe function requests the interrupt before initializing
the ddp component. Which leads to a null pointer dereference at boot.
Fix this by requesting the interrput after all components got
initialized properly.

Fixes: 119f5173628a ("drm/mediatek: Add DRM Driver for Mediatek SoC MT8173.")
Signed-off-by: Matthias Brugger &lt;matthias.bgg@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

Change-Id: I57193a7ab554dfb37c35a455900689333adf511c

</content>
</entry>
<entry>
<title>pwm: Fix device reference leak</title>
<updated>2016-12-08T06:16:20Z</updated>
<author>
<name>Johan Hovold</name>
<email>johan@kernel.org</email>
</author>
<published>2016-11-01T10:46:39Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=43b5bb262711e0e81ea348072a01ef1744b157ca'/>
<id>urn:sha1:43b5bb262711e0e81ea348072a01ef1744b157ca</id>
<content type='text'>
commit 0e1614ac84f1719d87bed577963bb8140d0c9ce8 upstream.

Make sure to drop the reference to the parent device taken by
class_find_device() after "unexporting" any children when deregistering
a PWM chip.

Fixes: 0733424c9ba9 ("pwm: Unexport children before chip removal")
Signed-off-by: Johan Hovold &lt;johan@kernel.org&gt;
Signed-off-by: Thierry Reding &lt;thierry.reding@gmail.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
<entry>
<title>KVM: use after free in kvm_ioctl_create_device()</title>
<updated>2016-12-08T06:16:19Z</updated>
<author>
<name>Dan Carpenter</name>
<email>dan.carpenter@oracle.com</email>
</author>
<published>2016-11-30T19:21:05Z</published>
<link rel='alternate' type='text/html' href='https://git.stealer.net/cgit.cgi/user/sven/linux.git/commit/?id=6c69476139799ccf8d3e76edfc892c64ced80bc4'/>
<id>urn:sha1:6c69476139799ccf8d3e76edfc892c64ced80bc4</id>
<content type='text'>
commit a0f1d21c1ccb1da66629627a74059dd7f5ac9c61 upstream.

We should move the ops-&gt;destroy(dev) after the list_del(&amp;dev-&gt;vm_node)
so that we don't use "dev" after freeing it.

Fixes: a28ebea2adc4 ("KVM: Protect device ops-&gt;create and list_add with kvm-&gt;lock")
Signed-off-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Reviewed-by: David Hildenbrand &lt;david@redhat.com&gt;
Signed-off-by: Radim Krčmář &lt;rkrcmar@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;

</content>
</entry>
</feed>
