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 C4D272DF68; Wed, 13 Aug 2025 16:49:05 +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=1755103745; cv=none; b=GrdMyOYUXLlFeY8+R1qihVLXs/gjB86Jh+uyWe57lQlf5H/jb2k9Y4M6eRb3d9OGWZ8kWbjkfD3G19gVYxrdecX64j6yXUKb21//eVIymfEyeJgVE+w7Af8cC+nOVYZJZy+KfXsp3ZzQLRJxpYB7zC7Ru68n3njz4ase6Y8ygs4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1755103745; c=relaxed/simple; bh=cyLrFdqxg4ZcH8nvggubxn/CxJcfjbfe1JuA4ehDYXQ=; h=Mime-Version:Content-Type:Date:Message-Id:Subject:Cc:To:From: References:In-Reply-To; b=FlScgC96Krz/mlLkiN5PrpIbI99vMPHdhPs5+AJHhtMbI+jpNpIX2ty/aEuDqDUdh+mnpu2NEDfGlWQq+q0dvppP6QiQd++QT2IkqsDSxQcZaYHBbM9ynTWfBqAFXp/MA46MNqzByVjU/zettxIlOkmCci9chjDjghucjVYOq5I= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=RguiXv+U; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="RguiXv+U" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 382C2C4CEEF; Wed, 13 Aug 2025 16:49:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1755103745; bh=cyLrFdqxg4ZcH8nvggubxn/CxJcfjbfe1JuA4ehDYXQ=; h=Date:Subject:Cc:To:From:References:In-Reply-To:From; b=RguiXv+UZoL+5Vf31csyIKrWunI2aX3ipzcjHK5Kyy9/TsmFF46g5XjoQamZStLtI eRMI0tsEpu1+rngNBb27ZSZAcg2XutpBc8Wh7jxBNkmljUEmXVrNV7nTxZSMoK4J+i VrRmXeieHSnbweU3unIIizYq7jbHTbcNxjKoBeN7shrbvGnL8aZBbtVQ4NFTimeeIJ zRWusjneQDhKYrdo5ws2NbSKAHUOSKOf6mhQjUY013m7N9hVBsoq0NBLIu8cQNJJ/5 s/aISnoOB2FxjhsjNUmox3r5TF4+V+DazWKzvgD4LkIydtpFX9oV0I2KKSZsxx1o26 H5IZsphCZYhBQ== Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 Date: Wed, 13 Aug 2025 18:48:59 +0200 Message-Id: Subject: Re: [PATCH v7 1/3] rust: allocator: add KUnit tests for alignment guarantees Cc: "Lorenzo Stoakes" , "Vlastimil Babka" , "Liam R . Howlett" , "Uladzislau Rezki" , "Miguel Ojeda" , "Alex Gaynor" , "Boqun Feng" , "Gary Guo" , , "Benno Lossin" , "Andreas Hindborg" , "Alice Ryhl" , "Trevor Gross" , , , , "Hui Zhu" , "Geliang Tang" , "Kunwu Chan" To: "Hui Zhu" , "Andrew Morton" From: "Danilo Krummrich" References: In-Reply-To: On Thu Jul 31, 2025 at 11:19 AM CEST, Danilo Krummrich wrote: > On Thu Jul 31, 2025 at 4:50 AM CEST, Hui Zhu wrote: >> From: Hui Zhu >> >> Add a test module to verify memory alignment guarantees for Rust kernel >> allocators. >> The tests cover `Kmalloc`, `Vmalloc` and `KVmalloc` allocators >> with both standard and large page-aligned allocations. >> >> Key features of the tests: >> 1. Creates alignment-constrained types: >> - 128-byte aligned `Blob` >> - 8192-byte (4-page) aligned `LargeAlignBlob` >> 2. Validates allocators using `TestAlign` helper which: >> - Checks address alignment masks >> - Supports uninitialized allocations >> 3. Tests all three allocators with both alignment requirements: >> - Kmalloc with 128B and 8192B >> - Vmalloc with 128B and 8192B >> - KVmalloc with 128B and 8192B >> >> Co-developed-by: Geliang Tang >> Signed-off-by: Geliang Tang >> Signed-off-by: Hui Zhu >> Reviewed-by: Kunwu Chan > > Acked-by: Danilo Krummrich > > @Andrew: Can you please pick this one up once we land Vitaly's series [1]= ? I'll > take the other two patches of the series through the Rust alloc tree once= -rc1 > is out. Just a reminder for this one to be picked up; I gave it a quick shot on top= of mm-everything and everything looks fine.. > [1] https://lore.kernel.org/lkml/20250730191921.352591-1-vitaly.wool@kons= ulko.se/