From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:60159) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbbAO-0000za-NU for qemu-devel@nongnu.org; Fri, 16 Dec 2011 12:02:01 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RbbAI-00078P-Vn for qemu-devel@nongnu.org; Fri, 16 Dec 2011 12:01:52 -0500 Received: from mail-yx0-f173.google.com ([209.85.213.173]:56525) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RbbAI-00078K-Fq for qemu-devel@nongnu.org; Fri, 16 Dec 2011 12:01:46 -0500 Received: by yenm6 with SMTP id m6so2751599yen.4 for ; Fri, 16 Dec 2011 09:01:46 -0800 (PST) Message-ID: <4EEB7977.1020402@codemonkey.ws> Date: Fri, 16 Dec 2011 11:01:43 -0600 From: Anthony Liguori MIME-Version: 1.0 References: <1324036918-2405-1-git-send-email-pbonzini@redhat.com> <1324036918-2405-6-git-send-email-pbonzini@redhat.com> <4EEB4EE1.5030807@codemonkey.ws> <4EEB4F3D.3000006@redhat.com> <4EEB791C.9060302@redhat.com> In-Reply-To: <4EEB791C.9060302@redhat.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 5/8] qom: introduce QERR_PROPERTY_VALUE_OUT_OF_RANGE List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: kwolf@redhat.com, qemu-devel@nongnu.org On 12/16/2011 11:00 AM, Paolo Bonzini wrote: > On 12/16/2011 03:01 PM, Paolo Bonzini wrote: >>> >>> I'd rather use generic errors when possible. How about >>> VALUE_OUT_OF_RANGE and we can make the message "'%(item)' doesn't take >>> value..." and pass "%s.%s" % (device, property) for item. >> >> Ok. > > I didn't do this in the end for two reasons. > > First, that it is inconsistent with other errors from qdev properties. Current > master does not raise them when properties are accessed via QOM, but my revised > series does. > > Second, that it is actually provides less structured information. There's no > reason why a client should be expected to "know" that %(item) is in that form. Ok, then Reviewed-by: Anthony Liguori Regards, Anthony Liguori > Paolo