From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:56537) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aooYB-0001KJ-1v for qemu-devel@nongnu.org; Sat, 09 Apr 2016 04:47:27 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aooY7-0002l0-RK for qemu-devel@nongnu.org; Sat, 09 Apr 2016 04:47:26 -0400 Received: from [59.151.112.132] (port=26167 helo=heian.cn.fujitsu.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aooY7-0002cv-4Y for qemu-devel@nongnu.org; Sat, 09 Apr 2016 04:47:23 -0400 References: <1459855602-16727-1-git-send-email-caoj.fnst@cn.fujitsu.com> <1459855602-16727-2-git-send-email-caoj.fnst@cn.fujitsu.com> <87pou0txyq.fsf@dusky.pond.sub.org> From: Cao jin Message-ID: <5708C22F.8050200@cn.fujitsu.com> Date: Sat, 9 Apr 2016 16:49:51 +0800 MIME-Version: 1.0 In-Reply-To: <87pou0txyq.fsf@dusky.pond.sub.org> Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH v4 1/5] fix some coding style problems List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Markus Armbruster Cc: qemu-devel@nongnu.org, mst@redhat.com, jasowang@redhat.com, marcel@redhat.com, alex.williamson@redhat.com, hare@suse.de, dmitry@daynix.com, pbonzini@redhat.com, jsnow@redhat.com, kraxel@redhat.com On 04/08/2016 02:29 PM, Markus Armbruster wrote: > Cao jin writes: > >> This patch comes along with patch "Add param Error ** for msi_init". > > What do you want to say with this sentence? I think it could be dropped > without loss. > According to what I learned here(http://lists.nongnu.org/archive/html/qemu-trivial/2015-10/msg00116.html), generally, I don`t send this kind of coding style patch separately:). So I add that interpretation per suggestion. Will remove it in next version. >> Add more newlines to make the code block well separated; add more >> comments for msi_init; and fix a indentation. >> goto err_pcie_cap; >> } >> - pcie_cap_root_init(d); >> + > > Code motion, not covered by commit message. Should this be in a later > patch? > Yes...I forget to mention it in commit message. It is just put relevant code together, make the code more logical. Because it is so trivial, and this patch is for all the trivial modification , so maybe I can cover it in the commit message:) >> +/* >> + * Make PCI device @dev MSI-capable. >> + * Non-zero @offset puts capability MSI at that offset in PCI config >> + * space. >> + * @nr_vectors is the number of MSI vectors (1, 2, 4, 8, 16 or 32). >> + * If @msi64bit, make the device capable of sending a 64-bit message >> + * address. >> + * If @msi_per_vector_mask, make the device support per-vector masking. >> + * @errp is for returning errors. >> + * Return the offset of capability MSI in config space on success, >> + * set @errp and return -errno on error. >> + * -ENOTSUP means lacking msi support for a msi-capable platform. > > Missing: -ENOSPC and -EINVAL. Intentional? > Yep...a kind of. Because I think -ENOTSUP deserve more comments, and the other two, the meaning are as the name implies. I will make it up -- Yours Sincerely, Cao jin