From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 D117B2D24B7 for ; Thu, 15 Jan 2026 21:57:34 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768514254; cv=none; b=Q4q5xF3ZSXsZPgG60bm53fO7jIQE85yv/frrY8JOiSCvrrmEFNFok6Peg8s5Q8hMoZKIncZZMs/fYvufNTP9iA2BkqEThIibPR7AH3GezV83RVTLSOIpUAT5q+WPjzzkcm2Z4vAzkww8lpfSaBE0qRlBhMKo65Yd/i08ukjQidM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1768514254; c=relaxed/simple; bh=FojpOiLAXUy8PRO6EnBczv5H+af01sTZZJr44RU5hig=; h=Date:From:To:Cc:Subject:Message-Id:In-Reply-To:References: Mime-Version:Content-Type; b=kXML8gIqVuKWmE7iUy2hAYnduClQIxt0T3O8hNSwLl/WqEeeL5QIwBTjyUkNUTKIzhXwHLftmkVQjq+fJsxmtcNe2XDHOj1XgeNix6iKurU7tRE/0MCao7w4q1sNQkkOEqi13Hnxr1eOfguqYInwWdGQM+IkA2JhtW/UacsGSfI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b=VFBjGK/T; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linux-foundation.org header.i=@linux-foundation.org header.b="VFBjGK/T" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 1AFD1C116D0; Thu, 15 Jan 2026 21:57:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1768514254; bh=FojpOiLAXUy8PRO6EnBczv5H+af01sTZZJr44RU5hig=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=VFBjGK/ThAVVKbG1zjNk4C+8Sw40IM0eslRG7Ea92qvFMUa95KS+YydlkyayI99xH cDawAoePrHk+EdhNFx54QW5+LSbF/7ExaRuwVNAlvlOOi7aXSBJk+5bTuTLMheq7A8 QFhLedJthc6ACUZM2VON6iVGAuSe68HiXszWBSrc= Date: Thu, 15 Jan 2026 13:57:33 -0800 From: Andrew Morton To: Joshua Hahn Cc: "David Hildenbrand (Red Hat)" , Muchun Song , Oscar Salvador , linux-kernel@vger.kernel.org, linux-mm@kvack.org Subject: Re: [PATCH 3/3] mm/hugetlb: Enforce brace style Message-Id: <20260115135733.27537586dc0716620c6b1180@linux-foundation.org> In-Reply-To: <20260115211446.1429024-1-joshua.hahnjy@gmail.com> References: <20260115211446.1429024-1-joshua.hahnjy@gmail.com> X-Mailer: Sylpheed 3.7.0 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On Thu, 15 Jan 2026 16:14:46 -0500 Joshua Hahn wrote: > On Thu, 15 Jan 2026 21:10:41 +0100 "David Hildenbrand (Red Hat)" wrote: > > > On 1/15/26 19:14, Joshua Hahn wrote: > > > Documentation/process/coding-style.rst explicitly notes that if only one > > > branch of a conditional statement is a single statement, braces should > > > be used in both branches. Enforce this in mm/hugetlb.c. > > > > > > No functional change intended. > > > > > > Signed-off-by: Joshua Hahn > > > --- > > > > [...] > > > > > update_and_free_hugetlb_folio(h, folio, false); > > > return rc; > > > @@ -2672,11 +2675,13 @@ void restore_reserve_on_error(struct hstate *h, struct vm_area_struct *vma, > > > * be consumed on a subsequent allocation. > > > */ > > > folio_set_hugetlb_restore_reserve(folio); > > > - } else > > > + } else { > > > /* > > > * No reservation present, do nothing > > > */ > > > vma_end_reservation(h, vma, address); > > > + > > > > But why the empty line? :) > > Hello David, > > Whoops, I totally forgot to run checkpatch on this one. I think Andrew > also noticed this, he sent a fixlet for it. I did. > Sorry for this! I'll fix it up in v2. I'm not actually seeing a need for a v2, unless something else changed?