From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:48290) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aqIzV-0001X5-I7 for qemu-devel@nongnu.org; Wed, 13 Apr 2016 07:29:50 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aqIzS-0003IC-DA for qemu-devel@nongnu.org; Wed, 13 Apr 2016 07:29:49 -0400 Received: from mx1.redhat.com ([209.132.183.28]:52375) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aqIzS-0003I7-8Y for qemu-devel@nongnu.org; Wed, 13 Apr 2016 07:29:46 -0400 From: Markus Armbruster References: <1460484949-5798-1-git-send-email-nutanshinde1992@gmail.com> <570D676F.3060600@redhat.com> <87potukogq.fsf@dusky.pond.sub.org> <570DF766.5020601@redhat.com> Date: Wed, 13 Apr 2016 13:29:43 +0200 In-Reply-To: <570DF766.5020601@redhat.com> (Paolo Bonzini's message of "Wed, 13 Apr 2016 09:38:14 +0200") Message-ID: <87pottn3vc.fsf@dusky.pond.sub.org> MIME-Version: 1.0 Content-Type: text/plain Subject: Re: [Qemu-devel] Fwd: [PATCH v2 2/5] Change return type of functions that are named *_exit or *_exitfn in hw/char from int to void List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: Nutan Shinde , QEMU Developers Paolo Bonzini writes: > On 13/04/2016 08:33, Markus Armbruster wrote: >> * Look for functions that are named *_exit or *_exitfn in hw/ and that >> return int. They should all return zero. Make them return void, and >> remove the checks for the callers. > > ... and change the exit method to "void fn(void)" > >> * Once the above change is done, remove the "Error **" argument from >> functions named *_unrealize in hw/ > > ... same for the unrealize method. > >> Added by Paolo on 2014-12-03. These tasks don't make sense to me. >> Paolo, can you explain? > > The exit functions always return zero, the unrealize functions never > touch the Error** argument. So make both of them "void fn(void)" and > remove the difference between exit and unrealize. Got it now, thanks!