[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PULL 5/6] tpm: Fix write to file descriptor function
From: |
Michael S. Tsirkin |
Subject: |
[Qemu-devel] [PULL 5/6] tpm: Fix write to file descriptor function |
Date: |
Thu, 14 Apr 2016 16:48:14 +0300 |
From: Stefan Berger <address@hidden>
Fix a bug introduced in commit 46f296c while moving send_all to the
tpm_passthrough code. Fix the name of the variable used in the loop.
Signed-off-by: Stefan Berger <address@hidden>
Acked-by: Michael S. Tsirkin <address@hidden>
Signed-off-by: Michael S. Tsirkin <address@hidden>
---
hw/tpm/tpm_passthrough.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/hw/tpm/tpm_passthrough.c b/hw/tpm/tpm_passthrough.c
index e98efb7..e88c0d2 100644
--- a/hw/tpm/tpm_passthrough.c
+++ b/hw/tpm/tpm_passthrough.c
@@ -86,7 +86,7 @@ static int tpm_passthrough_unix_write(int fd, const uint8_t
*buf, uint32_t len)
int ret, remain;
remain = len;
- while (len > 0) {
+ while (remain > 0) {
ret = write(fd, buf, remain);
if (ret < 0) {
if (errno != EINTR && errno != EAGAIN) {
--
MST
- [Qemu-devel] [PULL 0/6] tpm, vhost, virtio: fixes for 2.6, Michael S. Tsirkin, 2016/04/14
- [Qemu-devel] [PULL 1/6] specs/vhost-user: improve VHOST_SET_VRING_NUM documentation, Michael S. Tsirkin, 2016/04/14
- [Qemu-devel] [PULL 2/6] specs/vhost-user: spelling fix, Michael S. Tsirkin, 2016/04/14
- [Qemu-devel] [PULL 4/6] tpm: acpi: remove IRQ from TPM's CRS to make Windows not see conflict, Michael S. Tsirkin, 2016/04/14
- [Qemu-devel] [PULL 3/6] pc: acpi: tpm: add missing MMIO resource to PCI0._CRS, Michael S. Tsirkin, 2016/04/14
- [Qemu-devel] [PULL 5/6] tpm: Fix write to file descriptor function,
Michael S. Tsirkin <=
- [Qemu-devel] [PULL 6/6] hw/virtio/balloon: Replace TARGET_PAGE_SIZE with BALLOON_PAGE_SIZE, Michael S. Tsirkin, 2016/04/14
- Re: [Qemu-devel] [PULL 0/6] tpm, vhost, virtio: fixes for 2.6, Peter Maydell, 2016/04/14