Re: [PATCH v6] rust: aref: make `AlwaysRefCounted::inc_ref` an associated function
kernel test robot <[email protected]> Mon, 3 Aug 2026 22:29:36 +0800
| Newsgroups | org.kernel.vger.rust-for-linux,dev.linux.lists.driver-core,dev.linux.lists.llvm,dev.linux.lists.oe-kbuild-all,org.kernel.vger.linux-block,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <[email protected]> |
Hi Trevor, kernel test robot noticed the following build errors: [auto build test ERROR on rust/rust-next] [also build test ERROR on driver-core/driver-core-testing driver-core/driver-core-next driver-core/driver-core-linus drm/drm-next drm-misc/drm-misc-next akpm-mm/mm-everything linus/master v7.2-rc6] [cannot apply to next-20260731] [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/Trevor-Chan/rust-aref-make-AlwaysRefCounted-inc_ref-an-associated-function/20260803-160221 base: https://github.com/Rust-for-Linux/linux rust-next patch link: https://lore.kernel.org/r/20260628095132.47753-1-trev%40trevrosa.dev patch subject: [PATCH v6] rust: aref: make `AlwaysRefCounted::inc_ref` an associated function config: x86_64-buildonly-randconfig-001-20260803 (https://download.01.org/0day-ci/archive/20260803/[email protected]/config) compiler: clang version 22.1.3 (https://github.com/llvm/llvm-project e9846648fd6183ee6d8cbdb4502213fcf902a211) rustc: rustc 1.96.0 (ac68faa20 2026-05-25) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260803/[email protected]/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 <[email protected]> | Closes: https://lore.kernel.org/oe-kbuild-all/[email protected]/ All errors (new ones prefixed by >>): >> error[E0424]: expected value, found module `self` --> rust/kernel/pwm.rs:637:50 | 634 | fn inc_ref(obj: &Self) { | ------- this function doesn't have a `self` parameter ... 637 | unsafe { bindings::get_device(&raw mut (*self.0.get()).dev) }; | ^^^^ `self` value is a keyword only available in methods with a `self` parameter | help: add a `self` receiver parameter to make the associated `fn` a method | 634 | fn inc_ref(&self, obj: &Self) { | ++++++ -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki