search for: hvc_alloc

Displaying 20 results from an estimated 91 matches for "hvc_alloc".

2020 Apr 05
0
[PATCH] Fix: buffer overflow during hvc_alloc().
...ops) vtermnos[index] = vtermno; cons_ops[index] = ops; - /* reserve all indices up to and including this index */ - if (last_hvc < index) - last_hvc = index; - /* check if we need to re-register the kernel console */ hvc_check_console(index); @@ -960,13 +956,22 @@ struct hvc_struct *hvc_alloc(uint32_t vtermno, int data, cons_ops[i] == hp->ops) break; - /* no matching slot, just use a counter */ - if (i >= MAX_NR_HVC_CONSOLES) - i = ++last_hvc; + if (i >= MAX_NR_HVC_CONSOLES) { + + /* find 'empty' slot for console */ + for (i = 0; i < MAX_NR_HVC_CONSOL...
2011 Nov 08
3
[PATCH RFC v2 0/3] Support multiple VirtioConsoles.
...tch having gotten into Linus' tree, and leaving other people to deal with crashes. I had meant to be asking for guidance, but I didn't mark it as "RFC". This series reflects the input from Konrad Rzeszutek, Amit Shah, Stephen Boyd, and Rusty Russell. I think we do have to limit hvc_alloc() to one thread. I would appreciate any comments or feedback, or accept if appropriate. Thanks, Miche Baker-Harvey --- Miche Baker-Harvey (3): virtio_console: Fix locking of vtermno. hvc_init(): Enforce one-time initialization. Use separate struct console structure for each...
2011 Nov 08
3
[PATCH RFC v2 0/3] Support multiple VirtioConsoles.
...tch having gotten into Linus' tree, and leaving other people to deal with crashes. I had meant to be asking for guidance, but I didn't mark it as "RFC". This series reflects the input from Konrad Rzeszutek, Amit Shah, Stephen Boyd, and Rusty Russell. I think we do have to limit hvc_alloc() to one thread. I would appreciate any comments or feedback, or accept if appropriate. Thanks, Miche Baker-Harvey --- Miche Baker-Harvey (3): virtio_console: Fix locking of vtermno. hvc_init(): Enforce one-time initialization. Use separate struct console structure for each...
2011 Nov 08
3
[PATCH RFC v3 0/3] Support multiple VirtioConsoles.
...tch having gotten into Linus' tree, and leaving other people to deal with crashes. I had meant to be asking for guidance, but I didn't mark it as "RFC". This series reflects the input from Konrad Rzeszutek, Amit Shah, Stephen Boyd, and Rusty Russell. I think we do have to limit hvc_alloc() to one thread. I would appreciate any comments or feedback, or accept if appropriate. Thanks, Miche Baker-Harvey --- Miche Baker-Harvey (3): virtio_console: Fix locking of vtermno. hvc_init(): Enforce one-time initialization. Use separate struct console structure for each...
2011 Nov 08
3
[PATCH RFC v3 0/3] Support multiple VirtioConsoles.
...tch having gotten into Linus' tree, and leaving other people to deal with crashes. I had meant to be asking for guidance, but I didn't mark it as "RFC". This series reflects the input from Konrad Rzeszutek, Amit Shah, Stephen Boyd, and Rusty Russell. I think we do have to limit hvc_alloc() to one thread. I would appreciate any comments or feedback, or accept if appropriate. Thanks, Miche Baker-Harvey --- Miche Baker-Harvey (3): virtio_console: Fix locking of vtermno. hvc_init(): Enforce one-time initialization. Use separate struct console structure for each...
2011 Nov 08
3
[PATCH RFC v3 0/3] Support multiple VirtioConsoles.
...tch having gotten into Linus' tree, and leaving other people to deal with crashes. I had meant to be asking for guidance, but I didn't mark it as "RFC". This series reflects the input from Konrad Rzeszutek, Amit Shah, Stephen Boyd, and Rusty Russell. I think we do have to limit hvc_alloc() to one thread. I would appreciate any comments or feedback, or accept if appropriate. Thanks, Miche Baker-Harvey --- Miche Baker-Harvey (3): virtio_console: Fix locking of vtermno. hvc_init(): Enforce one-time initialization. Use separate struct console structure for each...
2011 Nov 08
3
[PATCH RFC v2 0/3] Support multiple VirtioConsoles.
...gotten into Linus'' tree, and leaving other people to deal with crashes. I had meant to be asking for guidance, but I didn''t mark it as "RFC". This series reflects the input from Konrad Rzeszutek, Amit Shah, Stephen Boyd, and Rusty Russell. I think we do have to limit hvc_alloc() to one thread. I would appreciate any comments or feedback, or accept if appropriate. Thanks, Miche Baker-Harvey --- Miche Baker-Harvey (3): virtio_console: Fix locking of vtermno. hvc_init(): Enforce one-time initialization. Use separate struct console structure for each...
2020 Apr 14
1
[PATCH v2] Fix: buffer overflow during hvc_alloc().
...[ 81.534914] CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 [ 81.535971] CR2: 00005624c55b14d0 CR3: 00000003a023c000 CR4: 00000000003406f0 [ 81.537283] Call Trace: [ 81.537763] __raw_callee_save___pv_queued_spin_unlock_slowpath+0x11/0x20 [ 81.539011] .slowpath+0x9/0xe [ 81.539585] hvc_alloc+0x25e/0x300 [ 81.540237] init_port_console+0x28/0x100 [virtio_console] [ 81.541251] handle_control_message.constprop.27+0x1c4/0x310 [virtio_console] [ 81.542546] control_work_handler+0x70/0x10c [virtio_console] [ 81.543601] process_one_work+0x1a7/0x3b0 [ 81.544356] worker_thread+0x30...
2010 Jan 18
2
[PATCH 00/32] virtio: console: Fixes, multiple devices and generic ports
...host when a console port is attached - Remove cached buffers when ports are closed / disconnected - Send only one buffer in send_buf As usual, this series is passed through the testsuite that tests for the functionality given here. Amit Shah (25): hvc_console: Remove __devinit annotation from hvc_alloc virtio: console: We support only one device at a time virtio: console: encapsulate buffer information in a struct virtio: console: ensure add_inbuf can work for multiple ports as well virtio: console: introduce a get_inbuf helper to fetch bufs from in_vq virtio: console: don't ass...
2010 Jan 18
2
[PATCH 00/32] virtio: console: Fixes, multiple devices and generic ports
...host when a console port is attached - Remove cached buffers when ports are closed / disconnected - Send only one buffer in send_buf As usual, this series is passed through the testsuite that tests for the functionality given here. Amit Shah (25): hvc_console: Remove __devinit annotation from hvc_alloc virtio: console: We support only one device at a time virtio: console: encapsulate buffer information in a struct virtio: console: ensure add_inbuf can work for multiple ports as well virtio: console: introduce a get_inbuf helper to fetch bufs from in_vq virtio: console: don't ass...
2020 Apr 06
0
[PATCH] Fix: buffer overflow during hvc_alloc().
...S: 0000 CR0: 0000000080050033 > [ 81.535971] CR2: 00005624c55b14d0 CR3: 00000003a023c000 CR4: > 00000000003406f0 > [ 81.537283] Call Trace: > [ 81.537763] > __raw_callee_save___pv_queued_spin_unlock_slowpath+0x11/0x20 > [ 81.539011] .slowpath+0x9/0xe > [ 81.539585] hvc_alloc+0x25e/0x300 > [ 81.540237] init_port_console+0x28/0x100 [virtio_console] > [ 81.541251] handle_control_message.constprop.27+0x1c4/0x310 > [virtio_console] > [ 81.542546] control_work_handler+0x70/0x10c [virtio_console] > [ 81.543601] process_one_work+0x1a7/0x3b0 > [...
2009 Nov 28
3
[PATCH 00/28] virtio: console: Fixes, support for generic ports
Hey Rusty, This is a respin of my patches on top of the series you posted. I've taken the liberty to modify your patches for style consistency and comments where needed, keeping the authorship info intact. I've had to update a few of your patches for functional changes, I've changed the authorship info on those patches. The (only) major functional change is to have a list for ports
2009 Nov 28
3
[PATCH 00/28] virtio: console: Fixes, support for generic ports
Hey Rusty, This is a respin of my patches on top of the series you posted. I've taken the liberty to modify your patches for style consistency and comments where needed, keeping the authorship info intact. I've had to update a few of your patches for functional changes, I've changed the authorship info on those patches. The (only) major functional change is to have a list for ports
2008 Jun 03
12
[RFC 0/3]: hvc_console rework for platform without hard irqs
This patch set if my first attempt to make virtio_console usable on s390. To do so, I had to change hvc_console, because s390 has no request_irq and no free_irq. I want to get feedback from the main users of hvc_console before I proceed. The basic idea of this patch set is to remove the calls to request_irq and free_irq and replace them with backend specific callbacks. Please see the
2008 Jun 03
12
[RFC 0/3]: hvc_console rework for platform without hard irqs
This patch set if my first attempt to make virtio_console usable on s390. To do so, I had to change hvc_console, because s390 has no request_irq and no free_irq. I want to get feedback from the main users of hvc_console before I proceed. The basic idea of this patch set is to remove the calls to request_irq and free_irq and replace them with backend specific callbacks. Please see the
2009 Dec 22
4
[PATCH 00/31] virtio: console: Fixes, multiple devices and generic ports
...* caching * throttling * console - with running 'find /' in the guest * open/close of chardevs * read/write/poll * sending a large file (> 100 MB) in either direction and matching sha1sums. Please review. Thanks, Amit Amit Shah (25): hvc_console: Remove __devinit annotation from hvc_alloc virtio: console: We support only one device at a time virtio: console: encapsulate buffer information in a struct virtio: console: ensure add_inbuf can work for multiple ports as well virtio: console: introduce a get_inbuf helper to fetch bufs from in_vq virtio: console: don't ass...
2009 Dec 22
4
[PATCH 00/31] virtio: console: Fixes, multiple devices and generic ports
...* caching * throttling * console - with running 'find /' in the guest * open/close of chardevs * read/write/poll * sending a large file (> 100 MB) in either direction and matching sha1sums. Please review. Thanks, Amit Amit Shah (25): hvc_console: Remove __devinit annotation from hvc_alloc virtio: console: We support only one device at a time virtio: console: encapsulate buffer information in a struct virtio: console: ensure add_inbuf can work for multiple ports as well virtio: console: introduce a get_inbuf helper to fetch bufs from in_vq virtio: console: don't ass...
2014 Mar 31
1
OOPS in hvc / virtconsole
...4] ffffffffa0050880 ffff88007bccbda8 ffffffff813f1e84 ffff88007c704000 [ 0.444004] ffff88007bd4a300 ffff88007c6deac4 ffff88007c6dea90 ffff88007c481000 [ 0.444004] Call Trace: [ 0.444004] [<ffffffff810bfdbb>] ? register_console+0x11b/0x370 [ 0.444004] [<ffffffff813f1e84>] hvc_alloc+0x1a4/0x330 [ 0.444004] [<ffffffffa004eb1b>] init_port_console+0x2b/0xe0 [virtio_console] [ 0.444004] [<ffffffffa004fb2f>] control_work_handler+0x19f/0x3bc [virtio_console] [ 0.444004] [<ffffffff81087b76>] process_one_work+0x176/0x430 [ 0.444004] [<ffffffff81088...
2014 Mar 31
1
OOPS in hvc / virtconsole
...4] ffffffffa0050880 ffff88007bccbda8 ffffffff813f1e84 ffff88007c704000 [ 0.444004] ffff88007bd4a300 ffff88007c6deac4 ffff88007c6dea90 ffff88007c481000 [ 0.444004] Call Trace: [ 0.444004] [<ffffffff810bfdbb>] ? register_console+0x11b/0x370 [ 0.444004] [<ffffffff813f1e84>] hvc_alloc+0x1a4/0x330 [ 0.444004] [<ffffffffa004eb1b>] init_port_console+0x2b/0xe0 [virtio_console] [ 0.444004] [<ffffffffa004fb2f>] control_work_handler+0x19f/0x3bc [virtio_console] [ 0.444004] [<ffffffff81087b76>] process_one_work+0x176/0x430 [ 0.444004] [<ffffffff81088...
2009 Sep 29
0
[PATCH] virtio_console: Add support for multiple ports for generic guest and host communication
...ected; +}; -/* The hvc device */ -static struct hvc_struct *hvc; +static struct virtio_console_struct virtconsole; -/*D:310 The put_chars() callback is pretty straightforward. +/* + * This is used to keep track of the number of hvc consoles spawned. + * This number is given as first argument to hvc_alloc(). We could as + * well pass on the minor number of the char device but to correctly + * map an initial console spawned via hvc_instantiate to the console + * being hooked up via hvc_alloc, we need to pass the same vtermno. * - * We turn the characters into a scatter-gather list, add it to the ou...