Re: [PATCH v2] rust: file: handle fd table teardown in file descriptor APIs
From: kernel test robot
Date: Mon Sep 28 2026 - 06:48:12 EST
Hi Georgios,
kernel test robot noticed the following build warnings:
[auto build test WARNING on brauner-vfs/vfs.all]
[also build test WARNING on linus/master v7.3-rc5 next-20260925]
[cannot apply to linux-review/Georgios-Androutsopoulos/rust-file-handle-fd-table-teardown-in-file-descriptor-APIs/20260920-160154]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Georgios-Androutsopoulos/rust-file-handle-fd-table-teardown-in-file-descriptor-APIs/20260922-222339
base: https://git.kernel.org/pub/scm/linux/kernel/git/vfs/vfs.git vfs.all
patch link: https://lore.kernel.org/r/20260923022339.3340694-1-georgeandrout13%40gmail.com
patch subject: [PATCH v2] rust: file: handle fd table teardown in file descriptor APIs
config: x86_64-rhel-9.4-rust (https://download.01.org/0day-ci/archive/20260928/202609281234.H1AixLDP-lkp@xxxxxxxxx/config)
compiler: clang version 22.1.8 (https://github.com/llvm/llvm-project ca7933e47d3a3451d81e72ac174dcb5aa28b59d1)
rustc: rustc 1.96.0 (ac68faa20 2026-05-25)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260928/202609281234.H1AixLDP-lkp@xxxxxxxxx/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202609281234.H1AixLDP-lkp@xxxxxxxxx/
All warnings (new ones prefixed by >>):
>> warning: statement has unnecessary safety comment
--> rust/kernel/fs/file.rs:455:9
|
455 | / if crate::warn_on!(unsafe { (*current.as_ptr()).files.is_null() }) {
456 | | // `put_unused_fd` also requires `current->files` to be valid, so do not run
457 | | // the reservation's destructor after the current task has lost its fd table.
458 | | core::mem::forget(self);
459 | | return;
460 | | }
| |_________^
|
help: consider removing the safety comment
--> rust/kernel/fs/file.rs:452:12
|
452 | // SAFETY: `current` points to the currently executing task, so it is
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
= help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#unnecessary_safety_comment
= note: requested on the command line with `-W clippy::unnecessary-safety-comment`
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki