All of lore.kernel.org
 help / color / mirror / Atom feed
* [tiwai-sound:test/sound-rust-v7.3 42/56] warning: `as` casting between raw pointers without changing their constness
@ 2026-11-06 21:06 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2026-11-06 21:06 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: oe-kbuild-all, alsa-devel

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git test/sound-rust-v7.3
head:   070444a8abf14da700680a5331d0a95cd11e578b
commit: b172ad8bf456b4d29c21afeebf24dba090c8a62e [42/56] rust: usb: Add safe mutable isochronous methods to Urb and UrbData
config: x86_64-rhel-9.4-rust (https://download.01.org/0day-ci/archive/20261106/202611062249.snPBEWys-lkp@intel.com/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/20261106/202611062249.snPBEWys-lkp@intel.com/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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202611062249.snPBEWys-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> warning: `as` casting between raw pointers without changing their constness
   --> rust/kernel/usb.rs:883:21
   |
   883 |                     urb.transfer_buffer as *mut u8,
   |                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try `pointer::cast`, a safer alternative: `urb.transfer_buffer.cast::<u8>()`
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#ptr_as_ptr
   = note: requested on the command line with `-W clippy::ptr-as-ptr`
--
>> warning: `as` casting between raw pointers without changing their constness
   --> rust/kernel/usb.rs:913:21
   |
   913 |                     urb.transfer_buffer as *mut u8,
   |                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try `pointer::cast`, a safer alternative: `urb.transfer_buffer.cast::<u8>()`
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#ptr_as_ptr
--
>> warning: `as` casting between raw pointers without changing their constness
   --> rust/kernel/usb.rs:982:24
   |
   982 |         unsafe { &mut *(self.urb.as_ptr() as *mut Urb<T>) }
   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try `pointer::cast`, a safer alternative: `self.urb.as_ptr().cast::<Urb<T>>()`
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.96.0/index.html#ptr_as_ptr

--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2026-11-06 21:07 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-06 21:06 [tiwai-sound:test/sound-rust-v7.3 42/56] warning: `as` casting between raw pointers without changing their constness kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.