From patchwork Wed Jan 31 11:55:44 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Michael Tokarev X-Patchwork-Id: 768485 Delivered-To: patch@linaro.org Received: by 2002:adf:ee41:0:b0:33a:e5bd:fedd with SMTP id w1csp1818999wro; Wed, 31 Jan 2024 03:59:51 -0800 (PST) X-Google-Smtp-Source: AGHT+IFvjj6PqhCV/4tGNpw3/cws+iVqtmno+cn+Askbasis3sWKHGUU3vp3izxcL6TuK0TMk/K0 X-Received: by 2002:a05:620a:1191:b0:783:f8cc:552 with SMTP id b17-20020a05620a119100b00783f8cc0552mr1262754qkk.27.1706702391725; Wed, 31 Jan 2024 03:59:51 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1706702391; cv=none; d=google.com; s=arc-20160816; b=GqUqQroRGlH3HCy2WPz407NAYQeOSkxrp3bTfPIvR8J8DuZcv5M4z9rC6Mu3YtiedX JIw4TRnrCkzs6a5juIRHpIM8KlF8vfJ50D517Pa0zn9IZwSS17d7Lsf4dsBDFo9taYYr IEJGPWNTY19Quaww4RmsYShPwCTHYpAM69jGEt15bD5n+uEU5cX4ElEpazVO2JtjkQrE Mm8MBz+oIuuXrLU3GM6CC4fw4p78jJKluzZ/MgFdDkbJRZ8RpbZOQ+lIYfLT73zsOsdN djiAS7K4fVxH9Gj9pSQRHr6M+O42O/7cnDcOEu5oS7mGf6LL2ITZ7iJkQ1bfPzYIQE/N juYg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from; bh=mE1Slv9huIEmb+MIvdlL2Zhw0Qhgjqlt44VpmIS7yoA=; fh=PTg4bTcesFEEyIpE8EOS4Lzu43waRU5ih7DhHOCb5NQ=; b=cXw2INSB4Mi52cs4xwItEDsBxUeHSYrX0l8L4NvRmHtZuisz7CGUMS1g+MxGX7pvAW WYfvG3Sa5oH9GMYX0HlfZ90wREjBBuUWJbGKVOBK70DrSi2Kbx/0j7PdMq4ND8V8iF0+ oC/Iw8cmzG26TtSsoADYYvQx8nXVXzEXap9KCc/dWnnva7kWOtfMKwZ8GwiKdWm3oHni j1KJFFrIQ5gVWv3ynnXGiqvOk/zjxZ6HRlQQdy6f74Mj4qZ2BmkeU93JQ/PaKVs6GEFK hJsU6L/pdIhmLbHB86NsYrRAh2uoKnKfAI4i09tq2+PMG435Eq6ZUQOFXeRYX/GxqOfV qPjg==; darn=linaro.org ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org" X-Forwarded-Encrypted: i=0; AJvYcCVwM8+BtYugEFUhdXAt2Gj/Xd09iHzlMRbZtoqKF+t8NZL+8LR9KletNgT1Kn/vSzbiPIoweYPVDHkKSaLZkFAz Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id bq40-20020a05620a46a800b0078538825194si1653383qkb.421.2024.01.31.03.59.51 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Wed, 31 Jan 2024 03:59:51 -0800 (PST) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org" Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rV9Cx-0001JQ-VD; Wed, 31 Jan 2024 06:56:48 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rV9Cw-0001IY-Rb; Wed, 31 Jan 2024 06:56:46 -0500 Received: from isrv.corpit.ru ([86.62.121.231]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rV9Cv-00041W-5m; Wed, 31 Jan 2024 06:56:46 -0500 Received: from tsrv.corpit.ru (tsrv.tls.msk.ru [192.168.177.2]) by isrv.corpit.ru (Postfix) with ESMTP id B8080490CE; Wed, 31 Jan 2024 14:56:47 +0300 (MSK) Received: from tls.msk.ru (mjt.wg.tls.msk.ru [192.168.177.130]) by tsrv.corpit.ru (Postfix) with SMTP id EED4F70277; Wed, 31 Jan 2024 14:55:50 +0300 (MSK) Received: (nullmailer pid 2263960 invoked by uid 1000); Wed, 31 Jan 2024 11:55:49 -0000 From: Michael Tokarev To: qemu-devel@nongnu.org Cc: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= , qemu-trivial@nongnu.org, Michael Tokarev Subject: [PULL 16/21] backends/hostmem: Fix block comments style (checkpatch.pl warnings) Date: Wed, 31 Jan 2024 14:55:44 +0300 Message-Id: <20240131115549.2263854-17-mjt@tls.msk.ru> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240131115549.2263854-1-mjt@tls.msk.ru> References: <20240131115549.2263854-1-mjt@tls.msk.ru> MIME-Version: 1.0 Received-SPF: pass client-ip=86.62.121.231; envelope-from=mjt@tls.msk.ru; helo=isrv.corpit.ru X-Spam_score_int: -68 X-Spam_score: -6.9 X-Spam_bar: ------ X-Spam_report: (-6.9 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_HI=-5, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org From: Philippe Mathieu-Daudé While re-indenting code in host_memory_backend_memory_complete(), we triggered various "Block comments use a leading /* on a separate line" warnings from checkpatch.pl. Correct the comments style. Fixes: e199f7ad4d ("backends: Simplify host_memory_backend_memory_complete()") Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Xiaoyao Li Signed-off-by: Michael Tokarev --- backends/hostmem.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/backends/hostmem.c b/backends/hostmem.c index 30f69b2cb5..987f6f591e 100644 --- a/backends/hostmem.c +++ b/backends/hostmem.c @@ -344,9 +344,11 @@ host_memory_backend_memory_complete(UserCreatable *uc, Error **errp) unsigned long lastbit = find_last_bit(backend->host_nodes, MAX_NODES); /* lastbit == MAX_NODES means maxnode = 0 */ unsigned long maxnode = (lastbit + 1) % (MAX_NODES + 1); - /* ensure policy won't be ignored in case memory is preallocated + /* + * Ensure policy won't be ignored in case memory is preallocated * before mbind(). note: MPOL_MF_STRICT is ignored on hugepages so - * this doesn't catch hugepage case. */ + * this doesn't catch hugepage case. + */ unsigned flags = MPOL_MF_STRICT | MPOL_MF_MOVE; int mode = backend->policy; @@ -363,7 +365,8 @@ host_memory_backend_memory_complete(UserCreatable *uc, Error **errp) return; } - /* We can have up to MAX_NODES nodes, but we need to pass maxnode+1 + /* + * We can have up to MAX_NODES nodes, but we need to pass maxnode+1 * as argument to mbind() due to an old Linux bug (feature?) which * cuts off the last specified node. This means backend->host_nodes * must have MAX_NODES+1 bits available. @@ -391,7 +394,8 @@ host_memory_backend_memory_complete(UserCreatable *uc, Error **errp) } } #endif - /* Preallocate memory after the NUMA policy has been instantiated. + /* + * Preallocate memory after the NUMA policy has been instantiated. * This is necessary to guarantee memory is allocated with * specified NUMA policy in place. */