Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-11-17 Thread Namhyung Kim
Hi, Thanks for your detailed information, On Wed, Nov 16, 2016 at 07:10:36AM -0500, Paolo Bonzini wrote: > > Not sure how independent ERST is from ACPI and other specs. It looks > > like referencing UEFI spec at least. > > It is just the format of error records that comes from the UEFI spec > (

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-11-15 Thread Namhyung Kim
Hi, On Tue, Nov 15, 2016 at 11:38 PM, Paolo Bonzini wrote: > > > On 15/11/2016 15:36, Namhyung Kim wrote: >> Hi, >> >> On Tue, Nov 15, 2016 at 10:57:29AM +0100, Paolo Bonzini wrote: >>> >>> >>> On 15/11/2016 06:06, Michael S. Tsirkin wrote: &

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-11-15 Thread Namhyung Kim
Hi, On Tue, Nov 15, 2016 at 10:57:29AM +0100, Paolo Bonzini wrote: > > > On 15/11/2016 06:06, Michael S. Tsirkin wrote: > > On Tue, Nov 15, 2016 at 01:50:21PM +0900, Namhyung Kim wrote: > >> Hi Michael, > >> > >> On Thu, Nov 10, 2016 at 06:39:55PM +02

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-11-14 Thread Namhyung Kim
On Fri, Nov 11, 2016 at 12:50:03AM +0200, Michael S. Tsirkin wrote: > On Fri, Sep 16, 2016 at 07:05:47PM +0900, Namhyung Kim wrote: > > On Tue, Sep 13, 2016 at 06:57:10PM +0300, Michael S. Tsirkin wrote: > > > On Sat, Aug 20, 2016 at 05:07:43PM +0900, Namhyung Kim wrote: > &g

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-11-14 Thread Namhyung Kim
On Tue, Nov 15, 2016 at 07:06:28AM +0200, Michael S. Tsirkin wrote: > On Tue, Nov 15, 2016 at 01:50:21PM +0900, Namhyung Kim wrote: > > On Thu, Nov 10, 2016 at 06:39:55PM +0200, Michael S. Tsirkin wrote: > > [SNIP] > > > > +struct virtio_pstore_fileinfo { > > >

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-11-14 Thread Namhyung Kim
Hi Michael, On Thu, Nov 10, 2016 at 06:39:55PM +0200, Michael S. Tsirkin wrote: > On Sat, Aug 20, 2016 at 05:07:42PM +0900, Namhyung Kim wrote: > > The virtio pstore driver provides interface to the pstore subsystem so > > that the guest kernel's log/dump message can

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-09-22 Thread Namhyung Kim
On Thu, Sep 22, 2016 at 01:23:16PM +0100, Stefan Hajnoczi wrote: > On Sun, Sep 04, 2016 at 11:38:59PM +0900, Namhyung Kim wrote: > > +static void virtio_pstore_handle_io(VirtIODevice *vdev, VirtQueue *vq) > > +{ > > +VirtIOPstore *s = VIRTIO_PSTORE(vdev); > >

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-09-22 Thread Namhyung Kim
Hi Stefan, On Thu, Sep 22, 2016 at 12:57:44PM +0100, Stefan Hajnoczi wrote: > On Sun, Sep 04, 2016 at 11:38:58PM +0900, Namhyung Kim wrote: > > The virtio pstore driver provides interface to the pstore subsystem so > > that the guest kernel's log/dump message can be saved on

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-09-16 Thread Namhyung Kim
On Tue, Sep 13, 2016 at 06:57:10PM +0300, Michael S. Tsirkin wrote: > On Sat, Aug 20, 2016 at 05:07:43PM +0900, Namhyung Kim wrote: > > Add virtio pstore device to allow kernel log files saved on the host. > > It will save the log files on the directory given by pstore de

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-09-16 Thread Namhyung Kim
Hello Michael, Thanks for your detailed review. Btw are you ok with the overall direction of the patch? On Tue, Sep 13, 2016 at 06:19:41PM +0300, Michael S. Tsirkin wrote: > On Sat, Aug 20, 2016 at 05:07:42PM +0900, Namhyung Kim wrote: > > The virtio pstore driver provides interfa

[PATCH 2/3] qemu: Implement virtio-pstore device

2016-09-04 Thread Namhyung Kim
From: Namhyung Kim Add virtio pstore device to allow kernel log files saved on the host. It will save the log files on the directory given by pstore device option. $ qemu-system-x86_64 -device virtio-pstore,directory=dir-xx ... (guest) # echo c > /proc/sysrq-trigger $ ls dir-xx dm

[PATCH 3/3] kvmtool: Implement virtio-pstore device

2016-09-04 Thread Namhyung Kim
From: Namhyung Kim Add virtio pstore device to allow kernel log messages saved on the host. With this patch, it will save the log files under directory given by --pstore option. $ lkvm run --pstore=dir-xx (guest) # echo c > /proc/sysrq-trigger $ ls dir-xx dmesg-1.enc.z dmesg-2.en

[RFC/PATCHSET 0/3] virtio: Implement virtio pstore device (v5)

2016-09-04 Thread Namhyung Kim
ive <6>[0.00] SMBIOS 2.8 present. <7>[ 0.00] DMI: QEMU Standard PC (i440FX + PIIX, 1996), BIOS rel-1.9.3-0-ge2fc41e-prebuilt.qemu-project.org 04/01/2014 ... Namhyung Kim (3): virtio: Basic implementation of virtio pstore driver qemu: Implement virtio-pstor

[PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-09-04 Thread Namhyung Kim
oasis-open.org Cc: k...@vger.kernel.org Cc: qemu-de...@nongnu.org Cc: virtualization@lists.linux-foundation.org Signed-off-by: Namhyung Kim --- drivers/virtio/Kconfig | 10 + drivers/virtio/Makefile| 1 + drivers/virtio/virtio_pstore.c | 417 ++

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-08-31 Thread Namhyung Kim
Hi Michael, On Wed, Aug 31, 2016 at 05:54:04PM +0300, Michael S. Tsirkin wrote: > On Wed, Aug 31, 2016 at 05:08:00PM +0900, Namhyung Kim wrote: > > The virtio pstore driver provides interface to the pstore subsystem so > > that the guest kernel's log/dump message can

[PATCH 3/3] kvmtool: Implement virtio-pstore device

2016-08-31 Thread Namhyung Kim
From: Namhyung Kim Add virtio pstore device to allow kernel log messages saved on the host. With this patch, it will save the log files under directory given by --pstore option. $ lkvm run --pstore=dir-xx (guest) # echo c > /proc/sysrq-trigger $ ls dir-xx dmesg-1.enc.z dmesg-2.en

[PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-08-31 Thread Namhyung Kim
r.kernel.org Cc: qemu-de...@nongnu.org Cc: virtualization@lists.linux-foundation.org Cc: virtio-...@lists.oasis-open.org Signed-off-by: Namhyung Kim --- drivers/virtio/Kconfig | 10 + drivers/virtio/Makefile| 1 + drivers/virtio/virtio_pst

[PATCH 2/3] qemu: Implement virtio-pstore device

2016-08-31 Thread Namhyung Kim
From: Namhyung Kim Add virtio pstore device to allow kernel log files saved on the host. It will save the log files on the directory given by pstore device option. $ qemu-system-x86_64 -device virtio-pstore,directory=dir-xx ... (guest) # echo c > /proc/sysrq-trigger $ ls dir-xx dm

[RFC/PATCHSET 0/3] virtio: Implement virtio pstore device (v4)

2016-08-31 Thread Namhyung Kim
0.00] BIOS-e820: [mem 0xfeffc000-0xfeff] reserved <6>[0.00] BIOS-e820: [mem 0xfffc-0x] reserved <6>[0.00] NX (Execute Disable) protection: active <6>[0.00] SMBIOS 2.8 present. <7>[ 0.00

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-08-25 Thread Namhyung Kim
irtio-pstore.c > > @@ -0,0 +1,699 @@ > > +/* > > + * Virtio Pstore Device > > + * > > + * Copyright (C) 2016 LG Electronics > > + * > > + * Authors: > > + * Namhyung Kim > > + * > > + * This work is licensed under the terms of

[PATCH 3/3] kvmtool: Implement virtio-pstore device

2016-08-20 Thread Namhyung Kim
From: Namhyung Kim Add virtio pstore device to allow kernel log messages saved on the host. With this patch, it will save the log files under directory given by --pstore option. $ lkvm run --pstore=dir-xx (guest) # echo c > /proc/sysrq-trigger $ ls dir-xx dmesg-1.enc.z dmesg-2.en

[PATCH 2/3] qemu: Implement virtio-pstore device

2016-08-20 Thread Namhyung Kim
rg Cc: virtualization@lists.linux-foundation.org Signed-off-by: Namhyung Kim --- hw/virtio/Makefile.objs| 2 +- hw/virtio/virtio-pci.c | 52 ++ hw/virtio/virtio-pci.h | 14 + hw/virtio/virtio-pstore.c | 699 +

[RFC/PATCHSET 0/3] virtio: Implement virtio pstore device (v3)

2016-08-20 Thread Namhyung Kim
00feffc000-0xfeff] reserved <6>[0.00] BIOS-e820: [mem 0xfffc-0x] reserved <6>[0.00] NX (Execute Disable) protection: active <6>[0.00] SMBIOS 2.8 present. <7>[ 0.00] DMI: QEMU Standard PC (i440FX + PIIX,

[PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-08-20 Thread Namhyung Kim
org Cc: qemu-de...@nongnu.org Cc: virtualization@lists.linux-foundation.org Signed-off-by: Namhyung Kim --- drivers/virtio/Kconfig | 10 + drivers/virtio/Makefile| 1 + drivers/virtio/virtio_pstore.c | 417 + include/uapi/linux/Kbuild

Re: [Qemu-devel] [PATCH 6/7] qemu: Implement virtio-pstore device

2016-08-01 Thread Namhyung Kim
On Mon, Aug 01, 2016 at 10:24:39AM +0100, Daniel P. Berrange wrote: > On Sat, Jul 30, 2016 at 05:57:02PM +0900, Namhyung Kim wrote: > > On Thu, Jul 28, 2016 at 02:22:39PM +0100, Daniel P. Berrange wrote: > > > > +static void virtio_pstore_from_filename(VirtIO

Re: [Qemu-devel] [PATCH 6/7] qemu: Implement virtio-pstore device

2016-08-01 Thread Namhyung Kim
Hi Daniel, On Mon, Aug 01, 2016 at 10:21:30AM +0100, Daniel P. Berrange wrote: > On Sat, Jul 30, 2016 at 05:38:27PM +0900, Namhyung Kim wrote: > > Hello, > > > > On Thu, Jul 28, 2016 at 02:08:41PM +0100, Daniel P. Berrange wrote: > > > On Thu, Jul 28, 2016 at 01:

Re: [Qemu-devel] [PATCH 6/7] qemu: Implement virtio-pstore device

2016-07-30 Thread Namhyung Kim
On Thu, Jul 28, 2016 at 02:22:39PM +0100, Daniel P. Berrange wrote: > On Thu, Jul 28, 2016 at 12:08:30AM +0900, Namhyung Kim wrote: > > Add virtio pstore device to allow kernel log files saved on the host. > > It will save the log files on the directory given by pstore de

Re: [Qemu-devel] [PATCH 6/7] qemu: Implement virtio-pstore device

2016-07-30 Thread Namhyung Kim
Hello, On Thu, Jul 28, 2016 at 02:08:41PM +0100, Daniel P. Berrange wrote: > On Thu, Jul 28, 2016 at 01:56:07PM +0100, Stefan Hajnoczi wrote: > > On Thu, Jul 28, 2016 at 02:39:53PM +0900, Namhyung Kim wrote: > > > On Thu, Jul 28, 2016 at 03:02:54AM +0300, Michael S. Tsirkin wro

Re: [PATCH 6/7] qemu: Implement virtio-pstore device

2016-07-27 Thread Namhyung Kim
On Thu, Jul 28, 2016 at 03:02:54AM +0300, Michael S. Tsirkin wrote: > On Thu, Jul 28, 2016 at 12:08:30AM +0900, Namhyung Kim wrote: > > Add virtio pstore device to allow kernel log files saved on the host. > > It will save the log files on the directory given by pstore de

Re: [RFC/PATCHSET 0/7] virtio: Implement virtio pstore device (v2)

2016-07-27 Thread Namhyung Kim
Hello, On Thu, Jul 28, 2016 at 01:18:42AM +0300, Michael S. Tsirkin wrote: > On Thu, Jul 28, 2016 at 12:08:24AM +0900, Namhyung Kim wrote: > > Hello, > > > > This is v2 of the virtio-pstore work. In this patchset I addressed > > most of feedbacks from previous vers

[PATCH 7/7] kvmtool: Implement virtio-pstore device

2016-07-27 Thread Namhyung Kim
are usually compressed using zlib. User can easily see the messages on the host or on the guest (using pstore filesystem). Cc: Anton Vorontsov Cc: Colin Cross Cc: Kees Cook Cc: Tony Luck Cc: Steven Rostedt Cc: Ingo Molnar Cc: Will Deacon Signed-off-by: Namhyung Kim --- Makef

[PATCH 6/7] qemu: Implement virtio-pstore device

2016-07-27 Thread Namhyung Kim
on@lists.linux-foundation.org Signed-off-by: Namhyung Kim --- hw/virtio/Makefile.objs| 2 +- hw/virtio/virtio-pci.c | 54 +++ hw/virtio/virtio-pci.h | 14 + hw/virtio/virtio-pstore.c | 477

[PATCH 5/7] virtio-pstore: Support PSTORE_TYPE_CONSOLE

2016-07-27 Thread Namhyung Kim
.org Signed-off-by: Namhyung Kim --- drivers/virtio/virtio_pstore.c | 9 - include/uapi/linux/virtio_pstore.h | 4 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/drivers/virtio/virtio_pstore.c b/drivers/virtio/virtio_pstore.c index 4ee1c186f582..458c4d3ccbb1 10064

[PATCH 4/7] virtio: Basic implementation of virtio pstore driver

2016-07-27 Thread Namhyung Kim
org Cc: qemu-de...@nongnu.org Cc: virtualization@lists.linux-foundation.org Signed-off-by: Namhyung Kim --- drivers/virtio/Kconfig | 10 + drivers/virtio/Makefile| 1 + drivers/virtio/virtio_pstore.c | 414 + include/uapi/linux/Kbuild

[PATCH 3/7] pstore: Manage buffer position for async write

2016-07-27 Thread Namhyung Kim
led after accessing the buf. The pstore_get_buf() is provided for psinfo->write callback to determine the current position of available buffer. Cc: Anton Vorontsov Cc: Colin Cross Cc: Kees Cook Cc: Tony Luck Cc: Matt Fleming Cc: linux-...@vger.kernel.org Signed-off-by: Namhyung Kim --- drivers/f

[RFC/PATCHSET 0/7] virtio: Implement virtio pstore device (v2)

2016-07-27 Thread Namhyung Kim
_CONSOLE, add 'console=true' to virtio-pstore device option. Also 'bufsize' option can set different size for pstore buffer (default is 16K). Maybe we can add a config option to control the compression later. Currently the kvmtool doesn't support any options except the di

[PATCH 2/7] pstore/ram: Set pstore flags dynamically

2016-07-27 Thread Namhyung Kim
The ramoops can be configured to enable each pstore type by setting their size. In that case, it'd be better not to register disabled types in the first place. Cc: Anton Vorontsov Cc: Colin Cross Cc: Kees Cook Cc: Tony Luck Signed-off-by: Namhyung Kim --- fs/pstore/ram.c

[PATCH 1/7] pstore: Split pstore fragile flags

2016-07-27 Thread Namhyung Kim
Cc: Colin Cross Cc: Kees Cook Cc: Tony Luck Cc: "Rafael J. Wysocki" Cc: Len Brown Cc: Matt Fleming Cc: linux-a...@vger.kernel.org Cc: linux-...@vger.kernel.org Signed-off-by: Namhyung Kim --- drivers/acpi/apei/erst.c | 2 +- drivers/firmware/efi/efi-pstore.c | 2 +-

[PATCH] content: Reserve virtio device ID for pstore

2016-07-23 Thread Namhyung Kim
From: Namhyung Kim This patch just reserve next available device ID for pstore device type. The device specification for pstore will come later. Signed-off-by: Namhyung Kim --- content.tex | 2 ++ 1 file changed, 2 insertions(+) diff --git a/content.tex b/content.tex index d989d98..10bacc5

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-07-20 Thread Namhyung Kim
On Tue, Jul 19, 2016 at 10:43 PM, Namhyung Kim wrote: > The other one is the file management on the host side. I am thinking > of a simple way that the log file is splitted when it exceeds the half > of the allowed max size. It would be configurable and might allow > unlimited

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-07-20 Thread Namhyung Kim
On Wed, Jul 20, 2016 at 09:29:06AM +0100, Stefan Hajnoczi wrote: > On Mon, Jul 18, 2016 at 11:21:18PM +0900, Namhyung Kim wrote: > > On Mon, Jul 18, 2016 at 11:03:53AM +0100, Stefan Hajnoczi wrote: > > > On Mon, Jul 18, 2016 at 01:37:40PM +0900, Namhyung Kim wrote: > >

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-07-20 Thread Namhyung Kim
On Wed, Jul 20, 2016 at 09:21:08AM +0100, Stefan Hajnoczi wrote: > On Wed, Jul 20, 2016 at 12:48:39AM +0900, Namhyung Kim wrote: > > Hello, > > > > On Mon, Jul 18, 2016 at 11:03:53AM +0100, Stefan Hajnoczi wrote: > > > On Mon, Jul 18, 2016 at 01:37:40PM +0900, Namhy

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-07-19 Thread Namhyung Kim
Hello, On Mon, Jul 18, 2016 at 11:03:53AM +0100, Stefan Hajnoczi wrote: > On Mon, Jul 18, 2016 at 01:37:40PM +0900, Namhyung Kim wrote: > > +static void virtio_pstore_handle_io(VirtIODevice *vdev, VirtQueue *vq) > > +{ > > +VirtIOPstore *s = VIRTIO_PSTORE(vdev); >

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-07-19 Thread Namhyung Kim
On Tue, Jul 19, 2016 at 10:43 PM, Namhyung Kim wrote: > Hi Kees, > > On Mon, Jul 18, 2016 at 10:50:06AM -0700, Kees Cook wrote: >> On Sun, Jul 17, 2016 at 10:50 PM, Namhyung Kim wrote: >> > Hello, >> > >> > On Sun, Jul 17, 2016 at 10:12:26PM -0700, Kees

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-07-19 Thread Namhyung Kim
Hi Kees, On Mon, Jul 18, 2016 at 10:50:06AM -0700, Kees Cook wrote: > On Sun, Jul 17, 2016 at 10:50 PM, Namhyung Kim wrote: > > Hello, > > > > On Sun, Jul 17, 2016 at 10:12:26PM -0700, Kees Cook wrote: > >> On Sun, Jul 17, 2016 at 9:37 PM, Namhyung Kim wrote:

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-07-18 Thread Namhyung Kim
Hello, On Mon, Jul 18, 2016 at 11:03:53AM +0100, Stefan Hajnoczi wrote: > On Mon, Jul 18, 2016 at 01:37:40PM +0900, Namhyung Kim wrote: > > From: Namhyung Kim > > > > Add virtio pstore device to allow kernel log files saved on the host. > > It will save the log file

Re: [PATCH 2/3] qemu: Implement virtio-pstore device

2016-07-18 Thread Namhyung Kim
Hello, On Mon, Jul 18, 2016 at 09:28:42AM +0200, Christian Borntraeger wrote: > On 07/18/2016 06:37 AM, Namhyung Kim wrote: > > Can you do the virtio-mmio and virtio-ccw plumbing as well, or > do you need help with that? Any help would be greatly appreciated! Than

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-07-18 Thread Namhyung Kim
Hello, On Mon, Jul 18, 2016 at 09:54:39AM +0200, Cornelia Huck wrote: > On Mon, 18 Jul 2016 13:37:39 +0900 > Namhyung Kim wrote: > > > The virtio pstore driver provides interface to the pstore subsystem so > > that the guest kernel's log/dump message can be saved on th

Re: [PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-07-18 Thread Namhyung Kim
Hello, On Sun, Jul 17, 2016 at 10:12:26PM -0700, Kees Cook wrote: > On Sun, Jul 17, 2016 at 9:37 PM, Namhyung Kim wrote: > > The virtio pstore driver provides interface to the pstore subsystem so > > that the guest kernel's log/dump message can be saved on the host > >

[PATCH 3/3] kvmtool: Implement virtio-pstore device

2016-07-18 Thread Namhyung Kim
edt Cc: Ingo Molnar Cc: Minchan Kim Cc: k...@vger.kernel.org Cc: virtualization@lists.linux-foundation.org Signed-off-by: Namhyung Kim --- Makefile | 1 + builtin-run.c| 2 + include/kvm/kvm-config.h | 1 + include/kvm/virtio-pci-dev.h | 2 +

[PATCH 2/3] qemu: Implement virtio-pstore device

2016-07-18 Thread Namhyung Kim
From: Namhyung Kim Add virtio pstore device to allow kernel log files saved on the host. It will save the log files on the directory given by pstore device option. $ qemu-system-x86_64 -device virtio-pstore,directory=dir-xx ... (guest) # echo c > /proc/sysrq-trigger $ ls dir-xx dm

[PATCH 1/3] virtio: Basic implementation of virtio pstore driver

2016-07-18 Thread Namhyung Kim
er.kernel.org Cc: qemu-de...@nongnu.org Cc: virtualization@lists.linux-foundation.org Signed-off-by: Namhyung Kim --- drivers/virtio/Kconfig | 10 ++ drivers/virtio/Makefile| 1 + drivers/virtio/virtio_pstore.c | 317 +

[RFC/PATCHSET 0/3] virtio-pstore: Implement virtio pstore device

2016-07-18 Thread Namhyung Kim
Hello, This patchset is a proof of concept of virtio-pstore idea [1]. It has some rough edges and I'm not familiar with this area, so please give me feedbacks and advices if I'm going to a wrong direction. It started from the fact that dumping ftrace buffer at kernel oops/panic takes too much ti