public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] virtio-mem: Assign boolean values to a bool variable
@ 2021-01-20  7:50 Jiapeng Zhong
  2021-01-20  9:40 ` David Hildenbrand
  0 siblings, 1 reply; 8+ messages in thread
From: Jiapeng Zhong @ 2021-01-20  7:50 UTC (permalink / raw)
  To: david; +Cc: mst, jasowang, virtualization, linux-kernel, Jiapeng Zhong

Fix the following coccicheck warnings:

./drivers/virtio/virtio_mem.c:2580:2-25: WARNING: Assignment
of 0/1 to bool variable.

Reported-by: Abaci Robot <abaci@linux.alibaba.com>
Signed-off-by: Jiapeng Zhong <abaci-bugfix@linux.alibaba.com>
---
 drivers/virtio/virtio_mem.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/virtio/virtio_mem.c b/drivers/virtio/virtio_mem.c
index 9fc9ec4..85a272c 100644
--- a/drivers/virtio/virtio_mem.c
+++ b/drivers/virtio/virtio_mem.c
@@ -2577,7 +2577,7 @@ static int virtio_mem_probe(struct virtio_device *vdev)
 	 * actually in use (e.g., trying to reload the driver).
 	 */
 	if (vm->plugged_size) {
-		vm->unplug_all_required = 1;
+		vm->unplug_all_required = true;
 		dev_info(&vm->vdev->dev, "unplugging all memory is required\n");
 	}
 
-- 
1.8.3.1


^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2021-01-20 12:00 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-01-20  7:50 [PATCH] virtio-mem: Assign boolean values to a bool variable Jiapeng Zhong
2021-01-20  9:40 ` David Hildenbrand
2021-01-20  9:57   ` Michael S. Tsirkin
2021-01-20 10:04     ` David Hildenbrand
2021-01-20 11:03       ` Michael S. Tsirkin
2021-01-20 11:14         ` David Hildenbrand
2021-01-20 11:33           ` Michael S. Tsirkin
2021-01-20 11:33             ` David Hildenbrand

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox