From: Wanpeng Li
Reported by syzkaller:
[ cut here ]
WARNING: CPU: 5 PID: 2939 at arch/x86/kvm/vmx.c:3844
free_loaded_vmcs+0x77/0x80 [kvm_intel]
CPU: 5 PID: 2939 Comm: repro Not tainted 4.14.0+ #26
RIP: 0010:free_loaded_vmcs+0x77/0x80 [kvm
On Wed, Nov 22, 2017 at 12:31:09AM -0500, Sinan Kaya wrote:
> pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
> where a PCI device is present. This restricts the device drivers to be
> reused for other domain numbers.
>
> Use pci_get_domain_bus_and_slot() with a domain numbe
On Wed, Nov 22, 2017 at 12:31:14AM -0500, Sinan Kaya wrote:
> pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
> where a PCI device is present. This restricts the device drivers to be
> reused for other domain numbers.
>
> Use pci_get_domain_bus_and_slot() with a domain numbe
Commit-ID: f68d62a56708b0c19dca7a998f408510f2fbc3a8
Gitweb: https://git.kernel.org/tip/f68d62a56708b0c19dca7a998f408510f2fbc3a8
Author: Andrey Ryabinin
AuthorDate: Wed, 15 Nov 2017 17:36:35 -0800
Committer: Ingo Molnar
CommitDate: Wed, 22 Nov 2017 07:18:35 +0100
x86/mm/kasan: Don't use
On Tue, 21 Nov 2017 17:25:05 +0100,
Takashi Iwai wrote:
>
> On Tue, 21 Nov 2017 17:14:42 +0100,
> Laura Abbott wrote:
> >
> > Hi,
> >
> > Fedora got a bug report
> > (https://bugzilla.redhat.com/show_bug.cgi?id=1512853)
> > that Line Out stopped working between 4.13.9 and 4.13.10. Reverting
> >
On Wed, Nov 22, 2017 at 12:30:57AM -0500, Sinan Kaya wrote:
> pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
> where a PCI device is present. This restricts the device drivers to be
> reused for other domain numbers.
>
> Use pci_get_domain_bus_and_slot() with a domain numbe
On 11/21/17 23:41, kbuild test robot wrote:
> Hi Jesse,
>
> Thank you for the patch! Yet something to improve:
missing
#include
Jesse, did you build all of these driver changes?
> [auto build test ERROR on linuxtv-media/master]
> [also build test ERROR on v4.14 next-20171
On Wed, Nov 22, 2017 at 12:08:45AM -0600, Timur Tabi wrote:
> On 11/21/17 11:55 PM, Sinan Kaya wrote:
> > For places where domain number information is available, I extracted domain
> > number
> > and added into pci_get_domain_bus_and_slot() call such as xen or bn drivers.
>
> My suggestion is th
As per APIs each mc-portal is of 64K size while currently
16bits (type u16) is used to store size of mc-portal.
In these cases upper bit of portal size gets truncated.
Signed-off-by: Bharat Bhushan
---
v2->v3:
- v2 patch: https://patchwork.kernel.org/patch/10067661/
- Changes patch subject and
Commit-ID: 548c3050ea8d16997ae27f9e080a8338a606fc93
Gitweb: https://git.kernel.org/tip/548c3050ea8d16997ae27f9e080a8338a606fc93
Author: Andy Lutomirski
AuthorDate: Tue, 21 Nov 2017 20:43:56 -0800
Committer: Ingo Molnar
CommitDate: Wed, 22 Nov 2017 06:35:48 +0100
x86/entry/64: Fix entry
* Ingo Molnar wrote:
>
> * Andy Lutomirski wrote:
>
> > This sets up stack switching, including for SYSCALL. I think it's
> > in decent shape.
> >
> > Known issues:
> > - I think we're going to want a way to turn the stack switching on and
> >off either at boot time or at runtime. It
From: Satheesh Rajendran
Certain systems are designed to have sparse/discontiguous nodes.
On such systems, perf bench numa hangs, shows wrong number of nodes
and shows values for non-existent nodes. Handle this by only
taking nodes that are exposed by kernel to userspace.
Cc: Arnaldo Carvalho de
From: Satheesh Rajendran
Certain systems would have sparse/discontinguous
numa nodes.
perf bench numa doesnt work well on such nodes.
1. It shows wrong values.
2. It can hang.
3. It can show redundant information for non-existant nodes.
#numactl -H
available: 2 nodes (0,8)
node 0 cpus: 0 1 2 3
Hi Jesse,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on linuxtv-media/master]
[also build test ERROR on v4.14 next-20171121]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system]
url:
https://github.com/0day-ci
On 11/22/2017 02:58 AM, Ben Hutchings wrote:
> 3.16.51-rc1 review patch. If anyone has any objections, please let me know.
I don't really care much in the end, but is "fix wrong comment" really a
stable patch material these days? :)
> --
>
> From: SeongJae Park
>
> commit f113
On 21/11/17 17:39, Ulf Hansson wrote:
> On 21 November 2017 at 14:42, Adrian Hunter wrote:
>> card_busy_detect() has a 10 minute timeout. However the correct timeout is
>> the data timeout. Change card_busy_detect() to use the data timeout.
>
> Unfortunate I don't think there is "correct" timeout
* Andy Lutomirski wrote:
> This sets up stack switching, including for SYSCALL. I think it's
> in decent shape.
>
> Known issues:
> - I think we're going to want a way to turn the stack switching on and
>off either at boot time or at runtime. It should be fairly straightforward
>to m
Hi Tim,
On Thu, Nov 09, 2017 at 10:45:33AM -0800, Tim Harvey wrote:
> Cc: Rob Herring
> Signed-off-by: Tim Harvey
> ---
> v3:
> - fix typo
>
> v2:
> - add vendor prefix and remove _ from vidout-portcfg
> - remove _ from labels
> - remove max-pixel-rate property
> - describe and provide exa
tree: https://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git
rcu/dev
head: b151f93a71fc9fecb560e823a92402d882516483
commit: b151f93a71fc9fecb560e823a92402d882516483 [62/62] torture: Eliminate
torture_runnable
config: i386-randconfig-x008-201747 (attached as .config)
compiler: g
Jens, please don't just revert the commit in your for-linus tree.
On its own this will totally mess up the interrupt assignments. Give
me a bit of time to sort this out properly.
Le 22/11/2017 à 00:07, Balbir Singh a écrit :
On Wed, Nov 22, 2017 at 1:28 AM, Christophe Leroy
wrote:
On powerpc32, patch_instruction() is called by apply_feature_fixups()
which is called from early_init()
There is the following note in front of early_init():
* Note that the kernel may be
tree: https://git.kernel.org/pub/scm/linux/kernel/git/paulmck/linux-rcu.git
rcu/dev
head: b151f93a71fc9fecb560e823a92402d882516483
commit: b151f93a71fc9fecb560e823a92402d882516483 [62/62] torture: Eliminate
torture_runnable
config: i386-randconfig-x001-201747 (attached as .config)
compiler: g
* Ian Abbott [2017-11-20 10:46:36 +]:
On 20/11/17 10:29, Ian Abbott wrote:
On 20/11/17 07:50, Jesse Chan wrote:
This change resolves a new compile-time warning
when built as a loadable module:
WARNING: modpost: missing MODULE_LICENSE() in
drivers/staging/comedi/drivers/ni_atmio.o
see i
Great news, that it works for you!
Thanks a lot!
Pavel
On 11/22/2017 03:49 AM, Stuart Hayes wrote:
My apologies... yes, your patch also fixes my issue. I was looking at the two
new places from which you were calling scsi_eh_wakeup(), and didn't notice that
you moved the spinlock in scsi_devi
On 11/22/2017 2:31 PM, Ravi Bangoria wrote:
On 11/20/2017 08:13 PM, Jin Yao wrote:
@@ -76,6 +97,17 @@ static struct rb_node *saved_value_new(struct
rblist *rblist __maybe_unused,
return &nd->rb_node;
}
+static void saved_value_delete(struct rblist *rblist __maybe_unused,
+
> > > On 10/20/2017 08:12 PM, alexander.stef...@infineon.com wrote:
> > > >> The TPM burstcount status indicates the number of bytes that can
> > > >> be sent to the TPM without causing bus wait states. Effectively,
> > > >> it is the number of empty bytes in the command FIFO.
> > > >>
> > > >> Th
Reviewed-by: Keiji Hayashibara
Thanks.
-
Best Regards,
Keiji Hayashibara
> -Original Message-
> From: Kunihiko Hayashi [mailto:hayashi.kunih...@socionext.com]
> Sent: Wednesday, November 22, 2017 2:15 PM
> To: Srinivas Kandagatla
> Cc: Yamada, Masahiro/山田 真弘 ; Hayashibara,
> Keiji
Hi,
I am trying to bring up suspend-to-disk (snapshot boot) on jetson-tx2
board (nvidia tegra186).
Suspend is working fine, but during boot with snapshot image, emmc
resume is failing.
Kernel version: 4.4
Repo: https://nv-tegra.nvidia.com/gitweb/?p=linux-4.4.git;a=summary
repo: tegra-l4t-r27.1
I
* Ingo Molnar wrote:
>
> * Andy Lutomirski wrote:
>
> > This sets up stack switching, including for SYSCALL. I think it's
> > in decent shape.
> >
> > Known issues:
> > - I think we're going to want a way to turn the stack switching on and
> >off either at boot time or at runtime. It
On 11/20/2017 08:13 PM, Jin Yao wrote:
@@ -76,6 +97,17 @@ static struct rb_node *saved_value_new(struct rblist *rblist
__maybe_unused,
return &nd->rb_node;
}
+static void saved_value_delete(struct rblist *rblist __maybe_unused,
+ struct rb_node *rb_node)
* Andy Lutomirski wrote:
> This sets up stack switching, including for SYSCALL. I think it's
> in decent shape.
>
> Known issues:
> - I think we're going to want a way to turn the stack switching on and
>off either at boot time or at runtime. It should be fairly straightforward
>to m
2017-11-22 14:14 GMT+09:00 Kunihiko Hayashi :
> The efuse on UniPhier allows 8bit access according to the specification.
> Since bit offset of nvmem is limited to 0-7, it is desiable to change
> access unit of nvmem to 8bit.
>
> Signed-off-by: Kunihiko Hayashi
Tested on LD4, sLD8, Pro4, PXs2, LD
* Andy Lutomirski wrote:
> The cpu_entry_area will contain stacks. Make sure that KASAN has
> appropriate shadow mappings for them.
>
> Cc: Andrey Ryabinin
> Cc: Alexander Potapenko
> Cc: Dmitry Vyukov
> Cc: kasan-...@googlegroups.com
> Signed-off-by: Andy Lutomirski
> ---
> arch/x86/mm/k
Thanks Tobin, for your detailed comments.
On Wed, Nov 22, 2017 at 5:29 AM, Tobin C. Harding wrote:
> You don't typically need [xxx v1] for version 1, the v1 is implicit.
>
> Please use the git brief description prefix that is already in use i.e
>
> leaking_addresses: add support for 32-bi
On 11/21/17 11:55 PM, Sinan Kaya wrote:
For places where domain number information is available, I extracted domain
number
and added into pci_get_domain_bus_and_slot() call such as xen or bn drivers.
My suggestion is that you restrict your first patch set to only these
patches.
The assumpt
On Fri, Nov 17, 2017 at 02:33:04PM -0600, Tom Zanussi wrote:
> @@ -1387,6 +1405,8 @@ static struct trace_event_file *find_var_file(struct
> trace_array *tr,
> list_for_each_entry(var_data, &tr->hist_vars, list) {
> var_hist_data = var_data->hist_data;
> file = var
On 11/22/2017 12:45 AM, Timur Tabi wrote:
> On 11/21/17 11:31 PM, Sinan Kaya wrote:
>> Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
>> extract the domain number. Other places, use the actual domain number from
>> the device.
>>
>> Now that all users of pci_get_bus_and_
On 11/21/17 11:31 PM, Sinan Kaya wrote:
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the actual domain number from
the device.
Now that all users of pci_get_bus_and_slot() switched to
pci_get_domain_bus_and_slot(), it is
2017-11-09 18:42 GMT+08:00 Vincent Chen :
>>>On Wed, Nov 8, 2017 at 6:55 AM, Greentime Hu wrote:
>>> +
>>> +static inline void __delay(unsigned long loops) {
>>> + __asm__ __volatile__(".align 2\n"
>>> +"1:\n"
>>> +"\taddi\t%0, %0, -1\n
"Kirill A. Shutemov" writes:
> With 5-level paging, we have 56-bit virtual address space available for
> userspace. But we don't want to expose userspace to addresses above
> 47-bits, unless it asked specifically for it.
>
> We use mmap(2) hint address as a way for kernel to know if it's okay to
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
On 11/21/2017 11:18 PM, Jiri Olsa wrote:
On Mon, Nov 20, 2017 at 10:43:43PM +0800, Jin Yao wrote:
Currently, if we execute 'perf stat --per-thread' without specifying
pid/tid, perf will return error.
root@skl:/tmp# perf stat --per-thread
The --per-thread option is only available when monitori
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
On Tue, 2017-11-21 at 22:50 -0500, Steven Rostedt wrote:
>
> Does it work if you revert the patch?
That would restore the gripe. How about this..
mm, memcg: serialize consume_stock(), drain_local_stock() and refill_stock()
Haiyang HY1 Tan reports encountering races between drain_stock() and
re
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
* Andy Lutomirski wrote:
> When I added entry_SYSCALL_64_after_hwframe, I left TRACE_IRQS_OFF
> before it. This means that users of entry_SYSCALL_64_after_hwframe
> were responsible for invoking TRACE_IRQS_OFF, and the one and only
> user (added in the same commit) got it wrong.
>
> I think th
On 11/21/2017 11:18 PM, Jiri Olsa wrote:
On Mon, Nov 20, 2017 at 10:43:43PM +0800, Jin Yao wrote:
SNIP
diff --git a/tools/perf/util/target.h b/tools/perf/util/target.h
index 446aa7a..6ef01a8 100644
--- a/tools/perf/util/target.h
+++ b/tools/perf/util/target.h
@@ -64,6 +64,11 @@ static inline
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
pci_get_bus_and_slot() is restrictive such that it assumes domain=0 as
where a PCI device is present. This restricts the device drivers to be
reused for other domain numbers.
Use pci_get_domain_bus_and_slot() with a domain number of 0 where we can't
extract the domain number. Other places, use the
Hello,
On (11/22/17 11:27), Fengguang Wu wrote:
> [CC LKML for possible printk improvements]
[..]
> > > In kernelCI, we're considering submitting a patch to add a
> > > "show_loglevel" command-line argument to enable that option on kernel
> > > boot.
> >
> > Thanks for doing that patch! It'll o
Here are the results of schbench(scheduler latency benchmark) and uperf
(networking benchmark).
Hardware config: 20 core (40 hyperthreaded cpus) x86 box.
schbench config: message threads = 2; time = 180s, worker thread = variable
uperf config:ping pong test on loopback interface with message siz
The efuse on UniPhier allows 8bit access according to the specification.
Since bit offset of nvmem is limited to 0-7, it is desiable to change
access unit of nvmem to 8bit.
Signed-off-by: Kunihiko Hayashi
---
drivers/nvmem/uniphier-efuse.c | 10 +-
1 file changed, 5 insertions(+), 5 dele
On 2017년 11월 17일 00:27, Joe Perches wrote:
> Line continuations with excess spacing causes unexpected output.
>
> Signed-off-by: Joe Perches
> ---
> drivers/devfreq/rk3399_dmc.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/devfreq/rk3399_dmc.c b/drivers/d
Make the cryptd queue length configurable. We recently had customer where this
needed to be tuned to accommodate the aesni_intel module and prevent packet
drop.
Signed-off-by: Jon Maxwell
---
crypto/cryptd.c | 7 +--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/crypto/cryp
On Wed, Nov 15, 2017 at 09:23:31AM -0800, Song Liu wrote:
> Changes RFC v2 to PATCH v1:
> Check type PERF_TYPE_PROBE in perf_event_set_filter().
> Rebase on to tip perf/core.
>
> Changes RFC v1 to RFC v2:
> Fix build issue reported by kbuild test bot by adding ifdef of
> CONFIG_KPROBE_EVEN
When I added entry_SYSCALL_64_after_hwframe, I left TRACE_IRQS_OFF
before it. This means that users of entry_SYSCALL_64_after_hwframe
were responsible for invoking TRACE_IRQS_OFF, and the one and only
user (added in the same commit) got it wrong.
I think this would manifest as a warning if a Xen
get_stack_info() doesn't currently know about the SYSENTER stack, so
unwinding will fail if we entered the kernel on the SYSENTER stack
and haven't fully switched off. Teach get_stack_info() about the
SYSENTER stack.
With future patches applied that run part of the entry code on the
SYSENTER stac
We currently special-case stack overflow on the task stack. We're
going to start putting special stacks in the fixmap with a custom
layout, so they'll have guard pages, too. Teach the unwinder to be
able to unwind an overflow of any of the stacks.
Signed-off-by: Andy Lutomirski
---
arch/x86/ke
The cpu_entry_area will contain stacks. Make sure that KASAN has
appropriate shadow mappings for them.
Cc: Andrey Ryabinin
Cc: Alexander Potapenko
Cc: Dmitry Vyukov
Cc: kasan-...@googlegroups.com
Signed-off-by: Andy Lutomirski
---
arch/x86/mm/kasan_init_64.c | 9 -
1 file changed, 8
I want SYSENTER_stack to have reliable overflow detection, which
means that it needs to be at the bottom of a page, not the top.
Move it to the beginning of struct tss_struct and page-align it.
Also add an assertion to make sure that the fixed hardware TSS
doesn't cross a page boundary.
Signed-of
I'm going to move SYSENTER_stack to the beginning of cpu_tss to help
detect overflow. Before this can happen, I need to fix several code
paths that hardcode assumptions about the old layout.
Reviewed-by: Thomas Gleixner
Signed-off-by: Andy Lutomirski
---
arch/x86/include/asm/desc.h | 2 +
On Tue, Nov 21, 2017 at 8:11 PM, Andy Lutomirski wrote:
> On Tue, Nov 21, 2017 at 7:33 PM, Andy Lutomirski wrote:
>> I'm doing:
>>
>> /usr/bin/qemu-system-x86_64 -machine accel=kvm:tcg -cpu host -net none
>> -nographic -kernel xen-4.8.2 -initrd './arch/x86/boot/bzImage' -m 2G
>> -smp 2 -append co
This has a secondary purpose: it puts the entry stack into a region
with a well-controlled layout. A subsequent patch will take
advantage of this to streamline the SYSCALL entry code to be able to
find it more easily.
Signed-off-by: Andy Lutomirski
---
arch/x86/entry/entry_32.S | 6 --
We currently have CPU 0's GDT at the top of the GDT range and
higher-numbered CPUs at lower addreses. This happens because the
fixmap is upside down (index 0 is the top of the fixmap).
Flip it so that GDTs are in ascending order by virtual address.
This will simplify a future patch that will gene
By itself, this is useless. It gives us the ability to run some final
code before exit that cannnot run on the kernel stack. This could
include a CR3 switch a la KAISER or some kernel stack erasing, for
example. (Or even weird things like *changing* which kernel stack
gets used as an ASLR-streng
On 64-bit kernels, we used to assume that TSS.sp0 was the current
top of stack. With the addition of an entry trampoline, this will
no longer be the case. Store the current top of stack in TSS.sp1,
which is otherwise unused but shares the same cacheline.
Signed-off-by: Andy Lutomirski
---
arch
When we start using an entry trampoline, a #GP from userspace will
be delivered on the entry stack, not on the task stack. Fix the
espfix64 #DF fixup to set up #GP according to TSS.SP0, rather than
assuming that pt_regs + 1 == SP0. This won't change anything
without an entry stack, but it will ma
That race has been fixed and code cleaned up for a while now.
Signed-off-by: Andy Lutomirski
---
arch/x86/kernel/irq.c | 12
1 file changed, 12 deletions(-)
diff --git a/arch/x86/kernel/irq.c b/arch/x86/kernel/irq.c
index 49cfd9fe7589..68e1867cca80 100644
--- a/arch/x86/kernel/irq.
Historically, IDT entries from usermode have always gone directly
to the running task's kernel stack. Rearrange it so that we enter on
a percpu trampoline stack and then manually switch to the task's stack.
This touches a couple of extra cachelines, but it gives us a chance
to run some code before
In case something goes wrong with unwind (not unlikely in case of
overflow), print the offending IP where we detected the overflow.
Signed-off-by: Andy Lutomirski
---
arch/x86/kernel/irq_64.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/arch/x86/kernel/irq_64.c b/arch/
Handling SYSCALL is tricky: the SYSCALL handler is entered with every
single register (except FLAGS), including RSP, live. It somehow needs
to set RSP to point to a valid stack, which means it needs to save the
user RSP somewhere and find its own stack pointer. The canonical way
to do this is wit
The IST stacks are needed when an IST exception occurs and are
accessed before any kernel code at all runs. Move them into
cpu_entry_area.
Signed-off-by: Andy Lutomirski
---
arch/x86/include/asm/fixmap.h | 10 ++
arch/x86/kernel/cpu/common.c | 40 +--
Currently, the GDT is an ad-hoc array of pages, one per CPU, in the
fixmap. Generalize it to be an array of a new struct cpu_entry_area
so that we can cleanly add new things to it.
Signed-off-by: Andy Lutomirski
---
arch/x86/include/asm/desc.h | 9 +
arch/x86/include/asm/fixmap.h | 3
This will simplify future changes that want scratch variables early in
the SYSENTER handler -- they'll be able to spill registers to the
stack. It also lets us get rid of a SWAPGS_UNSAFE_STACK user.
This does not depend on CONFIG_IA32_EMULATION because we'll want the
stack space even without IA32
This sets up stack switching, including for SYSCALL. I think it's
in decent shape.
Known issues:
- I think we're going to want a way to turn the stack switching on and
off either at boot time or at runtime. It should be fairly straightforward
to make it work.
- I think the ORC unwinder
1 - 100 of 995 matches
Mail list logo