Displaying 20 results from an estimated 2000 matches similar to: "[PATCHv2] virtio_mmio: fix devm cleanup"
2017 Dec 12
2
[PATCH] virtio_mmio: fix devm cleanup
Recent rework of the virtio_mmio probe path balanced a devm_ioremap()
with an iounmap() rather than its devm variant. This ends up corrupting
the devm datastructures, and results in the following boot failure on
arm64 under QEMU 2.9.0:
[ 3.450397] ------------[ cut here ]------------
[ 3.453822] Trying to vfree() nonexistent vm area (00000000c05b4844)
[ 3.460534] WARNING: CPU: 1 PID: 1
2017 Dec 12
2
[PATCH] virtio_mmio: fix devm cleanup
Recent rework of the virtio_mmio probe path balanced a devm_ioremap()
with an iounmap() rather than its devm variant. This ends up corrupting
the devm datastructures, and results in the following boot failure on
arm64 under QEMU 2.9.0:
[ 3.450397] ------------[ cut here ]------------
[ 3.453822] Trying to vfree() nonexistent vm area (00000000c05b4844)
[ 3.460534] WARNING: CPU: 1 PID: 1
2017 Dec 13
2
[PATCHv2] virtio_mmio: fix devm cleanup
On Tue, Dec 12, 2017 at 06:02:23PM +0100, Cornelia Huck wrote:
> On Tue, 12 Dec 2017 13:45:50 +0000
> Mark Rutland <mark.rutland at arm.com> wrote:
>
> > Recent rework of the virtio_mmio probe/remove paths balanced a
> > devm_ioremap() with an iounmap() rather than its devm variant. This ends
> > up corrupting the devm datastructures, and results in the following
2017 Dec 13
2
[PATCHv2] virtio_mmio: fix devm cleanup
On Tue, Dec 12, 2017 at 06:02:23PM +0100, Cornelia Huck wrote:
> On Tue, 12 Dec 2017 13:45:50 +0000
> Mark Rutland <mark.rutland at arm.com> wrote:
>
> > Recent rework of the virtio_mmio probe/remove paths balanced a
> > devm_ioremap() with an iounmap() rather than its devm variant. This ends
> > up corrupting the devm datastructures, and results in the following
2017 Dec 12
1
[PATCHv2] virtio_mmio: fix devm cleanup
On Tue, Dec 12, 2017 at 10:26:24PM +0800, weiping zhang wrote:
> 2017-12-12 21:45 GMT+08:00 Mark Rutland <mark.rutland at arm.com>:
> Hi Mark,
Hi,
> thanks your patch, I dig into these three devm_xxx funciton,
> all of them represented by a struct devres as following,
>
> struct devres_node {
> struct list_head entry;
> dr_release_t
2017 Dec 12
1
[PATCHv2] virtio_mmio: fix devm cleanup
On Tue, Dec 12, 2017 at 10:26:24PM +0800, weiping zhang wrote:
> 2017-12-12 21:45 GMT+08:00 Mark Rutland <mark.rutland at arm.com>:
> Hi Mark,
Hi,
> thanks your patch, I dig into these three devm_xxx funciton,
> all of them represented by a struct devres as following,
>
> struct devres_node {
> struct list_head entry;
> dr_release_t
2017 Dec 12
0
[PATCHv2] virtio_mmio: fix devm cleanup
2017-12-12 21:45 GMT+08:00 Mark Rutland <mark.rutland at arm.com>:
> Recent rework of the virtio_mmio probe/remove paths balanced a
> devm_ioremap() with an iounmap() rather than its devm variant. This ends
> up corrupting the devm datastructures, and results in the following
> boot-time splat on arm64 under QEMU 2.9.0:
>
> [ 3.450397] ------------[ cut here
2017 Dec 12
0
[PATCH] virtio_mmio: fix devm cleanup
On Tue, 12 Dec 2017 12:53:02 +0000
Mark Rutland <mark.rutland at arm.com> wrote:
> Recent rework of the virtio_mmio probe path balanced a devm_ioremap()
> with an iounmap() rather than its devm variant. This ends up corrupting
> the devm datastructures, and results in the following boot failure on
> arm64 under QEMU 2.9.0:
>
> [ 3.450397] ------------[ cut here
2017 Dec 12
2
[PATCH] virtio_mmio: fix devm cleanup
On Tue, Dec 12, 2017 at 02:09:52PM +0100, Cornelia Huck wrote:
> On Tue, 12 Dec 2017 12:53:02 +0000
> Mark Rutland <mark.rutland at arm.com> wrote:
>
> > Recent rework of the virtio_mmio probe path balanced a devm_ioremap()
> > with an iounmap() rather than its devm variant. This ends up corrupting
> > the devm datastructures, and results in the following boot
2017 Dec 12
2
[PATCH] virtio_mmio: fix devm cleanup
On Tue, Dec 12, 2017 at 02:09:52PM +0100, Cornelia Huck wrote:
> On Tue, 12 Dec 2017 12:53:02 +0000
> Mark Rutland <mark.rutland at arm.com> wrote:
>
> > Recent rework of the virtio_mmio probe path balanced a devm_ioremap()
> > with an iounmap() rather than its devm variant. This ends up corrupting
> > the devm datastructures, and results in the following boot
2017 Dec 14
0
[PATCHv2] virtio_mmio: fix devm cleanup
On Wed, Dec 13, 2017 at 02:34:14PM +0000, Mark Rutland wrote:
> On Tue, Dec 12, 2017 at 06:02:23PM +0100, Cornelia Huck wrote:
> > On Tue, 12 Dec 2017 13:45:50 +0000
> > Mark Rutland <mark.rutland at arm.com> wrote:
> >
> > > Recent rework of the virtio_mmio probe/remove paths balanced a
> > > devm_ioremap() with an iounmap() rather than its devm
2017 Dec 12
0
[PATCHv2] virtio_mmio: fix devm cleanup
On Tue, 12 Dec 2017 13:45:50 +0000
Mark Rutland <mark.rutland at arm.com> wrote:
> Recent rework of the virtio_mmio probe/remove paths balanced a
> devm_ioremap() with an iounmap() rather than its devm variant. This ends
> up corrupting the devm datastructures, and results in the following
> boot-time splat on arm64 under QEMU 2.9.0:
>
> [ 3.450397] ------------[ cut
2017 Dec 01
2
[PATCH] virtio_mmio: add cleanup for virtio_mmio_probe
cleanup all resource allocated by virtio_mmio_probe.
Signed-off-by: weiping zhang <zhangweiping at didichuxing.com>
---
drivers/virtio/virtio_mmio.c | 34 ++++++++++++++++++++++++++--------
1 file changed, 26 insertions(+), 8 deletions(-)
diff --git a/drivers/virtio/virtio_mmio.c b/drivers/virtio/virtio_mmio.c
index 74dc717..3fd0e66 100644
--- a/drivers/virtio/virtio_mmio.c
+++
2017 Dec 01
2
[PATCH] virtio_mmio: add cleanup for virtio_mmio_probe
cleanup all resource allocated by virtio_mmio_probe.
Signed-off-by: weiping zhang <zhangweiping at didichuxing.com>
---
drivers/virtio/virtio_mmio.c | 34 ++++++++++++++++++++++++++--------
1 file changed, 26 insertions(+), 8 deletions(-)
diff --git a/drivers/virtio/virtio_mmio.c b/drivers/virtio/virtio_mmio.c
index 74dc717..3fd0e66 100644
--- a/drivers/virtio/virtio_mmio.c
+++
2017 Dec 06
1
[PATCH v2 1/2] virtio_mmio: add cleanup for virtio_mmio_probe
On Tue, 5 Dec 2017 19:57:10 +0800
weiping zhang <zhangweiping at didichuxing.com> wrote:
> As mentioned at drivers/base/core.c:
> /*
> * NOTE: _Never_ directly free @dev after calling this function, even
> * if it returned an error! Always use put_device() to give up the
> * reference initialized in this function instead.
> */
>
> Normal we do cleanup for
2017 Dec 06
1
[PATCH v2 1/2] virtio_mmio: add cleanup for virtio_mmio_probe
On Tue, 5 Dec 2017 19:57:10 +0800
weiping zhang <zhangweiping at didichuxing.com> wrote:
> As mentioned at drivers/base/core.c:
> /*
> * NOTE: _Never_ directly free @dev after calling this function, even
> * if it returned an error! Always use put_device() to give up the
> * reference initialized in this function instead.
> */
>
> Normal we do cleanup for
2016 Nov 25
1
[PATCH] virtio_mmio: Set dev.release() to avoid warning
I think not. In virtio_pci_common, vp_dev is allocated by kzalloc so a
kfree is needed. Here vm_dev is allocated by devm_kmalloc which is
"automatically freed on driver detach" from the comment
(drivers/base/devres.c:769).
On Thu, Nov 24, 2016 at 6:37 PM, Jason Wang <jasowang at redhat.com> wrote:
>
>
> On 2016?11?24? 08:31, Yuan Liu wrote:
>
>> From: Yuan Liu
2016 Nov 25
1
[PATCH] virtio_mmio: Set dev.release() to avoid warning
I think not. In virtio_pci_common, vp_dev is allocated by kzalloc so a
kfree is needed. Here vm_dev is allocated by devm_kmalloc which is
"automatically freed on driver detach" from the comment
(drivers/base/devres.c:769).
On Thu, Nov 24, 2016 at 6:37 PM, Jason Wang <jasowang at redhat.com> wrote:
>
>
> On 2016?11?24? 08:31, Yuan Liu wrote:
>
>> From: Yuan Liu
2016 Nov 24
2
[PATCH] virtio_mmio: Set dev.release() to avoid warning
From: Yuan Liu <liuyuan at google.com>
Fix a warning thrown from virtio_mmio_remove():
Device 'virtio0' does not have a release() function
The fix is according to virtio_pci_probe() of
drivers/virtio/virtio_pci_common.c
Signed-off-by: Yuan Liu <liuyuan at google.com>
---
drivers/virtio/virtio_mmio.c | 2 ++
1 file changed, 2 insertions(+)
diff --git
2016 Nov 24
2
[PATCH] virtio_mmio: Set dev.release() to avoid warning
From: Yuan Liu <liuyuan at google.com>
Fix a warning thrown from virtio_mmio_remove():
Device 'virtio0' does not have a release() function
The fix is according to virtio_pci_probe() of
drivers/virtio/virtio_pci_common.c
Signed-off-by: Yuan Liu <liuyuan at google.com>
---
drivers/virtio/virtio_mmio.c | 2 ++
1 file changed, 2 insertions(+)
diff --git