From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out-172.mta0.migadu.com (out-172.mta0.migadu.com [91.218.175.172]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id B88533612E0 for ; Mon, 10 Aug 2026 09:32:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=91.218.175.172 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786354375; cv=none; b=EtzKeuy/7nTZuNaXs/iwjD2p6F0x2SfvQKs/cRj6ucD8TNdKIwYEoqj2uWCPSCSXM2ohQrezydle673sNzxP3VcGGj5rMqV5DzhtWz8Gnm4+G5XMnZpgOPN6DtRfxbS9/NiRy2OvynG+9mZrBUWjz2CZe73CyLe+ZU22wEbOOMQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786354375; c=relaxed/simple; bh=lIW+WebqeEoZcyPCSLK0czTHF+vyCRMIWDCHXE/Ufms=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version; b=Lg+zbHd351CGncU6qdEyfxVajIMieNL6uqnYq0wDZb44+NeeY0KmEkjwccz1gDIRCzQIV2k1Cf1UNqbQ6e6lzDwZP1PvbUO0krMiNkJIRvvbjV60iBsDCf0Gc+PPLqK9huHZzhLvcYtDdCN9+SBkUY6Oy+y4qEQi92v70gFIiyE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev; spf=pass smtp.mailfrom=linux.dev; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b=YQ4BDv4R; arc=none smtp.client-ip=91.218.175.172 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.dev Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=linux.dev Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux.dev header.i=@linux.dev header.b="YQ4BDv4R" X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1786354370; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=1XFvf8w7v4DlH4awXePCLi5hpsAxTi4mLDtG0/Z7htc=; b=YQ4BDv4RX2WwPEQQ8BDcG8Gcq6JLVa1hpEWCKM99bA9S3peEMMpAk8oBV8UdN9q8UQGp/+ DK8Md6OeiEHLJNqs2JPPgdIZ36XJxVHDmBhIBL0fMO0+ZFEUrvt89NA2E16Q3nWPTag45Z Mo1CpT9o3bEsknJcgTNtKV4iWQKZWI8= From: Hongfu Li To: akpm@linux-foundation.org, david@kernel.org, ljs@kernel.org, liam@infradead.org, vbabka@kernel.org, rppt@kernel.org, surenb@google.com, mhocko@suse.com Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, hongfu.li@linux.dev, Hongfu Li Subject: [PATCH] mm/cma: remove stray newline from auto-generated CMA area name Date: Mon, 10 Aug 2026 17:32:15 +0800 Message-ID: <20260810093215.91419-1-hongfu.li@linux.dev> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT From: Hongfu Li When no name is supplied, cma_new_area() generates names with format "cma%d\n", introducing an unintended newline character ('\n') in the CMA name. Most CMA regions are created with explicit names, so this path is seldom hit. The newline only creates cosmetic noise in debug logs, traces and debugfs with no functional impact. Signed-off-by: Hongfu Li --- mm/cma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/cma.c b/mm/cma.c index a7929c758df1..a10ea37a261d 100644 --- a/mm/cma.c +++ b/mm/cma.c @@ -242,7 +242,7 @@ static int __init cma_new_area(const char *name, phys_addr_t size, if (name) strscpy(cma->name, name); else - snprintf(cma->name, CMA_MAX_NAME, "cma%d\n", cma_area_count); + snprintf(cma->name, CMA_MAX_NAME, "cma%d", cma_area_count); cma->available_count = cma->count = size >> PAGE_SHIFT; cma->order_per_bit = order_per_bit; -- 2.54.0