From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:53912) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WL8Jf-0005Cz-WF for qemu-devel@nongnu.org; Wed, 05 Mar 2014 04:40:49 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WL8Ja-00060B-1n for qemu-devel@nongnu.org; Wed, 05 Mar 2014 04:40:43 -0500 Received: from mx1.redhat.com ([209.132.183.28]:43029) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WL8JZ-0005zy-LA for qemu-devel@nongnu.org; Wed, 05 Mar 2014 04:40:37 -0500 From: Stefan Hajnoczi Date: Wed, 5 Mar 2014 10:40:24 +0100 Message-Id: <1394012428-11678-1-git-send-email-stefanha@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: [Qemu-devel] [PATCH v2 0/4] qom: link property fixes List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Peter Maydell , Stefan Hajnoczi , Andreas Faerber , Anthony Liguori , Paolo Bonzini v2: * A NULL set() callback should make the property read-only There are two problems with QOM link properties: 1. There are refcount leaks in many object_property_add_link() callers. 2. There is no way to prevent link properties from being set after a device is realized. This patch series fixes these issues by extending the object_property_add_link() function. Stefan Hajnoczi (4): qom: split object_property_set_link() qom: make QOM link property unref optional qom: add set() argument to object_property_add_link() virtio-rng: avoid default_backend refcount leak hw/core/qdev-properties.c | 12 ++++ hw/core/qdev.c | 9 ++- hw/dma/xilinx_axidma.c | 16 ++++-- hw/net/xilinx_axienet.c | 16 ++++-- hw/pcmcia/pxa2xx.c | 5 +- hw/s390x/s390-virtio-bus.c | 4 +- hw/s390x/virtio-ccw.c | 4 +- hw/virtio/virtio-pci.c | 4 +- hw/virtio/virtio-rng.c | 7 ++- include/hw/qdev-properties.h | 11 ++++ include/qom/object.h | 19 ++++++- qom/object.c | 130 ++++++++++++++++++++++++++++++++----------- ui/console.c | 4 +- 13 files changed, 191 insertions(+), 50 deletions(-) -- 1.8.5.3